Repository navigation
wallet: Use PACKAGE_NAME to mention our software - #23311
Conversation
shaavan
left a comment
There was a problem hiding this comment.
Concept ACK
This change helps in the generalization of strings and makes them robust in case of any possible future change.
I was just curious. What do you think about adding the word “instance” followed by the package name?
For example:
throw std::runtime_error("SQLiteDatabase: Unable to obtain an exclusive lock on the database, is it being used by another " PACKAGE_NAME "?\n");
Changed to
throw std::runtime_error("SQLiteDatabase: Unable to obtain an exclusive lock on the database, is it being used by another " PACKAGE_NAME " instance?\n");
This suggestion is valid for all the strings that have been updated except the one in the src/wallet/bdb.cpp file
|
Concept ACK
Yes, I think adding "instance" makes the sentences better. |
|
concept ACK |
|
Updated 16fad5b -> da791c7 (pr23311.01 -> pr23311.02, diff). Thanks to all reviewers, your comments are addressed 🐅 |
|
ACK da791c7 Verified that changing the test assertions to just "Bitcoin Core" is equivalent. Would it make sense to also update these 3 lines? |
stratospher
left a comment
There was a problem hiding this comment.
Tested ACK da791c7
The generic error messages introduced by this PR in src/wallet/bdb.cpp and src/wallet/sqlite.cpp, which reflect that there may be other instances(not necessarily a bitcoin instance or a bitcoind instance) using the lock is a nice change!
shaavan
left a comment
There was a problem hiding this comment.
ACK da791c7
Changes since my last review:
- Removed “of bitcoin” in the string in the
src/wallet/bdb.cppfile to increase the generality of this string message. - Added “instance of” in all other (updated) strings to correct the sentences.
|
I still think we can remove PACKAGE_NAME, because it is not possible to say whether the other instance is Bitcoin Core or Bitcoin Knots, or bitcoind, or bitcoin-qt, or ... But 🤷 |
This PR replaces "bitcoin" and "bitcoind" with
PACKAGE_NAMEin wallet log and error messages.