Skip to content
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

fix(summary): no longer display non existent logfile #9907

Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion crates/turborepo-lib/src/run/summary/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -629,7 +629,7 @@ impl<'a> RunSummary<'a> {
ui,
GREY,
" Log File\t=\t{}",
task.shared.log_file
task.shared.log_file.as_deref().unwrap_or_default()
)?;

let dependencies = if !self.monorepo {
Expand Down
3 changes: 2 additions & 1 deletion crates/turborepo-lib/src/run/summary/task.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,8 @@ pub(crate) struct SharedTaskSummary<T> {
pub cli_arguments: Vec<String>,
pub outputs: Option<Vec<String>>,
pub excluded_outputs: Option<Vec<String>>,
pub log_file: String,
#[serde(skip_serializing_if = "Option::is_none")]
pub log_file: Option<String>,
#[serde(skip_serializing_if = "Option::is_none")]
pub directory: Option<String>,
pub dependencies: Vec<T>,
Expand Down
4 changes: 2 additions & 2 deletions crates/turborepo-lib/src/run/summary/task_factory.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,11 +146,11 @@ impl<'a> TaskSummaryFactory<'a> {

let (dependencies, dependents) = self.dependencies_and_dependents(task_id, display_task);

let log_file = {
let log_file = task_definition.cache.then(|| {
let path = workspace_info.package_path().to_owned();
let relative_log_file = TaskDefinition::workspace_relative_log_file(task_id.task());
path.join(&relative_log_file).to_string()
};
});

Ok(SharedTaskSummary {
hash,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ Setup
"cliArguments": [],
"outputs": null,
"excludedOutputs": null,
"logFile": "\.turbo(\/|\\\\)turbo-build\.log", (re)
"dependencies": [],
"dependents": [],
"resolvedTaskDefinition": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Check
Cached \(Remote\) = false\s* (re)
Command = echo building > foo.txt\s* (re)
Outputs =\s* (re)
Log File = .turbo(\/|\\)turbo-build.log\s* (re)
Log File =
Dependencies =\s* (re)
Dependents =\s* (re)
Inputs Files Considered = 4\s* (re)
Expand Down
Loading