Bitcoin Core Github
44 subscribers
120K links
Download Telegram
💬 maflcko commented on pull request "refactor: Replace g_genesis_wait_cv with m_tip_block_cv":
(https://github.com/bitcoin/bitcoin/pull/30967#discussion_r1775409498)
> These are similar conditions but not exactly the same

The `m_tip_block` condition implies the `Tip()` condition, because `SetTip()` happens before `blockTip()`.

An assert (`Assert`) is already present in the next commit, which was asked to be split up: https://github.com/bitcoin/bitcoin/pull/30967#discussion_r1775007062
📝 maflcko converted_to_draft a pull request: "refactor: Replace g_genesis_wait_cv with m_tip_block_cv"
(https://github.com/bitcoin/bitcoin/pull/30967)
`g_genesis_wait_cv` is similar to `m_tip_block_cv` but shuffling everything through a redundant `boost::signals2`.

So remove it, along with some other dead code, as well as minor fixups.
👋 maflcko's pull request is ready for review: "refactor: Replace g_genesis_wait_cv with m_tip_block_cv"
(https://github.com/bitcoin/bitcoin/pull/30967)
👍 ryanofsky approved a pull request: "init: Remove retry for loop"
(https://github.com/bitcoin/bitcoin/pull/30968#pullrequestreview-2328680000)
Code review ACK 705105de4f84f2ce3bb1d754c88c32349e01bb3b

Nice cleanup. Previous for loop was very confusing and new code is straightforward.

Not important, but I think it would be a little better if `InitAndLoadChainstate` simply returned `ChainstateLoadStatus` instead of `std::tuple</*may_retry*/ bool, /*error*/ bilingual_str>`. This way retry logic would be implemented in one function, not split across two functions. And it would avoid introducing a new way to represent success/interrupt
...
💬 maflcko commented on pull request "refactor: Replace g_genesis_wait_cv with m_tip_block_cv":
(https://github.com/bitcoin/bitcoin/pull/30967#discussion_r1775481467)
Thanks, but closing as no longer relevant. I'll follow-up with iwyu at some point, which should fix all of this either way.
💬 itornaza commented on pull request "multiprocess: Add IPC wrapper for Mining interface":
(https://github.com/bitcoin/bitcoin/pull/30510#issuecomment-2374471920)
> My `clang-tidy` also wants to indent the `requires` expressions, but I don't think that is necessarily more readable.

Checking with the C++ Core Guidelines and Stroustrup's books, while they do not mention anything about indenting require statements, they do indent it all through the guide like in this [minimal example](https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rt-raise)
💬 maflcko commented on pull request "refactor: Replace g_genesis_wait_cv with m_tip_block_cv":
(https://github.com/bitcoin/bitcoin/pull/30967#discussion_r1775489809)
> I'm not sure about the steady clock thing

I was referring to https://en.cppreference.com/w/cpp/thread/condition_variable/wait_until#Notes, but it can probably be dropped. I just wanted to mention that it may not be a refactor in a strict sense.
👍 itornaza approved a pull request: "multiprocess: Add IPC wrapper for Mining interface"
(https://github.com/bitcoin/bitcoin/pull/30510#pullrequestreview-2328717165)
ACK 1a332817665f77f55090fa166930fec0e5500727

Very clever rework to maximize code reuse while using already existing concepts. The code is now far easier to read. Built locally and all unit, and functional tests pass including the extended.
👍 ryanofsky approved a pull request: "refactor: Replace g_genesis_wait_cv with m_tip_block_cv"
(https://github.com/bitcoin/bitcoin/pull/30967#pullrequestreview-2328742682)
Code review ACK fa7c2c9f18f5468baf81c04177b75e2b684a327a
💬 ryanofsky commented on pull request "refactor: Replace g_genesis_wait_cv with m_tip_block_cv":
(https://github.com/bitcoin/bitcoin/pull/30967#discussion_r1775515667)
re: https://github.com/bitcoin/bitcoin/pull/30967#discussion_r1775163810

I think Cory's suggestion could be implemented here with:

```diff
--- a/src/node/interfaces.cpp
+++ b/src/node/interfaces.cpp
@@ -940,17 +940,11 @@ public:

BlockRef waitTipChanged(uint256 current_tip, MillisecondsDouble timeout) override
{
- // Interrupt check interval
- const MillisecondsDouble tick{1000};
- auto now{std::chrono::steady_clock::now()};
- const auto dea
...
📝 theuni opened a pull request: "build: Add missing USDT header dependency to kernel"
(https://github.com/bitcoin/bitcoin/pull/30970)
Noticed while testing a branch that replaces `boost::multi_index` with a custom replacement.

Currently depends builds pick up usdt and boost from the same path, and because boost always exists, the usdt path is implicitly included. So without boost, USDT isn't found.

An alternative to this would be to disable USDT for the kernel. I'd be open to either approach.
💬 theuni commented on pull request "build: Add missing USDT header dependency to kernel":
(https://github.com/bitcoin/bitcoin/pull/30970#issuecomment-2374557476)
Ping @hebasto @TheCharlatan
💬 ryanofsky commented on pull request "multiprocess: Add IPC wrapper for Mining interface":
(https://github.com/bitcoin/bitcoin/pull/30510#issuecomment-2374559335)
@Sjors did you re-ack the right commit hash in https://github.com/bitcoin/bitcoin/pull/30510#issuecomment-2373443353? (ACK is a for a commit that was replaced about 12 hours before the comment)
🤔 theuni reviewed a pull request: "init: Remove retry for loop"
(https://github.com/bitcoin/bitcoin/pull/30968#pullrequestreview-2328825567)
Concept ACK. I've also spent a good amount of time (more than once) scratching my head trying to understand this loop.
💬 ryanofsky commented on pull request "multiprocess: Add IPC wrapper for Mining interface":
(https://github.com/bitcoin/bitcoin/pull/30510#issuecomment-2374578102)
> I wonder if the Deserializable concept could just live in the `serialize.h` header. It seems like it could be generally useful?

Definitely could be. Would be happy to move it if I need to update this again. Reason I didn't move is after the last update is that it's not really consistent with other concepts there, because it not used in that file, and it doesn't take a stream parameter. But I could move it and make it more consistent.

>
> My `clang-format` also wants to indent the `requ
...
⚠️ fanquake opened an issue: "assumeutxo: not syncing the snapshot chainstate"
(https://github.com/bitcoin/bitcoin/issues/30971)
Testing `-loadtxoutset` on node running master (39219fe145e5), with Sjors snapshot (height 840000). After it finished validating the snapshot, it (so far), has just not started syncing the snapshot chain, only the background chain is progressing. It also seems like the cache resizing has note worked correctly?
```bash
./build/src/bitcoind
2024-09-25T15:53:23Z Bitcoin Core version v28.99.0-39219fe145e5 (release build)
2024-09-25T15:53:23Z Script verification uses 9 additional threads
2024-0
...
📝 BrandonOdiwuor opened a pull request: "Wallet listreceivedby fix"
(https://github.com/bitcoin/bitcoin/pull/30972)
Fixes https://github.com/bitcoin/bitcoin/issues/16159,

This PR builds on https://github.com/bitcoin/bitcoin/pull/25973, fixing `listreceivedby*` RPCs by filtering out `send` addresses using `IsMine` (see https://github.com/bitcoin/bitcoin/pull/25973#discussion_r1269477246). It also breaks down the `listreceivedby` tests into subtests and adds a test to verify 'listreceivedby*' does not return `send` addresses
📝 BrandonOdiwuor converted_to_draft a pull request: "Wallet listreceivedby fix"
(https://github.com/bitcoin/bitcoin/pull/30972)
Fixes https://github.com/bitcoin/bitcoin/issues/16159,

This PR builds on https://github.com/bitcoin/bitcoin/pull/25973, fixing `listreceivedby*` RPCs by filtering out `send` addresses using `IsMine` (see https://github.com/bitcoin/bitcoin/pull/25973#discussion_r1269477246). It also breaks down the `listreceivedby` tests into subtests and adds a test to verify 'listreceivedby*' does not return `send` addresses
💬 average-gary commented on issue "Embedded ASMap data Tracking Issue":
(https://github.com/bitcoin/bitcoin/issues/28794#issuecomment-2374720112)
Is there no way to query AS Maps directly from the BGP tables?
💬 TheCharlatan commented on pull request "init: Remove retry for loop":
(https://github.com/bitcoin/bitcoin/pull/30968#issuecomment-2374760380)
Thank you for your suggestion @ryanofsky,

Updated 705105de4f84f2ce3bb1d754c88c32349e01bb3b -> e9d60af9889c12b4d427adefa53fd234e417f8f6 ([removeInitForLoop_0](https://github.com/TheCharlatan/bitcoin/tree/removeInitForLoop_0) -> [removeInitForLoop_1](https://github.com/TheCharlatan/bitcoin/tree/removeInitForLoop_1), [compare](https://github.com/TheCharlatan/bitcoin/compare/removeInitForLoop_0..removeInitForLoop_1))

* Took @ryanofsky's [suggestion](https://github.com/bitcoin/bitcoin/pull/3096
...