Skip to content

enhance(build): finish to log compilied pkg. #14865

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

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
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
25 changes: 24 additions & 1 deletion src/cargo/core/compiler/job_queue/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1118,7 +1118,30 @@ impl<'gctx> DrainState<'gctx> {
}
let unlocked = self.queue.finish(unit, &artifact);
match artifact {
Artifact::All => self.timings.unit_finished(id, unlocked),
Artifact::All => {
self.timings.unit_finished(id, unlocked);
// Here we log the completion of a unit of work.
// This is useful for tracking the progress of the job queue.
debug!("Finished unit: {:?}", unit);
if unit.mode.is_doc() {
self.documented.insert(unit.pkg.package_id());
build_runner
.bcx
.gctx
.shell()
.status("Documented", &unit.pkg)?;
} else if unit.mode.is_doc_scrape() {
self.scraped.insert(unit.pkg.package_id());
build_runner.bcx.gctx.shell().status("Scraped", &unit.pkg)?;
} else {
self.compiled.insert(unit.pkg.package_id());
build_runner
.bcx
.gctx
.shell()
.status("Compiled", &unit.pkg)?;
}
}
Artifact::Metadata => self.timings.unit_rmeta_finished(id, unlocked),
}
Ok(())
Expand Down
Loading