Page MenuHomePhabricator

[avalanche] pass the processor to Chainstate::ProcessNewBlock
ClosedPublic

Authored by PiRK on Jun 4 2024, 10:13.

Details

Summary

Another step in removing access to the g_avalanche global in Chainstate code.

This adds some g_avalanche callsites in RPC commands, but they will be removed in a later diff when the node context owns avalanche.
Depends on D16267

Test Plan

ninja all check-all

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Fabien requested changes to this revision.Jun 4 2024, 11:54
Fabien added a subscriber: Fabien.
Fabien added inline comments.
src/rpc/mining.cpp
443 ↗(On Diff #48081)

You should be able to mine blocks with avalanche disabled

1207 ↗(On Diff #48081)

dito

This revision now requires changes to proceed.Jun 4 2024, 11:54
PiRK edited the summary of this revision. (Show Details)

don't use EnsureAvalanche in the RPC calls, make it possible to use the RPCs with the processor not initialized

This revision is now accepted and ready to land.Jun 4 2024, 16:30