Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2023 05 tx compression #8

Closed
wants to merge 124 commits into from
Closed

2023 05 tx compression #8

wants to merge 124 commits into from

Conversation

TomBriar
Copy link
Owner

@TomBriar TomBriar commented Jan 3, 2024

No description provided.

@TomBriar TomBriar force-pushed the 2023-05--tx-compression branch 11 times, most recently from baeba39 to 7e8511c Compare January 5, 2024 17:22
We often need to construct a CExtKey given an CExtPubKey and CKey, so
implement a constructor that does that for us.
@TomBriar TomBriar force-pushed the 2023-05--tx-compression branch 6 times, most recently from a850ab0 to d24d48c Compare March 11, 2024 14:38
MarcoFalke and others added 11 commits March 13, 2024 16:16
No change in behavior, only the modern aliases and types are used.
We currently do this sporadically. Not only amongst packages, but across
OS's, i.e sometimes it's done for BSDs/Android, and sometimes not.

Configure with `--with-pic` globally instead. I think this generally
makes more sense, and should not have any downsides.

See related discussion in
bitcoin#28846 (comment).
-BEGIN VERIFY SCRIPT-
sed -i 's/TxStateConflicted/TxStateBlockConflicted/g' src/wallet/wallet.cpp src/wallet/interfaces.cpp src/wallet/transaction.h src/wallet/transaction.cpp
sed -i 's/isConflicted/isBlockConflicted/g' src/wallet/transaction.h src/wallet/wallet.cpp
-END VERIFY SCRIPT-
Co-authored-by: Suhas Daftuar <sdaftuar@chaincode.com>
Co-authored-by: Pieter Wuille <pieter.wuille@gmail.com>
Co-authored-by: Suhas Daftuar <sdaftuar@chaincode.com>
This new function takes the populated sets of
direct and all conflicts computed in the current
mempool, assuming the replacements are a single
chunk, and computes a diagram check.

The diagram check only works against cluster
sizes of 2 or less, and fails if it encounters
a different topology.

Co-authored-by: Suhas Daftuar <sdaftuar@chaincode.com>
Co-authored-by: Suhas Daftuar <sdaftuar@chaincode.com>
fanquake and others added 17 commits March 27, 2024 16:45
I need to try and patch around Qts buildsystem to keep bitcoin#21778 moving
along (the issue being that even when you tell Qt to build using
Clang on Linux, it still calls out to GCC, breaking our ability to have
a macOS release build env that doesn't have a GCC toolchain installed,
and thus no ld binary).

Before trying to patch Qt any further, update to the latest LTS
release, and update the current patch set.
The `next()` call throws an exception if the default parameter is omitted and the iterator is exhausted.
Fix it by providing a default value.

The failure can be tested by commenting out lines 90 and 91 in the test (the `self.connect_nodes(2, 0)``).
Since there is no connection, the node in question retrieves a single element in the 'getchaintips()' call.
This scenario without the fix, aborts the test right away, throwing an StopIteration exception, and with
the fix, the test properly waits until the timeout (wait_until() call).
…ons to disk

4d5b557 log: renamed disk to file so wording was more accurate (kevkevin)
b9f04be mempool: Log added for dumping mempool transactions to disk (kevkevin)

Pull request description:

  Sometimes when shutting off bitcoind it can take a while to dump the mempool transaction onto the disk so
  this change adds additional logging to the `DumpMempool` method in `kernel/mempool_persist.cpp`

  Motivated by bitcoin#29227 this change
   - adds a single new line for the amount of transactions being dumped and the amount of memory being dumped to file

  This is in response to bitcoin#29227 (comment)

  The logs will now look like this
  ```
  2024-02-09T23:41:52Z DumpAnchors: Flush 2 outbound block-relay-only peer addresses to anchors.dat completed (0.02s)
  2024-02-09T23:41:52Z scheduler thread exit
  2024-02-09T23:41:52Z Writing 29 mempool transactions to file...
  2024-02-09T23:41:52Z Writing 0 unbroadcast transactions to file.
  2024-02-09T23:41:52Z Dumped mempool: 0.000s to copy, 0.022s to dump, 0.015 MB dumped to file
  2024-02-09T23:41:52Z Flushed fee estimates to fee_estimates.dat.
  2024-02-09T23:41:53Z Shutdown: done
  ```

ACKs for top commit:
  maflcko:
    cr-ACK 4d5b557
  glozow:
    reACK 4d5b557

Tree-SHA512: 049191e140d00c1ea57debe0138f1c9eb0f9bb0ef8138e2568e6d89e64f45a5d5853ce3b9cc0b28566aab97555b47ddfb0f9199fc8cea6b81e53f50592d5ae6a
Pretty much all library packages were renamed in the 64-bit time_t
migration to add `t64` (even on 64-bit platforms).

Instead of complicating the doc with conditional package names, suggest
installing the `-dev` packages which still have the same name, and
besides that, are the right way to go about it as they contain the
"user facing" C++ headers needed to build against Qt5.

For Fedora, devel packages are already suggested.

This affects Ubuntu 24.04 and Debian Testing.
…eys` RPCs for adding new automatically generated descriptors

746b6d8 test: Add test for createwalletdescriptor (Ava Chow)
2402b63 wallet: Test upgrade of pre-taproot wallet to have tr() descriptors (Ava Chow)
460ae1b wallet, rpc: Add createwalletdescriptor RPC (Ava Chow)
8e1a475 wallet: Be able to retrieve single key from descriptors (Ava Chow)
85b1fb1 wallet: Add GetActiveHDPubKeys to retrieve xpubs from active descriptors (Ava Chow)
73926f2 wallet, descspkm: Refactor wallet descriptor generation to standalone func (Andrew Chow)
54e74f4 wallet: Refactor function for single DescSPKM setup (Andrew Chow)
3b09d0e tests: Test for gethdkeys (Ava Chow)
5febe28 wallet, rpc: Add gethdkeys RPC (Ava Chow)
66632e5 wallet: Add IsActiveScriptPubKeyMan (Ava Chow)
fa6a259 desc spkm: Add functions to retrieve specific private keys (Ava Chow)
fe67841 descriptor: Be able to get the pubkeys involved in a descriptor (Ava Chow)
ef67458 key: Add constructor for CExtKey that takes CExtPubKey and CKey (Ava Chow)

Pull request description:

  This PR adds a `createwalletdescriptor` RPC which allows users to add new automatically generated descriptors to their wallet, e.g. to upgrade a 0.21.x wallet to contain a taproot descriptor. This RPC takes 3 arguments: the output type to create a descriptor for, whether the descriptor will be internal or external, and the HD key to use if the user wishes to use a specific key. The HD key is an optional parameter. If it is not specified, the wallet will use the key shared by the active descriptors, if they are all single key. For most users in the expected upgrade scenario, this should be sufficient. In more advanced cases, the user must specify the HD key to use.

  Currently, specified HD keys must already exist in the wallet. To make it easier for the user to know, `gethdkeys` is also added to list out the HD keys in use by all of the descriptors in the wallet. This will include all HD keys, whether we have the private key, for it, which descriptors use it and their activeness, and optionally the extended private key. In this way, users with more complex wallets will be still be able to get HD keys from their wallet for use in other scenarios, and if they want to use `createwalletdescriptor`, they can easily get the keys that they can specify to it.

  See also bitcoin#26728 (comment)

ACKs for top commit:
  Sjors:
    re-utACK 746b6d8
  furszy:
    ACK 746b6d8
  ryanofsky:
    Code review ACK 746b6d8, and this looks ready to merge. There were various suggested changes since last review where main change seems to be switching `gethdkeys` output to use normalized descriptors (removing hardened path components).

Tree-SHA512: f2849101e6fbf1f59cb031eaaaee97af5b1ae92aaab54c5716940d210f08ab4fc952df2725b636596cd5747b8f5beb1a7a533425bc10d09da02659473516fbda
ee1b9b2 CalculateFeerateDiagramsForRBF: update misleading description of old diagram contents (Greg Sanders)
a9d42b9 CompareFeerateDiagram: short-circuit comparison when detected as incomparable (Greg Sanders)
cebcced remove erroneous CompareFeerateDiagram comment about slope (Greg Sanders)
a0376e1 unit test: clarify unstated assumption for calc_feerate_diagram_rbf chunking (Greg Sanders)
890cb01 s/effected/affected/ (Greg Sanders)
d9391ec CalculateFeerateDiagramsForRBF: remove size tie-breaking from chunking conflicts (Greg Sanders)
b684d82 fuzz: Add more invariant checks for package_rbf (Greg Sanders)
2a3ada8 fuzz: finer grained ImprovesFeerateDiagram check on error result (Greg Sanders)
c377ae9 unit test: improve ImprovesFeerateDiagram coverage with one less vb case (Greg Sanders)
d2bf923 unit test: make calc_feerate_diagram_rbf less brittle (Greg Sanders)
defe023 fuzz: add PrioritiseTransaction coverage in diagram checks (Greg Sanders)
216d5ff unit test: add coverage showing priority affects diagram check results (Greg Sanders)
a80d809 unit test: add CheckConflictTopology case for not the only child (Greg Sanders)
69bd18c unit test: check tx4 conflict error message (Greg Sanders)
c0c37f0 unit test: have CompareFeerateDiagram tested with diagrams both ways (Greg Sanders)
b62e2c0 ImprovesFeerateDiagram: Spelling fix and removal of unused diagram vectors (Greg Sanders)
bb42402 doc: fix comment about non-existing CompareFeeFrac (Greg Sanders)

Pull request description:

  Follow-ups to bitcoin#29242

ACKs for top commit:
  glozow:
    ACK ee1b9b2, reviewed the changes and package_rbf fuzzer seems to run fine
  murchandamus:
    crACK ee1b9b2
  ismaelsadeeq:
    Code review ACK ee1b9b2
  willcl-ark:
    ACK ee1b9b2

Tree-SHA512: 8399fe12064fb49b0e4c73258968b57be1d9c2e35701b2d3b0bb67e2e4052e44216358238f92508e4697d0fb6176518d5b885474054d3deda242f669e99262a7
601edd8 ci: use codespell 2.2.6 (fanquake)
52fa0d2 doc: fix some typos (crazeteam)
b5ed13a doc: Fix typos (RoboSchmied)

Pull request description:

  Combines the recent PRs to fix typos so they can be merged.

ACKs for top commit:
  brunoerg:
    crACK 601edd8
  tdb3:
    crACK 601edd8
  kristapsk:
    cr utACK 601edd8

Tree-SHA512: d054b1dad1336d6b9291cc5d5252d4debf6424a993d4edd6a97d7c15055a7fc48a333d30967f72e7dc9c6c1d9a9038ca8bb5e219c529f4c2365ea48404a508d0
…ubuntu qt5 build

6c29904 ci: Pull in qtbase5-dev instead of seperate low-level libraries (laanwj)
a3c6a13 doc: Suggest installing dev packages for debian/ubuntu qt5 build (laanwj)

Pull request description:

  Pretty much all library packages were renamed in the 64-bit time_t migration to add `t64` (even on 64-bit platforms).

  Instead of complicating the doc with conditional package names, suggest installing the `-dev` packages which still have the same name, and besides that, are the right way to go about it as they contain the "user facing" C++ headers needed to build against Qt5. They pull in the necessary library packages through dependencies.

  For Fedora, devel packages are already suggested.

  This affects Ubuntu 24.04 and Debian Testing.

ACKs for top commit:
  maflcko:
    lgtm ACK 6c29904
  hebasto:
    ACK 6c29904.

Tree-SHA512: dae21b7d08fdb221b7b72c323fdaaa6d1a8b014f90e24d2beae64b1ae229fdbeb93d726a61e826447813e52a3cb9775426aefc6c44a4c5ccc541afabb89cb135
430f319 depends: qt 5.15.13 (fanquake)

Pull request description:

  I need to try and patch around Qts buildsystem to keep bitcoin#21778 moving along (the issue being that even when you tell Qt to build using Clang on Linux, it still calls out to GCC, breaking our ability to have a macOS release build env that doesn't have a GCC toolchain installed, and thus no `ld` binary).

  Before trying to patch Qt any further, update to the latest LTS release, and update the current patch set.

ACKs for top commit:
  TheCharlatan:
    Re-ACK 430f319
  hebasto:
    re-ACK 430f319.

Tree-SHA512: 11122c04d63f4ec79e5d7945e1686eaf308cb1f98c3ff8bc52e265d7353cd4f1a532f4d78d55b43183245aeebf93cc1092087d9fe83e42eefa8a69ad9017d2da
fa75220 ci: Use clang-18 in asan/fuzz/tsan task (MarcoFalke)
fad23a0 ci: Bump clang+llvm in i686_multiprocess task (MarcoFalke)

Pull request description:

  Use clang-18, which comes with bugfixes and sanitizer upgrades.

ACKs for top commit:
  fanquake:
    ACK fa75220

Tree-SHA512: da251eb55d3a7e537110b03fb0fc10fc6e2f4406d55bdb33bdc91459daabfd3b8d1d20859a66718bb1b09126e11495f6584c52504a85eb09bde9eafafdaf0b0b
…formation

f8f5cec doc: Override `-g` properly to skip debugging information (Hennadii Stepanov)

Pull request description:

  Fix bitcoin#29755.

ACKs for top commit:
  TheCharlatan:
    ACK f8f5cec

Tree-SHA512: 02bff5fc41859deb914531ef01ea1ac88ab2e138219fe175472962192b11feefe772128da03f466ec765c1b35b21eead31a42cc76e62ecb7ea5dc947cf568d61
80f8b92 remove libbitcoinconsensus (fanquake)

Pull request description:

  This was deprecated in `v27.0`, for removal in `v28.0`. See discussion in PR bitcoin#29189.

ACKs for top commit:
  theuni:
    Concept ACK and light review ACK 80f8b92. My only hesitation here is that (afaics?) there's now nothing keeping undesired features like threading or globals from working their way into the interpreter in future commits.
  m3dwards:
    Concept ACK bitcoin@80f8b92
  TheCharlatan:
    ACK 80f8b92
  hebasto:
    ACK 80f8b92, I have reviewed the code and it looks OK.

Tree-SHA512: 17a62118aeb088f2695c892bb32794dfea3061e3cb7d9e8e9f1c06c3ff6f63a7587fa532e37edbb91fbc5a19b12c9a0f8e05fa9e8864aa07f92665375d847e80
…twork_limited.py

2eb5175 test: fix StopIteration exception in p2p_node_network_limited.py (furszy)

Pull request description:

  Fixes bitcoin#29731

  The `next()` call throws an exception if the default parameter is omitted and the iterator is exhausted.
  Fix it by providing a default value.

  The failure can be tested by commenting out lines 90 and 91 in the test (the `self.connect_nodes(2, 0)`). Since there is no connection, the node in question retrieves a single element in the 'getchaintips()' call. This scenario without the fix, aborts the test right away, throwing an `StopIteration` exception, and with the fix, the test properly waits until the timeout (`wait_until()` call).

ACKs for top commit:
  maflcko:
    review ACK 2eb5175
  brunoerg:
    crACK 2eb5175
  BrandonOdiwuor:
    crACK 2eb5175
  tdb3:
    Tested ACK for 2eb5175.

Tree-SHA512: b0873eb4d3334146fd250cd2cd23add3e744877033c8bfa4eb8dff36633100604adf49dd7846856ddfa88c9768663f095db705c00eef3641618df8fc13f8c2c5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet