-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
feat: add json logger output #1026
Conversation
This will allow to format log output as json. This is helpful in cases where act is not executed on a 'local' machine.
Codecov Report
@@ Coverage Diff @@
## master #1026 +/- ##
==========================================
+ Coverage 57.50% 58.58% +1.07%
==========================================
Files 32 34 +2
Lines 4594 4648 +54
==========================================
+ Hits 2642 2723 +81
+ Misses 1729 1696 -33
- Partials 223 229 +6
📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more |
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.
Nice to have, it works :)
Using the runner config to configure logging is cleaner.
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.
Note: I wondered why I see a Error: <errmsg>
line after a failure, which ignored the logrus logger / json formatter. It seems that cobra cli prints it if we return the error back to the library, here the callback which causes the printed line when error != nil
Line 158 in 3db3c73
return func(cmd *cobra.Command, args []string) error { |
This will allow to format log output as json.
This is helpful in cases where act is not executed on a 'local' machine.