]> git.proxmox.com Git - cargo.git/commitdiff
Downgrade some log messages.
authorEric Huss <eric@huss.org>
Sat, 15 Jan 2022 22:16:50 +0000 (14:16 -0800)
committerEric Huss <eric@huss.org>
Sat, 15 Jan 2022 22:16:50 +0000 (14:16 -0800)
src/cargo/core/compiler/context/compilation_files.rs
src/cargo/core/compiler/job_queue.rs
src/cargo/core/compiler/mod.rs
src/cargo/sources/git/utils.rs

index 37ab252022325077820d80f7d800213d869af260..5efc84c988d0d617be99b400dcd88f29d59f85d2 100644 (file)
@@ -6,7 +6,7 @@ use std::path::{Path, PathBuf};
 use std::sync::Arc;
 
 use lazycell::LazyCell;
-use log::info;
+use log::debug;
 
 use super::{BuildContext, CompileKind, Context, FileFlavor, Layout};
 use crate::core::compiler::{CompileMode, CompileTarget, CrateType, FileType, Unit};
@@ -435,7 +435,7 @@ impl<'a, 'cfg: 'a> CompilationFiles<'a, 'cfg> {
             | CompileMode::Bench
             | CompileMode::Check { .. } => self.calc_outputs_rustc(unit, bcx)?,
         };
-        info!("Target filenames: {:?}", ret);
+        debug!("Target filenames: {:?}", ret);
 
         Ok(Arc::new(ret))
     }
index 4e64ec110bd1c1d6000061f025c4c8f482d637bc..86f23ee1c9e3ef798597630daf7889ecba1cd565 100644 (file)
@@ -61,7 +61,7 @@ use anyhow::{format_err, Context as _};
 use cargo_util::ProcessBuilder;
 use crossbeam_utils::thread::Scope;
 use jobserver::{Acquired, Client, HelperThread};
-use log::{debug, info, trace};
+use log::{debug, trace};
 use semver::Version;
 
 use super::context::OutputFile;
@@ -649,7 +649,7 @@ impl<'cfg> DrainState<'cfg> {
                     // If `id` has completely finished we remove it
                     // from the `active` map ...
                     Artifact::All => {
-                        info!("end: {:?}", id);
+                        trace!("end: {:?}", id);
                         self.finished += 1;
                         if let Some(rustc_tokens) = self.rustc_tokens.remove(&id) {
                             // This puts back the tokens that this rustc
@@ -670,11 +670,11 @@ impl<'cfg> DrainState<'cfg> {
                     // ... otherwise if it hasn't finished we leave it
                     // in there as we'll get another `Finish` later on.
                     Artifact::Metadata => {
-                        info!("end (meta): {:?}", id);
+                        trace!("end (meta): {:?}", id);
                         self.active[&id].clone()
                     }
                 };
-                info!("end ({:?}): {:?}", unit, result);
+                debug!("end ({:?}): {:?}", unit, result);
                 match result {
                     Ok(()) => self.finish(id, &unit, artifact, cx)?,
                     Err(e) => {
@@ -695,7 +695,7 @@ impl<'cfg> DrainState<'cfg> {
                 self.tokens.push(token);
             }
             Message::NeedsToken(id) => {
-                log::info!("queue token request");
+                trace!("queue token request");
                 jobserver_helper.request_token();
                 let client = cx.rustc_clients[&self.active[&id]].clone();
                 self.to_send_clients
@@ -733,7 +733,7 @@ impl<'cfg> DrainState<'cfg> {
         // listen for a message with a timeout, and on timeout we run the
         // previous parts of the loop again.
         let mut events = self.messages.try_pop_all();
-        info!(
+        trace!(
             "tokens in use: {}, rustc_tokens: {:?}, waiting_rustcs: {:?} (events this tick: {})",
             self.tokens.len(),
             self.rustc_tokens
@@ -966,7 +966,7 @@ impl<'cfg> DrainState<'cfg> {
         let id = JobId(self.next_id);
         self.next_id = self.next_id.checked_add(1).unwrap();
 
-        info!("start {}: {:?}", id, unit);
+        debug!("start {}: {:?}", id, unit);
 
         assert!(self.active.insert(id, unit.clone()).is_none());
 
index 8e782b5dee0b4f334afa56dccd18f0c785656b64..ff535d0c31a5b9e92991ecb0c8e0d23c83aefa15 100644 (file)
@@ -31,7 +31,7 @@ use std::sync::Arc;
 
 use anyhow::{Context as _, Error};
 use lazycell::LazyCell;
-use log::debug;
+use log::{debug, trace};
 
 pub use self::build_config::{BuildConfig, CompileMode, MessageFormat};
 pub use self::build_context::{
@@ -720,7 +720,7 @@ fn rustdoc(cx: &mut Context<'_, '_>, unit: &Unit) -> CargoResult<Work> {
         if crate_dir.exists() {
             // Remove output from a previous build. This ensures that stale
             // files for removed items are removed.
-            log::debug!("removing pre-existing doc directory {:?}", crate_dir);
+            debug!("removing pre-existing doc directory {:?}", crate_dir);
             paths::remove_dir_all(crate_dir)?;
         }
         state.running(&rustdoc);
@@ -1430,9 +1430,9 @@ fn on_stderr_line_inner(
     }
 
     if let Ok(artifact) = serde_json::from_str::<ArtifactNotification>(compiler_message.get()) {
-        log::trace!("found directive from rustc: `{}`", artifact.artifact);
+        trace!("found directive from rustc: `{}`", artifact.artifact);
         if artifact.artifact.ends_with(".rmeta") {
-            log::debug!("looks like metadata finished early!");
+            debug!("looks like metadata finished early!");
             state.rmeta_produced();
         }
         return Ok(false);
@@ -1452,7 +1452,7 @@ fn on_stderr_line_inner(
     if let Ok(JobserverNotification { jobserver_event }) =
         serde_json::from_str::<JobserverNotification>(compiler_message.get())
     {
-        log::info!(
+        trace!(
             "found jobserver directive from rustc: `{:?}`",
             jobserver_event
         );
index 8f73a1a124700c0f0107ffcd165e69287d0e8d8f..4eafae1c99c418260ba9035bcb6d1d417e2b43ab 100644 (file)
@@ -347,7 +347,7 @@ impl<'a> GitCheckout<'a> {
         return update_submodules(&self.repo, cargo_config);
 
         fn update_submodules(repo: &git2::Repository, cargo_config: &Config) -> CargoResult<()> {
-            info!("update submodules for: {:?}", repo.workdir().unwrap());
+            debug!("update submodules for: {:?}", repo.workdir().unwrap());
 
             for mut child in repo.submodules()? {
                 update_submodule(repo, &mut child, cargo_config).with_context(|| {