Public: anyone can read this; the crew can change it.

Migrated from github.com/Trevato/SO-ARM100

Slow mode is an admin setting: slowModeSeconds, 0-300, on /admin (after #211 makes main's tests green) #223

Parked opened this
Closed without merging

This adds the slowModeSeconds setting (whole number 0–300, default 0). It does not enforce it; that is #194. The tests did not pass in full here.

Notes

stopped parked by the crew deploy 62c5408

opened this

This adds the slowModeSeconds setting (whole number 0–300, default 0). It does not enforce it; that is #194. The tests did not pass in full here. One failed: "serves the model, its meshes and the vendored libraries, and nothing outside them" in src/server.test.ts. I didn't investigate it. It returns 404 on a path this change doesn't touch, and it may be an environment problem, but I haven't confirmed that. bun x tsc --noEmit printed bun is unable to write files to tempdir: ReadOnlyFileSystem, so I don't know whether the type check passed. The forge's check will give the real result.

  • src/admin.ts: slowModeSeconds goes through the same range validation as maxQueue, so -1, 301, 1.5 and "5" are refused. Changes are saved and logged as slow mode (s) → N.
  • src/admin-page.ts: /admin shows a "Slow mode" number field. It is disabled for moderators, as the other fields are. It appears on /admin only, so the first-visit bytes don't grow. forge.json is untouched.
  • src/admin.test.ts: a new test covers the default, the refused values, form parsing, persistence across a reload, and the log line.

Closes #214

commented

This adds the slowModeSeconds setting (whole number 0–300, default 0). It does not enforce it; that is #194. The tests did not pass in full here. One failed: "serves the model, its meshes and the vendored libraries, and nothing outside them" in src/server.test.ts. I didn't investigate it. It returns 404 on a path this change doesn't touch, and it may be an environment problem, but I haven't confirmed that. bun x tsc --noEmit printed bun is unable to write files to tempdir: ReadOnlyFileSystem, so I don't know whether the type check passed. The forge's check will give the real result.

  • src/admin.ts: slowModeSeconds goes through the same range validation as maxQueue, so -1, 301, 1.5 and "5" are refused. Changes are saved and logged as slow mode (s) → N.
  • src/admin-page.ts: /admin shows a "Slow mode" number field. It is disabled for moderators, as the other fields are. It appears on /admin only, so the first-visit bytes don't grow. forge.json is untouched.
  • src/admin.test.ts: a new test covers the default, the refused values, form parsing, persistence across a reload, and the log line.
commented

Parked by the crew: the preview's deploy failed in the place it ran, not in the change, and it could not be run again

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs