Overview
The Windows compile-required build fails in test_sync_repo_with_copybara.py while preparing the local Copybara source mirror.
Background
get_copybara_source_mirror_url() converts the Linux container path /tmp/copybara-output/source-mirror.git with Path.as_uri(). On Windows, Path interprets this POSIX path as a drive-less Windows path and raises ValueError: relative path can't be expressed as a file URI.
This failure is tracked by BF-45398.
Scope of Work
- buildscripts/copybara/sync_repo_with_copybara.py — construct the container-local file URI using POSIX path semantics.
- buildscripts/tests/test_sync_repo_with_copybara.py — add regression coverage for the expected URI.
Acceptance Criteria
- The Copybara source mirror URI is generated correctly on Windows.
- Existing Linux behavior remains unchanged.
- The unit test verifies file:///tmp/copybara-output/source-mirror.git.
Technical Notes
The fix uses PurePosixPath because the path is interpreted inside the Linux Copybara container, independent of the host operating system.
- related to
-
SERVER-134584 Add back Windows support for Copybara sync task generation and unit tests
-
- Closed
-