You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug: build_context emits OS-native (backslash) component paths on Windows — non-portable SARIF + Windows test failures #86
build_context emits OS-native path separators for relative component paths. On Windows this produces backslashes (e.g. references\guide.md), where every other consumer expects forward slashes.
In src/skillspector/nodes/build_context.py, the relative path is built with str(item.relative_to(skill_dir)), which yields references\guide.md on Windows.
Why it matters
These relative paths are used as:
keys in components / file_cache / component_metadata, and
SARIF physicalLocation URIs, which are meant to be portable, forward-slash, URI-style paths.
So on Windows the generated SARIF report contains non-portable backslash locations, and any integrator (or test) that keys findings by forward-slash paths silently mismatches. It also makes the unit/integration suite fail on Windows (11 tests in test_build_context.py and the semantic-analyzer fixtures), which raises the barrier for contributors developing on Windows.
Fix
Use Path.as_posix() so component paths are forward-slash on every OS, in build_context and the handful of test helpers that mirror the same relative_to logic. One-line, behavior-preserving on Linux/macOS (where str() already produces forward slashes).
I have the fix ready and will open a small PR referencing this issue.
Activity
fix(build_context): use forward-slash component paths (cross-platform)
Merge PR #87: use Path.as_posix() for build_context paths (#86)