Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions crates/uv/src/commands/project/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,8 @@ hint: If you are running a script with `{}` in the shebang, you may need to incl
.await?
.into_environment()?;

let _lock = environment.lock().await?;

// Determine the lock mode.
let mode = if frozen {
LockMode::Frozen
Expand Down Expand Up @@ -363,6 +365,8 @@ hint: If you are running a script with `{}` in the shebang, you may need to incl
.await?
.into_environment()?;

let _lock = environment.lock().await?;
Copy link
Member

Choose a reason for hiding this comment

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

nit: we can more one statement later, just before update_environment


let build_constraints = script
.metadata()
.tool
Expand Down Expand Up @@ -685,6 +689,8 @@ hint: If you are running a script with `{}` in the shebang, you may need to incl
.map(|lock| (lock, project.workspace().install_path().to_owned()));
}
} else {
let _lock = venv.lock().await?;

// Determine the lock mode.
let mode = if frozen {
LockMode::Frozen
Expand Down
Loading