Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): resolve partial clone repository identities #7499

Closedmarinushv(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromrefs/pull/7499/headopened View on GitHub

What

Resolve repository identity for Git partial clones whose git remote -v fetch line includes transport metadata such as [blob:none].

Why

The parser previously required (fetch) to be the end of the line. For partial clones, that left repositoryIdentity empty, so projects on those machines could not group with normal clones of the same repository.

Validation

  • vp test apps/server/src/project/RepositoryIdentityResolver.test.ts (8 passed)

Note

Low Risk Narrow parser change in project identity resolution with a targeted test; no auth, data, or broad API surface impact.

Overview Repository identity resolution now tolerates Git partial-clone metadata on git remote -v lines (e.g. [blob:none] after (fetch)), so those workspaces get the same canonical identity as full clones.

parseRemoteFetchUrls in RepositoryIdentityResolver extends the line regex to accept zero or more bracketed annotations after the fetch/push direction while still extracting remote name and URL. A new integration test configures remote.origin.promisor and partialclonefilter and asserts the expected GitHub canonical key and origin locator.

Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit adbf94c81b0ee64f1da092fa7b12bc14e28d13a6. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).
    1. Important

      Review skipped

      Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

      ⚙️ Run configuration

      Configuration used: Repository UI

      Review profile: CHILL

      Plan: Pro Plus

      Run ID: b1ed221f-bb5f-4a73-acbf-2e1b3910e9ab

      You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

      Use the checkbox below for a quick retry:

      • 🔍 Trigger review

      Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

      ❤️ Share
      Comment `@coderabbitai help` to get the list of available commands.
    2. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched

    3. Approvability

      Verdict: Approved at adbf94c

      Macroscope's review found this PR approvable — This is a straightforward bug fix that extends a regex to handle git's partial clone annotations in remote output. The change is backwards compatible, well-scoped, and includes a test verifying the fix.

      You can add or adjust custom eligibility rules. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    4. Maintainer verification: the tolerant fetch/push suffix is conservative — name/url/direction capture is unchanged and normal lines parse exactly as before. One test-strength caveat (non-blocking): the regression relies on the installed git annotating remote -v with [blob:none]; if a git ever omits that annotation the test passes without exercising the regex. A synthetic-stdout unit case would make it airtight, but I would not hold the PR for it.

    5. juliusmarminge added labelsmacroscope-review

    6. juliusmarminge assignedjuliusmarminge

    7. Taking over this one. I’ll reduce the tests to the useful coverage, update the implementation against current main, and verify it before publishing the changes.

    8. Thanks @marinushv for identifying and fixing partial-clone repository identity resolution. I compared this change with the published #16316 at ab39784. It preserves the same real-Git blob:none identity regression, including the canonical repository key and fetch remote, and covers four additional remote readers.

      The remaining regex difference is repeated bracket acceptance; actual Git emits one bracket field, including combined filters, which that implementation handles. Closing this as superseded by #16316, with your original intent covered there. Thank you!

    9. juliusmarminge closed this

Sign in to join this conversation.