Repository navigation
fix(code-metrics): partial type-debt run on hyphenated same-named modules (#4123) - #4765
Merged
Merged
Conversation
…al (#4123) Two same-named files under hyphenated directories (a-dir/mod.py, b-dir/mod.py) both derive a bare module name, and mypy stopped before analysis, turning the whole Python lane unavailable. The mypy-report collector now groups the scope by the derived module name, keeps the first file of each group (the one mypy itself keeps), measures the rest of the scope, and writes the held-out files to the partial-reason file so the run row reads partial. A duplicate only mypy's __init__.py naming mode produces is held out from mypy's own message and the run repeats. Any other blocking mypy error still reaches the exit-4 unavailable row. Adds a real mypy 1.19.1 capture and tests for the stub, the naming-mode path, and the real mypy. Co-authored-by: Kyle Sexton <[email protected]>
Contributor
|
PR body contract — issue linkage This PR body conforms to the issue-linkage contract. Nothing to do. |
5 tasks
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Closes #4123
Summary
Type-debt Python lane reports
partial(other files measured) when same-named modules collide under hyphenated directories, instead of whole-laneunavailable(triage option 3).code-metrics→ 0.3.19.Fix
CODE_METRICS_PARTIAL_REASON_FILEchannel (same as jscpd).Verification
Related
jscpd.pypartial-reason channel precedent