Repository navigation
fix: use dots for Windows path separators in fullyQualifiedName - #112
Merged
Merged
Conversation
os.walk and os.path.join yield backslash paths on Windows, which the replace of '/' left untouched, so annotations.yml named elements like src\pkg\mod.func. Normalise with PurePath.as_posix() first. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Mt2FAVc4k9yNuEdkfxHdQX Signed-off-by: Jimisola Laursen <jimisola@jimisola.com>
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.
Requested by Jimisola · project thread
Fixes #111.
What & Why
fullyQualifiedNamewas built withstr(file_path).replace("/", "."). On Windows, paths fromos.walk/os.path.joinuse backslashes, so nothing was replaced andannotations.ymlheld names likesrc\pkg\mod.func, which reqstool-client can't match to code. Now the path goes throughPurePath(...).as_posix()first; behaviour on POSIX is unchanged.Test plan
PureWindowsPath("src\\pkg\\mod.py")(works on any host) and expectssrc.pkg.mod.my_func. It fails without the fix.hatch run dev:pytest tests/unit: 38 passed; black and flake8 clean🤖 Generated with Claude Code
https://claude.ai/code/session_01Mt2FAXZTXnbKG2Ho6GYy1z