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

Include option to save failed build environments #157

Merged
merged 7 commits into from
Jan 23, 2024
Merged
Prev Previous commit
Next Next commit
feat: just clone the saved_build_envs value
  • Loading branch information
tdejager committed Jan 23, 2024
commit cec1bc8016a9de45a0e6b47d723bc11d1e29fb70
6 changes: 3 additions & 3 deletions crates/rattler_installs_packages/src/wheel_builder/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -217,8 +217,8 @@ impl<'db, 'i> WheelBuilder<'db, 'i> {
}

/// Get the paths to the saved build environments
pub fn saved_build_envs(&self) -> parking_lot::MutexGuard<HashSet<PathBuf>> {
self.saved_build_envs.lock()
pub fn saved_build_envs(&self) -> HashSet<PathBuf> {
self.saved_build_envs.lock().clone()
}

/// Handle's a build failure by either saving the build environment or deleting it
Expand All @@ -236,7 +236,7 @@ impl<'db, 'i> WheelBuilder<'db, 'i> {

// Save the information for later usage
let path = build_environment.work_dir();
tracing::info!("saving build environment to {:?}", &path);
tracing::info!("saved build environment is available at: {:?}", &path);
self.saved_build_envs
.lock()
.insert(build_environment.work_dir());
Expand Down