Commit ca1a046
committed
Allow workspace root sources to override member non-workspace sources for workspace members
When a workspace member (e.g., `app-a`) declares a non-workspace source (Git, path, etc.)
for another workspace member (e.g., `lib-x`) in its `tool.uv.sources`, but the workspace
root declares `lib-x = { workspace = true }`, fall back to the workspace root's source
instead of raising a `NonWorkspaceSource` error.
This supports the pattern where members declare Git sources for standalone use outside
the workspace, while the workspace root overrides them as workspace sources when
developing within the monorepo.
The regression was introduced in v0.9.3 when commit b151e0e fixed workspace member
glob normalization for `./` prefixed paths. Before that fix, workspaces using
`members = ["./packages/..."]` didn't properly discover members from child directories,
so the workspace member source check didn't fire.
Fixes #18232
https://claude.ai/code/session_01XBDgKsN3dyqoucYic8YNGn1 parent 6571827 commit ca1a046
2 files changed
Lines changed: 108 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
59 | 87 | | |
60 | 88 | | |
61 | 89 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9726 | 9726 | | |
9727 | 9727 | | |
9728 | 9728 | | |
| 9729 | + | |
| 9730 | + | |
| 9731 | + | |
| 9732 | + | |
| 9733 | + | |
| 9734 | + | |
| 9735 | + | |
| 9736 | + | |
| 9737 | + | |
| 9738 | + | |
| 9739 | + | |
| 9740 | + | |
| 9741 | + | |
| 9742 | + | |
| 9743 | + | |
| 9744 | + | |
| 9745 | + | |
| 9746 | + | |
| 9747 | + | |
| 9748 | + | |
| 9749 | + | |
| 9750 | + | |
| 9751 | + | |
| 9752 | + | |
| 9753 | + | |
| 9754 | + | |
| 9755 | + | |
| 9756 | + | |
| 9757 | + | |
| 9758 | + | |
| 9759 | + | |
| 9760 | + | |
| 9761 | + | |
| 9762 | + | |
| 9763 | + | |
| 9764 | + | |
| 9765 | + | |
| 9766 | + | |
| 9767 | + | |
| 9768 | + | |
| 9769 | + | |
| 9770 | + | |
| 9771 | + | |
| 9772 | + | |
| 9773 | + | |
| 9774 | + | |
| 9775 | + | |
| 9776 | + | |
| 9777 | + | |
| 9778 | + | |
| 9779 | + | |
| 9780 | + | |
| 9781 | + | |
| 9782 | + | |
| 9783 | + | |
| 9784 | + | |
| 9785 | + | |
| 9786 | + | |
| 9787 | + | |
| 9788 | + | |
| 9789 | + | |
| 9790 | + | |
| 9791 | + | |
| 9792 | + | |
| 9793 | + | |
| 9794 | + | |
| 9795 | + | |
| 9796 | + | |
| 9797 | + | |
| 9798 | + | |
| 9799 | + | |
| 9800 | + | |
| 9801 | + | |
| 9802 | + | |
| 9803 | + | |
| 9804 | + | |
| 9805 | + | |
| 9806 | + | |
| 9807 | + | |
| 9808 | + | |
9729 | 9809 | | |
9730 | 9810 | | |
9731 | 9811 | | |
| |||
0 commit comments