Page MenuHomePhabricator

Add <datadir>/settings.json persistent settings storage.
ClosedPublic

Authored by deadalnix on Oct 20 2020, 16:43.

Details

Summary

Persistent settings are used in followup PRs #15936 to unify gui settings
between bitcoin-qt and bitcoind, and #15937 to add a load_on_startup flag to
the loadwallet RPC and maintain a dynamic list of wallets that should be loaded
on startup that also can be shared between bitcoind and bitcoin-qt.

Backport of PR15935 part [2/2] : https://github.com/bitcoin/bitcoin/pull/15935/commits/9c69cfe4c54e38edd2f54303be2f8a53dcf5bad8

Depends on D8009 and D8011

Test Plan
ninja all check-all

Diff Detail

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

Event Timeline

Tail of the build log:

[382/435] Generating forms/ui_modaloverlay.h
[383/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/prevector.cpp.o
[384/435] Generating forms/ui_optionsdialog.h
[385/435] Generating forms/ui_overviewpage.h
[386/435] Generating forms/ui_openuridialog.h
[387/435] Generating forms/ui_receiverequestdialog.h
[388/435] Generating forms/ui_debugwindow.h
[389/435] Generating forms/ui_sendcoinsdialog.h
[390/435] Generating qrc_bitcoin.cpp
[391/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/util_time.cpp.o
[392/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/checkqueue.cpp.o
[393/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/data.cpp.o
[394/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/crypto_aes.cpp.o
[395/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/checkblock.cpp.o
[396/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/duplicate_inputs.cpp.o
[397/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/mempool_eviction.cpp.o
[398/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/rpc_mempool.cpp.o
[399/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/mempool_stress.cpp.o
[400/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoinaddressvalidator.cpp.o
[401/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoinunits.cpp.o
[402/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoinamountfield.cpp.o
[403/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/csvmodelwriter.cpp.o
[404/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o
FAILED: src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o 
/usr/bin/ccache /usr/bin/c++  -DBOOST_AC_USE_STD_ATOMIC -DBOOST_SP_USE_STD_ATOMIC -DBUILD_BITCOIN_INTERNAL -DENABLE_AVX2 -DENABLE_SHANI -DENABLE_SSE41 -DHAVE_BUILD_INFO -DHAVE_CONFIG_H -DHAVE_CONSENSUS_LIB -DHAVE_DECL_EVP_MD_CTX_NEW=1 -DLEVELDB_ATOMIC_PRESENT -DLEVELDB_PLATFORM_POSIX -DOS_LINUX -DQT_CORE_LIB -DQT_DBUS_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DUSE_PROTOBUF_MESSAGE_BYTESIZELONG -Isrc/qt/bitcoin-qt-base_autogen/include -I../../src/. -Isrc -I../../src/univalue/include -Isrc/crypto/.. -I../../src/secp256k1/include -I../../src/leveldb/include -isystem /usr/include/jemalloc -isystem /usr/include/miniupnpc -isystem /usr/include/x86_64-linux-gnu/qt5 -isystem /usr/include/x86_64-linux-gnu/qt5/QtWidgets -isystem /usr/include/x86_64-linux-gnu/qt5/QtGui -isystem /usr/include/x86_64-linux-gnu/qt5/QtCore -isystem /usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++ -isystem /usr/include/x86_64-linux-gnu/qt5/QtNetwork -isystem /usr/include/x86_64-linux-gnu/qt5/QtDBus -Werror -g -O2 -fPIC -fvisibility=hidden   -fstack-reuse=none -fstack-protector-all -Wstack-protector -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -Wall -Wextra -Wformat -Wvla -Wcast-align -Wunused-parameter -Wmissing-braces -Wshadow -Wredundant-decls -Wformat-security -Wno-unused-parameter -Wno-implicit-fallthrough -pthread -fPIC -std=gnu++14 -MD -MT src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o -MF src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o.d -o src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o -c ../../src/qt/bitcoin.cpp
../../src/qt/bitcoin.cpp: In function ‘int GuiMain(int, char**)’:
../../src/qt/bitcoin.cpp:669:25: error: ‘Untranslated’ was not declared in this scope
         node->initError(Untranslated(error).original);
                         ^~~~~~~~~~~~
../../src/qt/bitcoin.cpp:669:25: note: suggested alternative: ‘translator’
         node->initError(Untranslated(error).original);
                         ^~~~~~~~~~~~
                         translator
[405/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/rpc_blockchain.cpp.o
[406/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bantablemodel.cpp.o
[407/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/block_assemble.cpp.o
[408/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/networkstyle.cpp.o
[409/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin-qt-base_autogen/mocs_compilation.cpp.o
[410/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/platformstyle.cpp.o
[411/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/qvalidatedlineedit.cpp.o
[412/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/modaloverlay.cpp.o
[413/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/qvaluecombobox.cpp.o
[414/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/notificator.cpp.o
[415/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/clientmodel.cpp.o
[416/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/qrc_bitcoin.cpp.o
[417/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoingui.cpp.o
[418/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/bench.cpp.o
[419/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/intro.cpp.o
[420/435] Linking CXX executable src/bench/bitcoin-bench
[421/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/guiutil.cpp.o
[422/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/trafficgraphwidget.cpp.o
[423/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/utilitydialog.cpp.o
[424/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/optionsmodel.cpp.o
[425/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/optionsdialog.cpp.o
[426/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/splashscreen.cpp.o
[427/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/peertablemodel.cpp.o
[428/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/qrc_bitcoin_locale.cpp.o
[429/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/rpcconsole.cpp.o
ninja: build stopped: cannot make progress due to previous errors.
Build build-without-wallet failed with exit code 1

Rebase and fix translation related conflict

Tail of the build log:

[382/435] Generating forms/ui_optionsdialog.h
[383/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/util_time.cpp.o
[384/435] Generating forms/ui_overviewpage.h
[385/435] Generating forms/ui_receiverequestdialog.h
[386/435] Generating forms/ui_debugwindow.h
[387/435] Generating forms/ui_sendcoinsentry.h
[388/435] Generating forms/ui_signverifymessagedialog.h
[389/435] Generating forms/ui_transactiondescdialog.h
[390/435] Generating forms/ui_sendcoinsdialog.h
[391/435] Generating qrc_bitcoin.cpp
[392/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/checkqueue.cpp.o
[393/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/data.cpp.o
[394/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/crypto_aes.cpp.o
[395/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/checkblock.cpp.o
[396/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/mempool_eviction.cpp.o
[397/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/duplicate_inputs.cpp.o
[398/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/rpc_mempool.cpp.o
[399/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoinunits.cpp.o
[400/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoinaddressvalidator.cpp.o
[401/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/mempool_stress.cpp.o
[402/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoinamountfield.cpp.o
[403/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/rpc_blockchain.cpp.o
[404/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/csvmodelwriter.cpp.o
[405/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o
FAILED: src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o 
/usr/bin/ccache /usr/bin/c++  -DBOOST_AC_USE_STD_ATOMIC -DBOOST_SP_USE_STD_ATOMIC -DBUILD_BITCOIN_INTERNAL -DENABLE_AVX2 -DENABLE_SHANI -DENABLE_SSE41 -DHAVE_BUILD_INFO -DHAVE_CONFIG_H -DHAVE_CONSENSUS_LIB -DHAVE_DECL_EVP_MD_CTX_NEW=1 -DLEVELDB_ATOMIC_PRESENT -DLEVELDB_PLATFORM_POSIX -DOS_LINUX -DQT_CORE_LIB -DQT_DBUS_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DUSE_PROTOBUF_MESSAGE_BYTESIZELONG -Isrc/qt/bitcoin-qt-base_autogen/include -I../../src/. -Isrc -I../../src/univalue/include -Isrc/crypto/.. -I../../src/secp256k1/include -I../../src/leveldb/include -isystem /usr/include/jemalloc -isystem /usr/include/miniupnpc -isystem /usr/include/x86_64-linux-gnu/qt5 -isystem /usr/include/x86_64-linux-gnu/qt5/QtWidgets -isystem /usr/include/x86_64-linux-gnu/qt5/QtGui -isystem /usr/include/x86_64-linux-gnu/qt5/QtCore -isystem /usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++ -isystem /usr/include/x86_64-linux-gnu/qt5/QtNetwork -isystem /usr/include/x86_64-linux-gnu/qt5/QtDBus -Werror -g -O2 -fPIC -fvisibility=hidden   -fstack-reuse=none -fstack-protector-all -Wstack-protector -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -Wall -Wextra -Wformat -Wvla -Wcast-align -Wunused-parameter -Wmissing-braces -Wshadow -Wredundant-decls -Wformat-security -Wno-unused-parameter -Wno-implicit-fallthrough -pthread -fPIC -std=gnu++14 -MD -MT src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o -MF src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o.d -o src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin.cpp.o -c ../../src/qt/bitcoin.cpp
../../src/qt/bitcoin.cpp: In function ‘int GuiMain(int, char**)’:
../../src/qt/bitcoin.cpp:673:25: error: ‘Untranslated’ was not declared in this scope
         node->initError(Untranslated(error).original);
                         ^~~~~~~~~~~~
../../src/qt/bitcoin.cpp:673:25: note: suggested alternative: ‘translator’
         node->initError(Untranslated(error).original);
                         ^~~~~~~~~~~~
                         translator
[406/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/block_assemble.cpp.o
[407/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bantablemodel.cpp.o
[408/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoin-qt-base_autogen/mocs_compilation.cpp.o
[409/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/networkstyle.cpp.o
[410/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/qvalidatedlineedit.cpp.o
[411/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/platformstyle.cpp.o
[412/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/modaloverlay.cpp.o
[413/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/qvaluecombobox.cpp.o
[414/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/notificator.cpp.o
[415/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/clientmodel.cpp.o
[416/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/qrc_bitcoin.cpp.o
[417/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/bitcoingui.cpp.o
[418/435] Building CXX object src/bench/CMakeFiles/bitcoin-bench.dir/bench.cpp.o
[419/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/intro.cpp.o
[420/435] Linking CXX executable src/bench/bitcoin-bench
[421/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/trafficgraphwidget.cpp.o
[422/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/guiutil.cpp.o
[423/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/splashscreen.cpp.o
[424/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/optionsmodel.cpp.o
[425/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/utilitydialog.cpp.o
[426/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/peertablemodel.cpp.o
[427/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/optionsdialog.cpp.o
[428/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/qrc_bitcoin_locale.cpp.o
[429/435] Building CXX object src/qt/CMakeFiles/bitcoin-qt-base.dir/rpcconsole.cpp.o
ninja: build stopped: cannot make progress due to previous errors.
Build build-without-wallet failed with exit code 1
jasonbcox requested changes to this revision.Oct 20 2020, 19:10
jasonbcox added a subscriber: jasonbcox.

Back to you. Still a translation issue.

This revision now requires changes to proceed.Oct 20 2020, 19:10

rebase and check that translation work with and without wallet

Tail of the build log:

[357/418] bitcoin: testing timedata_tests
[358/418] bitcoin: testing streams_tests
[359/418] Running utility command for check-bitcoin-torcontrol_tests
[360/418] Running utility command for check-bitcoin-timedata_tests
[361/418] Running utility command for check-bitcoin-streams_tests
[362/418] bitcoin: testing uint256_tests
[363/418] bitcoin: testing undo_tests
[364/418] Running utility command for check-bitcoin-uint256_tests
[365/418] Running utility command for check-bitcoin-undo_tests
[366/418] bitcoin: testing sigencoding_tests
[367/418] Running utility command for check-bitcoin-sigencoding_tests
[368/418] bitcoin: testing walletdb_tests
[369/418] Running utility command for check-bitcoin-walletdb_tests
[370/418] bitcoin: testing util_threadnames_tests
[371/418] Running utility command for check-bitcoin-util_threadnames_tests
[372/418] bitcoin: testing compilerbug_tests
[373/418] bitcoin: testing txvalidationcache_tests
[374/418] Running utility command for check-bitcoin-compilerbug_tests
[375/418] Running utility command for check-bitcoin-txvalidationcache_tests
[376/418] bitcoin: testing serialize_tests
[377/418] bitcoin: testing checkpoints_tests
[378/418] Running utility command for check-bitcoin-serialize_tests
[379/418] bitcoin: testing validationinterface_tests
[380/418] Running utility command for check-bitcoin-checkpoints_tests
[381/418] Running utility command for check-bitcoin-validationinterface_tests
[382/418] bitcoin: testing blockcheck_tests
[383/418] bitcoin: testing script_standard_tests
[384/418] bitcoin: testing radix_tests
[385/418] bitcoin: testing crypto_tests
[386/418] Running utility command for check-bitcoin-blockcheck_tests
[387/418] Running utility command for check-bitcoin-script_standard_tests
[388/418] Running utility command for check-bitcoin-radix_tests
[389/418] Running utility command for check-bitcoin-crypto_tests
[390/418] bitcoin: testing getarg_tests
[391/418] Running utility command for check-bitcoin-getarg_tests
[392/418] bitcoin: testing bswap_tests
[393/418] bitcoin: testing ref_tests
[394/418] Running utility command for check-bitcoin-bswap_tests
[395/418] Running utility command for check-bitcoin-ref_tests
[396/418] bitcoin: testing script_tests
[397/418] Running utility command for check-bitcoin-script_tests
[398/418] bitcoin: testing validation_tests
[399/418] Running utility command for check-bitcoin-validation_tests
[400/418] bitcoin: testing validation_block_tests
[401/418] bitcoin: testing monolith_opcodes_tests
[402/418] Running utility command for check-bitcoin-validation_block_tests
[403/418] Running utility command for check-bitcoin-monolith_opcodes_tests
[404/418] bitcoin: testing cuckoocache_tests
[405/418] Running utility command for check-bitcoin-cuckoocache_tests
[406/418] bitcoin: testing skiplist_tests
[407/418] Running utility command for check-bitcoin-skiplist_tests
[408/418] bitcoin: testing util_tests
[409/418] bitcoin: testing op_reversebytes_tests
[410/418] Running utility command for check-bitcoin-util_tests
[411/418] Running utility command for check-bitcoin-op_reversebytes_tests
[412/418] bitcoin: testing transaction_tests
[413/418] Running utility command for check-bitcoin-transaction_tests
[414/418] bitcoin: testing coins_tests
[415/418] Running utility command for check-bitcoin-coins_tests
Build build-clang timed out after 1200.0s
This revision is now accepted and ready to land.Oct 21 2020, 21:17