Files
PaperClipAI/ui/src/components
DottaandPaperclip e198f77cea fix(ui): remove obsolete Experimental harness picker from new agent dialog (#22919)
## Thinking Path

> - Paperclip is the open source app people use to manage AI agents for
work.
> - When a user creates a new agent, `AgentBasicsDialog` shows top-level
adapter cards for each supported harness.
> - Both OpenCode and Grok Build already resolve automatically to
Paperclip Runner through their main adapter cards on supported targets
(`#17120`, `#17922`).
> - However, `AgentBasicsDialog` still rendered an **Advanced ->
Experimental harness** dropdown listing **Grok Build (Paperclip
Runner)** and **OpenCode (Paperclip Runner)** left over from the phased
Runner rollout.
> - Showing both the main cards and a separate experimental Paperclip
Runner dropdown for the same two harnesses confuses users into thinking
the main cards do not use Paperclip Runner.
> - This pull request removes the obsolete dropdown and dead selection
state from `AgentBasicsDialog`, cleans up its Storybook story and
visual-test override, and updates the E2E tests to pick the main Grok
Build and OpenCode cards.
> - The benefit is a single clear creation path for every harness
without duplicate experimental entries.

## Linked Issues or Issue Description

Refs #15993, Refs #17120, Refs #17922.

**What happened?**

When `enableNativeRunner` is enabled, the **Choose an adapter** step in
`AgentBasicsDialog` displays both the top-level **Grok Build** and
**OpenCode** cards and an **Advanced -> Experimental harness** dropdown
containing **Grok Build (Paperclip Runner)** and **OpenCode (Paperclip
Runner)**.

**Expected behavior**

The new-agent adapter picker should show only the main adapter cards,
because selecting **Grok Build** or **OpenCode** already sends `runner:
"auto"` and resolves to Paperclip Runner automatically on supported
targets and managed Paperclip Cloud sandboxes.

**Steps to reproduce**

1. Enable `enableNativeRunner` in instance experimental settings.
2. Open the **New Agent** dialog, enter a name, and click **Choose
adapter**.
3. Expand **Advanced** and observe the duplicate **Experimental
harness** dropdown listing Grok Build and OpenCode.

## What Changed

- Removed the **Advanced -> Experimental harness**
`<details>`/`SelectPopover` block and dead `runnerProvider`,
`experimentalRunnerAvailable`, and `advancedRunnerOptions` code from
`ui/src/components/new-agent/AgentBasicsDialog.tsx`, along with
unreachable `"claude"` / `"grok"` branches in its `paperclip_runner`
update payload.
- Removed the obsolete `ExperimentalNativeHarnesses` story from
`ui/storybook/stories/agents/codex-runner/creation.stories.tsx` and its
visual-test selector/branch in
`tests/storybook-visual/storybook-visual.spec.ts`.
- Updated `tests/e2e/onboarding.spec.ts` to assert the **Advanced**
section is absent even when `enableNativeRunner` is enabled, select the
main **Grok Build** card, and verify the saved setup agent still
resolves to `paperclip_runner` (`provider: "acpx"`, `acpxAgent: "grok"`,
`model: "grok-4.7"`).
- Updated
`tests/runner-e2e/chat-catalog-domains/identity-new-company-native.ts`
to select the main **OpenCode** card instead of the removed dropdown.

## Verification

- `pnpm --filter @paperclipai/ui typecheck` passed.
- `node scripts/run-tsc.mjs -p tests/tsconfig.playwright.json --noEmit
&& node scripts/run-tsc.mjs -p tests/e2e/tsconfig.json --noEmit && node
scripts/run-tsc.mjs -p tests/runner-e2e/tsconfig.json --noEmit` passed.
- `node scripts/check-test-budget.mjs --base origin/master` and `node
scripts/storybook-catalog.mjs` passed.
- `pnpm exec vitest run --config tests/runner-e2e/vitest.config.ts
tests/runner-e2e/chat-catalog-domains/identity-new-company-native.test.ts`
passed (51/51 tests).
- `pnpm exec playwright test --config tests/e2e/playwright.config.ts
tests/e2e/onboarding.spec.ts -g "name-only setup saves the Grok Build
Paperclip Runner adapter"` passed locally (1/1).
- `pnpm verify` exited 2 because
`tests/storybook-visual/storybook-visual.spec.ts` is unclassified; full
workspace, build, and E2E verification is covered by required PR CI.

## Risks

- Low risk. The main **Grok Build** and **OpenCode** cards already
resolve to Paperclip Runner on all supported platforms and managed Cloud
sandboxes via `resolveNewAgentRunnerForCompany`.
- On platforms where Paperclip Runner is not supported for Grok Build or
OpenCode (for example Linux ARM64), the main cards fall back to the
legacy adapter instead of forcing `paperclip_runner`, which matches
Codex and Claude Code behavior.

## Model Used

- Google Gemini (Antigravity agent with tool use, file editing, and
terminal execution).

## 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: Paperclip <noreply@paperclip.ing>
2026-11-25 06:14:45 -06:00
..