GeezerVison is showing github.com — fix(server): bare repositories now group with projects of the same remote by shrikantkalar023 · Pull Request #17340 · pingdotgg/t3code
Conversation
shrikantkalar023
commented
Oct 8, 2026
•
edited by juliusmarminge
Loading
Uh oh!
There was an error while loading. Please reload this page.
Bare repositories currently return no repository identity because Git's work-tree-root query fails. Their projects therefore stay separate from checkouts of the same remote.
After a completed root-query failure, probe the project directory and its .git target explicitly, accepting only a bare repository. Read its remotes with an explicit Git directory, preserve safe.bareRepository=explicit, and use the Git directory as rootPath. Normal checkout discovery, shared caching and refresh remain intact; checkout metadata directories and repositories without a usable remote return no identity. Failed or timed-out process launches stop discovery.
Rebuilt on current main from @shrikantkalar023's original contribution, retaining the contributor's commits. The original five added tests were reduced to four behavior cases; the resolver suite is 16 tests instead of 17.
Verification at 2e0a27b9c1:
- Resolver and enrichment suites: 23 passed / 2 expected bare-layout failures before → 25 passed after.
- Server and contracts typechecks, focused lint, formatting and diff checks passed. Four temporary mutations were caught; alias cache hits and cross-path refresh were checked.
- Real Linux Git → actual server resolver → shared client grouping: plain bare, .bare and pointer-container projects in separate synthetic environments produce two groups before → one after, in both repository grouping modes. Checkout .git metadata remains rejected.
- One independent full-diff review round by Claude Opus 5.5 and Codex GPT-6 Sol found no code blockers.
Before/after test and grouping proof
This is identity/grouping behavior, with no visual layout change. No browser session or live multi-machine client session was run. Windows/macOS Git path handling, Electron desktop, iOS/Android and Forgejo refinement were not verified natively on this Linux host. Each uncached non-Git project can now perform up to two additional bounded Git probes; negative caching remains one minute. Current-head build/typecheck, lint, release smoke, general tests and all eight server shards passed; configured correctness and approvability checks passed. CI is blocked: the first web job failed two unchanged browser cases on asynchronous rendering waits; both files passed locally (6/6). The rerun failed the same cases plus an unchanged HtmlRenderDialog zoom-button timeout. No web/client-runtime or workflow source changes are in this PR. These unrelated browser failures were not bypassed; the PR is not declared merge-ready. A canceled duplicate fingerprint run is superseded by the successful fingerprint run on the same head.
Implementation: Codex GPT-6.1 Sol in T3 Code; tests: Codex GPT-6 Astra; adversarial reviews: Claude Opus 5.5 and Codex GPT-6 Sol.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
macroscopeapp
Bot
commented
Oct 8, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
Approvability
Verdict: Approved at 2e0a27b
Macroscope's review found this PR approvable — This is a narrowly scoped server-side bug fix that adds tested bare-repository detection while preserving normal checkout behavior. The contract change is documentation-only, and the runtime impact is limited to enabling existing repository identity and grouping flows for bare repositories.
You can add or adjust custom eligibility rules. Learn more.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
coderabbitai
Bot
commented
Oct 8, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
|

Warning
Review limit reached
Only developers with an assigned seat can use this organization's usage-based review budget, and seats here are assigned manually. Ask an admin to assign a seat, or change the review continuation mode in Billing.
Next included review available in 14 minutes.
Check out review usage here.
View limit details
-
Limit details: You’ve used all 10 included reviews currently available.
Learn how review limits work.
Review configuration:
⚙️ Run configuration
-
- Configuration used: Path: .coderabbit.config.ts
- Review profile: CHILL
- Plan: Advanced
- Run ID:
12097e6d-9b85-4a21-b32c-11a09e649cf5
📥 Commits
-
Reviewing files that changed from the base of the PR and between c0fe8a6 and f4954f5.
📒 Files selected for processing: 3
-
apps/server/src/project/RepositoryIdentityResolver.test.ts
apps/server/src/project/RepositoryIdentityResolver.ts
packages/contracts/src/environment.ts
No actionable comments were generated in the recent review. 🎉
ℹ️ Recent review info
-
⚙️ Run configuration
-
- Configuration used: Path: .coderabbit.config.ts
- Review profile: CHILL
- Plan: Advanced
- Run ID:
20cbfe2e-518e-4da2-84cd-3efd928dc753
📥 Commits
-
Reviewing files that changed from the base of the PR and between b512235fb9c99a86c00d81f2d5dc8ac97405daf3 and c0fe8a6.
📒 Files selected for processing: 2
-
apps/server/src/project/RepositoryIdentityResolver.test.ts
packages/contracts/src/environment.ts
🚧 Files skipped from review as they are similar to previous changes: 1
-
- packages/contracts/src/environment.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
📝 Walkthrough
-
Repository root resolution now recognizes bare repositories after an unsuccessful work-tree lookup. Tests cover bare repository layouts, failure cases, and checkout .git directories.
Changes: Repository identity resolution
| Layer / File(s) |
Summary |
Resolve work-tree and bare-repository roots apps/server/src/project/RepositoryIdentityResolver.ts, packages/contracts/src/environment.ts |
The resolver uses a shared Git invocation helper. It returns a nonempty work-tree path on success, and probes for a bare repository after an unsuccessful work-tree lookup. The contract comment describes rootPath for both repository types. |
Test repository root resolution apps/server/src/project/RepositoryIdentityResolver.test.ts |
Tests cover retries, timeouts and process-start failures, bare clones and dot-bare layouts, checkout .git directories, and bare repositories without remotes. |
Priority: ⬇️ Low
Estimated code review effort: 2 (Simple) | ~12 minutes
Change: Bug fix
Suggested reviewers: juliusmarminge
Merge Risk: ⚪ Minimal · up to c0fe8
-
Bare repositories can now share an identity with checkouts using the same remote. No actionable merge-blocking risk is established; the change is ready for normal merge checks.
Security architecture risk: 🔵 Low · up to c0fe8
-
This is a small repository-matching change with no demonstrated new security issue. Some downstream effects of newly recognized bare repositories remain unverified.
Retained concerns
No architecture-level concerns identified.
Security review details
-
Security Blast Radius
- inferred — The newly affected inputs are registered bare repositories whose local Git configuration supplies a remote. Their identities can participate in existing cross-environment repository selection. In the inspected pull-request selection path, matches still produce explicit environmentId, projectId, and workspaceRoot values rather than merging those ownership identifiers.
Trust Boundaries and Controls
- observed — Root discovery passes the supplied directory as a separate Git argument and accepts the fallback only after successful output reporting true and a nonempty Git directory. Ordinary executable dispatch is non-shell; the unchanged Windows batch-file branch uses argument sanitization. This does not turn a remote-derived grouping identity into proof of repository ownership.
- observed — Newly recognized bare identities enter the existing provider-refinement callback, which can resolve provider context. Its wiring is unchanged, but provider-specific host, account, and credential controls were not fully inspected; unchanged wiring alone does not establish unchanged effective exposure.
Resilience and Maintainability Implications
- observed — Existing project enrichment bounds worker concurrency and pending roots, releases pending reservations after resolution, and scopes workers and queues. The fallback adds one probe inside the existing root-cache loader rather than introducing another background worker or persistent reservation.
Pre-merge checks: 4
-
| Check name |
Status |
Explanation |
| Linked Issues check |
 |
Check skipped because no linked issues were found for this pull request. |
| Out of Scope Changes check |
 |
Check skipped because no linked issues were found for this pull request. |
| Title check |
 |
The title clearly and concisely describes the primary change: grouping bare repositories with projects that use the same remote. |
| Description check |
 |
The pull request description clearly explains the problem, implementation, scope, verification results, limitations, and test status. It does not provide a dedicated Scope and approval section or expl… |
Full details: Description check
-
Explanation
The pull request description clearly explains the problem, implementation, scope, verification results, limitations, and test status. It does not provide a dedicated Scope and approval section or explicit maintainer approval, but it links the originating contribution and gives sufficient context for this focused fix.
✨ Finishing Touches
-
🧪 Generate unit tests (beta)
-
- Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Comment @coderabbitai help to get the list of available commands.
|
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.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
…mote
`git rev-parse --show-toplevel` exits 128 in a bare repository, so bare-repo
projects resolved no repository identity and never grouped with same-remote
projects in other environments. When it fails, probe `--is-bare-repository
--absolute-git-dir` and key bare repositories by their git dir.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Taking over this one. I’ll preserve the original commits, merge main, and adapt bare-repository identity discovery around the current metadata fast path, with focused real-Git regression proof and independent reviews.
|
shrikantkalar023 reacted with heart emoji
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.
aorwall
added a commit
to aorwall/t3code
that referenced
this pull request
Oct 21, 2026
Merges `pingdotgg/t3code` `main` at `e64766c56a` (367 commits from
`143ab1606d`) into the fork. It branches from `main`; no other merge PR
is open.
## Numbers
- Landed: 2630 files from `git diff --stat HEAD^1 HEAD`, against 2629 in
the upstream range. The gap:
- Kept deleted: `pair.ts`, `pair.test.ts` and
`useDiscoveredLocalServers.test.ts`.
- Kept as fork files: `branding.test.ts` and
`addBrowserSurface.test.ts`.
- Extra on the merge side: four ported fork browser tests,
`fork/ThreadParentLine.tsx` and `inventory.json`.
- Fork delta: 812 files, down from 817.
## Conflicts (40, each by its preflight verdict)
- **Upstream's test prune (pingdotgg#22557):** upstream's deletions win,
fork-only tests stay, and fork adaptations of deleted upstream tests are
dropped.
- Upstream's deletion accepted for the `ThreadDetailsPrRows`,
`PreviewEmptyState`, `previewEmptyStateLogic`,
`projectScriptEditor.permissions` and `terminalSessionAvailability`
tests.
- Four fork browser tests are ported to the new
`require-disposable-render` pattern: ThreadForkDialog,
MoatlessArtifactChip, PreviewView.frame and MobileSidebarDrawer.
- **`threadRoutes.ts`, `ThreadRouteView.tsx`, `ChatView.tsx`:** take
upstream's `unlistedThreadDetail` (pingdotgg#19724), plus three fork changes:
- An unlisted thread is "missing" once its subscription has failed.
- A closed thread is not redirected by `archivedAt`, because it is
absent from a Moatless listing and still opens by URL.
- `onOpenRelatedThread` shows its toast only for a deleted shell.
The `unlisted-thread-adoption` inventory entry now owns
`threadRoutes.test.ts` and `ChatView.tsx`.
- **`AGENTS.md` (`decide`):** kept the fork bullet and appended
upstream's test rules and browser-test section.
- **Upstream's change with the fork delta re-stated:** `BranchToolbar`
(`showWorkspaceControls`), `GitActionsControl`, `ChatOverlayHosts`,
`FilePreviewPanel`, `projectFilesQueryState`, `usePreviewSession` (on
upstream's `inactiveAtom`) and `useThreadActions`.
- **`getSidebarForkParentThreadId`:** upstream removed it, so it moves
into `fork/ThreadParentLine.tsx`.
- **New inventory entries:** the `branding-test` path policy and the
`preview-session-use-atom-value` duplicate-add exception.
- **Sweep:** 19 owned-concern hits, all upstream-owned and taken as
upstream's. No new workflow.
## Feature classification
### Usable as-is
- Mermaid rendering through pele (pingdotgg#21472) and project icon previews
(pingdotgg#20372).
- Dialog and composer polish, PR panel fixes and centred tables.
- The Waiting thread state (pingdotgg#21500), which shows once the backend sends
`blockedOnThreadWait`.
- The even-pace tick on Limits (pingdotgg#22408).
### Unsupported in Moatless / needs implementation
- `device.easAccount` and EAS Simulator device hosts (pingdotgg#21841–pingdotgg#21846).
Added to the `UnsupportedMethodError` union, and the Integrations page
that holds them is already flag-gated.
- `projects.listIgnoredFiles` and the `ignoredFileListing` capability,
which "Add project to another machine" uses (pingdotgg#22180). Added to the
union. The dialog falls back to tracked files only while the capability
is absent.
- `pullRequests.changeBreakdown` (pingdotgg#22189, pingdotgg#22255). Its union already
carries `UnsupportedMethodError`, and the tooltip drops the split when
the call fails.
- T3 Connect reachability (pingdotgg#22172).
- Scheduled-task webhook filters and dedupe (pingdotgg#22194, pingdotgg#22234).
- `lastEventLoopStall` (pingdotgg#22213) and the `previewClose` scope (pingdotgg#22156).
- `compactIdleThreads` and `autoCompactThreshold` (pingdotgg#21682).
- MCP diff tools (pingdotgg#15464), the install id (pingdotgg#21506) and the writing-style
setting (pingdotgg#22203).
### Backend behavior to consider reproducing in Moatless
- **Settlement and waits:** `blockedOnThreadWait`, orphaned follow-ups
and delegated waits (pingdotgg#21499, pingdotgg#22581, pingdotgg#20037, pingdotgg#20025).
- **Stop and wake:** `latestRunStopRequested` stops a stopped
usage-limit thread from auto-resuming (pingdotgg#21114). A wake run settles when
the provider never opens the wake turn (pingdotgg#19196). Snooze survives a run's
completion (pingdotgg#22202, pingdotgg#17118).
- **Runs and shells:** run failures are persisted (pingdotgg#19646), and shell
updates coalesce for a slow client (pingdotgg#14859).
- **VCS:** bare repositories (pingdotgg#17340, pingdotgg#16688, pingdotgg#18152, pingdotgg#20368), stack
layers (pingdotgg#20415, pingdotgg#20388), VCS safety fixes (pingdotgg#15036, pingdotgg#19802) and PR
provider robustness (pingdotgg#18780).
- **Other:** update and restart safety (pingdotgg#22253), terminal and checkpoint
performance (pingdotgg#21242, pingdotgg#21291), resource metrics (pingdotgg#22122), provider
polling (pingdotgg#18851) and tool-token expiry (pingdotgg#18552, pingdotgg#19491).
`docs/fork/gaps.md` is updated under *Methods the backend does not
dispatch* and *Runtime fixes upstream made to its own server*.
## Verification
Full `verify.mjs` run: every check except `test` passes (duplicate-adds,
tripwires, resolution-check, unsupported-methods with ADD 2 / DROP 0 /
KEEP 2, lockfile, fmt, lint, typecheck and build).
Test failures and what was done about each:
- **Machine failures seen in earlier merges:** `shared` `AgentScope`,
`t3` `OrchestratorReplayFixtures` and `provider-opencode`
`OpenCodeServerLedger`. The `GitVcsDriver` and
`RepositoryIdentityResolver` partial-clone tests fail because of the
sandbox's `insteadOf` rewrite.
- **New and environmental:** `t3` `ProviderInstanceRegistry` reads the
sandbox's own `ANTHROPIC_*` and `CLAUDE_CONFIG_DIR`. With those unset,
all 9 of its tests pass.
- **`web`:**
- The fork's `AppRoot.test.tsx` broke on upstream's new `useEffect`
(pingdotgg#20886). It now stubs `useEffect` and passes.
- Four browser files failed to import in the parallel run and pass
alone.
- **Playwright:** 1.60 wants chromium build 1223, which this sandbox
lacks. Browser tests ran against 1243 through a symlinked
`PLAYWRIGHT_BROWSERS_PATH`.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
---
Moatless task:
https://moatless.soaplabstest.com/tasks/c3df6407-7ad0-483c-a46c-e8b603326150
Uh oh!
There was an error while loading. Please reload this page.
Labels
macroscope-review
Opt PRs made by unvouched contributors in for Macroscope review. Vouched contributors auto-reviews
size:M
30-99 changed lines (additions + deletions).
vouch:unvouched
Author is not yet trusted in the VOUCHED list.
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.
|