-
Notifications
You must be signed in to change notification settings - Fork 147
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
Add singleLine
config option
#158
Conversation
Pull Request Test Coverage Report for Build 590866056
💛 - Coveralls |
Is this meant to include all of the work done in #125? If so, please see my comment in the PR for instructions on how to start your branch so that the original author is credited for their work. |
4b9bf33
to
a6c702b
Compare
Sorry about that. I just pushed to include their commit. I had to make some changes to the test to match my implementation but the structure of them is the same. |
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.
lgtm
a6c702b
to
ae9beee
Compare
ae9beee
to
980205e
Compare
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.
LGTM
9c3260a
to
28a8996
Compare
Thanks for bearing with me on this. I rebased master + squashed, is there anything else I need to do before this can be merged? |
Yay, thank you so much for implementing this ❤️ |
A bug in #158 left a trailing space on lines that had no extra log fields with singleLine=true. This commit fixes that, and updates a test accordingly.
A bug in #158 left a trailing space on lines that had no extra log fields with singleLine=true. This commit fixes that, and updates a test accordingly.
This adds a
singleLine
config option. When enabled, all unrecognized non-error fields will be printed on the same line as the main log message, as a simple JSON string. Error messages are still printed like normal, on a new line.The implementation for this is very rough. I wanted to get feedback on the design/behavior before I spent any time polishing the code. I also haven't updated any docs yet. The tests should provide all the examples/behavior definitions needed though.
This builds off of #125 and hopefully fixes #97.
Remaining work: