Start onboarding in chat and defer execution until the user chooses work (#22077)

## Thinking Path

> - Paperclip is the open source app people use to manage AI agents for
work.
> - Onboarding connects an agent and gives the user a place to discuss
work.
> - The previous flow created an execution task and project before the
user chose a scope.
> - A standing chat can gather the goal and clear exit criteria first.
> - This pull request opens chat after onboarding and starts a live
welcome after the chat is visible.
> - The agent proposes work for acceptance, or creates a task when the
user explicitly requests one.
> - Subscription setup and shared question state must work for this
first conversation to succeed.

## Linked Issues or Issue Description

**Subsystem affected**
Company onboarding, agent chat, local subscription setup, task
numbering, and shared interaction views.

**Problem or motivation**
The first session creates work before the user has agreed to a goal.
Standing chats consume task numbers. An answered chat question can
remain pending in the inbox. Claude code entry requires an extra click,
and switching from Claude to Codex can leave an incompatible model
selected.

**Proposed solution**
Open an owner-bound chat for every new company. Start a live welcome
after the chat paints in a visible tab. Gather scope in conversation and
use the existing task acceptance flow. Keep chat records out of the task
number sequence. Publish question responses to shared caches and cancel
stale reads. Submit pasted Claude codes once and wait for verified
sign-in before connecting.

**Alternatives considered**
A fixed welcome would not use the onboarding context. A hidden execution
task would still create work and consume a task number. Keep the
existing task proposal and acceptance contract instead.

**Roadmap alignment**
This improves the shipped Agent Chat and Personal & Shared AI Accounts
flows in ROADMAP.md. It does not add a separate execution or approval
system.

Related prior work: Refs #19643 and #19512. Related route handoff work:
Refs #12557. This change replaces the automatic first task with chat; it
also repairs the subscription and shared question state paths used
during that journey.

## What Changed

- Finish onboarding in agent chat for default and team-template
companies. Create no execution task or project.
- Queue one live welcome after visible chat content paints. Pass company
goals and the initial idea as context. Preserve access, budget, and
hiring controls.
- Instruct the agent to gather a goal and exit criteria, offer an
interview, and propose tasks for acceptance. Allow direct creation on an
explicit user request.
- Leave new standing chats unnumbered. The first execution task receives
number 1. Preserve existing identifiers.
- Synchronize answered question cards across chat and inbox, including
concurrent requests and inactive cached views.
- Submit a pasted Claude authorization code once. Show connection
progress and hide the restart link while sign-in is still preparing.
Detect rejected OAuth codes promptly. Clear incompatible models when the
provider changes.
- Use `Work with [agent name]` as the default chat composer placeholder.
- Add regression coverage and update onboarding documentation and API
notes.

## Verification

- Completed a real Claude subscription journey on macOS with an isolated
local database. Authorized the account, pasted the real code, and
reached the review step without clicking Submit code or Connect. Get
started opened chat and the live welcome run succeeded. The company had
zero execution tasks, zero projects, and task counter 0.
- On rebased commit c664949858, 6 browser cases passed for
paste-to-connect-to-chat, task-free onboarding, existing-company
routing, the native connection probe gate, desktop/mobile planning, and
two-tab chat/inbox question synchronization.
- On the rebased head, 419 focused UI tests passed. The focused server
and adapter run passed 160 tests and hit one `socket hang up` in the
existing authenticated chat route test. The full 72-test conversation
suite passed on one repeat. The cause of that first socket failure
remains unconfirmed; the passing repeat does not establish its cause.
- UI typecheck and server declaration typecheck pass after the rebase.
The first server check found a missing local dependency from master; a
frozen-lockfile install repaired it. No dependency manifest or lockfile
change was needed.
- The first Greptile review found two welcome edge cases. Four new tests
reproduced both before the fix. On commit b380f14ef9, all 114 onboarding
and queue tests pass, including timeout retries and queued welcomes
replaced by a user message or chat reset. Server source and focused test
type checks pass on this revision.
- [Greptile
review](https://github.com/paperclipai/paperclip/pull/22077#issuecomment-6961533641)
gives rebased commit 2dbad34445 a score of
5/5. The current-head check passed. Both welcome review threads are
resolved, with no new actionable findings.
- CI serialized shard 8/9 found a missing OpenAPI inventory entry for
the new route file. The exact coverage test reproduced this locally.
Commit 17a72ec8b7 adds explicit mounted paths and documents both
board-only operations. All 65 OpenAPI and onboarding route tests and
server source typecheck pass after the fix. The final CI run passes on
this revision.
- Rebased onto master 23ce68a8dc and regenerated the SDK source registry
from committed inputs. Worktree preflight, SDK source validation, and
all 65 API/onboarding tests pass on final head
2dbad34445.
- On final head 2dbad34445, all 419
affected UI tests pass. UI package typecheck and server declaration
typecheck also pass. Commands: `pnpm --filter @paperclipai/ui
typecheck`; `node server/scripts/typecheck-layers.mjs
--declarations-only`; focused Vitest suites for the wizard, subscription
login, agent chat, shared interaction cache, and OpenAPI/onboarding
routes.
- [Final-head CI
run](https://github.com/paperclipai/paperclip/actions/runs/44208652564)
completed successfully on commit
2dbad34445. All required typecheck, build,
test, Runner, browser, serialized-server, and canary gates pass,
including the [final verify
job](https://github.com/paperclipai/paperclip/actions/runs/44208652564/job/134487749343).
The fresh routing gate selected the trusted AWS fleet after the
protected owner policy in #22098 merged. No source rebase was needed:
the gate reads that policy from protected master.
- The repaired OpenAPI shard passed in the earlier same-head CI run.
General server shard 8/12 hit a 20-second step timeout in the existing
`issue-recovery-live-run-agent-census` suite. This PR does not change
that suite or its fixture. All four tests pass locally on the exact
current commit in 84 seconds. The cause of the CI timeout remains
unconfirmed. Every other test job passed. A single failed-shard retry
was accepted but remained queued on its saved GitHub-hosted selection.
It was cancelled before test execution after #22098 merged. The fresh
full-CI run passed on the unchanged head under the approved AWS policy,
including [server shard
8/12](https://github.com/paperclipai/paperclip/actions/runs/44208652564/job/134481388730).
This passing execution does not establish the cause of the earlier
timeout.
- Worktree preflight, committed SDK source input validation, and diff
whitespace checks pass after the rebase.
- `pnpm verify` reports exit 2 because the new subsystem documentation
requires broader CI coverage. The final successful CI run supplies that
broader coverage. This is not a full local suite pass.

## Risks

- The initial task is now an explicit user decision. Existing onboarding
tasks and numbered records remain readable. No schema migration is
required.
- A welcome still depends on a working provider connection and the
normal run queue. Failed starts can be retried without duplicate
successful welcomes.
- Claude paste acceptance was verified with a real subscription on
macOS. This change does not claim a new live Codex or Windows acceptance
test.

## Model Used

OpenAI Codex, based on GPT-6, with tool-assisted reasoning, code
execution, terminal checks, and browser verification. The client does
not expose the exact routed build or context limit.

## 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 searched GitHub for duplicate or related PRs and linked
them above
- [x] I have either (a) linked existing issues with `Fixes: #` / `Closes
#` / `Refs #` OR (b) described the issue in-PR following the relevant
issue template
- [x] I have not referenced internal/instance-local Paperclip issues or
links (only public GitHub `#NNN` / `github.com/paperclipai/paperclip`
URLs)
- [x] My branch name describes the change (e.g. `docs/...`, `fix/...`)
and contains no internal Paperclip ticket id or instance-derived details
- [x] I have run tests locally and they pass
- [x] I have added or updated tests where applicable
- [x] I have updated relevant documentation to reflect my changes
- [x] I have considered and documented any risks above
- [x] All Paperclip CI gates are green
- [x] Greptile is 5/5 with no open P2s, recommendations, or follow-ups
- [x] I will address all Greptile and reviewer comments before
requesting merge

---------

Co-authored-by: Scott Tong <scott@scottsmbpm5max.lan>
Co-authored-by: Paperclip <noreply@paperclip.ing>
This commit is contained in:
authored and GitHub committed 2026-11-17 16:52:35 -08:00
1 parent 96907f5518
commit ce27dde855
57 files changed
+1156 -509

No files matched your search

+26
View File
@@ -4,6 +4,32 @@ import { idle, json, send, setup } from "./agent-chat.shared";
test.use({ trace: "retain-on-failure" });
test.setTimeout(120_000);
test("answering questions in chat and inbox updates both open surfaces", async ({ page, request, context }) => {
const f = await setup(request);
const inbox = await context.newPage();
try {
await page.goto(f.route);
for (const answerIn of ["chat", "inbox"] as const) {
await send(page, { action: "question" });
await expect(page.getByRole("radio", { name: "Garden club", exact: true }).last()).toBeVisible({ timeout: 45_000 });
if (answerIn === "chat") await inbox.goto(`/${f.company.issuePrefix}/decisions`);
const inboxQuestion = inbox.getByRole("radio", { name: "Garden club", exact: true });
await expect(inboxQuestion).toBeVisible({ timeout: 20_000 });
const answeringPage = answerIn === "chat" ? page : inbox;
await answeringPage.getByRole("radio", { name: "Garden club", exact: true }).last().click();
await answeringPage.getByRole("button", { name: "Submit answers", exact: true }).last().click();
await expect(inboxQuestion).toHaveCount(0, { timeout: 20_000 });
await expect(page.getByRole("radio", { name: "Garden club", exact: true })).toHaveCount(0, { timeout: 20_000 });
const chat = await json(await request.get(f.chatPath));
await expect.poll(async () => {
const feed = await json(await request.get(`/api/companies/${f.company.id}/attention?all=true&view=mine`));
return feed.items.filter((item: any) => item.sourceKind === "issue_thread_interaction" && item.relatedIssue?.id === chat.id).length;
}).toBe(0);
await idle(request, f.chatPath, answerIn === "chat" ? 2 : 4);
}
} finally { await inbox.close(); await f.restore(); }
});
test("a routine delivers a first digest, unread state, source link and replyable history", async ({ page, request }) => {
const f = await setup(request);
try {
+69 -45
View File
@@ -1,25 +1,12 @@
import { test, expect, type Page } from "@playwright/test";
import { mockOnboardingLocalAiConnection } from "./helpers/onboarding-ai-connection";
import {
expectLandsOnFirstTaskWithoutDashboardBounce,
expectLandsOnChatWithoutDashboardBounce,
instrumentNavLog,
} from "./helpers/onboarding-landing";
/**
* E2E: post-wizard onboarding launch.
*
* Completing the onboarding wizard now creates the first assigned task and
* drops the user straight onto that task's detail page (not the dashboard),
* so they land in the conversation the agent will start in. The chat intro
* still has unit coverage in BoardChat tests.
*
* PAP-404: onboarding used to intermittently bounce to the company dashboard.
* The bounce only reproduces when the instance already has ≥1 company (the
* board's test ports), so the second test seeds a company first to exercise
* exactly that failing condition.
*/
const FIRST_TASK_TITLE = "Paperclip onboarding";
/** Post-wizard onboarding opens the standing chat without execution work.
* PAP-404: company page memory must not bounce the new chat to the dashboard. */
/**
* Intercept authentication, environment checks, and hiring so no real CLI check
@@ -28,6 +15,13 @@ const FIRST_TASK_TITLE = "Paperclip onboarding";
*/
async function installLaunchIntercepts(page: Page, baseURL?: string) {
await mockOnboardingLocalAiConnection(page);
// Keep the inert provider from starting; verify the welcome is requested only
// after navigation and the conversation composer are visible.
await page.route("**/onboarding/greeting", async route => {
await expect(page).toHaveURL(/\/chats\/[^/]+$/);
await expect(page.getByTestId("task-chat-composer-add")).toBeVisible();
await route.fulfill({ json: { started: false } });
});
await page.route("**/test-environment", (route) =>
route.fulfill({
contentType: "application/json",
@@ -62,7 +56,7 @@ async function installLaunchIntercepts(page: Page, baseURL?: string) {
}
/** Drive the wizard from the /onboarding route through to "Get started". */
async function runOnboardingWizard(page: Page, companyName: string) {
async function runOnboardingWizard(page: Page, companyName: string, signIn?: { source: RegExp; complete: () => Promise<void> }) {
await page.goto("/onboarding");
// Launcher card path (existing companies) — enter the wizard if the
@@ -90,28 +84,21 @@ async function runOnboardingWizard(page: Page, companyName: string) {
// — the row is a question, not a confirmation — so the CTA is disabled until
// a tile is pressed. By role rather than by label: which adapters the tiles
// offer depends on the registry this environment reports.
const source = page.getByRole("radio").first();
const source = signIn ? page.getByRole("radio", { name: signIn.source }) : page.getByRole("radio").first();
await source.waitFor({ timeout: 30_000 });
await source.click();
// "Connect", not "Next": this step's button starts the sign-in where there
// is one to start, so it is named for what it does. This test simulates
// successful local account connection before the environment check and hire.
//
// Waited on for enabled rather than for visible: it is already on screen,
// disabled, and clicking a disabled button raises nothing and does nothing.
const connectNext = page.getByRole("button", { name: /^Connect$/ });
await expect(connectNext).toBeEnabled({ timeout: 30_000 });
await connectNext.click();
// A verified account, or pasting its authorization code, continues
// automatically through the environment check and hire.
if (signIn) await signIn.complete();
// Step 5: review → Get started creates the first task and opens its
// detail page.
// Step 5: review → Get started opens the standing chat.
const getStarted = page.getByRole("button", { name: /Get started/ });
await getStarted.waitFor({ timeout: 20_000 });
await getStarted.click();
}
async function assertFirstTaskExists(page: Page, companyName: string) {
async function assertOnlyChatExists(page: Page, companyName: string) {
const companiesRes = await page.request.get("/api/companies");
expect(companiesRes.ok()).toBe(true);
const companies = await companiesRes.json();
@@ -123,32 +110,69 @@ async function assertFirstTaskExists(page: Page, companyName: string) {
const issuesRes = await page.request.get(`/api/companies/${company.id}/issues`);
expect(issuesRes.ok()).toBe(true);
const issues = await issuesRes.json();
const firstTask = issues.find(
(candidate: { title: string }) => candidate.title === FIRST_TASK_TITLE,
);
expect(firstTask).toBeTruthy();
await expect(page.getByText(FIRST_TASK_TITLE).first()).toBeVisible({
timeout: 15_000,
});
expect(issues).toEqual([]);
const projectsRes = await page.request.get(`/api/companies/${company.id}/projects`);
expect(projectsRes.ok()).toBe(true);
expect(await projectsRes.json()).toEqual([]);
const chatsRes = await page.request.get(`/api/companies/${company.id}/chats`);
expect(chatsRes.ok()).toBe(true);
const chats = await chatsRes.json();
expect(chats).toHaveLength(1);
expect(chats[0]).toMatchObject({ originKind: "onboarding_chat", projectId: null });
await expect(page.getByTestId("task-chat-composer-add")).toBeVisible();
}
test.describe("First-task launch after onboarding wizard", () => {
test("creates the first task and opens its detail page", async ({ page, baseURL }) => {
test.describe("Chat launch after onboarding wizard", () => {
test("pasting a Claude code connects automatically and continues onboarding", async ({ page, baseURL }) => {
await installLaunchIntercepts(page, baseURL);
let verified = false;
let submissions = 0;
await page.route("**/ai-connections/local/attempts", route => route.fulfill({ status: 201, json: {
sessionId: "00000000-0000-4000-8000-000000000001", expiresAt: "2099-01-01T00:00:00Z",
} }));
await page.route("**/ai-connections/local/check", route => route.fulfill({ json: verified
? { status: "ready" }
: { status: "sign_in_required", authorizationUrl: "https://claude.ai/oauth/authorize?fixture=auto-paste" },
}));
await page.route("**/ai-connections/local/attempts/*/code", async route => {
expect(route.request().postDataJSON()).toEqual({ browserCode: "fixture-authorization-code" });
submissions++;
verified = true;
await route.fulfill({ json: { ok: true } });
});
const companyName = `E2E-ClaudePaste-${Date.now()}`;
await runOnboardingWizard(page, companyName, { source: /Claude/, complete: async () => {
const code = page.getByRole("textbox", { name: "Authorization code", exact: true });
await expect(code).toBeVisible({ timeout: 20_000 });
await expect(page.getByRole("button", { name: "Connect", exact: true })).toBeDisabled();
await code.evaluate(input => {
const clipboardData = new DataTransfer();
clipboardData.setData("text/plain", "fixture-authorization-code");
input.dispatchEvent(new ClipboardEvent("paste", { clipboardData, bubbles: true, cancelable: true }));
});
await expect(page.getByRole("status").filter({ hasText: "Finishing sign-in" })).toBeVisible();
} });
expect(submissions).toBe(1);
await assertOnlyChatExists(page, companyName);
});
test("opens chat without creating a task or project", async ({ page, baseURL }) => {
await instrumentNavLog(page);
await installLaunchIntercepts(page, baseURL);
const companyName = `E2E-TypingIntro-${Date.now()}`;
await runOnboardingWizard(page, companyName);
await expectLandsOnFirstTaskWithoutDashboardBounce(page);
await assertFirstTaskExists(page, companyName);
await expectLandsOnChatWithoutDashboardBounce(page);
await assertOnlyChatExists(page, companyName);
await page.screenshot({ path: test.info().outputPath("onboarding-chat.png"), fullPage: true });
});
// PAP-404 regression: the dashboard bounce only fires when the instance
// already has a company for the route-sync effect to reset selection to.
// Seed one first, then onboard a brand-new company and assert we still land
// on the first task without a dashboard bounce.
test("lands on the first task even when a company already exists", async ({
// in chat without a dashboard bounce.
test("lands on chat even when a company already exists", async ({
page,
baseURL,
}) => {
@@ -165,7 +189,7 @@ test.describe("First-task launch after onboarding wizard", () => {
const companyName = `E2E-TypingIntro-Existing-${Date.now()}`;
await runOnboardingWizard(page, companyName);
await expectLandsOnFirstTaskWithoutDashboardBounce(page);
await assertFirstTaskExists(page, companyName);
await expectLandsOnChatWithoutDashboardBounce(page);
await assertOnlyChatExists(page, companyName);
});
});
+4
View File
@@ -23,6 +23,10 @@ const ctx = run.contextSnapshot;
const task = await api(`/issues/${ctx.issueId}`);
const comment = async (body) =>
api(`/issues/${task.id}/comments`, "POST", { body });
if (ctx.wakeReason === "onboarding_chat_greeting") {
await comment("Welcome to Paperclip! I'm your first agent teammate. Tell me what you'd like to achieve, or ask me to interview you so we can work it out together.");
process.exit(0);
}
if (!task.conversationAgentId) {
if (task.description?.includes("proactive-digest-fixture")) {
await api("/agents/me/chat/messages", "POST", {
@@ -6,6 +6,12 @@ import { expect, type Page } from "@playwright/test";
export async function mockOnboardingLocalAiConnection(page: Page) {
const connectionId = randomUUID();
const grantId = randomUUID();
const sessionId = randomUUID();
await page.route("**/ai-connections/local/attempts", route => route.fulfill({ status: 201, json: {
sessionId, expiresAt: "2099-01-01T00:00:00Z",
} }));
await page.route("**/ai-connections/local/check", route => route.fulfill({ json: { status: "ready" } }));
await page.route("**/ai-connections/local/attempts/*", route => route.fulfill({ json: { ok: true } }));
await page.route("**/ai-connections/local", async (route) => {
expect(route.request().method()).toBe("POST");
expect(route.request().postDataJSON()).toMatchObject({ method: "subscription", ownership: "personal" });
+12 -12
View File
@@ -2,9 +2,9 @@ import { expect, type Page } from "@playwright/test";
/**
* Regression guard for PAP-404: onboarding must land the user on the newly
* created first-task detail page and must NOT bounce to the company dashboard.
* created agent chat and must NOT bounce to the company dashboard.
*
* The bounce is a navigation race: the wizard `navigate(/…/issues/…)` used to
* The bounce is a navigation race: the wizard `navigate(/…/chats/…)` used to
* be clobbered by `useCompanyPageMemory`, which restores a company's remembered
* page (falling back to `/dashboard`) on a non-`route_sync` selection change.
*
@@ -15,7 +15,7 @@ import { expect, type Page } from "@playwright/test";
* one that later self-corrects) leaves a trace in the log.
*/
const ISSUE_URL = /\/issues\/[^/]+$/;
const CHAT_URL = /\/chats\/[^/]+$/;
const DASHBOARD_PATH = /\/dashboard(\/|$)/;
/**
@@ -50,26 +50,26 @@ async function readNavLog(page: Page): Promise<string[]> {
}
/**
* Assert the wizard settled on the first-task detail page and never rested on
* Assert the wizard settled on the agent chat and never rested on
* (or bounced through) the dashboard.
*
* Fails if a dashboard bounce is reintroduced: the History-API log will contain
* a `/dashboard` entry and/or the settled URL will not be the issue page.
* a `/dashboard` entry and/or the settled URL will not be the chat page.
*/
export async function expectLandsOnFirstTaskWithoutDashboardBounce(
export async function expectLandsOnChatWithoutDashboardBounce(
page: Page,
): Promise<void> {
// The wizard's launch handler does async work (hire + create issue) before
// navigating, so give reaching the issue page a generous budget.
await expect(page).toHaveURL(ISSUE_URL, { timeout: 30_000 });
// The wizard's launch handler does async work (hire + open chat) before
// navigating, so give reaching the chat page a generous budget.
await expect(page).toHaveURL(CHAT_URL, { timeout: 30_000 });
const settledUrl = page.url();
// Short settle window: the page-memory effect fires on the selection change
// that accompanies the launch navigate, so any bounce lands within ~1s. If
// the URL is still the issue after this window it has genuinely settled.
// the URL is still the chat after this window it has genuinely settled.
await page.waitForTimeout(1_500);
expect(page.url(), "onboarding bounced away from the first task").toBe(settledUrl);
await expect(page).toHaveURL(ISSUE_URL);
expect(page.url(), "onboarding bounced away from the chat").toBe(settledUrl);
await expect(page).toHaveURL(CHAT_URL);
const navLog = await readNavLog(page);
const bounced = navLog.filter((path) => DASHBOARD_PATH.test(path));
@@ -1,7 +1,7 @@
import { expect, test } from "@playwright/test";
import { mockOnboardingLocalAiConnection } from "./helpers/onboarding-ai-connection";
import {
expectLandsOnFirstTaskWithoutDashboardBounce,
expectLandsOnChatWithoutDashboardBounce,
instrumentNavLog,
} from "./helpers/onboarding-landing";
@@ -32,6 +32,7 @@ test("captures planning mode UI for desktop and mobile", async ({ page }) => {
await instrumentNavLog(page);
await mockOnboardingLocalAiConnection(page);
await page.route("**/onboarding/greeting", route => route.fulfill({ json: { started: false } }));
await page.route("**/test-environment", (route) =>
route.fulfill({
@@ -88,27 +89,19 @@ test("captures planning mode UI for desktop and mobile", async ({ page }) => {
// The connect step arrives with no source selected — the tile row is a
// question, not a confirmation — so its CTA stays disabled until one is
// pressed. It reads "Connect", not "Next": the button starts the sign-in
// where there is one to start. The test simulates successful local account
// connection, then exercises the real first-task creation flow.
//
// Waited on for enabled rather than visible: it is already on screen, and
// clicking a disabled button raises nothing and does nothing.
// pressed. The simulated verified account then advances automatically.
const source = page.getByRole("radio").first();
await source.waitFor({ timeout: 30_000 });
await source.click();
const connectNext = page.getByRole("button", { name: /^Connect$/ });
await expect(connectNext).toBeEnabled({ timeout: 30_000 });
await connectNext.click();
// The review step names the agent rather than the step.
await expect(
page.getByRole("heading", { name: "Let's get started..." }),
).toBeVisible({ timeout: 30_000 });
await page.getByRole("button", { name: /Get started/ }).click();
// The wizard now drops the user straight onto the first task's detail page,
// The wizard opens the standing chat,
// and must not bounce through the dashboard (PAP-404).
await expectLandsOnFirstTaskWithoutDashboardBounce(page);
await expectLandsOnChatWithoutDashboardBounce(page);
const baseOrigin = new URL(page.url()).origin;
const companyRes = await page.request.get(`${baseOrigin}/api/companies`);
@@ -119,13 +112,16 @@ test("captures planning mode UI for desktop and mobile", async ({ page }) => {
const issueRes = await page.request.get(`${baseOrigin}/api/companies/${company.id}/issues`);
expect(issueRes.ok()).toBe(true);
const issues = await issueRes.json();
const planningSeedIssue = issues.find(
(candidate: { id: string; identifier?: string; title: string }) =>
candidate.title === TASK_TITLE,
);
expect(planningSeedIssue).toBeTruthy();
const issue = planningSeedIssue;
expect(issues).toEqual([]);
const agentsRes = await page.request.get(`${baseOrigin}/api/companies/${company.id}/agents`);
const [agent] = await agentsRes.json();
// This suite explicitly creates its legacy planning/question fixture; the
// onboarding wizard itself must leave execution work empty.
const created = await page.request.post(`${baseOrigin}/api/companies/${company.id}/issues`, {
data: { title: TASK_TITLE, assigneeAgentId: agent.id, onboardingFirstTask: true, status: "todo" },
});
expect(created.ok()).toBe(true);
const issue = await created.json();
const issueIdentifier = issue.identifier ?? issue.id;
const issuePath = `/${company.issuePrefix ?? company.id}/issues/${issueIdentifier}`;
const companyPrefix = company.issuePrefix ?? company.id;
@@ -229,7 +229,7 @@
"packages/shared/src/connector-availability.ts": "82aec0dfb2e9b8cb04e21c4bcd9aab74b087c76a",
"packages/shared/src/connector-identity.test.ts": "d58357707faefa7c98bb906cdaeb4db39d31081a",
"packages/shared/src/connector-identity.ts": "5ede83c9c5225dbe8af9cf3a49c74e477ef5b955",
"packages/shared/src/constants.ts": "698b73db1661e18bd435a9dfef5f3804fcf0612a",
"packages/shared/src/constants.ts": "9762160217907b1a3cc33f3dc9f86b46afae2cdd",
"packages/shared/src/crash-point-registry.ts": "3cbf2d290bc111061376b43020848623e493737c",
"packages/shared/src/crash-points.test.ts": "3564a1f62d22f54a3c2fb0a72b3a6cde17c957d2",
"packages/shared/src/crash-points.ts": "c15259f39610e352eac5423a491548ec1bae94fe",
@@ -268,7 +268,7 @@
"packages/shared/src/home-paths.ts": "fa4f1c440653b76b3dbb7a51026d557287deb45d",
"packages/shared/src/humanize-connection.test.ts": "ba9e90a44c63452b0bf9f733adb90241921e8eca",
"packages/shared/src/humanize-connection.ts": "fbd414476a0ef7106a7c80d8572208781b091699",
"packages/shared/src/index.ts": "0ee8c415f1dc36e4aec1a44b8e2e1a8f59885668",
"packages/shared/src/index.ts": "bc4373e3956c06613f3214706824a93050a757cf",
"packages/shared/src/issue-activity-identity.test.ts": "3dc294640f54c2be67943e3e0149cf4eff2c95ca",
"packages/shared/src/issue-activity-identity.ts": "1b0f07ec3fe0506aaaf80a4fa9893f3baf8f0075",
"packages/shared/src/issue-attribution.test.ts": "84563685e7f3c48029243cf1cc24a3a09ee3cde9",