You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Preserve repository ownership in overview snapshots - #151
A combined repository overview needs to keep repositories with the same name distinct. It also needs to keep existing snapshots readable and primary organization detail links working.
Store repository owners in schema 31, infer owners when reading schema 30, and give secondary organizations their own detail page namespace. Use repository ownership in GitHub links and dependency matching.
Support rendering snapshots that contain identically named repositories from different organizations. Store the repository owner, reserve a namespace for secondary detail pages, and continue to read schema 30 snapshots.
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
Approval is blocked by unresolved moderate and critical issues that leave same-named repositories ambiguous, fail to populate owner data through collection, and allow unvalidated owner values to corrupt Markdown links.
This pull request upgrades repository overview snapshots to preserve repository ownership across schema migrations and multi-organization views, adding owner-aware links and detail-page paths.
Changes:
Adds schema 31 ownership metadata with schema 30 compatibility.
Updates Markdown and HTML renderers, dependency matching, and repository links for owned repositories.
Adds multi-organization regression tests and documents snapshot behavior.
File
Description
tests/test_multi_organization.py
Adds tests for invalid repository paths, secondary-organization namespaces, and schema 30 migration.
src/generate_repo_overview/profile_readme.py
Renders owner-qualified names and links for repositories in secondary organizations.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Two active findings remain: repository ownership is not populated or preserved through collection and caching, and empty-owner URL validation fails to fall back to primary_org, allowing malformed links.
No open issues 🎉
1 previously missed issue
In code that hasn't changed since last review
Validate primary organization when repository owner is empty
src/generate_repo_overview/models.py:364
This validation omits primary_org when entry.owner is empty, which is the normal primary-repository representation in schema 31. HTML callers invoke detail_path before constructing GitHub URLs, so a snapshot with an invalid primary org_name bypasses the new path-segment guard and still emits a malformed link. Validate using primary_org as the default owner here.
Follow-up to the empty-owner validation finding. In 5e31bac, HTML detail rendering validates the primary organization when a repository has no explicit owner. The regression test covers a schema 31 snapshot with an empty owner and an invalid primary organization.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because the compatibility change introduces a subtle inconsistency between the loader’s accepted schema versions and its rejection diagnostic.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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.
Why
A combined repository overview needs to keep repositories with the same name distinct. It also needs to keep existing snapshots readable and primary organization detail links working.
Store repository owners in schema 31, infer owners when reading schema 30, and give secondary organizations their own detail page namespace. Use repository ownership in GitHub links and dependency matching.
Part of #123.