-
Notifications
You must be signed in to change notification settings - Fork 530
feat: pixi add skips already-present packages without version spec
#6145
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
base: main
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -333,8 +333,17 @@ impl DependencyConfig { | |
| &self, | ||
| operation: &str, | ||
| implicit_constraints: HashMap<String, String>, | ||
| skipped: &[String], | ||
| ) { | ||
| for package in self.specs.clone() { | ||
| if skipped.iter().any(|s| { | ||
| package == s.as_str() | ||
| || package.strip_prefix(s.as_str()).is_some_and(|rest| { | ||
| rest.starts_with(|c: char| !c.is_alphanumeric() && c != '-' && c != '_') | ||
| }) | ||
| }) { | ||
| continue; | ||
| } | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What does this do?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This prevents the "✔ Added crane" logs from appearing for packages that we skip. The extra prefix testing is to handle the fact that
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 9ca5329 refactors this to use the CondaDependency/PypiDependency types and filter in add.rs |
||
| eprintln!( | ||
| "{}{operation} {}{}", | ||
| console::style(console::Emoji("✔ ", "")).green(), | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.