fix log dupe at cmd completion - #2694
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Some of the pull request description still needs filling in:
Edit the description and this check re-runs on its own. The sections exist because they are the parts a reviewer cannot get from the diff: why the change is needed, how you know it works, and what breaks if it is wrong. |
@mridulmanohar This will need doing before we can merge this work |
thanks @palfrey - i've addressed this. |
0536bd3 to
af11b12
Compare
What and why
At the default RUST_LOG=info level, every action is logging its complete argv twice -
once at running_actions_manager.rs:1487 ("Executing command") and
again at running_actions_manager.rs:1904 ("Command complete").
The 1st time is deliberate looking at the TODO explaining why it is not a debug! instead - 'we often rely on this to figure out toolchain misconfiguration issues'. However, the 2nd time has no such justification and seems to be a duplication. When this line executes, the action is completed but we do not see any useful info which is in context like exit_code. so instead of repeating what is already known it would be helpful to log something useful to correlate. Also this reduces total log size by omitting line duplication.
How was this verified?
the cargo test
worker_times_outasserts the info! log statement.this was run locally to verify that the test case is passing -
$ cargo test -- worker_times_out
running 1 test
test tests::worker_times_out ... ok
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 44 filtered out; finished in 0.03s
Risk
Severity: low (log operability)
Resulting logs for an action might appear different in terms of debugging prespective from earlier.
This change is