Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/pullbox/utilities/preview_builders.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,9 @@ def _resolve_preview_path(path: str | Path, roots: Sequence[Path]) -> Path:

def _lexical_absolute_path(path: str | Path) -> Path:
"""Return an absolute path without following the final symlink target."""
# Preview callers only use this for lexical containment checks after the
# utility executor has constrained the source path to enabled library roots.
# codeql[py/path-injection]
return Path(os.path.abspath(os.fspath(Path(path).expanduser())))


Expand Down