You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 73be80e
Browse filesBrowse the repository at this point in the historyBrowse files
* Start fix for #673
Assisted-by: Claude Code:claude-opus-5-5
* Refuse hosted Hatch pins shadowed by uv sources
When a Hatch environment uses the uv installer, uv resolves a project
dependency through the project's [tool.uv.sources] entry instead of
the direct reference hosted mode writes. A url or path source then
installs the unpatched wheel while the scan reports "redirected", and
a git source breaks every install with conflicting URLs.
Hosted Hatch now refuses such a pin before writing, as it already does
for Hatch's own source tables, and reports redirect_hatch_unsupported.
Environment dependencies, index-only sources and the pip installer
are unaffected and still rewrite.
Fixes#673
Assisted-by: Claude Code:claude-opus-5-5
* Also refuse uv sources under the uv env switch
HATCH_ENV_TYPE_VIRTUAL_UV_PATH switches Hatch to the uv installer with
no file setting, so a url or path source still shadowed the hosted
pin there. An empty source array is no longer treated as index-only.
Refs #673
Assisted-by: Claude Code:claude-opus-5-5
---------
Co-authored-by: Claude <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: docs/testing/hatch.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,7 +35,9 @@ A `pylock.toml` in a Hatch project without locked environments (`uv export`,
35
35
36
36
A range, transitive-only declaration, dynamic dependency metadata, custom
37
37
environment plugin, source table or conditional override is refused before
38
-
writing. Use agent mode (`scan --mode agent` + `socket-patch apply` in CI) for these shapes. Hosted PEP 735 groups are
38
+
writing. So is a project-table pin of a package with a url, path, git or
39
+
workspace entry in `[tool.uv.sources]` when an environment uses the uv
40
+
installer: uv applies that source over the hosted reference (#673). Use agent mode (`scan --mode agent` + `socket-patch apply` in CI) for these shapes. Hosted PEP 735 groups are
39
41
supported; vendored groups are refused because Hatch does not expand
40
42
`{root:uri}` within dependency groups. Unknown direct sources require an
41
43
explicit revert before patching. A hosted scan re-pins socket-patch's own
0 commit comments