Skip to content

Fix secret requests from deep working directories - #3884

Merged
ymichael merged 1 commit into
mainfrom
bb/fix-bb-secret-request-failing-on-long-destinatio-thr_sy6ag4mbgj
Sep 17, 2026
Merged

ymichael merged 1 commit into
mainfrom
bb/fix-bb-secret-request-failing-on-long-destinatio-thr_sy6ag4mbgj

Conversation

@ymichael

@ymichael ymichael commented Sep 17, 2026 •

Copy link
Copy Markdown
Collaborator

Human comments

What was wrong

PR #731 changed secret request destinations to resolved absolute host paths and reused that unbounded path in the pending interaction title. Deep working directories could therefore exceed the Plugin SDK's 160-character title limit before the secure form was created.

What changed

Secret requests now use the concise Add secrets interaction title. The complete resolved destination remains in the typed interaction payload and is still shown in the secure form and command result. A server harness regression covers a relative dotenv destination resolved from an overlong working directory.

Pending-interaction headers now add invisible line-break opportunities after / and \\ path separators. This preserves the exact visible and accessible title while preventing path-like labels from wrapping into short, ragged lines.

No server/daemon wire contract changed, so HOST_DAEMON_PROTOCOL_VERSION is unchanged.

How you verified

  • Reproduced on origin/main from a 227-character working directory: bb secret request TEST_SECRET --write-env .env.local exited 1 with ui.requestInput title must be 1-160 characters.
  • pnpm exec turbo run test typecheck --filter=bb-plugin-secrets --force
  • pnpm exec turbo run test --filter=@bb/app --force -- src/components/plugin/PluginPendingInteractionComposer.test.tsx
  • pnpm exec turbo run typecheck --filter=@bb/app --force
  • pnpm exec prettier --check plugins/secrets/src/server.ts plugins/secrets/src/server-harness.test.ts
  • git diff --check

AGENT GENERATED

@ymichael
ymichael force-pushed the bb/fix-bb-secret-request-failing-on-long-destinatio-thr_sy6ag4mbgj branch from 0eb83c0 to 0c6a813 Compare September 17, 2026 23:30
@ymichael
ymichael force-pushed the bb/fix-bb-secret-request-failing-on-long-destinatio-thr_sy6ag4mbgj branch from 0c6a813 to f8de34c Compare September 17, 2026 23:45
@ymichael
ymichael merged commit 94fe62b into main Sep 17, 2026
16 checks passed
@ymichael
ymichael deleted the bb/fix-bb-secret-request-failing-on-long-destinatio-thr_sy6ag4mbgj branch September 17, 2026 23:50
ymichael added a commit that referenced this pull request Sep 18, 2026
#3884 took the unbounded path out of the card title and let the card shell
wrap it instead. The two row strings this branch adds are the same shape and
were not covered: describeSubmission still built a 160 character row title
around the absolute destination, and the row labels had nothing holding them
under 80 as secret names accumulate.

Follow the same rule. The row title names the variables and the destination
moves to the detail, which has room for it, and both label halves are
clamped.

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
ymichael added a commit that referenced this pull request Sep 18, 2026
#3884 added a header-wrapping test against dismissal, which this branch has
since renamed to origin. The merge is clean textually and only the types
catch it.

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant