qa: Fix wallet_multiwallet.py #31410

pull hebasto wants to merge 2 commits into bitcoin:master from hebasto:241203-multiwallet changing 1 files +25 −10
  1. hebasto commented at 1:37 pm on December 3, 2024: member

    Fixes #31409.

    The first commit prevents possible false positives by ensuring that each condition potentially causing the “Error scanning” log message is tested separately.

    The second commit disables a problematic check on Windows.

  2. hebasto added the label Tests on Dec 3, 2024
  3. DrahtBot commented at 1:37 pm on December 3, 2024: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/31410.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK maflcko

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    • #19461 (multiprocess: Add bitcoin-gui -ipcconnect option by ryanofsky)
    • #19460 (multiprocess: Add bitcoin-wallet -ipcconnect option by ryanofsky)
    • #10102 (Multiprocess bitcoin by ryanofsky)

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

  4. hebasto force-pushed on Dec 3, 2024
  5. DrahtBot added the label CI failed on Dec 3, 2024
  6. in test/functional/wallet_multiwallet.py:132 in b58c8fe005 outdated
    125@@ -129,15 +126,23 @@ def wallet_file(name):
    126         for wallet_name in to_load:
    127             self.nodes[0].loadwallet(wallet_name)
    128 
    129+        # Tests for possible scanning errors:
    130+        # 1. "Permission denied" error.
    131         os.mkdir(wallet_dir('no_access'))
    132         os.chmod(wallet_dir('no_access'), 0)
    


    maflcko commented at 2:36 pm on December 3, 2024:
    Would it be possible to achieve the same with icacls on Windows?

    hebasto commented at 2:48 pm on December 3, 2024:
    Via subprocess?

    hebasto commented at 9:12 pm on December 3, 2024:
    I’m not sure if testing the scenario with the modified ACL on Windows is worth the added complexity of the test script.
  7. hebasto force-pushed on Dec 3, 2024
  8. hebasto marked this as ready for review on Dec 3, 2024
  9. hebasto added the label Wallet on Dec 3, 2024
  10. maflcko removed the label CI failed on Dec 4, 2024
  11. in test/functional/wallet_multiwallet.py:145 in fd8d7c367f outdated
    148+            assert_equal(sorted(map(lambda w: w['name'], walletlist)), sorted(in_wallet_dir))
    149+        # 2. "Too many levels of symbolic links" error.
    150+        os.mkdir(wallet_dir('self_walletdat_symlink'))
    151+        os.symlink('wallet.dat', wallet_dir('self_walletdat_symlink/wallet.dat'))
    152+        with self.nodes[0].assert_debug_log(expected_msgs=['Error scanning']):
    153+            walletlist = self.nodes[0].listwalletdir()['wallets']
    


    maflcko commented at 7:30 am on December 4, 2024:
    Could do a third listwalletdir without the symlink to check that the test is working by checking for absence of error scanning?

    hebasto commented at 9:41 am on December 4, 2024:
    Thanks! Done.
  12. qa: Test scanning errors individually
    This change prevents possible false positives by ensuring that each
    condition potentially causing the "Error scanning" log message is tested
    separately.
    3f53cc8b8c
  13. qa: Disable self-symlink test on Windows and document it c012743959
  14. hebasto force-pushed on Dec 4, 2024
  15. maflcko commented at 8:48 pm on December 5, 2024: member

    review ACK c0127439597ee9d09b8e117be7d6226a68b45721 🎑

    Signature:

    0untrusted comment: signature from minisign secret key on empty file; verify via: minisign -Vm "${path_to_any_empty_file}" -P RWTRmVTMeKV5noAMqVlsMugDDCyyTSbA3Re5AkUrhvLVln0tSaFWglOw -x "${path_to_this_whole_four_line_signature_blob}"
    1RUTRmVTMeKV5npGrKx1nqXCw5zeVHdtdYURB/KlyA/LMFgpNCs+SkW9a8N95d+U4AP1RJMi+krxU1A3Yux4bpwZNLvVBKy0wLgM=
    2trusted comment: review ACK c0127439597ee9d09b8e117be7d6226a68b45721 🎑
    3tf/up7OMkfp/8WkQfPI/JfkrY0jnqtfRAg2T09eD2yTw/BRFey4pUZPMlJu+Y93FYLisAf28Ld2wEeMnGisIBQ==
    
  16. maflcko added this to the milestone 29.0 on Dec 18, 2024
  17. hebasto commented at 11:55 am on December 20, 2024: member
    Friendly ping a Python connoisseur @stickies-v :)


hebasto DrahtBot maflcko

Labels
Wallet Tests

Milestone
29.0


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-12-21 15:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me