this commit will not work with `--enable-c++20` as c++20 does away with
aggregate initialization when constructors are declared. a partial
backport of bitcoin#24169 will sort that out.
059171009b0138555f311cedc2553015ff618323 consensus/params: simplify ValidDeployment check to avoid gcc warning (Anthony Towns)
Pull request description:
Simplifies the ValidDeployment check to only check the upperbound, relying on the lower bound to be trivially true due to enum values starting at the minimum value of the underlying type (which is checked at compile time in deploymentstatus.cpp). Avoids a "comparison always true" warning in some versions of gcc.
Fixes#22587
ACKs for top commit:
MarcoFalke:
review ACK 059171009b0138555f311cedc2553015ff618323
tryphe:
retested ACK 059171009b0138555f311cedc2553015ff618323
Tree-SHA512: e53b5d478b46d35ec476d004e3c92803afb874c138dd6ef3848861f4281cc113fe88921bc4ac74fd4decbf318ed776d3f816c3a1185f99dc36a5cfecfff51f7c
12f094ec215aacf30e4e380c0399f80d4e45c345 test: use constants for CSV/CLTV activation heights in rpc_signrawtransaction (Sebastian Falbesoner)
746f203f1950a7df50b9a7de87a361cc7354ffb4 test: introduce `generate_to_height` helper, use in rpc_signrawtransaction (Sebastian Falbesoner)
e3237b1cd07a5099fbb0108218194eb653b6a9f3 test: check that CSV/CLTV are active in rpc_signrawtransaction (Sebastian Falbesoner)
Pull request description:
This PR primarily aims to solve the current RPC timeout problem for test rpc_signrawtransaction.py, as described in #22542. In the course of that the test is also improved in other ways (see https://github.com/bitcoin/bitcoin/pull/22542#pullrequestreview-714297804).
Reviewers guideline:
* In `test_signing_with_cltv()`, a comment is fixed -- it wrongly referred to CSV, it should be CLTV.
* As preparation, assertions are added that ensure that CSV and CLTV have been really activated after generating blocks by checking the 'softforks' output of the getblockchaininfo() RPC. Right now in master, one could remove (or decrease, like in #22542) the generate calls and the test would still pass, when it shouldn't.
* A helper `generate_to_height()` is introduced which improves the previous way of reaching a block height in two ways:
- instead of blindly generating TH blocks to reach target block height >= TH, the current block height CH is taken into account, and only (TH - CH) are generated in total
- to avoid potential RPC timeouts, the block generation is split up into multiple generatetoaddress RPC calls ([as suggested by laanwj](https://github.com/bitcoin/bitcoin/pull/22542#issuecomment-886237866)); here chunks of 200 blocks have been chosen
* The helper is used in the affected sub-tests, which should both speed-up the test (from ~18s to ~12s on my machine) and avoid potential timeouts
* Finally, the activation constants for CSV and CLTV are used instead of using magic numbers 500 and 1500
Open questions:
* Any good naming alternatives for `generate_to_height()`? Not really happy with the name, happy to hear suggestions
* Where to put the CSV and CLTV activation height constants in the test_framewor folder? I guess importing constants from other tests isn't really the desired way to go
ACKs for top commit:
laanwj:
Code review and tested ACK 12f094ec215aacf30e4e380c0399f80d4e45c345
rajarshimaitra:
reACK 12f094ec21
Tree-SHA512: 14509f6d3e5a5a05d6a30a3145bb82cd96a29d9d8a589abf1944a8bf34291cde78ce711195f52e9426588dc822b3618ec9b455e057360021ae46152bb7613516
fa5658ed077bfb02b6281d642dc649abdb99b6ee Use DeploymentEnabled to hide VB deployments (MarcoFalke)
fa11fecf0dac44846a08e1b325547641f2eca957 doc: Move buried deployment doc to the enum that enumerates them (MarcoFalke)
Pull request description:
Plus a doc commit.
ACKs for top commit:
jnewbery:
utACK fa5658ed077bfb02b6281d642dc649abdb99b6ee
ajtowns:
utACK fa5658ed077bfb02b6281d642dc649abdb99b6ee
Tree-SHA512: 2aeceee0674feb603d76656eff40695b7d7305de309f837bbb6a8c1dbb1d0b962b741f06ab7b9a8b1dbd1964c9c0c9aa5dc9588fd8e6d896e620b69e08eedbaa
stdout:
2024-08-08T05:02:32.216000Z TestFramework (INFO): Initializing test directory /tmp/test_runner_∋_🏃_20240808_120217/p2p_timeouts_0
2024-08-08T05:02:35.079000Z TestFramework.utils (ERROR): wait_until() failed. Predicate: ''''
def test_function():
if check_connected:
assert self.is_connected
return test_function_in()
'''
2024-08-08T05:02:35.080000Z TestFramework (ERROR): Assertion failed
Traceback (most recent call last):
File "DASH/test/functional/test_framework/test_framework.py", line 159, in main
self.run_test()
File "DASH/test/functional/p2p_timeouts.py", line 93, in run_test
no_verack_node.wait_for_disconnect(timeout=1)
File "DASH/test/functional/test_framework/p2p.py", line 495, in wait_for_disconnect
self.wait_until(test_function, timeout=timeout, check_connected=False)
File "DASH/test/functional/test_framework/p2p.py", line 487, in wait_until
wait_until_helper(test_function, timeout=timeout, lock=p2p_lock, timeout_factor=self.timeout_factor)
File "DASH/test/functional/test_framework/util.py", line 267, in wait_until_helper
raise AssertionError("Predicate {} not true after {} seconds".format(predicate_source, timeout))
AssertionError: Predicate ''''
def test_function():
if check_connected:
assert self.is_connected
return test_function_in()
''' not true after 1.0 seconds
2024-08-08T05:02:35.581000Z TestFramework (INFO): Stopping nodes
2024-08-08T05:02:36.582000Z TestFramework (WARNING): Not cleaning up dir /tmp/test_runner_∋_🏃_20240808_120217/p2p_timeouts_0
2024-08-08T05:02:36.582000Z TestFramework (ERROR): Test failed. Test logging available at /tmp/test_runner_∋_🏃_20240808_120217/p2p_timeouts_0/test_framework.log
2024-08-08T05:02:36.582000Z TestFramework (ERROR):
2024-08-08T05:02:36.582000Z TestFramework (ERROR): Hint: Call DASH/test/functional/combine_logs.py '/tmp/test_runner_∋_🏃_20240808_120217/p2p_timeouts_0' to consolidate all logs
2024-08-08T05:02:36.582000Z TestFramework (ERROR):
2024-08-08T05:02:36.582000Z TestFramework (ERROR): If this failure happened unexpectedly or intermittently, please file a bug and provide a link or upload of the combined log.
2024-08-08T05:02:36.582000Z TestFramework (ERROR): https://github.com/dashpay/dash/issues
2024-08-08T05:02:36.582000Z TestFramework (ERROR):
stderr:
TEST | STATUS | DURATION
p2p_timeouts.py | ✓ Passed | 4 s
p2p_timeouts.py | ✖ Failed | 4 s
p2p_timeouts.py | ✖ Failed | 5 s
p2p_timeouts.py | ✖ Failed | 5 s
p2p_timeouts.py | ✖ Failed | 6 s
p2p_timeouts.py | ✖ Failed | 6 s
p2p_timeouts.py | ✖ Failed | 7 s
ALL | ✖ Failed | 37 s (accumulated)
Runtime: 7 s
8e9dd127c7 chore: bump version in configure.ac (pasta)
afb8dc0698 docs: add v21.1.0 release notes and archive v21.0.2 (pasta)
269dd025e8 Merge #6179: chore: update manpages v21.1 (pasta)
a8cb643db8 Merge #6175: feat: allow resigning for EHF (pasta)
de5cc22b0c Merge #6178: chore: bump protocol version to 70233 (pasta)
2de4ce51b0 Merge #6176: test: reduce BRRHeight in regtest (pasta)
840175ecb4 Merge #6174: fix: stop trying to sign pending txes when they are no longer non-locked (pasta)
Pull request description:
## Issue being fixed or feature implemented
## 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 058ff45772
kwvg:
utACK 058ff45772
Tree-SHA512: b619f9754258cece012f817a523f5849128e044ffbe17a28e12f1e8424d11f6a4c8d011a554fce0b106e1d6efee2aa306befdc034b8e47be077ad28c7f39c975
8e9dd127c7 chore: bump version in configure.ac (pasta)
afb8dc0698 docs: add v21.1.0 release notes and archive v21.0.2 (pasta)
269dd025e8 Merge #6179: chore: update manpages v21.1 (pasta)
a8cb643db8 Merge #6175: feat: allow resigning for EHF (pasta)
de5cc22b0c Merge #6178: chore: bump protocol version to 70233 (pasta)
2de4ce51b0 Merge #6176: test: reduce BRRHeight in regtest (pasta)
840175ecb4 Merge #6174: fix: stop trying to sign pending txes when they are no longer non-locked (pasta)
Pull request description:
## Issue being fixed or feature implemented
Backports for v21.1.0, add release notes and
## What was done?
See commits
## How Has This Been Tested?
Been on devnet
## Breaking Changes
None
## Checklist:
_Go over all the following points, and put an `x` in all the boxes that apply._
- [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)_
ACKs for top commit:
knst:
utACK 8e9dd127c7
Tree-SHA512: 3c968c4f0e06bc88f63bf10f742d39595c45c7fcd4aef1891d2e76d9f443cae1ddd3cb84c787faa189ef3a189a9dd63a7f75e69f5787a47d1281d5b6a445a2a6
d32a03c7e7 chore: update man pages (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
V21.1 preparation
## What was done?
Update manpages
## How Has This Been Tested?
n/a
## 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 d32a03c7e7
Tree-SHA512: a16036121c48597d80eefcf9232afb8f2da20d7b2e45de4beac31f025f3d8d638f5006e0bb52f706e08235fca172ddfc3309fd143734d37a14776cd7e8842128
d32a03c7e7 chore: update man pages (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
V21.1 preparation
## What was done?
Update manpages
## How Has This Been Tested?
n/a
## 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 d32a03c7e7
Tree-SHA512: a16036121c48597d80eefcf9232afb8f2da20d7b2e45de4beac31f025f3d8d638f5006e0bb52f706e08235fca172ddfc3309fd143734d37a14776cd7e8842128
6f82a56171 feat: add option to AsyncSignIfMember to allow signing same requestID on different msgHashes (pasta)
Pull request description:
## Issue being fixed or feature implemented
Please see: https://www.dash.org/forum/index.php?threads/ehf-activation-issues.55146/ for a description of this issue
## What was done?
Allow re-signing specifically for EHF messages, this is important as due to rotation, and duplicate requestIDs a member will refuse to re-sign when they participate in a later quorum.
## How Has This Been Tested?
Devnet deployed with a mix of this version, older versions and current v21.0
## Breaking Changes
This doesn't introduce any 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)_
Top commit has no ACKs.
Tree-SHA512: a758e6363901624d8540983ad09085d47a33fe61e8e576ec4317b051a0f988efb983bd06d9894bcce19c9f587ad703022ce00ceddd3760d7c9d382878f40c2d7
6f82a56171 feat: add option to AsyncSignIfMember to allow signing same requestID on different msgHashes (pasta)
Pull request description:
## Issue being fixed or feature implemented
Please see: https://www.dash.org/forum/index.php?threads/ehf-activation-issues.55146/ for a description of this issue
## What was done?
Allow re-signing specifically for EHF messages, this is important as due to rotation, and duplicate requestIDs a member will refuse to re-sign when they participate in a later quorum.
## How Has This Been Tested?
Devnet deployed with a mix of this version, older versions and current v21.0
## Breaking Changes
This doesn't introduce any 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)_
Top commit has no ACKs.
Tree-SHA512: a758e6363901624d8540983ad09085d47a33fe61e8e576ec4317b051a0f988efb983bd06d9894bcce19c9f587ad703022ce00ceddd3760d7c9d382878f40c2d7
3783b70129 chore: bump protocol version to 70233 (Odysseas Gabrielides)
Pull request description:
## Issue being fixed or feature implemented
## What was done?
Bumped protocol version to 70233
## How Has This Been Tested?
## Breaking Changes
## 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)_
ACKs for top commit:
PastaPastaPasta:
utACK 3783b70129
knst:
utACK 3783b70129
Tree-SHA512: 3f5f04fcc31c5381a1ddce408a3c31876ca6d58ff229c80784ab938be70c3820b773c5db7f0c77fb7a00cc03dbefb70a42b81a0bf17195b78b47cee1e12310b5
38ecd6f951 test: reduce BRRHeight on regtest (Odysseas Gabrielides)
Pull request description:
## Issue being fixed or feature implemented
In regtest, Block Reward Reallocation is buried at height 2500, which happens after v20 activation.
## What was done?
Reduced BRRHeight in regtest from 2500 to 1000.
The purpose of this change is to simplify regtests of Platform as well.
Note: This change affects only regtest.
## How Has This Been Tested?
tests
## Breaking Changes
no, this only affects Regtest (where we make no guarantees about breaking stuff)
## 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)_
Top commit has no ACKs.
Tree-SHA512: b5a1c2b2c2b70682f266d9d0af9e048a03417c0cb2480eb5ab5838965342b6465acd10d8dac5a0d3c5c5f59f4e36ac5b909a838bc3805c2265a83776e92b4827
d8449aecf9 fix: stop trying to sign pending txes when they are no longer non-locked (UdjinM6)
Pull request description:
## Issue being fixed or feature implemented
Masternodes keep trying to sign txes they received initially even after these txes were replaced by is/chain-locked txes later.
## What was done?
Remove entries from `pendingRetryTxs` when txes are removed from `nonLockedTxs` set (as either already locked or as conflicted, doesn't matter).
## How Has This Been Tested?
## Breaking Changes
## 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 _(for repository code-owners and collaborators only)_
ACKs for top commit:
PastaPastaPasta:
utACK d8449aecf9
knst:
utACK d8449aecf9
Tree-SHA512: 45983faad6d590d4e44fc195c77d73d216e3d0bebef963fe556688773c82c07a118916f56fde7f1213df19d4fb9b7d82d8fd51abecd8e6c2108c27d62d0426c1
3783b70129 chore: bump protocol version to 70233 (Odysseas Gabrielides)
Pull request description:
## Issue being fixed or feature implemented
## What was done?
Bumped protocol version to 70233
## How Has This Been Tested?
## Breaking Changes
## 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)_
ACKs for top commit:
PastaPastaPasta:
utACK 3783b70129
knst:
utACK 3783b70129
Tree-SHA512: 3f5f04fcc31c5381a1ddce408a3c31876ca6d58ff229c80784ab938be70c3820b773c5db7f0c77fb7a00cc03dbefb70a42b81a0bf17195b78b47cee1e12310b5
38ecd6f951 test: reduce BRRHeight on regtest (Odysseas Gabrielides)
Pull request description:
## Issue being fixed or feature implemented
In regtest, Block Reward Reallocation is buried at height 2500, which happens after v20 activation.
## What was done?
Reduced BRRHeight in regtest from 2500 to 1000.
The purpose of this change is to simplify regtests of Platform as well.
Note: This change affects only regtest.
## How Has This Been Tested?
tests
## Breaking Changes
no, this only affects Regtest (where we make no guarantees about breaking stuff)
## 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)_
Top commit has no ACKs.
Tree-SHA512: b5a1c2b2c2b70682f266d9d0af9e048a03417c0cb2480eb5ab5838965342b6465acd10d8dac5a0d3c5c5f59f4e36ac5b909a838bc3805c2265a83776e92b4827
0f239203a8 partial bitcoin#24169: Add --enable-c++20 option (Kittywhiskers Van Gogh)
a3b79267e0 merge bitcoin#20744: Use std::filesystem. Remove Boost Filesystem & System (Kittywhiskers Van Gogh)
be7ac493d0 merge bitcoin#24167: consistently use fsbridge:: for ifstream / ofstream (Kittywhiskers Van Gogh)
7ffea4348f merge bitcoin#24104: Make compatible with boost 1.78 (Kittywhiskers Van Gogh)
7c270e6883 merge bitcoin#24026: Block unsafe std::string fs::path conversion copy_file calls (Kittywhiskers Van Gogh)
b0d2484a0b merge bitcoin#23522: Improve fs::PathToString documentation (Kittywhiskers Van Gogh)
20d359b570 partial bitcoin#23469: Remove Boost build note from build-unix.md (Kittywhiskers Van Gogh)
193f6fde2e merge bitcoin#23446: Mention that BerkeleyDB is for legacy wallet in build-unix (Kittywhiskers Van Gogh)
ecfac10b8e merge bitcoin#22937: Forbid calling unsafe fs::path(std::string) constructor and fs::path::string() method (Kittywhiskers Van Gogh)
23fe7e2f07 chore: dashify symbols in some unit tests (Kittywhiskers Van Gogh)
28b96a071d merge bitcoin#22840: fix unoptimized libraries in depends (Kittywhiskers Van Gogh)
Pull request description:
## Additional Information
* Depends on https://github.com/dashpay/dash/pull/6085
* Depends on https://github.com/dashpay/dash/pull/6137
* Dependency for https://github.com/dashpay/dash/pull/6150
## Breaking Changes
None observed.
## Checklist:
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas **(note: N/A)**
- [x] I have added or updated relevant unit/integration/functional/e2e tests
- [x] I have made corresponding changes to the documentation **(note: N/A)**
- [x] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_
ACKs for top commit:
knst:
utACK 0f239203a8
PastaPastaPasta:
utACK 0f239203a8
Tree-SHA512: 4b8f0ae55185ece27d8084a5339196b7ed993c8138f4c59a0db3e16729d4edf4a59a68a8c7309c32df57734c07182821c4878b55c253da5df763204ad7158426
21f174aff1 feat: improve query categorisation in Qt App (Konstantin Akimov)
c863473286 test: add spending asset unlock tx in functional tests (Konstantin Akimov)
1fb67ece0e feat: make a support of Qt app to show Platform Transfer transaction as a new type of transaction (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
Transfers from platform have incorrectly shown amount in Dash Core wallet app.
They also shown in Qt app as self-send that is not completely true.
## What was done?
Added new type of transaction to Qt App, added a filter for its type, fixed calculation of output for tx records.
As well added a new type of transaction `platform-transfer` in rpc output of `gettransaction` RPC
## How Has This Been Tested?
Make a Platform Transfer transaction on RegTest and check it in Dash Core
![image](https://github.com/user-attachments/assets/16c83f09-724f-4b8b-99c8-9bb0df1428da)
Helper to see it: export dpath=/tmp/dash_func_test_PATHPATH/ ; src/qt/dash-qt -regtest -conf=$dpath/node0/dash.conf -datadir=$dpath/node0/ -debug=0 -debuglogfile=/dev/stdout
## Breaking Changes
There's new type of transaction "platform-transfer" in rpc output of `gettransaction`.
**This PR DOES NOT change any consensus rules.**
Breaking changes that makes withdrawal transaction immature is moved to https://github.com/dashpay/dash/pull/6128
## 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
Top commit has no ACKs.
Tree-SHA512: ec2a54a910f121ad30ff8e94cf17080b5b3c651872e9bc3de9ec0924ca7f7a0e526b74b05cde26aaf860e3809e67f66142112319a69c216527e5bcb1b8a2b8f6
cafef080a2e59c2bcae6baeee3c3c7e187e931ae qt: Refactor to remove unnecessary block in DispatchNotifications (João Barbosa)
57785fb7f61e51e8a8a459486a594443665ea8c9 qt: Early subscribe core signals in transaction table model (João Barbosa)
c6cbdf1a90a253fef0259b365a782bf88cd437f2 qt: Refactor ShowProgress to DispatchNotifications (João Barbosa)
3bccd50ad2f384e6c8c97c7f44bda7ae0d777696 qt: Set flag after inital load on transaction table model (João Barbosa)
Pull request description:
This fixes the case where transaction notifications arrive between `getWalletTxs` and `subscribeToCoreSignals`. Basically notifications are queued until `getWalletTxs` and wallet rescan complete.
This is also a requirement to call `getWalletTxs` in a background thread.
Motivated by https://github.com/bitcoin/bitcoin/issues/20241.
ACKs for top commit:
jonatack:
tACK cafef080a2e59c2bcae6baeee3c3c7e187e931ae
ryanofsky:
Code review ACK cafef080a2e59c2bcae6baeee3c3c7e187e931ae. Only change since last review is splitting commits and replacing m_progress with m_loading.
meshcollider:
Code review ACK cafef080a2e59c2bcae6baeee3c3c7e187e931ae
Tree-SHA512: 003caab2f2ae3522619711c8d02d521d2b8f7f280a467f6c3d08abf37ca81cc66b4b9fa10acfdf34e5fe250da7b696cfeec435f72b53c1ea97ccda96d8b4be33
7eea659fc908e5edfc90c185a6958ed07ecf5cd4 qt, test: use qsignalspy instead of qeventloop (Jarol Rodriguez)
Pull request description:
This PR refactors our GUI `apptests` to use [QSignalSpy](https://doc.qt.io/qt-5/qsignalspy.html) instead of [QEventLoop](https://doc.qt.io/qt-5/qeventloop.html).
`QSignalSpy` is more appropriate for our GUI test's as it is purpose-built for testing emission of signals and sets up its own `QEventLoop` when the `wait` function is called.
ACKs for top commit:
hebasto:
ACK 7eea659fc908e5edfc90c185a6958ed07ecf5cd4, tested on Linux Mint 20.1 (Qt 5.12.8).
promag:
Code review ACK 7eea659fc908e5edfc90c185a6958ed07ecf5cd4.
Tree-SHA512: 3adddbcc5efd726302b606980c9923025c44bb8ee16cb8a183e633e423179c0822db66de9ccba20dc5124fff34af4151a379c9cd18130625c60789ce809ee6fd
2a45134b5694c12546d77cdff541612881f7e3e7 qt: Add shortcuts for console font resize buttons (Hennadii Stepanov)
a2e122f0fe72d695762db2b83905e246f451300c qt: Add GUIUtil::AddButtonShortcut (Hennadii Stepanov)
4ee9ee72363d46c5ba0c71b8d8283d9c5621e3ed qt: Use native presentation of shortcut (Hennadii Stepanov)
Pull request description:
On `master` the only way to resize the console font is to manually move your mouse and click the resize buttons. This PR introduces convenient keyboard shortcuts to resize the console font.
The common resize shortcuts for applications are `Ctrl+=`/`Ctrl++` and `Ctrl+-`/`Ctrl+_`. This means that the resize QPushButtons need two shortcuts each, but you cannot assign multiple shortcuts to a QPushButton. See: https://doc.qt.io/qt-5/qabstractbutton.html#shortcut-prop
To get around this, we introduce a new function in `guiutil`, which connects a supplied `QKeySequence` shortcut to a `QAbstractButton`. This function can be reused in other situations where more than one shortcut is needed for a button.
| PR on macOS | PR on Linux |
| ---------------- | ------------ |
| ![mac-resize-shortcuts](https://user-images.githubusercontent.com/23396902/114750132-a2752580-9d21-11eb-9542-15716f2c257d.gif) | ![linux-resize-shortcuts](https://user-images.githubusercontent.com/23396902/114750165-aacd6080-9d21-11eb-8abc-5388690dcf0b.gif) |
ACKs for top commit:
hebasto:
re-ACK 2a45134b5694c12546d77cdff541612881f7e3e7
Talkless:
tACK 2a45134b5694c12546d77cdff541612881f7e3e7, tested on Debian Sid with Qt 5.15.2, shortcuts still work.
Tree-SHA512: e894ccb7e5c695ba83998c21a474d6c587c9c849f12ced665c5e0034feb6b143e41b32ba135cab6cfab22cbf153d5a52b1083b2a278e6dfca3f5ad14c0f6c573
33b0b26a03a401bd39b88931b69d162c3c538d31 doc: note that brew installed qt is not supported (Raul Siles)
Pull request description:
picking up #21791, the author has stated they [cannot squash](https://github.com/bitcoin/bitcoin/pull/21791#issuecomment-828770283).
This is a useful note to prevent any issues from being opened up about this. The reason that both cannot co-exist and build bitcoin is stated [here](https://github.com/bitcoin/bitcoin/pull/21791#issuecomment-837278123):
> ... the reason is sharing /usr/local/include/ and /usr/local/lib/ directories by both qt5 and qt6 installations.
Changes from original PR:
- slightly move the note up in this section, this placement seems more appropriate to me
- drop "Note:"
[PR Render](33b0b26a03/doc/build-osx.md (qt))
ACKs for top commit:
laanwj:
LGTM ACK 33b0b26a03a401bd39b88931b69d162c3c538d31
hebasto:
ACK 33b0b26a03a401bd39b88931b69d162c3c538d31
Tree-SHA512: f9efac1921a7a33b5791a9f9f4bada4b5369d358fc42e9884c077bfb4dc3f273fdd4432ce012006a8009dfafb87e13bddd56c6336fe84b6133f4b22f849c289a
07bc22ef105dee3c6c465a3ef31e52fd198e786d docs: improve make with parallel jobs description. (Klement Tan)
Pull request description:
Changed `use -jX here for parallelism` to `use "-j N" for N parallel jobs`
**Rationale**: In my opinion `use -jX here for parallelism` is quite ambiguous as it could be perceived as a single option without any argument. Ie running:
```sh
make -jX
```
Embarrassingly this caused me to be stuck for quite a long time until I opened the help menu for `make` but if I am the only one who faced this issue I would be happy to close this PR.
ACKs for top commit:
jarolrod:
ACK 07bc22ef105dee3c6c465a3ef31e52fd198e786d
Tree-SHA512: 2d119b6a461668906c63184b865d2cc9fb2f75abeba34e2e44bc1ef3bcb4adec4a49896ddaf3cc6a20c0095ad20d0de0908401b351eaca9443161d24d6b20d0b
cdbc2bd1f1c171848c1fef7f217afe140e1afb06 qt: Use template function qOverload in signal-slot connections (Hennadii Stepanov)
Pull request description:
A nice template function [`qOverload`](https://doc.qt.io/qt-5/qtglobal.html#qOverload) is available for us now (https://github.com/bitcoin/bitcoin/pull/20413, https://github.com/bitcoin/bitcoin/pull/21286).
Its usage makes code much more readable.
This PR does not change behavior.
ACKs for top commit:
Talkless:
utACK cdbc2bd1f1c171848c1fef7f217afe140e1afb06.
promag:
Code review ACK cdbc2bd1f1c171848c1fef7f217afe140e1afb06.
Tree-SHA512: 72002aa646b1a79bab62d498825b3f245dc7ebdc189280f8bd3b4076e1bb50be8802c02bc872ff6f70c1ea81faec66d3bec36471119dd98c9e70d87b990396ae
5a4a15d2b4456272fd8aa080195f40a09576ae01 qt, refactor: Drop no longer used PeerTableModel::getRowByNodeId func (Hennadii Stepanov)
9a9f180df0d51396fee2468681df6dd935b0248e qt, refactor: Drop no longer used PeerTableModel::sort function (Hennadii Stepanov)
778a64af209e4fa692a3aca8376ba1bd5e1af881 qt: Use PeerTableSortProxy for sorting peer table (Hennadii Stepanov)
df2d165ba9e0acc53f36a326f68f57ad9c297872 qt: Add peertablesortproxy module (Hennadii Stepanov)
Pull request description:
The "Peers" table in the "Node" window does not hold multiple selection after sorting.
This PR introduces a `QSortFilterProxyModel` subclass, that is a standard Qt [practice](https://doc.qt.io/qt-5/model-view-programming.html#custom-sorting-models) for such cases.
Now the sorting code is encapsulated into the dedicated Qt class, and we do not need to maintain it.
Fixes#283 (additionally).
---
On **master** (7ae86b3c6845873ca96650fc69beb4ae5285c801):
- rows are sorted by "Ping", and a selection is made
![Screenshot from 2020-11-28 22-53-11](https://user-images.githubusercontent.com/32963518/100525900-96eaed00-31cc-11eb-86e7-72ede3b8b33c.png)
- rows are sorted by "NodeId", and the previous selection is _lost_
![Screenshot from 2020-11-28 22-53-21](https://user-images.githubusercontent.com/32963518/100525904-9c483780-31cc-11eb-957c-06f53d7d31ab.png)
With **this PR**:
- rows are sorted by "Ping", and a selection is made
![Screenshot from 2020-11-28 22-39-41](https://user-images.githubusercontent.com/32963518/100525776-06aca800-31cc-11eb-8c4e-9c6566fe80fe.png)
- rows are sorted by "NodeId", and the row are still selected
![Screenshot from 2020-11-28 22-39-53](https://user-images.githubusercontent.com/32963518/100525791-2348e000-31cc-11eb-8b78-716a5551d7ec.png)
ACKs for top commit:
jarolrod:
re-ACK 5a4a15d2b4456272fd8aa080195f40a09576ae01, tested on macOS 11.2 Qt 5.15.2 after rebase
promag:
Tested ACK 5a4a15d2b4456272fd8aa080195f40a09576ae01.
Tree-SHA512: f81c1385892fbf1a46ffb98b42094ca1cc97da52114bbbc94fedb553899b1f18c26a349e186bba6e27922a89426bd61e8bc88b1f7832512dbe211b5f834e076e