Repository navigation
π fix: qualify bare project repos when deriving the public repo set - #16238
Conversation
config.Load strips the org off project.repos and primary_repo, but registryPublicRepos added the bare names through publicRepoSet.add, which only accepts owner/name. A public hive therefore derived an empty public set, HubActivitySnapshot marked every tracker row Private, hubactivity.Build dropped them, and the hub's anonymous /activity/public view showed 0 items for every reporting hive. Qualify bare names with project.org (names that already carry an owner are left alone) and exercise the bare-name shape in tests. Closes #16234 Signed-off-by: Andrew Anderson <andy@clubanderson.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Open PR overlap checkBase branch: Conflicts are checked with every PR merged onto the current tip of No conflicting open PRs or same-file overlaps were found. |
There was a problem hiding this comment.
Read registryPublicRepos/publicRepoSet.add in src/pkg/dashboard/battle_log.go and the config loader at this head. The premise holds: src/pkg/config/config.go:5911 and :5914 store parts[1] for repos and primary_repo, so a public hive's live values really are bare names and add (owner/name only) was dropping all of them. qualifyProjectRepo leaves already-qualified and empty-org inputs alone, and the new table case plus the hub_activity_test.go fixture now use the bare shape the loader actually produces. Looks correct to me.
Note for whoever merges: #16239 fixes the same root cause (bare slug from config) at a different site (sentinel_sweep.go observer β Matrix allowlist). They touch disjoint files and are complementary, not duplicates β both should land.
Optional, not blocking: the dashboard already has this exact qualify-if-no-slash pattern inline at api_contribute.go:757-762, api_config.go:24, api.go:1429 and api_event_triggers.go:36; a later cleanup could point them at qualifyProjectRepo.
β hive: agent=reviewer backend=copilot model=claude-fable-5.1 copilot=1.0.88
|
Hive status β updated in place; edits do not notify. Full history is in the Activity Monitor. Review findings from Verified the premise rather than taking it from the body: Note for the maintainer: #16239 fixes the same root cause on the sentinel side ( |
|
Thank you for your contribution! Your PR has been merged. We'd love to hear how your experience was: share feedback |
Closes #16234
Root cause
config.Loadstrips the org offproject.repos/primary_repo(live hive config:repos: [crux, dibs, hive, β¦],primary_repo: "").registryPublicReposadded those bare names viapublicRepoSet.add, which requiresowner/name, so a public hive's derived public set was empty.HubActivitySnapshotthen marked every tracker rowPrivate,hubactivity.Builddropped them, and the hub's anonymous/activity/public(the fleet stream) showed 0 items for every reporting hive.Fix
Qualify bare names with
project.orginregistryPublicRepos(names that already carry an owner are untouched). The existingHubActivityItemsReadsTheMemoisedTrackertest now uses the bare-name shape config loading actually produces, andTestRegistryPublicReposDerivedFromPublicHivecovers bare / qualified / no-org cases.Validation
go test ./pkg/dashboard/ -run 'TestRegistryPublicRepos|TestHubActivity|TestBattleLogAndHiveOfWeek',go vet ./pkg/dashboard/.