[Bug] Doc drift reports a path about another repo when the repo name has a dot or the qualifier is on the previous line

Open
#6,264 2 comments 0 reactions 1 assignee View on GitHub

Maintainers usually reply within 1 day

@Gaurav01MH is already working on this.

Since Nov 25, 2026.

  • #6280 by @Gaurav01MH — open

Assessment

This issue has not been assessed yet.

Description

bug good first issue

Summary

Doc drift checks a path that is about another repository when that repository's name contains a dot, or when the qualifier sits on the previous wrapped line.

Mechanism

  • _foreign_project in packages/core/src/repowise/core/analysis/doc_drift/resolver.py:342 cuts the sentence at the last ., ! or ? before the path, so the dot in acme/scanner.js starts a new sentence and the "repo" qualifier is lost.
  • ref.context is the single source line (resolver.py:339), so a qualifier on the line above never reaches the regexes.

Repro

_foreign_project(ref("In the acme/scanner repo, `src/x.py` handles it."))
_foreign_project(ref("In the acme/scanner.js repo, `src/x.py` handles it."))

Output on main (6ea4f0a3e): 'other-repository', then ''. The second reference is reported as drift.

Impact

False drift findings on docs that point at a dotted repo name (socket.io, next.js).

Done looks like

  • A . inside a word.word token (no whitespace after it) does not end the sentence.
  • The previous line is passed into the check, or wrapped lines are joined before extraction.
  • Good first issue: one function and two cases.

Tests

tests/unit/analysis/doc_drift/: a dotted repo name, and a qualifier on a wrapped previous line.

Dominant language
Python
Stars
7.1k
Forks
756
Avg merge
21h 5m
Merged PRs (30d)
797

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from repowise-dev/repowise

All issues in repowise-dev/repowise

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.