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
Implement new echo behavior and command #139
Conversation
Can we link the adr/issue? |
Lets make sure we have a ticket or pr open to update the toolkit |
Normally, when system.debug is on, all extra log will start with ##debug Looks like the output produced here won’t starts with ##debug An ADR would help😀 |
@TingluoHuang BTW, here's the ADR: https://github.com/github/pe-actions-runtime/pull/136. @thboop, @bryanmacfarlane, and I had a conversation on the ##debug thing. We decided to direct the command processing to the regular output logs, even when debug is on. This is for logging consistency -- with debug off, we can output error for only the command processing failures to output/error streams respectively, and with debug on, the successfully-processed commands go to output as well. |
@thboop I don't think we can easily link to the ADR, as it lives in a private repo, and this repo will eventually be open-sourced. I copied most of the ADR contents to this PR description as a mitigation. |
abc2533
to
4a3c94f
Compare
4a3c94f
to
38f4154
Compare
06744c8
to
0a7cefd
Compare
0a7cefd
to
09e5853
Compare
09e5853
to
e815969
Compare
Toolkit issue to leverage the echo command: actions/toolkit#192 cc @thboop |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor thoughts, LGTM
f3855be
to
4ced8a1
Compare
Updates look good |
Going to merge this tomorrow if thats cool with you @ericsciple. |
* Remove controlling echoing by command * Add 'echo on' and 'echo off' action commands * PR feedback and add L0 tests * Register new command * Eric's PR feedback * Tweak logging a bit * Rename EchoOnActionCommandSuccess -> EchoOnActionCommand * More PR reaction * Make warning messages in Action Commands not rely on context from echo commands
Command echoing as a default behavior tends to clutter the user logs, so we want to swap to a system where users have to opt in to see this information.
Command outputs will still be echoed in the case there are any errors processing such commands. This is so the end user can have more context on why the command failed and help with troubleshooting.
Echo output in the user logs can be explicitly controlled by the new commands
::echo::on
and::echo::off
. By default, echoing is enabled ifACTIONS_STEP_DEBUG
secret is enabled, otherwise echoing is disabled.ToDo
::echo::on
and::echo::off
action commandsACTIONS_STEP_DEBUG
secret sets echo on by default