Skip to content

Comments

Fix uv sync accidentally retaining editables#15450

Closed
charliermarsh wants to merge 4 commits intomainfrom
fix/sync-no-sources-editable-switch
Closed

Fix uv sync accidentally retaining editables#15450
charliermarsh wants to merge 4 commits intomainfrom
fix/sync-no-sources-editable-switch

Conversation

@charliermarsh
Copy link
Member

Summary

Closes #15190.

yumeminami and others added 4 commits August 12, 2025 16:32
- Added logic to force reinstall URL-based packages when `--no-sources` is specified, ensuring they are replaced with registry versions.
- Updated the `do_sync` function to handle the reinstall logic based on the presence of URL-based packages in the environment.
- Introduced a new test to verify the correct transition from editable to package installation when using the `--no-sources` flag, addressing Issue #15190.

This change improves the reliability of package installations in environments where source installations are disabled.
- Updated the logic to selectively reinstall URL-based packages only when the resolution selects a registry distribution, preventing unnecessary reinstalls for packages specified via direct URL.
- Enhanced debug logging for better clarity on package evaluation during the reinstall process.
- Adjusted related test expectations to reflect the changes in package installation behavior.

This change improves the efficiency of package management when source installations are disabled.
@charliermarsh
Copy link
Member Author

Closing in favor of #15234.

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.

uv sync does not switch from editable to plain install when run with --no-sources

2 participants