Add a local resource path portability audit - #2663
Merged
maziyarpanahi merged 12 commits intoAug 22, 2026
Merged
maziyarpanahi merged 12 commits into
maziyarpanahi merged 12 commits into
Conversation
…r2663-path-portability # Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
maziyarpanahi
changed the base branch from
master
to
batch/maziyarpanahi-filesystem-safety-2026-08-22
August 22, 2026 13:19
maziyarpanahi
merged commit Aug 22, 2026
2c878a9
into
batch/maziyarpanahi-filesystem-safety-2026-08-22
22 of 30 checks passed
15 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.
Description
Adds a deterministic, local-only audit for resource-path portability. It reports only normalized SHA-256 fingerprints, issue categories, and occurrence counts while detecting traversal, host-specific roots, Windows-reserved components, Unicode normalization drift, and case-fold collisions.
The review repair bounds path count, size, and component count; contains hostile iterator and path-like hooks; validates immutable report state; preserves UNC identity; detects Unicode-only normalization drift; and covers Windows invalid/control characters without echoing source paths.
Type of Change
Changes Made
Testing
Commands run:
.venv/bin/python -m pytest tests/unit/core/test_path_portability.py -q— 23 passed.venv/bin/python -m pytest tests/unit/core -q— 2,671 passed and 3 skipped; the sole socket-restricted sandbox failure passed on isolated rerun.venv/bin/python -m pytest tests/unit/test_docs_publication.py tests/unit/release/test_changelog.py tests/unit/test_public_api_docstrings.py -q— 27 passed.venv/bin/python -m mypy openmed/core/path_portability.py— passed.venv/bin/pre-commit run --files ...— passed.venv/bin/python scripts/docs/stage_pages.py— strict staged Pages build passedDocumentation
CHANGELOG.mdupdatedCode Quality
Dependencies
Related Issues
Closes #2637
Screenshots/Examples
Not applicable; this is a Python audit contract with canonical JSON output.