diff --git a/src/backend/mod.rs b/src/backend/mod.rs index 75b0cdc8c3..041f3b262c 100644 --- a/src/backend/mod.rs +++ b/src/backend/mod.rs @@ -779,7 +779,8 @@ pub trait Backend: Debug + Send + Sync { } } // Check for --locked mode: if enabled and no lockfile URL exists, fail early - if ctx.locked { + // Exempt tool stubs from lockfile requirements since they are ephemeral + if ctx.locked && !tv.request.source().is_tool_stub() { let platform_key = self.get_platform_key(); let has_lockfile_url = tv .lock_platforms