Skip to content
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

Refactoring: use proper logging solution #779

Closed
freak12techno opened this issue May 2, 2024 · 2 comments · Fixed by #780
Closed

Refactoring: use proper logging solution #779

freak12techno opened this issue May 2, 2024 · 2 comments · Fixed by #780
Assignees

Comments

@freak12techno
Copy link
Contributor

freak12techno commented May 2, 2024

Would be nice if REStake would use the logging solution instead of timestamp(...). My suggestion is winston.

Benefits:

  1. possibility to display logs in one format instead of needing to have custom helpers to format logs
  2. ability to create subloggers (e.g. there can be main logger and each NetworkRunner can have a sublogger with { chain: <chain_name> } and inside all logs would have chain=<chain_name> prepended
  3. all logging is done via structured entries that include not only the timestamp, but some data (see the point above)
  4. ability to log into JSON (extra useful for those viewing logs via external logging solutions, like me lol), colored logs etc.

Also feel free to assign me to this, I have an idea on how to make it possible.

@freak12techno
Copy link
Contributor Author

Just noticed it basically duplicates #734, but with more context.

@tombeynon
Copy link
Contributor

@freak12techno Completely agree this is needed and has been requested a few times. It would be amazing if you could take a look, otherwise I'll prioritise. Thanks so much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants