mirror of
https://github.com/alkimake/paperclip.git
synced 2026-06-19 12:10:37 +09:00
## Thinking Path > - Paperclip orchestrates AI agents for zero-human companies. > - This branch extends the issue control-plane so board operators can pause, cancel, and later restore whole issue subtrees while keeping descendant execution and wake behavior coherent. > - That required new hold state in the database, shared contracts, server routes/services, and issue detail UI controls so subtree actions are durable and auditable instead of ad hoc. > - While this branch was in flight, `master` advanced with new environment lifecycle work, including a new `0065_environments` migration. > - Before opening the PR, this branch had to be rebased onto `paperclipai/paperclip:master` without losing the existing subtree-control work or leaving conflicting migration numbering behind. > - This pull request rebases the subtree pause/cancel/restore feature cleanly onto current `master`, renumbers the hold migration to `0066_issue_tree_holds`, and preserves the full branch diff in a single PR. > - The benefit is that reviewers get one clean, mergeable PR for the subtree-control feature instead of stale branch history with migration conflicts. ## What Changed - Added durable issue subtree hold data structures, shared API/types/validators, server routes/services, and UI flows for subtree pause, cancel, and restore operations. - Added server and UI coverage for subtree previewing, hold creation/release, dependency-aware scheduling under holds, and issue detail subtree controls. - Rebased the branch onto current `paperclipai/paperclip:master` and renumbered the branch migration from `0065_issue_tree_holds` to `0066_issue_tree_holds` so it no longer conflicts with upstream `0065_environments`. - Added a small follow-up commit that makes restore requests return `200 OK` explicitly while keeping pause/cancel hold creation at `201 Created`, and updated the route test to match that contract. ## Verification - `pnpm --filter @paperclipai/db typecheck` - `pnpm --filter @paperclipai/shared typecheck` - `pnpm --filter @paperclipai/server typecheck` - `pnpm --filter @paperclipai/ui typecheck` - `cd server && pnpm exec vitest run src/__tests__/issue-tree-control-routes.test.ts src/__tests__/issue-tree-control-service.test.ts src/__tests__/issue-tree-control-service-unit.test.ts src/__tests__/heartbeat-dependency-scheduling.test.ts` - `cd ui && pnpm exec vitest run src/components/IssueChatThread.test.tsx src/pages/IssueDetail.test.tsx` ## Risks - This is a broad cross-layer change touching DB/schema, shared contracts, server orchestration, and UI; regressions are most likely around subtree status restoration or wake suppression/resume edge cases. - The migration was renumbered during PR prep to avoid the new upstream `0065_environments` conflict. Reviewers should confirm the final `0066_issue_tree_holds` ordering is the only hold-related migration that lands. - The issue-tree restore endpoint now responds with `200` instead of relying on implicit behavior, which is semantically better for a restore operation but still changes an API detail that clients or tests could have assumed. > For core feature work, check [`ROADMAP.md`](ROADMAP.md) first and discuss it in `#dev` before opening the PR. Feature PRs that overlap with planned core work may need to be redirected — check the roadmap first. See `CONTRIBUTING.md`. ## Model Used - OpenAI Codex coding agent in the Paperclip Codex runtime (GPT-5-class tool-using coding model; exact deployment ID/context window is not exposed inside this session). ## Checklist - [x] I have included a thinking path that traces from project context to this change - [x] I have specified the model used (with version and capability details) - [x] I have checked ROADMAP.md and confirmed this PR does not duplicate planned core work - [x] I have run tests locally and they pass - [x] I have added or updated tests where applicable - [ ] If this change affects the UI, I have included before/after screenshots - [ ] I have updated relevant documentation to reflect my changes - [x] I have considered and documented any risks above - [x] I will address all Greptile and reviewer comments before requesting merge --------- Co-authored-by: Paperclip <noreply@paperclip.ing>
72 lines
4.1 KiB
TypeScript
72 lines
4.1 KiB
TypeScript
export { companies } from "./companies.js";
|
|
export { companyLogos } from "./company_logos.js";
|
|
export { authUsers, authSessions, authAccounts, authVerifications } from "./auth.js";
|
|
export { instanceSettings } from "./instance_settings.js";
|
|
export { instanceUserRoles } from "./instance_user_roles.js";
|
|
export { userSidebarPreferences } from "./user_sidebar_preferences.js";
|
|
export { agents } from "./agents.js";
|
|
export { boardApiKeys } from "./board_api_keys.js";
|
|
export { cliAuthChallenges } from "./cli_auth_challenges.js";
|
|
export { companyMemberships } from "./company_memberships.js";
|
|
export { companyUserSidebarPreferences } from "./company_user_sidebar_preferences.js";
|
|
export { principalPermissionGrants } from "./principal_permission_grants.js";
|
|
export { invites } from "./invites.js";
|
|
export { joinRequests } from "./join_requests.js";
|
|
export { budgetPolicies } from "./budget_policies.js";
|
|
export { budgetIncidents } from "./budget_incidents.js";
|
|
export { agentConfigRevisions } from "./agent_config_revisions.js";
|
|
export { agentApiKeys } from "./agent_api_keys.js";
|
|
export { agentRuntimeState } from "./agent_runtime_state.js";
|
|
export { agentTaskSessions } from "./agent_task_sessions.js";
|
|
export { agentWakeupRequests } from "./agent_wakeup_requests.js";
|
|
export { projects } from "./projects.js";
|
|
export { projectWorkspaces } from "./project_workspaces.js";
|
|
export { executionWorkspaces } from "./execution_workspaces.js";
|
|
export { environments } from "./environments.js";
|
|
export { environmentLeases } from "./environment_leases.js";
|
|
export { workspaceOperations } from "./workspace_operations.js";
|
|
export { workspaceRuntimeServices } from "./workspace_runtime_services.js";
|
|
export { projectGoals } from "./project_goals.js";
|
|
export { goals } from "./goals.js";
|
|
export { issues } from "./issues.js";
|
|
export { issueReferenceMentions } from "./issue_reference_mentions.js";
|
|
export { issueRelations } from "./issue_relations.js";
|
|
export { routines, routineTriggers, routineRuns } from "./routines.js";
|
|
export { issueWorkProducts } from "./issue_work_products.js";
|
|
export { labels } from "./labels.js";
|
|
export { issueLabels } from "./issue_labels.js";
|
|
export { issueApprovals } from "./issue_approvals.js";
|
|
export { issueComments } from "./issue_comments.js";
|
|
export { issueThreadInteractions } from "./issue_thread_interactions.js";
|
|
export { issueTreeHolds } from "./issue_tree_holds.js";
|
|
export { issueTreeHoldMembers } from "./issue_tree_hold_members.js";
|
|
export { issueExecutionDecisions } from "./issue_execution_decisions.js";
|
|
export { issueInboxArchives } from "./issue_inbox_archives.js";
|
|
export { inboxDismissals } from "./inbox_dismissals.js";
|
|
export { feedbackVotes } from "./feedback_votes.js";
|
|
export { feedbackExports } from "./feedback_exports.js";
|
|
export { issueReadStates } from "./issue_read_states.js";
|
|
export { assets } from "./assets.js";
|
|
export { issueAttachments } from "./issue_attachments.js";
|
|
export { documents } from "./documents.js";
|
|
export { documentRevisions } from "./document_revisions.js";
|
|
export { issueDocuments } from "./issue_documents.js";
|
|
export { heartbeatRuns } from "./heartbeat_runs.js";
|
|
export { heartbeatRunEvents } from "./heartbeat_run_events.js";
|
|
export { costEvents } from "./cost_events.js";
|
|
export { financeEvents } from "./finance_events.js";
|
|
export { approvals } from "./approvals.js";
|
|
export { approvalComments } from "./approval_comments.js";
|
|
export { activityLog } from "./activity_log.js";
|
|
export { companySecrets } from "./company_secrets.js";
|
|
export { companySecretVersions } from "./company_secret_versions.js";
|
|
export { companySkills } from "./company_skills.js";
|
|
export { plugins } from "./plugins.js";
|
|
export { pluginConfig } from "./plugin_config.js";
|
|
export { pluginCompanySettings } from "./plugin_company_settings.js";
|
|
export { pluginState } from "./plugin_state.js";
|
|
export { pluginEntities } from "./plugin_entities.js";
|
|
export { pluginDatabaseNamespaces, pluginMigrations } from "./plugin_database.js";
|
|
export { pluginJobs, pluginJobRuns } from "./plugin_jobs.js";
|
|
export { pluginWebhookDeliveries } from "./plugin_webhooks.js";
|
|
export { pluginLogs } from "./plugin_logs.js";
|