HomePhabricator

Ignoring (but warn) on duplicate -wallet parameters

Description

Ignoring (but warn) on duplicate -wallet parameters

Summary:
I expect that there are many users with load on startup wallet definitions in bitcoin.conf or via startup CLI argument.
With the new settings.json r/w configuration file, users unloading and loading a wallet through the GUI or via the RPC calls might end up with a duplicate -wallet entry (one that still remains in bitcoin.conf or CLI) plus the new duplication in settings.json due to the unload/load.

Steps to reproduce

  • create wallet (if via RPC set load_on_startup or unloadwallet/loadwallet then set load_on_startup).
  • stop bitcoin
  • start bitcoind again with same --wallet=mywallet

I guess it is acceptable to skip duplicates.

This is a backport of core#20199

Test Plan: ninja all check-all

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D10718

Details

Provenance
Jonas Schnelli <dev@jonasschnelli.ch>Authored on Oct 20 2020, 15:48
PiRKCommitted on Dec 22 2021, 13:34
PiRKPushed on Dec 22 2021, 13:34
Reviewer
Restricted Project
Differential Revision
D10718: Ignoring (but warn) on duplicate -wallet parameters
Parents
rABCdbd80d667356: minor feerate improvements
Branches
Unknown
Tags
Unknown