Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid dropping pip sync requirements with markers #4051

Merged
merged 1 commit into from
Jun 5, 2024
Merged

Conversation

charliermarsh
Copy link
Member

Summary

Thankfully this is pretty rare since pip sync is usually run on pip compile output, and pip compile never outputs markers.

Closes #4044

@charliermarsh charliermarsh added the bug Something isn't working label Jun 5, 2024
@charliermarsh charliermarsh marked this pull request as ready for review June 5, 2024 15:56
@@ -968,7 +968,21 @@ impl<InstalledPackages: InstalledPackagesProvider> ResolverState<InstalledPackag
.wait_blocking(&version_id)
.ok_or(ResolveError::Unregistered)?;

return Ok(Dependencies::Available(Vec::default()));
// If a package has a marker, add a dependency from it to the
// same package without markers.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to the comment below, there may be a better way to solve this. I have a feeling we might want a separate PubGrubPackageInner marker type.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have that same feeling, especially after you added the Extra variant.

Copy link
Member

@BurntSushi BurntSushi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahhhh right, I see now. The fix makes sense to me. Thank you!

@charliermarsh charliermarsh merged commit ae96101 into main Jun 5, 2024
46 checks passed
@charliermarsh charliermarsh deleted the charlie/m branch June 5, 2024 16:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

uv pip sync requirements.txt does nothing on 0.2.6 with python_full_version specified
3 participants