Commit Graph

24388 Commits

Author SHA1 Message Date
Konstantin Akimov
55abf7fa8d refactor: drop dependency test/evo_deterministicmns_tests on llmq::utils 2023-12-21 23:02:31 -06:00
Konstantin Akimov
ad4d753bd7 refactor: use DeploymentActiveAfter in llmq/blockprocessor 2023-12-21 23:02:31 -06:00
Konstantin Akimov
1ed7f0cca4 refactor: use DeploymentActiveAfter instead llmq::utils in rpc/ 2023-12-21 23:02:31 -06:00
Konstantin Akimov
39dc612eee refactor: drop dependency test/util/setup_common on llmq/utils 2023-12-21 23:02:31 -06:00
Konstantin Akimov
c4d634c051 refactor: use DeploymentActiveAfter in init.cpp 2023-12-21 23:02:31 -06:00
Konstantin Akimov
7bce9d8209 refactor: use CFinalCommitment::GetVersion in llmq/{commitment,dkgsession} 2023-12-21 23:02:31 -06:00
Konstantin Akimov
9aa437115a refactor: use DeploymentActiveAfter in evo/mnauth 2023-12-21 23:02:31 -06:00
Konstantin Akimov
2128d58b4f refactor: use DeploymentActiveAfter in cbtx 2023-12-21 23:02:31 -06:00
Konstantin Akimov
488c895a65 refactor: use DeploymentActiveAfter in ehf_signals 2023-12-21 23:02:31 -06:00
Konstantin Akimov
377d929edc refactor: drop dependency evo/simplifiedmns on llmq/utils 2023-12-21 23:02:31 -06:00
Konstantin Akimov
c742b9acf5 refactor: drop unused llmq::utils::IsMNRewardReallocationActive 2023-12-21 23:02:31 -06:00
Konstantin Akimov
a79aa56d9b refactor: move out helper IsDIP3Enforced from deterministicmns 2023-12-21 23:02:31 -06:00
Konstantin Akimov
5a84eb0f0a refactor: drop default value from IsDIP3Enforced() 2023-12-21 23:02:31 -06:00
Konstantin Akimov
f7274c450b refactor: use deployment status in deterministicmns instead llmq's helpers 2023-12-21 23:02:31 -06:00
Konstantin Akimov
13adedb423 refactor: move common code in deterministicmns to the helper 2023-12-21 23:02:31 -06:00
Konstantin Akimov
251a89736d refactor: rename argument pindex to pindexPrev in GetMNPayee and GetProjectedMNPayees 2023-12-21 23:02:31 -06:00
Konstantin Akimov
82c01ea664 refactor: drop dependency creditpool on llmq/utils 2023-12-21 23:02:31 -06:00
Konstantin Akimov
e94f5753c9 refactor: drop dependency of specialtxman on llmq/utils 2023-12-21 23:02:31 -06:00
Konstantin Akimov
bacaa805ea fix: use proper pindex/pindex->pprev in credit pool code during v20/mn_rr activations 2023-12-21 23:02:31 -06:00
Konstantin Akimov
f3d2f2da26 refactor: drop dependency unit test block_reward_reallocation_tests on llmq/utils 2023-12-21 23:02:31 -06:00
Konstantin Akimov
c25d336e95 refactor: drop dependency masternode/payments on llmq/utils 2023-12-21 23:02:31 -06:00
Konstantin Akimov
8f3d3db9a4 refactor: drop dependency governance/classes on llmq/utils 2023-12-21 23:02:31 -06:00
Konstantin Akimov
c329615584 refactor: use value_or in std::optional 2023-12-21 23:02:31 -06:00
Konstantin Akimov
a7ad399824 refactor: drop IsDIP0024Active and its usage of llmq_vbc 2023-12-21 23:02:31 -06:00
Konstantin Akimov
68442e8dfe chore: add TODO for llmq/utils.h refactoring 2023-12-21 23:02:31 -06:00
PastaPastaPasta
3855f9775e
chore: do not include dash-qt in the docker images (#5775)
## Issue being fixed or feature implemented
Remove dash-qt from docker images; save ~41MB

## What was done?


## How Has This Been Tested?
Hasn't

## Breaking Changes
I guess in theory someone could've been relying on dash-qt from docker 🤷

## Checklist:
_Go over all the following points, and put an `x` in all the boxes that
apply._
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have added or updated relevant unit/integration/functional/e2e
tests
- [ ] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone _(for repository
code-owners and collaborators only)_
2023-12-21 21:59:01 -06:00
PastaPastaPasta
acd2acd592
refactor: pass large structure by const reference on every RPC call (#5780) 2023-12-21 12:01:39 -06:00
UdjinM6
6fe36cc1cb
fix: Improve quorum caching (again) (#5761)
## Issue being fixed or feature implemented
1. `scanQuorumsCache` is a special one and we use it incorrectly.
2. Platform doesn't really use anything that calls `ScanQuorums()`
directly, they specify the exact quorum hash in RPCs so it's
`GetQuorum()` that is used instead. The only place `ScanQuorums()` is
used for Platform related stuff is `StartCleanupOldQuorumDataThread()`
because we want to preserve quorum data used by `GetQuorum()`. But this
can be optimised with its own (much more compact) cache.
3. RPCs that use `ScanQuorums()` should in most cases be ok with smaller
cache, for other use cases there is a note in help text now.

## What was done?
pls see individual commits

## How Has This Been Tested?
run tests, run a node (~in progress~ looks stable)

## Breaking Changes
n/a

## Checklist:
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have added or updated relevant unit/integration/functional/e2e
tests
- [ ] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone
2023-12-20 09:54:00 -06:00
UdjinM6
647f4831c1
chore: update file permissions in tests, add missing executable flag (#5778)
## Issue being fixed or feature implemented
old mode 100644
new mode 100755

## What was done?
`chmod +x test/functional/*.py`

## How Has This Been Tested?
can now run these test directly e.g. `./test/functional/rpc_quorum.py`

## Breaking Changes
n/a

## Checklist:
- [x] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have added or updated relevant unit/integration/functional/e2e
tests
- [ ] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone _(for repository
code-owners and collaborators only)_
2023-12-19 08:03:11 -06:00
UdjinM6
9a99a4abdc
fix(rpc): pass blockhash into TxToJSON so that getspecialtxes could show correct instantlock/chainlock values (#5774)
## Issue being fixed or feature implemented
`instantlock` and `chainlock` are broken in `getspecialtxes`

kudos to @thephez for finding the issue

## What was done?
pass the hash and also rename the variable to self-describing

## How Has This Been Tested?
run `getspecialtxes` on a node with and without the patch

## Breaking Changes
`instantlock` and `chainlock` will show actual values and not just
`false` all the time now (not sure if that qualifies for "breaking"
though)

## Checklist:
- [x] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have added or updated relevant unit/integration/functional/e2e
tests
- [ ] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone _(for repository
code-owners and collaborators only)_
2023-12-19 07:43:36 -06:00
Odysseas Gabrielides
3bc77a6e1d
feat(rpc): submit chainlock signature if needed RPC (#5765)
## Issue being fixed or feature implemented
Once Platform is live, there could be an edge case where the CL could
arrive to an EvoNode faster through Platform quorum than regular P2P
propagation.

## What was done?
This PR introduces a new RPC `submitchainlock` with the following 3
mandatory parameters:
- `blockHash`, `signature` and `height`.

Besides some basic tests:
- If the block is unknown then the RPC returns an error (could happen if
the node is stucked)
- If the signature is not verified then the RPC return an error.
- If the node already has this CL, the RPC returns true.
- If the node doesn't have this CL, it inserts it, broadcast it through
the inv system and return true.

## How Has This Been Tested?
`feature_llmq_chainlocks.py` was modified with the following scenario:

1. node0 is isolated from the rest of the network
2. node1 mines a new block and waits for CL
3. Make sure node0 doesn't know the new block/CL (by checking
`getbestchainlock()`)
4. CL is submitted via the new RPC on node0
5. checking `getbestchainlock()` and make sure the CL was processed +
'known_block' is false
6. reconnect node0

## Breaking Changes
no

## Checklist:
- [x] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [x] I have added or updated relevant unit/integration/functional/e2e
tests
- [ ] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone _(for repository
code-owners and collaborators only)_

---------

Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>
Co-authored-by: thephez <thephez@users.noreply.github.com>
2023-12-18 22:27:19 -06:00
PastaPastaPasta
714be63de5
Merge pull request #5743 from knst/bitcoinserver-15639-p1
refactor: pull libbitcoin_server code out of wallet code 3/N
2023-12-17 12:43:32 -06:00
Konstantin Akimov
e3d9327d17 refactor: replace usage of deterministicMNManager to new interface listMNCollaterials 2023-12-17 12:42:45 -06:00
Konstantin Akimov
2c61d842a9 refactor: new method listMNCollaterials() for chain interface 2023-12-17 12:42:45 -06:00
Konstantin Akimov
4966bf7582 refactor: use static method CDeterministicMNManager without touching global variable in wallet's code 2023-12-17 12:42:45 -06:00
Konstantin Akimov
2310e353ff refactor: use std::all_of in isGroupISLocked 2023-12-17 12:42:45 -06:00
Konstantin Akimov
41b71dc0f5 refactor: removed usage of llmq::chainLocksHandler from wallet 2023-12-17 12:42:45 -06:00
Konstantin Akimov
0fea98b65f refactor: replace llmq::quorumInstantSendManager->IsLocked() to new chain's interface 2023-12-17 12:42:45 -06:00
Konstantin Akimov
808e631a08 fix: dirty removal of dependency of scriptpubkeyman on ShutdownRequested introduced in #5456 2023-12-17 12:42:45 -06:00
Konstantin Akimov
d95d7f63c9 refactor: remove dependency scriptpubkeyman on uiInterface 2023-12-17 12:42:45 -06:00
Konstantin Akimov
aa48c222ab follow-up bitcoin#15288 - missing fPrune usage 2023-12-17 12:42:45 -06:00
PastaPastaPasta
40f7ae8fbc
Merge pull request #5682 from vijaydasmp/bp23_4
backport: Merge partial bitcoin#24203,22523,22739,13533
2023-12-11 15:49:15 -06:00
fanquake
5cd9882759 Merge bitcoin/bitcoin#22739: doc: link to managing-wallets from docs README
1ea11e10acd60807a06adea5ecf553974a1b0346 doc: link to managing-wallets from doc readme (fanquake)

Pull request description:

  This was forgotten in #22523.

ACKs for top commit:
  achow101:
    ACK 1ea11e10acd60807a06adea5ecf553974a1b0346
  jarolrod:
    ACK 1ea11e10acd60807a06adea5ecf553974a1b0346

Tree-SHA512: b82664b282cc0fe733b752c011621593df0f846d2188f12dbc5fedb7ffed2bd161293ce2a369ca973926030795b5f7acde7a1cbf5e337042a6f665906069c656
2023-12-11 15:48:44 -06:00
Samuel Dobson
5bd334a33b Merge bitcoin/bitcoin#22523: Document about wallet backup and restoration
ce4e90629ed70f4d45906d7e79563b2f7ad6493e Document about wallet backup and restoration (lsilva01)

Pull request description:

  This PR adds a document about backing up and restoring the Bitcoin Core wallet as suggested in the issue https://github.com/bitcoin/bitcoin/issues/20149 .

ACKs for top commit:
  achow101:
    re-ACK ce4e90629ed70f4d45906d7e79563b2f7ad6493e
  prayank23:
    reACK ce4e90629e
  meshcollider:
    re-ACK ce4e90629ed70f4d45906d7e79563b2f7ad6493e

Tree-SHA512: 68881fc1d81ff27cb59b891e6d422e303844a751afd9f4699f7ae505f204452afe9496c9be915ba94a7045f3cf3eaeb2af0e42ff2a12b4c77ef1f71a9de4faad
2023-12-11 15:48:44 -06:00
Vijay Das Manikpuri
38b9074275 (partial) Merge #24203: doc: Fix typos pointed out by lint-spelling 2023-12-11 15:48:44 -06:00
PastaPastaPasta
985da9ab93
Merge pull request #5759 from UdjinM6/bp26532
backport: partial merge bitcoin#26532: wallet: bugfix, invalid crypted key "checksum_valid" set
2023-12-11 15:43:57 -06:00
furszy
d7bae33f57
partial merge bitcoin#26532: wallet: bugfix, invalid crypted key "checksum_valid" set
backports cc5a5e81217506ec6f9fff34056290f8f40a7396 only

```
wallet: bugfix, invalid crypted key "checksum_valid" set

At wallet load time, we set the crypted key "checksum_valid" variable always to false.
Which, on every wallet decryption call, forces the process to re-write the entire ckeys to db when
it's not needed.
```
2023-12-10 20:04:48 +03:00
UdjinM6
3c516eeec4
Merge pull request #5534 from vijaydasmp/bp22_15
backport: Merge bitcoin#18842, 21162, 21043, 17556, 18017, 8795, 19362, 20932, bitcoin-core/gui#162
2023-12-09 12:36:28 +03:00
MarcoFalke
09973f2bee Merge #20932: refactor: Replace fs::absolute calls with AbsPathJoin calls
da9caa1cedd69702aea44cb44b2fd0a2d6d56916 Replace fs::absolute calls with AbsPathJoin calls (Kiminuo)
66576c4fd532ac18b8b355ea93d25581a2c15654 test: Clear forced -walletdir setting after wallet init_tests (Kiminuo)

Pull request description:

  This adds better test coverage and will make it easier in #20744 to remove our dependency on the two-argument boost::filesystem::absolute() function which does not have a direct equivalent in C++17.

  This PR doesn't change behavior aside from adding an assert and fixing a test bug.

ACKs for top commit:
  jonatack:
    Code review ACK da9caa1cedd69702aea44cb44b2fd0a2d6d56916 only doxygen improvements since my last review per `git diff d867d7a da9caa1`
  MarcoFalke:
    review ACK da9caa1cedd69702aea44cb44b2fd0a2d6d56916 📯
  ryanofsky:
    Code review ACK da9caa1cedd69702aea44cb44b2fd0a2d6d56916. Just comment and test tweaks since previous review.

Tree-SHA512: c940ee60f3ba374d4927cf34cf12d27c4c735c94af591fbc0ca408c641b30f8f8fbcfe521d66bfbddf9877a1fc8cd99bd8a47ebcd2fa59789de6bd87a7b9cf4d
2023-12-08 21:16:00 +03:00
MarcoFalke
d6d3e0905c Merge bitcoin/bitcoin#19362: rpc/blockchain: Reset scantxoutset progress before inferring descriptors
8c4129b4540f4f739413ed9a6fbfc78afc252f42 rpc: reset scantxoutset progress on finish (Pavol Rusnak)

Pull request description:

  Fixes https://github.com/bitcoin/bitcoin/issues/19361 by moving resetting the `g_scan_progress` variable **before** inferring the descriptors

ACKs for top commit:
  achow101:
    Code review ACK 8c4129b4540f4f739413ed9a6fbfc78afc252f42

Tree-SHA512: 2b81e5c930b9c201a1b9cc742c37e0617582326acd9adbd6b14991d33c05d51b1d5ff6a26f3accab7d274dc8c6a48bc8cbccf0811b60c1f76dd805f9b31482c0
2023-12-08 21:16:00 +03:00