c7b0d80939 Merge #6441: fix: hold wallet shared pointer in CJ Manager/Sessions to prevent concurrent unload (pasta)
c074e0965b Merge #6444: fix: add platform transfer to "most common" filter (pasta)
cb04114143 Merge #6442: fix: coin selection with `include_unsafe` option should respect `nCoinType` (pasta)
db5b53a9a7 Merge #6434: fix: early EHF and buried EHF are indistinguish (pasta)
Pull request description:
## Issue being fixed or feature implemented
See commits; backports for rc.3
## What was done?
## How Has This Been Tested?
built locally
## Breaking Changes
## 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)_
ACKs for top commit:
kwvg:
ACK c7b0d80939
UdjinM6:
utACK c7b0d80939
Tree-SHA512: a64d6503a845ea86df8660d34cdf819c6fefcae5e82035bd8de40152f4f7d894cd1870315b791cca81e6d4db08d9929e4d1de3338a0338478072c9e6bb66952a
2d7c7f81b8 fix: do not transfer wallet ownership to CTransactionBuilder{Output} (UdjinM6)
0aeeb8583a fix: add missing `AddWallet` call in `TestLoadWallet` (UdjinM6)
e800d9d09c fix: hold wallet shared pointer in CJ Manager/Sessions to prevent concurrent unload (UdjinM6)
Pull request description:
## Issue being fixed or feature implemented
https://github.com/dashpay/dash/pull/6440#discussion_r1865042366
## What was done?
## How Has This Been Tested?
## Breaking Changes
## Checklist:
- [ ] 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
- [ ] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_
ACKs for top commit:
PastaPastaPasta:
utACK 2d7c7f81b8
Tree-SHA512: 308e3bed077baa2167b7f9d81b87e5a61a113e4d465706548f303dfc499bc072d4e823e85772e591a879986b0fb0413d5afe0e3995e1f939fa772b29adc0300d
36893e4ba4 fix: add platform transfer to "most common" filter on transactions tab (Konstantin Akimov)
d033a3ae06 refactor: change mask from Dec presentation to Hex for transaction filter (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
Follow-up https://github.com/dashpay/dash/pull/6131 - missing 'Platform Transfer' in the list of most common. Reported by splawik.
## What was done?
Updated filter, added comment to prevent similar mistakes in future, present filter in hex for better readability.
## How Has This Been Tested?
Transaction with platform transfer appeared in filter "Most Common"
![image](https://github.com/user-attachments/assets/ccc17553-d71a-45f8-be2f-8ce5fb699c1a)
Also they are added to Overview page (compare screenshots by 'address' field)
![image](https://github.com/user-attachments/assets/ea657672-46c8-4a66-a972-15768feb4d57)
## 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
ACKs for top commit:
UdjinM6:
utACK 36893e4ba4
PastaPastaPasta:
utACK 36893e4ba4
Tree-SHA512: e072b78e257b2c262a912a3cc0daebde93aca655edfee9bbf4869f2528f10377d7d234c73c4fd7ab6006e87607d5a7c4eddd7634d55b16d1b3885d0bc48f225a
e5114da325 fix: coin selection with `include_unsafe` option should respect `nCoinType` (UdjinM6)
Pull request description:
## Issue being fixed or feature implemented
The issue was introduced in #6074 via 69c5aa8947
## What was done?
## How Has This Been Tested?
## Breaking Changes
## Checklist:
- [ ] 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
- [ ] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_
ACKs for top commit:
PastaPastaPasta:
utACK e5114da325
kwvg:
utACK e5114da325
Tree-SHA512: 5d4e22f9d2cecf2239185e0f4c9d8b29b995b25b4f53a74d6c9b7929aac6ec918ebfb4029a83b72a003fe42fe82619f7ab4892d620bf5846cadf99f1f0cb0969
4629bb9ba5 fix: add missing cs_main annotation for ForceSignalDBUpdate (Konstantin Akimov)
05041a4572 fix: force ehf signal db update (UdjinM6)
94d80323d4 fix: typo name of key (Konstantin Akimov)
9ceba88cdb style: clang suggestion (Konstantin Akimov)
c6bb9a5685 perf: re-use evo data about signals between v20 and mn_rr as non-corrupted (Konstantin Akimov)
7a7c9f12a4 fix: early EHF and buried EHF are indistinguish (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
It seems as EHF signal will be mined before node is updated, this signal is lost and node can't activate hard-fork anymore.
## What was done?
EHF signals doesn't expire anymore.
To avoid full re-index key in database is changed.
Client with enabled "pruned mode" will be required to do re-index.
Alternate solution - revert this commit 4b046bb608 and introduce time-out for expiring EHF signals.
## How Has This Been Tested?
Test on my local instance with testnet and mainnet.
Testing on miner-1 on testnet is done.
First start of miner took 50 seconds, 29 of them the node was re-scanning blockchain and looking for EHF transaction
## Breaking Changes
It requires re-index for nodes with enabled pruning of blocks.
## Checklist:
- [ ] 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)_
ACKs for top commit:
PastaPastaPasta:
utACK [4629bb9](4629bb9ba5)
UdjinM6:
utACK 4629bb9ba5
Tree-SHA512: 189533da5726edbcf2d9cf0e9a3957a10ebc223c25fd88aec3aa9095ae2e7d955ea1f7a1384bc2c97a0cc06110c9e38845a8cafdbd56ff9637bb907ddc639850
2d7c7f81b8 fix: do not transfer wallet ownership to CTransactionBuilder{Output} (UdjinM6)
0aeeb8583a fix: add missing `AddWallet` call in `TestLoadWallet` (UdjinM6)
e800d9d09c fix: hold wallet shared pointer in CJ Manager/Sessions to prevent concurrent unload (UdjinM6)
Pull request description:
## Issue being fixed or feature implemented
https://github.com/dashpay/dash/pull/6440#discussion_r1865042366
## What was done?
## How Has This Been Tested?
## Breaking Changes
## Checklist:
- [ ] 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
- [ ] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_
ACKs for top commit:
PastaPastaPasta:
utACK 2d7c7f81b8
Tree-SHA512: 308e3bed077baa2167b7f9d81b87e5a61a113e4d465706548f303dfc499bc072d4e823e85772e591a879986b0fb0413d5afe0e3995e1f939fa772b29adc0300d
e5114da325 fix: coin selection with `include_unsafe` option should respect `nCoinType` (UdjinM6)
Pull request description:
## Issue being fixed or feature implemented
The issue was introduced in #6074 via 69c5aa8947
## What was done?
## How Has This Been Tested?
## Breaking Changes
## Checklist:
- [ ] 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
- [ ] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_
ACKs for top commit:
PastaPastaPasta:
utACK e5114da325
kwvg:
utACK e5114da325
Tree-SHA512: 5d4e22f9d2cecf2239185e0f4c9d8b29b995b25b4f53a74d6c9b7929aac6ec918ebfb4029a83b72a003fe42fe82619f7ab4892d620bf5846cadf99f1f0cb0969
36893e4ba4 fix: add platform transfer to "most common" filter on transactions tab (Konstantin Akimov)
d033a3ae06 refactor: change mask from Dec presentation to Hex for transaction filter (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
Follow-up https://github.com/dashpay/dash/pull/6131 - missing 'Platform Transfer' in the list of most common. Reported by splawik.
## What was done?
Updated filter, added comment to prevent similar mistakes in future, present filter in hex for better readability.
## How Has This Been Tested?
Transaction with platform transfer appeared in filter "Most Common"
![image](https://github.com/user-attachments/assets/ccc17553-d71a-45f8-be2f-8ce5fb699c1a)
Also they are added to Overview page (compare screenshots by 'address' field)
![image](https://github.com/user-attachments/assets/ea657672-46c8-4a66-a972-15768feb4d57)
## 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
ACKs for top commit:
UdjinM6:
utACK 36893e4ba4
PastaPastaPasta:
utACK 36893e4ba4
Tree-SHA512: e072b78e257b2c262a912a3cc0daebde93aca655edfee9bbf4869f2528f10377d7d234c73c4fd7ab6006e87607d5a7c4eddd7634d55b16d1b3885d0bc48f225a
4629bb9ba5 fix: add missing cs_main annotation for ForceSignalDBUpdate (Konstantin Akimov)
05041a4572 fix: force ehf signal db update (UdjinM6)
94d80323d4 fix: typo name of key (Konstantin Akimov)
9ceba88cdb style: clang suggestion (Konstantin Akimov)
c6bb9a5685 perf: re-use evo data about signals between v20 and mn_rr as non-corrupted (Konstantin Akimov)
7a7c9f12a4 fix: early EHF and buried EHF are indistinguish (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
It seems as EHF signal will be mined before node is updated, this signal is lost and node can't activate hard-fork anymore.
## What was done?
EHF signals doesn't expire anymore.
To avoid full re-index key in database is changed.
Client with enabled "pruned mode" will be required to do re-index.
Alternate solution - revert this commit 4b046bb608 and introduce time-out for expiring EHF signals.
## How Has This Been Tested?
Test on my local instance with testnet and mainnet.
Testing on miner-1 on testnet is done.
First start of miner took 50 seconds, 29 of them the node was re-scanning blockchain and looking for EHF transaction
## Breaking Changes
It requires re-index for nodes with enabled pruning of blocks.
## Checklist:
- [ ] 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)_
ACKs for top commit:
PastaPastaPasta:
utACK [4629bb9](4629bb9ba5)
UdjinM6:
utACK 4629bb9ba5
Tree-SHA512: 189533da5726edbcf2d9cf0e9a3957a10ebc223c25fd88aec3aa9095ae2e7d955ea1f7a1384bc2c97a0cc06110c9e38845a8cafdbd56ff9637bb907ddc639850
da0b8e2ce1 refactor: drop unneeded MIN_PEER_PROTO_VERSION from RelayInv (pasta)
94da0de6ef refactor: implement minimal RelayInv which doesn't rely on m_connman (pasta)
Pull request description:
## Issue being fixed or feature implemented
Vast majority of usages of RelayInv don't use the minProtoVersion, we may as well have these not contribute to contention of m_nodes_mutex / use m_connman
## What was done?
new implementation of RelayInv which doesn't rely on m_connman
## How Has This Been Tested?
See CI
## Breaking Changes
## Checklist:
- [ ] 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)_
ACKs for top commit:
kwvg:
utACK da0b8e2ce1
knst:
utACK da0b8e2ce1
UdjinM6:
utACK da0b8e2ce1
Tree-SHA512: 55e3e18607f3da104a943e09b29068ecf3bced869efbc804d6242c818ec3f7eb6768ea0cc6a409677559d3206dfc21bfff096a050ebbeb903e3fc2883e9bc8a4
0a63029c96 feat: increase threshold from 2000 DASH to 21M DASH for CJ amount in option (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
With rpc and command line option you can choose any amount of CJ (threshold to stop), but UI let to choose maximum 2000 Dash.
Assuming, that Evo collateral is 4000 it's unwisely to limit UI to just 2k.
## What was done?
Limits are increased to `MAX_COINJOIN_AMOUNT` (21M)
## How Has This Been Tested?
Run UI and set
## 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
ACKs for top commit:
UdjinM6:
utACK 0a63029c96
PastaPastaPasta:
utACK 0a63029c96
Tree-SHA512: 0e3498b3788e3786d51b4f0534e719201ce2c90ddba094f7e1d7a8ee5f88d860db62efc480c1910d80fe2c0ec4536c9f339a4a0c36ab781974da03b1453cdfd0
37fbdee1d9 feat: do not mine extra quorum in feature_dip3_v19.py (Konstantin Akimov)
70ba007f1a feat: do not mine extra quorum in feature_llmq_evo.py (Konstantin Akimov)
129385d349 feat: remove regular masternodes from feature_asset_locks tests (Konstantin Akimov)
8ea45bbf69 fix: make helper get_merkle_root works with no masternodes (Konstantin Akimov)
7e0c2ca5a5 fix: make dynamic masternode register even without is-quorum (Konstantin Akimov)
Pull request description:
This PR has important fixes to implement "single-node quorum" feature.
## Issue being fixed or feature implemented
Without IS-quorum you can not dynamically add a new MN or Evo node.
For evo nodes adding it dynamically is the only way.
## What was done?
Fixed a function that dynamically adds a masternode without Instant Send quorums; use it in a functional test feature_asset_locks.py
As side effect it improves performance of functional tests which do not wait more IS lock significantly; for feature_asset_locks.py it gave ~20 seconds per run.
## How Has This Been Tested?
See updates in `feature_asset_locks.py`, `feature_llmq_evo.py`, `feature_dip3_v19.py`
## 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
- [x] I have added or updated relevant unit/integration/functional/e2e tests
- [x] 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)_
ACKs for top commit:
UdjinM6:
utACK 37fbdee1d9
PastaPastaPasta:
utACK 37fbdee1d9
Tree-SHA512: 2da036ccd9842946f20450606621108fa8cd8fae31927ac2d1fc5f02bf9c2f6955a67e23ef76141a02299510c8cbf206fcd4947b0ec41b776fe80f70947afc14
Vast majority of usages of RelayInv don't use the minProtoVersion, we may as well have these not contribute to contention of m_nodes_mutex / use m_connman
6f75a7f601 refactor: use swap instead assign+clean in GetAndClearDirtyGovernanceObjectHashes (Konstantin Akimov)
83e0bb6e35 fix: potential bug due to unspecified state of std::vector after move (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
All standard library objects that have been moved from are placed in a "valid but unspecified state", meaning the object's class invariants hold (so functions without preconditions, such as the assignment operator, can be safely used on the object after it was moved from). See example:
```
std::vector<int> v = {2, 3, 3};
std::vector<int> u = std::move(v); // the value of v is unspecified
v.clear(); // we are good now
```
Instead, let's have swap better!
```
WITH_LOCK(cs_pendingSigns, v.swap(pendingSigns));
```
## What was done?
Fixed `CSigSharesManager::SignPendingSigShares`, `CSigningManager::ProcessPendingReconstructedRecoveredSigs` and refactored `CMasternodeMetaMan::GetAndClearDirtyGovernanceObjectHashes` for unification.
## How Has This Been Tested?
Run unit and functional tests.
## 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
ACKs for top commit:
PastaPastaPasta:
utACK 6f75a7f601
UdjinM6:
utACK 6f75a7f601
Tree-SHA512: 5dd8664dbe9ce78329dfae24f6e8b67b7032ff7d2c066da0e01c4ed1b13bf76359a0307ee76e5b006820318693f067b505e59408614f47ee2fa8a979a1e0dc4d
1bba72d824224f8a2625f529963d8982a00dfe14 Clarify in -maxtimeadjustment that only outbound peers influence time data (Jon Atack)
Pull request description:
#23631 changed our adjusted time to only take into account time from outbound peers.
Update `-maxtimeadjustment` to clarify this for users.
ACKs for top commit:
MarcoFalke:
cr ACK 1bba72d824224f8a2625f529963d8982a00dfe14
mzumsande:
code Review ACK 1bba72d824224f8a2625f529963d8982a00dfe14
brunoerg:
crACK 1bba72d824224f8a2625f529963d8982a00dfe14
Tree-SHA512: ad610ab3038fb83134e21d31cca952ef9ac926e88992ff93023b7010f2499f9a4d952e8e98a0ec56f8949872d966e5ffdd01a81e6b6115768f1992bd81be7a56
0c85dc30e6b628f7538a67776c7eefcb84ef4f82 p2p: Don't use timestamps from inbound peers (Martin Zumsande)
Pull request description:
`GetAdjustedTime()` (used e.g. in validation and addrman) returns a time with an offset that is influenced by timestamps that our peers have sent us in their version message.
Currently, timestamps from all peers are used for this.
However, I think that it would make sense to ignore the timedata samples from inbound peers, making it much harder for others to influence the Adjusted Time in a targeted way.
With the extra feeler connections (every 2 minutes on average) and extra block-relay-only connections (every 5 minutes on average) there are also now plenty of opportunities to gather a meaningful number of timedata samples from outbound peers.
There are some measures in place to prevent abuse: the `-maxtimeadjustment` parameter with a default of 70 minutes, warnings in cases of large deviations, only using the first 200 samples ([explanation](383d350bd5/src/timedata.cpp (L57-L72))), but I think that only using samples from outbound connections in the first place would be an additional safety measure that would make sense.
See also issue #4521 for further context and links: There have been several discussions in the past about replacing or abolishing the existing timedata system.
ACKs for top commit:
jnewbery:
Concept and code review ACK 0c85dc30e6b628f7538a67776c7eefcb84ef4f82
naumenkogs:
ACK 0c85dc30e6b628f7538a67776c7eefcb84ef4f82
vasild:
ACK 0c85dc30e6b628f7538a67776c7eefcb84ef4f82
Tree-SHA512: 2d6375305bcae034d68b58b7a07777b40ac430dfed554c88e681a048c527536691e1b7d08c0ef995247d356f8e81aa0a4b983bf2674faf6a416264e5f1af0a96
fad81548fa03861c244397201d6b6e6cbf883c38 test: Avoid testing negative block heights (MarcoFalke)
Pull request description:
A negative chain height is only used to denote an empty chain, not the height of any block.
So stop testing that and remove a suppression.
ACKs for top commit:
brunoerg:
crACK fad81548fa03861c244397201d6b6e6cbf883c38
Tree-SHA512: 0f9e91617dfb6ceda99831e6cf4b4bf0d951054957c159b1a05a178ab6090798fae7368edefe12800da24585bcdf7299ec3534f4d3bbf5ce6a6eca74dd3bb766