Summary
When exporting to pylock.toml, uv currently emits absolute file URLs on all platforms. The "URLs" emitted on windows dump in the raw Windows path, including the use of backslash separators instead of forward slash ones.
This is inconvenient when the local files should be located relative to the lock file (e.g. when they're stored in Git LFS).
Proposed changes:
- always use POSIX path separators in
pylock.toml, even on Windows
- emit relative
path entries rather than absolute url entries where possible
- emit absolute
path entries on Windows if the files referenced are on a different drive from the lock file export location
There could potentially be a config flag to force the use of absolute paths (that may still be useful for some use cases where the files are in known locations on target systems of interest, but the location of the lock file itself at installation time isn't the same as it's location when being exported)
Example
No response
Summary
When exporting to
pylock.toml,uvcurrently emits absolute file URLs on all platforms. The "URLs" emitted on windows dump in the raw Windows path, including the use of backslash separators instead of forward slash ones.This is inconvenient when the local files should be located relative to the lock file (e.g. when they're stored in Git LFS).
Proposed changes:
pylock.toml, even on Windowspathentries rather than absoluteurlentries where possiblepathentries on Windows if the files referenced are on a different drive from the lock file export locationThere could potentially be a config flag to force the use of absolute paths (that may still be useful for some use cases where the files are in known locations on target systems of interest, but the location of the lock file itself at installation time isn't the same as it's location when being exported)
Example
No response