Repository navigation
Fix Windows path inference for opaque URIs with slash prefixes - #49388
Merged
copyberry[bot] merged 1 commit intoSep 29, 2026
Conversation
## Why Opaque Windows paths encoded as UTF-16LE could be mistaken for POSIX paths when they began with `/`, or fail Windows convention inference when their leading separators mixed `/` and `\`. This prevented them from retaining the Windows path convention across URI serialization. ## What changed Distinguish a UTF-16LE slash from a POSIX root and recognize either Windows separator in both positions of an opaque UNC prefix. ## Testing Add round-trip coverage for Windows drive, UNC, device, and namespace paths, including forward and mixed separators. Cover JSON serialization, absolute-path joins, relative-path separator handling, and Windows-only host-native conversions. GitOrigin-RevId: d4e8a40a314cfc030c30fa8c124bfdd1e565076d
copyberry
Bot
force-pushed
the
copyberry/codex-internal-to-codex-oss/d4e8a40a314cfc030c30fa8c124bfdd1e565076d
branch
from
September 29, 2026 22:49
f825a24 to
d657132
Compare
copyberry
Bot
deleted the
copyberry/codex-internal-to-codex-oss/d4e8a40a314cfc030c30fa8c124bfdd1e565076d
branch
September 29, 2026 22:49
Contributor
|
I have read the CLA Document and I hereby sign the CLA You can retrigger this bot by commenting recheck in this Pull Request. Posted by the CLA Assistant Lite bot. |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Fix Windows path inference for opaque URIs with slash prefixes
Why
Opaque Windows paths encoded as UTF-16LE could be mistaken for POSIX paths when they began with
/, or fail Windows convention inference when their leading separators mixed/and\. This prevented them from retaining the Windows path convention across URI serialization.What changed
Distinguish a UTF-16LE slash from a POSIX root and recognize either Windows separator in both positions of an opaque UNC prefix.
Testing
Add round-trip coverage for Windows drive, UNC, device, and namespace paths, including forward and mixed separators. Cover JSON serialization, absolute-path joins, relative-path separator handling, and Windows-only host-native conversions.