mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-30 13:20:54 +01:00
Make an archived isolated execution workspace usable again, so a terminal issue can resume without a dead end. Reopen the same workspace row: flip it back to active and rebuild the worktree. Do not create a new row and do not change any issue-to-workspace link, so every issue that shares the row keeps access. Add reopenClosedIsolatedExecutionWorkspaceForIssue in the execution workspace service. It binds the workspace to the issue company and project, accepts only an isolated workspace in a closed state, and fails closed with no workspace detail on a mismatch. It rebuilds the worktree first and publishes active only on success. A rebuild failure keeps the row closed and returns an error, so the caller never dispatches a run against a broken workspace. Fence a cleanup against a concurrent reopen. Every archive and every reopen raises a lifecycle generation stored in the workspace metadata. Reopen and the destructive cleanup paths take the same transaction-scoped Postgres advisory lock. A cleanup captures the generation it archived at and re-checks it under the lock before it deletes the worktree. A reopen that ran in between raises the generation, so the stale cleanup does nothing. The terminal-workspace reaper and the archive route both use this fence. Wire the reopen at the resume, checkout, and comment guards. Each guard runs after the route authorizes the request on the issue. A closed isolated workspace now reopens and the request continues, instead of a 409 dead end. A non-reopenable workspace returns 409 and a rebuild failure returns 503. Enable the comment composer for a reopened issue and show a hint that the next comment or resume rebuilds the worktree. Co-authored-by: Paperclip <noreply@paperclip.ing>
@paperclipai/ui
Published static assets for the Paperclip board UI.
What gets published
The npm package contains the production build under dist/. It does not ship the UI source tree or workspace-only dependencies.
Storybook
Storybook config, stories, and fixtures live under ui/storybook/.
pnpm --filter @paperclipai/ui storybook
pnpm --filter @paperclipai/ui build-storybook
Typical use
Install the package, then serve or copy the built files from node_modules/@paperclipai/ui/dist.