-
Notifications
You must be signed in to change notification settings - Fork 20.5k
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
all: make logs a bit easier on the eye to digest #22665
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
You really should've waited for review on this, the big.Int case was broken. Fixed in #22679. |
atif-konasl
pushed a commit
to frozeman/pandora-execution-engine
that referenced
this pull request
Oct 15, 2021
* all: add thousandths separators for big numbers on log messages * p2p/sentry: drop accidental file * common, log: add fast number formatter * common, eth/protocols/snap: simplifty fancy num types * log: handle nil big ints
9 tasks
9 tasks
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 12, 2024
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 12, 2024
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 13, 2024
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 14, 2024
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 14, 2024
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 14, 2024
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 15, 2024
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 15, 2024
gzliudan
added a commit
to gzliudan/XDPoSChain
that referenced
this pull request
Nov 15, 2024
19 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is up for debate, but the idea is that numbers displayed in the log lines are starting to get unwieldy. With state counts reaching soon 1 billion, it's just impossible to see at a glance what the number order of magnitudes are. This PR adds the thousandth separators for numbers > 99999. Numbers smaller are probably clearer without added symbols.
Now, it probably would take a bit of getting used to to see that many commas in the output, but I'd guess it might be worthwhile.
The PR also replaces the ellipse (three dots) unicode character from the logs with two
..
. This will result in the log package unquoting all the hashes (the quotes were caused by the non-ASCII byte).(the image above didn't have the hash change in yet)
Final fancy algo courtesy of Felix.