lbryio / lbrycrd

The blockchain that provides the digital content namespace for the LBRY protocol
https://lbry.com
MIT License
2.57k stars 178 forks source link

Improve logging by separating debug from information #144

Closed shyba closed 5 years ago

shyba commented 6 years ago

fDebug flag can be used for that like: https://github.com/lbryio/lbrycrd/blob/01a222a3c5f730973c857ff9d13d032e6108462a/src/main.cpp#L5226-L5227

It's initialized according to -debug setting: https://github.com/lbryio/lbrycrd/blob/270307a29070a4c10095528e232ad0f8e251ec5a/src/init.cpp#L860

Ideally it should be applied to log messages that doesn't hold information for a sysadmin, but mainly for developers, like: https://github.com/lbryio/lbrycrd/blob/master/src/claimtrie.cpp#L1927

To be updated with more examples where it should be applied after #137 gets merged as it adds more cases.

alyssaoc commented 6 years ago

@shyba Is this still a valid issue

BrannonKing commented 6 years ago

I didn't mean to close this. I think it's a valid issue. I think it could be a subset of the work on issue #211

BrannonKing commented 5 years ago

@lbrynaut reports that repeatedly calling "generate 1" significantly increases the log size. This appears to just be the standard logging for every new block -- log new claims, supports, etc. I think we should revisit that logging as part of this issue. Maybe by default we just summarize each new block, and maybe we don't bother to summarize those that we generate locally.

BrannonKing commented 5 years ago

I think is sufficiently covered with the move of the claim logging into its own category.

ghost commented 4 years ago

I want free swag t-shirt. Fake crying