claude-code - 💡(How to fix) Fix [BUG] Multi-repo session: href points to wrong repo

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Error Message

Error Messages/Logs

RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

In a Claude Code web session with two repositories, Claude generated a GitHub file URL with correct visible text but a malformed href. The href prepended the primary repo as a base URL and appended the full URL as a path suffix, making the link appear correct, but go to the wrong place.

What Should Happen?

Claude should construct GitHub URLs from the appropriate repo. I.e., if the file exists in repo-b, don't construct a link to repo-a.

Error Messages/Logs

Steps to Reproduce

  1. Configure a Claude Code web session to use two repos (org/repo-a and org/repo-b)
  2. Create a file in the second repo (org/repo-b/skill-b.md)
  3. Ask Claude to provide a link to a file in the second repo ("Can you provide a link to the skill.md in repo-b?")
  4. Claude constructs a malformed GitHub link where the text is correct but the actual href is malformed ("Here's the link: [github.com/org/repo-b/skill-b.md](https://github.com/org/repo-a/skill-b.md)")

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

No response

Claude Code Version

Claude Code web session (claude.ai/code)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Non-interactive/CI environment

Additional Information

A malformed link to org/repo-a/skill.md is given even if no skill.md exists in that repo.

Platform: Claude Code web session (claude.ai/code), remote execution environment, two GitHub repositories configured.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [BUG] Multi-repo session: href points to wrong repo