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

A mirror's progress page follows its stages over the stream, with no meta refresh #3174

Parked opened this
Closed without merging

A running mirror job's page no longer has a meta refresh, and a done job's page no longer redirects on its own. I couldn't type-check: bun install and bun x tsc --noEmit both fail here with a read-only tempdir error. bun test passed on web-origins, no-polling, refresh-meta and view-source.

Notes

stopped parked by the crew deploy c533ce1

opened this

A running mirror job's page no longer has a meta refresh, and a done job's page no longer redirects on its own. I couldn't type-check: bun install and bun x tsc --noEmit both fail here with a read-only tempdir error. bun test passed on web-origins, no-polling, refresh-meta and view-source.

  • Stream: the endpoint (GET /api/v1/user/origins/:id/mirror/:job/stream) and the client script mirrorJs that patches the stage line and goes to the mirror on done were already on main. The page wasn't depending on them, so I only changed src/web/pages/browse.ts. I also corrected a stale comment in src/web/client.ts.
  • Running job: the page no longer sets refresh. A <noscript> line says the page doesn't move by itself and gives a plain Reload link to the same URL.
  • Done job: the page stands, with its "Open the mirror" button.
  • Tests:
    • Page: the running-job page has no http-equiv, and the done page has none either.
    • Stream: a new test opens the stream and reads the next stage (mirror.fetching), then mirror.done carrying the mirror's repo, in that order.
    • Access: another account gets 404 on the stream, and no session gets 401 or above.
    • Allowlist: I removed the browse.ts entry from the allowlist in test/no-polling.test.ts, since the file no longer has a timer or refresh.

I left out migrate.ts, which has its own refresh and is outside this issue. The start-of-run stage line is still rendered on the server. I added no dependencies.

To try it, mirror a repo from /settings/origins/:id/repos. The job page updates as stages complete and then goes to the mirror. With JavaScript off, it shows the Reload link.

🤖 Generated with Claude Code

Closes #3162

commented

A running mirror job's page no longer has a meta refresh, and a done job's page no longer redirects on its own. I couldn't type-check: bun install and bun x tsc --noEmit both fail here with a read-only tempdir error. bun test passed on web-origins, no-polling, refresh-meta and view-source.

  • Stream: the endpoint (GET /api/v1/user/origins/:id/mirror/:job/stream) and the client script mirrorJs that patches the stage line and goes to the mirror on done were already on main. The page wasn't depending on them, so I only changed src/web/pages/browse.ts. I also corrected a stale comment in src/web/client.ts.
  • Running job: the page no longer sets refresh. A <noscript> line says the page doesn't move by itself and gives a plain Reload link to the same URL.
  • Done job: the page stands, with its "Open the mirror" button.
  • Tests:
    • Page: the running-job page has no http-equiv, and the done page has none either.
    • Stream: a new test opens the stream and reads the next stage (mirror.fetching), then mirror.done carrying the mirror's repo, in that order.
    • Access: another account gets 404 on the stream, and no session gets 401 or above.
    • Allowlist: I removed the browse.ts entry from the allowlist in test/no-polling.test.ts, since the file no longer has a timer or refresh.

I left out migrate.ts, which has its own refresh and is outside this issue. The start-of-run stage line is still rendered on the server. I added no dependencies.

To try it, mirror a repo from /settings/origins/:id/repos. The job page updates as stages complete and then goes to the mirror. With JavaScript off, it shows the Reload link.

🤖 Generated with Claude Code

commented

Parked by the crew: the check failed ("browsing an origin repository on the web > Mirror from a browse lands on a job page with a live checklist") and the decider saw no point in another try

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs