Skip to content

Handle Windows absolute paths as file URIs#230

Open
anoobbacker wants to merge 1 commit into
microsoft:mainfrom
anoobbacker:fix/windows-absolute-paths
Open

Handle Windows absolute paths as file URIs#230
anoobbacker wants to merge 1 commit into
microsoft:mainfrom
anoobbacker:fix/windows-absolute-paths

Conversation

@anoobbacker

@anoobbacker anoobbacker commented May 26, 2026

Copy link
Copy Markdown
Member

Problem

On Windows, a relative bundle module source can resolve to a drive-letter absolute path, but the source resolver does not treat C:\... as a local file path, causing module activation to fail.

PS D:\projects\sample-repo> amplifier
Failed to activate tool-apply-patch: No handler for URI: C:\Users\jane.doe\.amplifier\cache\amplifier-bundle-filesystem-abc123def456\modules\tool-apply-patch

Summary

  • Treat Windows drive-letter absolute paths as file URIs in parse_uri()
  • Treat UNC paths as file URIs
  • Add regression tests for both path forms

Tests

  • uv --directory C:\git\amplifier-foundation run pytest tests/test_paths.py::TestParseUri tests/test_sources.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant