Finish off support for Bitcoin Core v31.0#615
Conversation
|
Latest force push uses enums for getpeerinfo types, maintaining full v31 docs in corepc (before, it simply discarded relevant messages from Bitcoin Core documentation). EDIT: below i retriggered CI |
|
Looks pretty good man. To create all the new types you just copied the one from the latest version and added the fields, right? I.e for |
|
Reviewed: 1d584d8 |
Yes. Everything that didn't need to change hasn't changed. Diffs only in new/modified fields or the corresponding docs. All "institutional memory" is kept. |
jamillambert
left a comment
There was a problem hiding this comment.
I've had a look through and it all looks good so far. There is a lot here at so will need to have another look tomorrow.
|
The first commit doesn't build. Can you get the PR into a state where I can review patch by patch and on each I can run |
508d5cf to
aad9a24
Compare
|
Force push fixed the bissectability of every commit. EDIT: no, a90eb31 is broken. |
508d5cf to
150016f
Compare
|
150016f needs rebase |
bc23b4d to
a58753a
Compare
|
Force push fixes the other bad force pushes I made. Should be good to go. |
Converted to enum the type of fields "connection_type" and "transport_protocol_type" to match Bitcoin Core docs.
New fields kernel and privatebroadcast.
RPC getwalletinfo no longer returns paytxfee
Add getmempoolcluster and getmempoolfeeratediagram RPCs. Update getmempoolentry, getrawmempool, getmempoolancestors, getmempooldescendants and getmempoolinfo with new field chunk_weight, chunk_fee and cluster_limit fields. Back-fill optional fields as None for earlier versions.
RPC getdeploymentinfo gets script_flags field. This commit adds an Enum with the possible flags.
RPC gettxspendingprevout adds spending_tx and block_hash fields when return_spending_tx is set.
RPC getblock gets new field coinbase_tx. Commit backfills None for earlier versions.
Deny unknown fields. Use i64 for peer timestamps because time can be emmited as a negative.
getblockfrompeer, disconnectnode, getnetworkinfo, getblocktemplate and waitfornewblock each carried a a note that said the fields since v30, but their modelled return types match v30.
Despite getmempoolfeeratediagram being a new RPC, it is hidden. It is not included in the rustdoc method table. Remove SetTxFee import because the RPC has been deleted but the re-export had been kept.
|
Latest force push:
|
Drop the v30_and_below gates from tests covering RPCs unchanged in v31.
|
Clean up accidental garbage file |
jamillambert
left a comment
There was a problem hiding this comment.
ACK daf4571
Nice one
Closes #599
Completes v31 support across the client, types, and integration tests. Makes v31 the default version.
Fixed:
inv_to_sendandlast_inv_sequence, and madestartingheightoptional now that it is only returned under-deprecatedrpc=startingheight.kernelandprivatebroadcastcategories.paytxfee.script_flagsfield.spendingtxandblockhashfields, plus added support for the newmempool_onlyandreturn_spending_txarguments.coinbase_txobject returned at verbosity 1, 2 and 3.Added:
getmempoolclusterandgetmempoolfeeratediagramRPCs, thechunk_weightandchunk_feefields ongetmempoolentry,getrawmempool,getmempoolancestorsandgetmempooldescendants, and thecluster_limitandoptimalfields ongetmempoolinfo.getprivatebroadcastinfoandabortprivatebroadcastRPCs.LLM usage: Claude helped on generating tests for new RPCs, verifying things over and over again, attempting to call every RPC, spotting additional unfixed things, and reviewing every change the PR.
When appropriate, comments have been checked to match v31 documentation exactly.