diff options
author | Ryan Ofsky <ryan@ofsky.org> | 2024-08-04 20:53:52 -0400 |
---|---|---|
committer | Ryan Ofsky <ryan@ofsky.org> | 2024-08-04 21:05:08 -0400 |
commit | 55d19945efbb58200c37fb8322ed3494bf67f9b1 (patch) | |
tree | f099e4158e94a6fcb8707a55c5d8bb9b98552c69 /src/rpc | |
parent | eb85cacd2969caaea682104f498f6b2e6cfb80f8 (diff) | |
parent | a7432dd6ed3e13a272d62ecde535e6d562cc932c (diff) |
Merge bitcoin/bitcoin#29798: Logging cleanup
a7432dd6ed3e13a272d62ecde535e6d562cc932c logging: clarify -debug and -debugexclude descriptions (Anthony Towns)
74dd33cb0a967086df32e5140d58843ca1359d81 rpc: make logging method reject "0" category and correct the help text (Vasil Dimov)
8c6f3bf1634533a0dd268dcf5929e49429640a09 logging, refactor: minor encapsulation improvement and use BCLog::NONE instead of 0 (Vasil Dimov)
160706aa387245ed96b1f13e5362fe1837e8fc4b logging, refactor: make category special cases explicit (Ryan Ofsky)
Pull request description:
* Move special cases from `LOG_CATEGORIES_BY_STR` to `GetLogCategory()` (suggested [here](https://github.com/bitcoin/bitcoin/pull/29419#discussion_r1547990373)).
* Remove `"none"` and `"0"` from RPC `logging` help because that help text was wrong. `"none"` resulted in an error and `"0"` was ignored itself (contrary to what the help text suggested).
* Remove unused `LOG_CATEGORIES_BY_STR[""]` (suggested [here](https://github.com/bitcoin/bitcoin/pull/29419#discussion_r1548018694)).
This is a followup to https://github.com/bitcoin/bitcoin/pull/29419, addressing leftover suggestions + more.
ACKs for top commit:
LarryRuane:
ACK a7432dd6ed3e13a272d62ecde535e6d562cc932c
ryanofsky:
Code review ACK a7432dd6ed3e13a272d62ecde535e6d562cc932c. Only changes since last review are removing dead if statement and adding AJ's suggested -debug and -debugexclude help improvements, which look accurate and much more clear.
Tree-SHA512: 41b997b06fccdb4c1d31f57d4752c83caa744cb3280276a337ef4a9b7012a04eb945071db6b8fad24c6a6cf8761f2f800fe6d8f3d8836f5b39c25e4f11c85bf0
Diffstat (limited to 'src/rpc')
-rw-r--r-- | src/rpc/node.cpp | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/src/rpc/node.cpp b/src/rpc/node.cpp index 65b0a93cdd..54e2c8e226 100644 --- a/src/rpc/node.cpp +++ b/src/rpc/node.cpp @@ -221,7 +221,6 @@ static RPCHelpMan logging() "The valid logging categories are: " + LogInstance().LogCategoriesString() + "\n" "In addition, the following are available as category names with special meanings:\n" " - \"all\", \"1\" : represent all logging categories.\n" - " - \"none\", \"0\" : even if other logging categories are specified, ignore all of them.\n" , { {"include", RPCArg::Type::ARR, RPCArg::Optional::OMITTED, "The categories to add to debug logging", |