Merge #818: Place the mainchain RPC warmup message in a better place

c5cb71484 Place the mainchain RPC warmup message in a better place (Steven Roose)

Pull request description:

  Now it also shows with `-validatepegin=0`.

Tree-SHA512: 7e04ab1b5b853fc6896245cb735e1fbfeb2c94950afdf4e2a40ad1c1d59ed06f578c1f491686caa88fa0432a02078ad4c04f338500b34812503e06570e988d52
This commit is contained in:
Gregory Sanders 2020-02-26 10:07:18 -05:00
commit c0e0e0a9d5
No known key found for this signature in database
GPG key ID: F3F68E2D86A48FDB
2 changed files with 1 additions and 1 deletions

View file

@ -1884,7 +1884,6 @@ bool AppInitMain(InitInterfaces& interfaces)
SetRPCWarmupFinished();
// ELEMENTS:
uiInterface.InitMessage(_("Awaiting mainchain RPC warmup"));
if (!MainchainRPCCheck(true)) { //Initial check only
const std::string err_msg = "ERROR: elements is set to verify pegins but cannot get valid response from the mainchain daemon. Please check debug.log for more information.\n\nIf you haven't setup a bitcoind please get the latest stable version from https://bitcoincore.org/en/download/ or if you do not need to validate pegins set in your elements configuration validatepegin=0";
// We fail immediately if this node has RPC server enabled

View file

@ -5294,6 +5294,7 @@ bool MainchainRPCCheck(const bool init)
// Next, check for working and valid rpc
if (gArgs.GetBoolArg("-validatepegin", Params().GetConsensus().has_parent_chain)) {
uiInterface.InitMessage(_("Awaiting mainchain RPC warmup"));
// During init try until a non-RPC_IN_WARMUP result
while (true) {
try {