Skip to content

acq: loud/gated kit-fetch fallback + docs for git-credential vs gh auth (public kit fetch) #208

Closed

Description

@wz-gsa

Summary

Two smaller issues surfaced alongside the interactive-prompt bug (#) in acq.backends/kit-translate.sh, split out so # stays a focused code fix.

1. Silent "pass ref through to sbx on failure" masks the real failure

On a kit fetch failure, acq emits warning: could not fetch kit; passing ref through: … and hands the raw ref to the sbx backend. The consensus panel flagged this as the single biggest risk: it masks the real error (the user sees a confusing downstream git-password error rather than a clear kit-fetch failure) and can silently run against a stale/unexpected ref.

Change (not remove — removal could break workflows that rely on passthrough): make the warning loud and actionable (name the fetch error + remedy), and consider gating passthrough behind an explicit opt-in (env/flag) so the default fails loudly. Keep backward-compat with a deprecation note if we later default it off.

2. Docs: git-credential vs gh auth, and the public-repo fetch

The kit repo (GSA-TTS/agentic-coding-patterns) is public — the fetch should need no credentials. But users with a global git credential helper or url.*.insteadOf rewrite hit friction with no documented remedy. Add:

  • A KNOWN_FAILURE_MODES entry: symptom (Username for 'https://github.com': prompt during acq run), cause (gh CLI auth ≠ git credential; a global helper/insteadOf forces auth on a public clone), fix (gh auth setup-git, or inspect git config --global --get-regexp 'url\..*insteadOf'), and the egress-restricted/enterprise-mirror caveat.
  • A short note in the acq docs (docs/explorations/acq-design.md or the acq usage docs) clarifying the same distinction.

Provenance

Found via a real user report (kit fetch prompting for GitHub credentials during acq run) + a consensus design review. Companion to # (the non-interactive fetch fix).

Activity

  1. added
    bugSomething isn't working
    documentationImprovements or additions to documentation
    on Jul 21, 2026
  2. wz-gsa commented on Aug 4, 2026

    @wz-gsa
    ContributorAuthor

    Resolved (verified against current code). Both acceptance items are met:

    1. No silent pass-through on fetch failure. acq.backends/kit-translate.sh _kit_git_fetch (anonymous attempt → authed retry, both with GIT_TERMINAL_PROMPT=0) now hard-fails loud on genuine failure — kit-translate: failed to fetch <ref> plus the captured git error and an actionable guidance block. The old "warning: could not fetch kit; passing ref through" behavior is gone (grep confirms no pass-through-to-sbx-on-failure remains).
    2. git-credential vs gh-auth docs. docs/KNOWN_FAILURE_MODES.md entry 25 documents the gh auth login (gh CLI) vs plain-git distinction, the insteadOf-rewrite trap, and the gh auth setup-git fix.

    Closing as done. (The companion bug #207 non-interactive fetch is the code half; this issue was the loud-fallback + docs half.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingdocumentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions