Alternate to #8354/#8359. Intended for 0.13.0.
As @laanwj observed, this is somewhat of a tedious change to make, but I do think that it’d be better to make this change now than live with the confusing “cost” terminology indefinitely into the future.
If we go with this, we should re-open https://github.com/bitcoin/bips/pull/420 and make the corresponding change to the BIP.
I didn’t change qt/bitcoinstrings.cpp, which – if I am understanding correctly – was just changed so that we wouldn’t translate the help language for -blockmaxcost
. Should I push a commit to this PR that changes the text there as well to refer to “weight”, to make this change self-contained?
There’s one more language reconciliation we should still do after this, which is that BIP 141 doesn’t define “sigop cost”, yet we refer to “sigop cost” as a term both in RPC calls (eg getblocktemplate) and throughout the code (comments, variables, function names, etc). I think it’d be best to pick a term, use that in the BIP, and then make a pass through the code to be compatible – presumably the simplest thing would be to just define “sigop cost” in BIP 141.