Skip to content

Merge upstream/main be1d066732 into coder-only (sync stage 2: forge definitions) - #254

Merged
henrychu04 merged 28 commits into
coder-onlyfrom
t3code/sync-upstream-be1d066732
Oct 24, 2026
Merged

henrychu04 merged 28 commits into
coder-onlyfrom
t3code/sync-upstream-be1d066732

Conversation

@henrychu04

Copy link
Copy Markdown
Owner

Stage 2 of the eb1510d → be1d066 upstream sync: upstream's forge-definitions refactor (pingdotgg#23992–pingdotgg#24288) and the 11 commits after it. Stage 1 was #253.

What changed

Upstream moved per-host behaviour into each forge's shared definition and server driver, read through one registry in the new @t3tools/source-control-definitions package. T3 Coder carries that package with only GitLab's definition, so most fork GitLab shims are now expressed by upstream's hooks and are gone:

  • Host terminology ("MR", "merge request") comes from GitLab's definition on most surfaces (fix(clients): change requests use their host's own term pingdotgg/t3code#23999); !N is still applied by hand.
  • GitManager reads merge request heads from GitLab's changeRequestHeadRef; upstream's targetsOnlyRemote is carried.
  • VcsProcess's semaphore and glab failure classification come from the per-call concurrency/classifyFailure hooks.
  • Icons, clone/publish pickers, settings search and project matching read the definitions; client-runtime's sourceControlClients.ts is upstream's.

GitLab seams moved into the new layout (marked Coder:):

  • GitLab definition: merge request URLs on any host, author profile links, and new referenceAutolinks (!N, #N, commit SHAs under /-/), so upstream's host-neutral web autolinker is carried unchanged.
  • The registry's parseChangeRequestUrl rejects URLs carrying credentials (replaces the deleted shared/changeRequestUrl.ts seam).
  • The GitLab-or-unknown project filter moved to client-runtime changeRequestLinks.ts.
  • ChatMarkdown opens GitLab references directly (no GitHub-style confirmation).

Still cut: GitHub/Forgejo/Bitbucket/Azure DevOps/GitCafe packages and definitions, cross-environment pull request routing and its settings, host token/account/host-settings forms, credentialed host media (SOURCE_CONTROL_MEDIA_ASSET), mobile/desktop/relay/Cursor.

Found and fixed

  • An earlier sync (ed3f965) had dropped RepositoryIdentityResolver's refine option and the helper never wired upstream's refine step. Upstream now relies on it (GitLab confirms a self-hosted host whose hostname lacks "gitlab" through glab auth status) after deleting PullRequestService's unknown-kind refinement. Restored and wired into coderServer.ts.

Behaviour change to note

  • A pasted owner/repo clone shorthand now becomes git@gitlab.com:owner/repo.git (upstream takes the first registered host's default transport; before, it produced GitHub over HTTPS).

Verification

  • pnpm test:coder: every package passes. The one failure under full load is web localApi.test.ts's afterEach hook timeout, a known flake listed in Tests that flake under full-suite load #236; it passes alone and the unit project passes alone (244 files).
  • All AGENTS.md typechecks (+ source-control-definitions), pnpm knip:check, unused-locals check, pnpm build, vp fmt --check over changed files
  • sync.md section 6: marker drops all match seams replaced by upstream hooks; lost upstream lines are cut hosts, routing, credential settings, host media, or wording seams; no RPC, capability, listener, MCP, Claude query, or Node changes in the range
  • Live smoke (gateway + real helper, no browser): stage smoke OK, signed asset/upload smoke OK (26 checks), and the fake-glab merge request smoke on a self-hosted host: list, summary, detail, diff, checks, author filter options all succeed

🤖 Generated with Claude Code

juliusmarminge and others added 28 commits October 24, 2026 04:24
…sitory keys (pingdotgg#23993)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…st media (pingdotgg#23994)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…hooks (pingdotgg#23995)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…abilities (pingdotgg#23996)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…uming GitHub (pingdotgg#23997)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…tions (pingdotgg#23998)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…nt/ (pingdotgg#24181)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…t quirks (pingdotgg#24288)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…rd is closed (pingdotgg#24363)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…with the sidebar collapsed (pingdotgg#23839)

Co-authored-by: PR Batch Tester <agent@local.test>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…gdotgg#23676)

Co-authored-by: PR Batch Tester <agent@local.test>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…to the delegator (pingdotgg#23795)

Co-authored-by: PR Batch Tester <agent@local.test>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…24405)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…iet (pingdotgg#24334)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
… error after the SDK's late resume (pingdotgg#24231)

Co-authored-by: PR Batch Tester <agent@local.test>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Stage 2 of the eb1510d → be1d066 sync: upstream's forge-definitions
refactor (pingdotgg#23992–pingdotgg#24288) and the 11 commits after it.

The refactor moves per-host behaviour into each forge's shared definition
and server driver, read through one registry in the new
@t3tools/source-control-definitions package. T3 Coder carries that package
with only GitLab's definition, so most GitLab shims the fork kept are now
expressed by upstream's hooks and are dropped:
- Host terminology ("MR", "merge request") comes from GitLab's definition
  on most surfaces (pingdotgg#23999); `!N` is still applied by hand.
- GitManager reads merge request heads from GitLab's changeRequestHeadRef;
  upstream's targetsOnlyRemote is carried (createsChangeRequestsIn).
- VcsProcess's semaphore and glab failure classification come from the
  per-call concurrency and classifyFailure hooks.
- Icons, clone/publish pickers, settings search, and project matching read
  the definitions; client-runtime's sourceControlClients is upstream's.
- PullRequestService's unknown-kind and Forgejo SSH-alias refinements are
  replaced by upstream's resolveRemoteWebHost and the identity refine hook.

GitLab seams moved into the new layout: the any-host merge request
reference URL, author profile links, and !N/#N/commit autolinks
(referenceAutolinks) in GitLab's shared definition; the credential check
that replaced shared/changeRequestUrl.ts in the registry's
parseChangeRequestUrl; the GitLab-or-unknown project filter in
client-runtime changeRequestLinks.ts.

Cut as before: GitHub, Forgejo, Bitbucket, Azure DevOps, and GitCafe
packages and definitions; cross-environment pull request routing and its
settings; host token, account, and host-settings forms; credentialed host
media (SOURCE_CONTROL_MEDIA_ASSET); mobile, desktop, relay, Cursor.

Conflicts were resolved by hand for manifests, lockfile, docs, and the
definitions package, and in four parallel groups for the server git layer,
the rest of the server with contracts and shared, the web merge request UI,
and client-runtime with the web shell.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The ed3f965 sync dropped RepositoryIdentityResolver's refine option, and the helper built the resolver without upstream's refine step. Upstream now relies on it: pingdotgg#23993–pingdotgg#24288 removed PullRequestService's unknown-kind refinement in favour of each host's refineRepositoryIdentity, which for GitLab confirms a self-hosted host whose hostname lacks "gitlab" through its glab login. Restore upstream's resolver, carry server.ts's layerRepositoryIdentityResolver, and use it in coderServer.ts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- linkCreatedPullRequest.test.ts reads hosts from GitLab merge request URLs; GitHub URLs no longer parse.
- PullRequestSyncReactor.test.ts runs its close-command case on glab mr merge and glab mr close, the only host close command carried, and drops the native stack auto-link test, which builds layer URLs from GitHub's uncarried definition.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
RepositoryIdentityResolver.layer (the helper uses server.ts's refining layer), and the source control icon, credential-settings, authority, and fake-driver helpers in client-runtime, core, and testing that only the cut forges and settings call.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@henrychu04
henrychu04 merged commit 24b2881 into coder-only Oct 24, 2026
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.

4 participants