GeezerVison is showing github.com — chore: sync with upstream/main (6ffde5ba3) by Fryuni · Pull Request #78 · Fryuni/t3code
Conversation
Problem
The fork is 325 commits behind upstream/main. This sync keeps the features recorded in docs/adr and uses upstream's implementation wherever it can.
Change
Merged pingdotgg/t3code main at 6ffde5ba39ba6a718b658e2ef846e8f674c9ee6e. 57 files conflicted. Most of the work was upstream's source-control refactor, where each forge's shared definition now parses its own change request URLs and keys (#23992, #23993, #24181, #24288). That refactor deleted changeRequestUrl.ts and most of shared/sourceControl.ts.
Partly implemented upstream
- ADR 0004, prefer the thread's checkout. Upstream's new
resolveChangeRequestLinkTarget takes a projectId that is tried first, and mobile passes it (#24738). The fork's own reordering is gone. The only fork change left is that the web opener passes the thread's project.
Re-homed on upstream's structure
- ADR 0002, Forgejo identity. The rules now live in the Forgejo shared definition:
parseChangeRequestUrl keeps the mount's case, changeRequestHost prefers the resolved webUrl, and repository and credential matching compare the mount exactly. Upstream's version compares the mount as a case-insensitive prefix. The core ChangeRequestHostIdentity gains webUrl. normalizeSourceControlRepository and a new foldRepositoryKey stay in shared/sourceControl.ts; the fork's canonicalRepositoryKey(key, kind) and pullRequestHostOf are gone in favor of upstream's registry. Thread PR key normalization now lives in upstream's makeThreadPullRequests, with the fork's URL-spelling rule and an Azure whole-path fold. The bound server and client-runtime modules export a visibleThreadPullRequests that canonicalizes keys.
- Web PR summary cache. Upstream now records observations where reads land, keyed without the host. The fork's host recovery from the summary URL is dropped. The key keeps mount case, and the fork's test for the removed hook is deleted.
- ADR 0020 / 0001. The MCP clone-host mapping uses the registry. The registry tests moved to upstream's fake-driver harness, and the Forgejo discovery tests moved into the Forgejo package, as upstream did with forge tests (#24000).
- ADR 0010, public URL. This now works alongside upstream's private-network listener for background services (#24588). The public URL still wins as the advertised address, and
t3 pair skips the "local network only" note when one is set. The user doc tells service users to set T3CODE_HOST=127.0.0.1 alongside it.
- ADRs 0008 / 0016, agent copy. Upstream cut the agent instructions and tool copy (#24850). The fork's
createBranch and target notes now sit in the short tool descriptions; the instructions match upstream.
- ADR 0011, CI. Kept the fork's
ci.yml layout and vp run --filter t3 test. Upstream's task-cache step in setup-ci-deps only runs in pingdotgg/t3code. Kept release.yml, web-preview.yml and mirror-play-apk.cjs deleted.
- Lint. Fork comments are cut to upstream's new four-line cap (#21514). The branch selector's existing-branch effect keeps an effect-budget exception with its reason (#24964).
ADRs
All ADRs now compare against 6ffde5ba3. ADR 0002 is rewritten for the new structure. Notes were added to ADRs 0001, 0004, 0008, 0010, 0011, 0016, 0020 and 0023. Nothing else in the ADRs was implemented upstream.
git show --remerge-diff HEAD shows the whole conflict resolution.
Scope and approval
This is a maintainer-requested sync of the fork onto upstream. Every fork divergence is covered by an ADR in docs/adr.
Verification
vp run check:changed upstream/main: format, lint, knip, GraphQL, typecheck (34 packages) and tests (123 files, 2313 tests) all pass.
- Full package suites: shared (90 files), contracts (29), client-runtime (140), source-control core, forgejo, github, gitlab, gitcafe, azure-devops and bitbucket, mobile (221 files, 2784 tests), and web's unit and browser projects. Server: every directory the merge touched (217 files, 2695 tests).
- Local environment notes:
- Two upstream
GitManager tests need GIT_CONFIG_GLOBAL=/dev/null on this machine, because its global config sets push.default=upstream.
- Chromium needed NixOS libraries on
LD_LIBRARY_PATH.
- Some desktop tests fail here because of umask 077, a missing
pkg-config, and one WSL install-script test. None of them touch fork code.
- One web browser test flaked under parallel load and passes when run alone.
- Web's
renders project fails here, but the package test script and CI don't run it.
- Not run: repo-wide
vp check and the full server suite; CI runs them. No manual UI pass in a real client.
Model: Claude Opus 5.5; harness: Claude Code in T3 Code.
🤖 Generated with Claude Code
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
chatgpt-codex-connector[bot] reacted with thumbs up emoji
fryuni-proval[bot] reacted with eyes emoji
All reactions
-
👍
1 reaction
-
👀
1 reaction
…gdotgg#24769)
Mobile push said "Thread completed" when a run ended and its continuation started a moment later, then again when the work really finished. Every completion now waits the relay's existing 5s confirm window and is dropped if the thread is live again. A thread that auto-settles during the hold still alerts its completion, then clears its card on a new window. Failed runs publish at once.
Follow-up to pingdotgg#24760.
Co-authored-by: Claude Opus 5.5 <[email protected]>
Merge pingdotgg/t3code main (6ffde5b) into the fork. ADRs in docs/adr record
how each fork feature was reconciled.
Codex Review Summary
This comment shows the latest Codex review activity on this pull request.
| Review |
Status |
Commit |
Review trigger |
| 📝 Code Review |
✅ Completed 2026-10-26T13:50:29.199001Z |
dbb816f |
New commits |
ℹ️ 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.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e24eabfdb5
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
A project can read change requests on another host, so dropping the host from
the observation key let one server's pull request overwrite another's. Covered
by ADR 0002.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
|
Thanks for this large desktop sweep. It's a lot of surface, and most of it holds up well.
Overview
Summary
This PR makes several focused behavior changes:
- Adds a
T3CODE_DESKTOP_LAUNCHER_PATH override for Linux .desktop entries. It is used by both the pre-ready writer and the runtime writer.
- Adds
launcherPath to the CLI command state. The boot-error triage command uses it.
- Adds
service.instance.id and release resource attributes to desktop telemetry, and renames service.mode → t3code.desktop.mode (noted in the docs).
- Forwards
OTEL_RESOURCE_ATTRIBUTES to WSL backends.
- Gates CI on the shared task cache.
Most of the remaining diff is a mechanical move of Electron adapter methods onto named Effect.fn spans, plus a large comment-trimming pass. The two things to fix are both side effects of that mechanical work. One span landed on a hot polling path. The other is a stray client → shared rename in a vendored test.
Good points
- 🟢 Both Linux
.desktop writers use the same precedence (launcher → APPIMAGE → execPath) and the same trimming (DesktopLinuxUrlHandler.ts:139, DesktopPreReadyPlatform.ts:112-115). Because their output matches, the existing === content skip still works, and each writer has a test.
- 🟢
launcherPath is set only after exists(launcher) succeeds (DesktopCliCommand.ts:155). The boot-error screen therefore never suggests a missing shim, and the test covers the state both before and after install.
- 🟢 New telemetry defaults go through
processServiceInstanceId / releaseResourceAttributes, so the operator's OTEL_RESOURCE_ATTRIBUTES still wins (DesktopObservability.ts:615). WSL backends now receive those attributes as well (DesktopBackendConfiguration.ts:113).
- 🟢 The shared task cache step requires the upstream repo, a same-repo PR, and a non-empty token, and it passes the token through step
env rather than interpolating it (.github/actions/setup-ci-deps/action.yml:74-82).
Main Issues
- ⚫️
.repos/alchemy-effect/packages/frontend-frameworks/src/core/test/NodeServe.test.ts:31: the test now expects "../shared/", but the unchanged relativeClientDirExpression (NodeServe.ts:91-111) still returns "../client/" for these inputs, so this test will fail.
- ⚫️
apps/desktop/src/electron/ElectronPowerMonitor.ts:82: getSystemIdleState now creates a span on every call. sampleOnce (DesktopTelemetryPublisher.ts:203-213, intentionally fnUntraced) polls it every 1–15s, so each tick exports a root span. Keep it untraced.
Additional Notes
.repos/alchemy-effect/packages/frontend-frameworks/src/core/NodeServe.ts, line 51: the JSDoc example and the test fixtures at lines 38/134 now point at ../shared/, a directory no adapter produces. Consider reverting this vendored churn entirely.
apps/desktop/src/app/DesktopAppIdentity.ts, line 94: the shortened comment now suggests the parentheses themselves break Turnstile. The original warned that rewriting preview-session UAs is what breaks it (fix(desktop): keep the native preview User-Agent so Turnstile passes pingdotgg/t3code#7110), and that point is worth restoring.
apps/desktop/src/preview/BrowserImport/ChromiumKeys.ts, line 52: "Keep modal prompts untimed to preserve their listener" no longer explains the failure mode (a timeout racing the Keychain modal makes approving appear to do nothing). That comment is the only guard against someone adding an Effect.timeout there later.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
|
Thanks for this one. It's a big change, and most of it is careful work: a lot of comment tightening, the Effect.fn span conversion, and a well-defended shared task cache stack.
Overview
Summary
This PR adds a shared remote task cache. The pieces are a Cloudflare worker with a vendored upstream protocol, D1/R2 storage, admission and savings accounting, client run hooks, developer and CI install scripts, and a setup-ci-deps step that turns it on in CI. On the desktop side it does four things:
- Moves the Electron service wrappers to named
Effect.fn spans.
- Renames the desktop telemetry resource attribute
service.mode → t3code.desktop.mode.
- Forwards
OTEL_RESOURCE_ATTRIBUTES to WSL backends.
- Makes the pre-ready and post-ready Linux URL handlers agree on the launcher path.
Most of the remaining ~3k files only condense comments. The main risk is in CI wiring: the cache is not actually active yet, and turning it on still needs one more permission.
Good points
- 🟢 The cache server runs route, method and credential checks before the shared rate limiter, and the
ci-reader token is refused for store and telemetry (infra/task-cache/src/Cache.ts). Anonymous traffic can't use up the team budget, and the read-only CI token can't upload poisoned artifacts.
- 🟢 The vendored JWT
authorize accepts only RS256 and rejects jku/x5u/jwk. It also ties the write policy to aud, repository, owner, visibility and branch (infra/task-cache/vendor/vite-plus-remote-cache-cloudflare/src/auth.ts), which closes the usual key-injection paths.
- 🟢
Savings.record makes the counter increment conditional on changes() = 1 inside one D1 batch (infra/task-cache/src/Savings.ts), so telemetry retries never double-count savings.
- 🟢 The pre-ready and post-ready desktop entries use the same launcher precedence and trimming (
apps/desktop/src/app/DesktopPreReadyPlatform.ts:112, DesktopLinuxUrlHandler.ts). Tests cover the quoted Exec= line in both paths, so the portal doesn't see the file rewritten on every launch.
Main Issues
- ⚫️
.github/actions/setup-ci-deps/action.yml:79: the cache step requires task-cache-read-token, but none of the four callers in .github/workflows/ci.yml (lines 46/96/139/192) pass it, so the cache never turns on in CI.
- ⚫️
.github/actions/setup-ci-deps/action.yml:86: read-write mode needs OIDC, but ci.yml:10-11 doesn't grant id-token: write. Uploads fail, and CI telemetry gets a 403 and is then silently deleted (infra/task-cache/src/telemetry.ts:216-248).
- ⚫️
apps/desktop/src/electron/ElectronPowerMonitor.ts:82: wrapping getSystemIdleState in Effect.fn creates a root span on each telemetry sample, up to once per second. That goes against the deliberate fnUntraced sampler in DesktopTelemetryPublisher.ts:203-213.
- ⚫️
infra/task-cache/vendor/vite-plus-remote-cache-cloudflare/src/database.ts:243: upload_id is never cleared after publish, so GC aborts multipart uploads that already completed. If R2 rejects that, the generation can never be deleted and its capacity is never released.
Additional Notes
- In
infra/task-cache/src/Cleanup.ts (line 9), the three concurrent cache.cleanup calls each run cleanAssociations against the same maintenance cursor, so association GC moves forward about one batch per tick, not three.
- In
infra/task-cache/scripts/install-ci.ts (line 45), the BASH_ENV script appends --import=<preload> to NODE_OPTIONS with no dedupe, so nested shells add it again; the case guard in install.ts would prevent that.
- In
apps/desktop/src/app/DesktopAppIdentity.ts (line 94), the shortened comment no longer warns against rewriting preview-session User-Agents, which breaks Turnstile (fix(desktop): keep the native preview User-Agent so Turnstile passes pingdotgg/t3code#7110); worth restoring that line.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Upstream's file preview browser tests time out on the fork's slower runners when
three test files share the browser. Covered by ADR 0011.
|
Thanks for the quick turnaround on the host-key thread, @Fryuni. This push fixes it, and the CI and ADR changes are focused.
Overview
Summary
This push changes three things since the last review:
- Host now part of the summary key.
pullRequestSummaryKey in apps/web/src/state/pullRequests.ts (lines 87–99) now includes the reference host. So two pull requests from different hosts that share the same owner/name/number get separate observation entries. Before, one could overwrite the other. It's also exported now so the new tests can call it directly.
- Web test workers capped in CI. The web
Test step in .github/workflows/ci.yml (line 169) now passes --maxWorkers=2, so the file preview browser tests stop timing out on GitHub-hosted runners.
- ADRs updated. ADR 0002 and ADR 0011 now record why the fork differs from upstream in both places.
I found no new issues in this push.
Good points
🟢 The new key part reference.host?.trim().toLowerCase() ?? null (apps/web/src/state/pullRequests.ts, line 96) normalizes the host the same way requireProject does in apps/server/src/pullRequest/PullRequestService.ts line 929. The web cache now matches how the server routes each pull request to a host.
🟢 The new pullRequestSummaryKey tests (apps/web/src/state/pullRequests.test.ts, lines 192–213) check both directions. Host and owner/name are matched without regard to case. A different port, a different host, or a mount that differs only in case still gets its own entry. If someone later changes the key shape, these tests will fail.
🟢 The worker cap lives only in the CI command (.github/workflows/ci.yml, line 169), with a comment there and a note in docs/adr/0011-fork-release-source.md. Local runs and apps/web/vite.config.ts are unchanged, and the next upstream sync is unlikely to drop it as unexplained drift.
Additional Notes
apps/web/src/state/pullRequests.ts, line 96: when a detail-panel reference has no host, its key gets a null host, so it no longer matches list observations stored under a real host. This is harmless today because usePullRequestDetail merges listEntry directly. Keep it in mind if a future reader relies only on the shared cache.
.github/workflows/ci.yml, line 169: the --maxWorkers=2 cap also applies to the unit project. That adds a little CI time but doesn't affect correctness.
Earlier threads that this push didn't touch (setup-ci-deps token/id-token, the ElectronPowerMonitor span, the task-cache multipart cleanup) still stand as previously discussed. I haven't repeated them here.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
The 100-page Word preview test still exceeded 15 seconds with two workers. Covered
by ADR 0011.
|
Thanks for the follow-up, @Fryuni. This push is small and does what it says. I didn't find anything new to block on.
Overview
Summary
This push gives the fork's Test Web CI job a 60-second test timeout on top of the existing --maxWorkers=2 (.github/workflows/ci.yml line 169). The step comment and ADR 0011 now give the same reason: GitHub-hosted runners render the file preview browser tests about five times slower than upstream's 8-core runners. The change only touches the fork's CI command. apps/web/vite.config.ts stays as it is, with 15s at lines 88 and 129, so local runs and upstream CI keep their timeouts.
Good points
🟢 The timeout is raised with a CLI flag in the fork-only step instead of in the synced apps/web/vite.config.ts. That keeps the workaround out of upstream code and means future upstream syncs won't hit a merge conflict here.
🟢 docs/adr/0011-fork-release-source.md (lines 45–47) was updated in the same push and now describes both settings, at most two test files at once and a 60-second test timeout. A maintainer can see why the fork's CI differs from upstream without going through the git history.
Main Issues
None in this push.
Additional Notes
The new flag only changes the test timeout. Hooks still time out after 15s (hookTimeout: 15_000 in apps/web/vite.config.ts lines 87 and 128), so if a slow render sits in a beforeEach/afterEach, CI could still fail there. If that happens, adding --hookTimeout=60000 to the same command (.github/workflows/ci.yml line 169) would cover it.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
The file preview tests' default one-second waits still failed with two files
sharing the browser. Covered by ADR 0011.
|
Thanks for running down the flaky file preview tests, @Fryuni. This push is small and doesn't break anything, and the ADR now says plainly why the change was needed.
Overview
This push changes Test Web from --maxWorkers=2 to --maxWorkers=1 and keeps --testTimeout=60000 (.github/workflows/ci.yml, line 169). It also updates ADR 0011 to say why: the one-second vi.waitFor waits failed when two test files shared the browser (docs/adr/0011-fork-release-source.md, lines 46-47). I didn't find any new correctness or security problems.
Good points
🟢 The ADR now names the actual failure. vi.waitFor defaults to a one-second timeout, and --testTimeout doesn't raise that, so a longer test timeout alone was never going to fix it (docs/adr/0011-fork-release-source.md, line 47). With that written down, a future upstream sync is less likely to undo the single-worker setting by mistake.
🟢 You changed the step comment and the ADR in the same push, so the CI command and the recorded decision still agree (.github/workflows/ci.yml, line 166).
Main Issues
None in this push.
Additional Notes
.github/workflows/ci.yml, line 169: the web test script runs vp test run --passWithNoTests --project unit --project browser as one Vitest call (apps/web/package.json, line 12). That means --maxWorkers=1 also makes the node-only unit files run one at a time, not just the browser files.
- If the extra wall-clock time matters, you could run the
unit project with default workers in its own command.
- Otherwise, a note in the comment that unit tests are serialized too would help.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
The maintainer approved raising the web CI job's test timeout for GitHub-hosted
runners. Covered by ADR 0011.
|
Thanks for writing down the CI timeout difference, @Fryuni. This push only changes docs, and both files match the workflow.
Overview
Summary
This push adds a one-line note to AGENTS.md under the "project timeout is the ceiling" rule. It says the fork's Test Web CI job raises the timeout to 60 seconds, and it links the reasoning in ADR 0011. The ADR now links back to AGENTS.md. I checked the claims against head:
.github/workflows/ci.yml line 169 runs --maxWorkers=1 --testTimeout=60000.
apps/web/vite.config.ts lines 88 and 129 keep the 15-second project timeout.
- Both relative links resolve.
Good points
🟢 AGENTS.md line 113 puts the fork's 60-second CI ceiling right next to the timeout rule and says tests must still pass within the project timeout locally. Agents won't read the CI flag as permission to write slower tests.
🟢 docs/adr/0011-fork-release-source.md line 48 links back to AGENTS.md with a correct ../../AGENTS.md path. With links in both directions, both docs are more likely to be updated together during future upstream syncs.
Main Issues
I found nothing to fix in this push.
Additional Notes
.github/workflows/ci.yml line 169 raises only --testTimeout. hookTimeout stays at its configured value, so slow beforeEach/afterEach setup on the hosted runners could still time out sooner. The new note talks only about the test timeout, so it's accurate as written.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Reviewers
+1 more reviewer
Reviewers whose approvals may not affect merge requirements
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
|