Skip to content

fix(site): drop deep link params from new chat URLs - #32068

Merged
ethanndickson merged 1 commit into
mainfrom
ethan/agent-create-deep-link-search
Nov 12, 2026
Merged

ethanndickson merged 1 commit into
mainfrom
ethan/agent-create-deep-link-search

Conversation

@ethanndickson

Copy link
Copy Markdown
Member

Closes CODAGT-1559

AgentCreatePage debug deep link > prefills the prompt and the build logs, and sends them on Send flaked in CI with the new chat's URL still carrying ?debug_workspace_build=....

It turns out react-router 7 applies router state inside React.startTransition, so router.state updates straight away but useLocation() lags until the transition commits. The query data that enables Send arrives as a sync update, so under load Send can commit first, and it forwarded the stale location.search. Waiting on router.state in the test wouldn't help, as it's already clean by the time Send is clicked.

To fix, we'll just strip the link params from the search once in render and use that for both the URL cleanup and the navigation on Send, so neither depends on when the transition commits.

…chat URL

react-router 7 applies router state in a transition, so useLocation()
can still hold debug_workspace_build or prompt after the cleanup
navigation when the user clicks Send. Derive the search without the
link params in render and use it for both the cleanup and Send.

Closes CODAGT-1559
@linear-code

linear-code Bot commented Nov 12, 2026

Copy link
Copy Markdown

CODAGT-1559

@ethanndickson
ethanndickson temporarily deployed to main November 12, 2026 03:47 — with GitHub Actions Inactive
@ethanndickson
ethanndickson marked this pull request as ready for review November 12, 2026 04:45
@ethanndickson
ethanndickson requested a review from a team as a code owner November 12, 2026 04:45
@ethanndickson
ethanndickson temporarily deployed to main November 12, 2026 04:46 — with GitHub Actions Inactive
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-12T04:49:04.795236Z 73abf15 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@ethanndickson ethanndickson changed the title fix(site/src/pages/AgentsPage): keep deep link params out of the new chat URL fix(site): drop deep link params from new chat URLs Nov 12, 2026
@ethanndickson
ethanndickson temporarily deployed to main November 12, 2026 04:46 — with GitHub Actions Inactive
@ethanndickson
ethanndickson merged commit f610e9a into main Nov 12, 2026
58 of 59 checks passed
@ethanndickson
ethanndickson deleted the ethan/agent-create-deep-link-search branch November 12, 2026 04:59
@ethanndickson
ethanndickson temporarily deployed to main November 12, 2026 04:59 — with GitHub Actions Inactive
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 12, 2026

This branch was previously deployed

1 inactive deployment
main — 73abf155 Deployed Nov 12, 2026 by ethanndickson via cla #254700
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants