-
Notifications
You must be signed in to change notification settings - Fork 23
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
feat: move favored,locked package and env variables into ResolveOptions #218
feat: move favored,locked package and env variables into ResolveOptions #218
Conversation
@@ -434,7 +431,7 @@ mod tests { | |||
let (wheel_builder, _temp) = setup(ResolveOptions::default()).await; | |||
|
|||
// Build the wheel | |||
wheel_builder.build_wheel(&sdist).await.unwrap(); | |||
wheel_builder.clone().build_wheel(&sdist).await.unwrap(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need the clone here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
because later we do this:
// Build the wheel
wheel_builder.build_wheel(&sdist).await.unwrap();
// See if we can retrieve it from the cache
wheel_builder
.package_db
.local_wheel_cache()
.wheel_for_key(&key)
.unwrap()
.unwrap();
and wheel builder is moved because of build_wheel
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait.. we don't want that at all, then we should accept a self: &Arc<self>
in the WheelBuilder
we definitely do not want to move for each method call
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would result in too many clones.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agree - changed to passing references
No description provided.