Nimbus: UX/UI and color scheme for console logging

Hello there,

We are currently polishing the user experience of Nimbus as we approach Ethereum 2.0 mainnet launch.

The main way people interact with Nimbus is via log files, i.e. they watch the messages to make sure it’s running properly.

We have a couple of tradeoffs to make (log verbosity, log content, log level) but the first advice we would like are the colors of each log level. We have the following in descending order of criticity:

  • Fatal: Node will crash
  • Error: Bugs or critical unexpected behaviors, node cannot proceed with task, consistency compromised
  • Warning: Expected behavior (file not found), node cannot proceed with task but can recover
  • Notice: Start/quit, validator funds, own PoS attestations, own PoS blocks, chain reached finality, validators have been slashed (i.e. might indicate malicious activity or network/chain split) (only important info)
  • Info: Networking or consensus information (standard user target)
  • Debug: Common networking activity (new peers, kick peers, timeouts), consensus/Proof-of-Stake various processing, block/attestation from peer (dev + curious users who help debugging)
  • Trace: Keep-alive, routine schedule (dev only)

We are currently revisiting those logs following user reports:

The first concrete question is a recommendation on a color scheme for each of those log level.

As you can see, the “NOT” / Notice log level looks scarier than warning even though it’s actually a level below.

2 Likes

Keep in mind the 16-colour palette on common terminal emulators: ANSI escape code - Wikipedia

1 Like

Apparently the best supported colors in console are those: std/terminal

Thinking about terminal colour schemes reminded me of Solarized ( Solarized ) that I was considering for inclusion in the Ubuntu terminal many years ago. Of course it would only be for terminals that support a full RGB palette, but this includes gnome-terminal, xterm which are probably the most widely used terminals on Linux, iTerm on OSX, etc…

It’s unfortunate that there are no standards for this, but we can consider the practices of other libraries that have put more thought into this:
https://coloredlogs.readthedocs.io/en/latest/api.html#id26

Thinking about terminal colour schemes reminded me of Solarized

That’s what I use in my xfce4-terminal - Solarized Dark - but I can’t ask people to support it. At most, I can ask for theming support and write my own scheme.

This is the current proposal given the very restricted color set.