I am importing a “warm” multi-sig quorum into bitcoind using importmulti
like so:
{"jsonrpc":"1.0","id":"curltest","method":"importmulti","params":[[{ "desc": "sh(multi(2,[eb2d2f9e/44'/1'/0']tprv8g5heqz5AnCKdYQHsHyYvyDvWFdp5RN8Z5uhvb1FrzgPmeuYseQNsknt1KFf1b1Y9dtNaNMbxkaNdkP7FLbhP9a4UosbV5rWLAMFPhUcMVT/0/*,[e19b3701/44'/1'/0']tpubDCkUBfVNYjzdX37ARqSFWNAA5WvQRGy3Y5PA13ve1dSVtBLr7tEf6c7C2sYtnRazFfsfAdCfuv9JG62BnUVvofvvvs9iyDreQhTRJJ6Mp8u/0/*,[65b2e5d3/44'/1'/0']tpubDCFM6STEuVkkh6qCCooJw4TXHRzyq6R6tBeigSQSgf4xY6ZwAeoSQH2ZTTfcsZTrJ7wJF2bixpn38XcKj3KihxH5LzMraCLwsbt3bnkAHrU/0/*))#2pztwc0s", "timestamp": "now", "range": [2500,5000], "watchonly": false, "label": "StandUp", "keypool": false, "internal": false }], {"rescan": false}]}
And occasionally getting the following response (sometimes it works without returning an error and sometimes not):
response = {
error = "";
id = curltest;
result = (
{
error = {
code = "-4";
message = "Error adding key to wallet";
};
success = 0;
warnings = (
"Some private keys are missing, outputs will be considered watchonly. If this is intentional, specify the watchonly flag."
);
}
);
}
I do not want to specify the watch-only flag to true
as I am importing private keys into the node and want the node to be able to sign. It is very odd that this seems to happen randomly. It feels like a bug.
If I set watch-only to true will it still import the descriptors private keys?
Just to prove my point here is the exact same command attempted a second time which returns success
as true
:
{"jsonrpc":"1.0","id":"curltest","method":"importmulti","params":[[{ "desc": "sh(multi(2,[eb2d2f9e/44'/1'/0']tprv8g5heqz5AnCKdYQHsHyYvyDvWFdp5RN8Z5uhvb1FrzgPmeuYseQNsknt1KFf1b1Y9dtNaNMbxkaNdkP7FLbhP9a4UosbV5rWLAMFPhUcMVT/0/*,[e19b3701/44'/1'/0']tpubDCkUBfVNYjzdX37ARqSFWNAA5WvQRGy3Y5PA13ve1dSVtBLr7tEf6c7C2sYtnRazFfsfAdCfuv9JG62BnUVvofvvvs9iyDreQhTRJJ6Mp8u/0/*,[65b2e5d3/44'/1'/0']tpubDCFM6STEuVkkh6qCCooJw4TXHRzyq6R6tBeigSQSgf4xY6ZwAeoSQH2ZTTfcsZTrJ7wJF2bixpn38XcKj3KihxH5LzMraCLwsbt3bnkAHrU/0/*))#2pztwc0s", "timestamp": "now", "range": [2500,5000], "watchonly": false, "label": "StandUp", "keypool": false, "internal": false }], {"rescan": false}]}
response = {
error = "";
id = curltest;
result = (
{
success = 1;
warnings = (
"Some private keys are missing, outputs will be considered watchonly. If this is intentional, specify the watchonly flag."
);
}
);
}