Skip to content

Commit 682e2a8

Browse files
committed
fix(build): improve handling of missing rustc args during workspace hotpatch replay
1 parent 2de87c9 commit 682e2a8

1 file changed

Lines changed: 9 additions & 6 deletions

File tree

packages/cli/src/build/link.rs

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -152,12 +152,15 @@ impl BuildRequest {
152152
let replayed_crates = self.workspace_hotpatch_replay_order(modified_crates)?;
153153
tracing::debug!("replaying crates: {replayed_crates:?}");
154154
for crate_name in &replayed_crates {
155-
let rustc_args = self
156-
.workspace_hotpatch_replay_args(workspace_rustc_args, crate_name)
157-
.with_context(|| format!("Missing rustc args for replay: '{crate_name}'"))?;
158-
self.compile_dep_crate(ctx, crate_name, rustc_args)
159-
.await
160-
.with_context(|| format!("Failed to replay workspace crate '{crate_name}'"))?;
155+
if let Some(rustc_args) =
156+
self.workspace_hotpatch_replay_args(workspace_rustc_args, crate_name)
157+
{
158+
self.compile_dep_crate(ctx, crate_name, rustc_args)
159+
.await
160+
.with_context(|| format!("Failed to replay workspace crate '{crate_name}'"))?;
161+
} else {
162+
tracing::warn!("No captured rustc args for workspace crate '{crate_name}', skipping");
163+
}
161164
}
162165

163166
// Recompile just the tip crate now

0 commit comments

Comments
 (0)