← Back to Pull requests

Link repos to their own host, like GitLab, not always GitHub #85

Closed
unknown closed this pull request without merging on Nov 28, 2026 10:49 UTC
View on GitHub
unknown unknown commented on Nov 23, 2026 10:32 UTC
Author

Fixes #84.

A linked repo's key is its path, so a project linked to a GitLab repo opened github.com/<path> from the board's header and from kanzo export. Now each linked repo keeps the host of the URL it was linked with, and links go there.

  • Store: a new migration, ALTER TABLE project_repos ADD COLUMN host TEXT. create_project and link_repo set it with host_from_url (gitlab.com from git@gitlab.com:acme/api.git, https://me:token@… or ssh://git@host:2222/…; a user, password or port is never stored). An SSH alias like github-work has no dot, so it counts as unknown. Empty means GitHub, so owner/repo and every repo linked before this work as they did. The column has no default, so COMPATIBLE_FROM stays at 4.

  • Project.repo_urls: each repo's page, in the order of repos. The board and kanzo export link with it. The board falls back to github.com when it gets no repo_urls from an older board it joined. A repo that isn't on github.com gets a git-branch icon (Lucide) instead of the GitHub one.

  • MCP: kanzo mcp keeps the remote URL next to each repo of the folder. When create_project or link_repo gets the folder's repo as owner/repo, it uses that remote, so the host isn't lost. Replies don't change. "GitHub owner/repo." becomes "owner/repo." in two argument docs, and "GitHub" is dropped from link_repo's description and the instructions, so the tool list gets a few bytes shorter.

  • Wording: the labels say "repo" instead of "GitHub repo" (zh-CN updated). Sync offers "Create a private repo on GitHub or GitLab", and the sign-in hint adds glab auth login.
  • Matching agents to projects is unchanged: it still uses the path alone.

    Not covered: a repo linked through an SSH alias, or before this change, still links to GitHub. Unlinking it and linking it again with its URL fixes it. A self-hosted instance on a non-default web port gets links without the port.

  • cargo fmt --check, cargo clippy --all-targets -- -D warnings and cargo test pass (100 tests, 3 new: store::hosts, store::repo_links_go_to_their_host, mcp::a_repo_linked_by_name_keeps_the_host_of_the_folders_remote)

  • A board change was tried in a browser, in light and dark mode. Not done: I checked the API on a throwaway board (repo_urls comes back as https://gitlab.com/acme/backend/api and https://github.com/me/api-docs), but couldn't open a browser on that machine. The header link and the Sync row (now a <span> holding two links) need a look.

  • The README says what changed for users
  • Diff: 320 lines (+240 / -80) across 4 files Reviewer: emanuele-em Review duration: 7216m
    All Vouch review confidence checks passed
    Residual risk 0.17 = Change Risk (0.42) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.42 · 320 lines diff across 4 files
    0.42
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.345
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #85"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 41.9% (MEDIUM) · Higher = larger blast radius
    41.9%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 16.6% · Safe to merge
    16.6%