ci: Exclude subtrees from iwyu #36112

pull maflcko wants to merge 2 commits into bitcoin:master from maflcko:2608-iwyu-subtrees-no changing 4 files +13 −4
  1. maflcko commented at 10:01 AM on August 28, 2026: member

    The iwyu CI may modify subtrees when iwyu thinks a header inside a subtree is "associated" (due to the naming).

    This happens to not be a problem on current master, but can become a problem if an iwyu-enforced file is renamed or a file is iwyu-enforced in the future.

    Fix this by excluding subtrees.

    Can be tested by running the iwyu CI on src/test/fuzz/minisketch.cpp and seeing a change in minisketch.h before this CI fix.

  2. DrahtBot renamed this:
    ci: Exclude subtrees from iwyu
    ci: Exclude subtrees from iwyu
    on Aug 28, 2026
  3. DrahtBot added the label Tests on Aug 28, 2026
  4. DrahtBot commented at 10:01 AM on August 28, 2026: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

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

    <!--006a51241073e994b41acfe9ec718e94-->

    Code Coverage & Benchmarks

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

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline and AI policy for information on the review process.

    Type Reviewers
    ACK hebasto

    If your review is incorrectly listed, please copy-paste <code>&lt;!--meta-tag:bot-skip--&gt;</code> into the comment that the bot should ignore.

    <!--174a7506f384e20aa4161008e828411d-->

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    • #36116 (iwyu: Fix warnings in src/rpc and treat them as errors by hebasto)

    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.

    <!--5faf32d7da4f0f540f40219e4f7537a3-->

  5. hebasto commented at 10:38 AM on August 28, 2026: member

    Concept ACK.

  6. in src/test/fuzz/minisketch.cpp:6 in fa0ebc77d3 outdated
       2 | @@ -3,14 +3,16 @@
       3 |  // file COPYING or http://www.opensource.org/licenses/mit-license.php.
       4 |  
       5 |  #include <minisketch.h>
       6 | -#include <node/minisketchwrapper.h>
       7 | +
    


    hebasto commented at 11:39 AM on August 28, 2026:

    Regardless of IWYU treating <minisketch.h> as an "associated" header, I don't think that justifies a separate group of includes, because it's not a real associated header and does not declare anything defined in this source file.


    maflcko commented at 12:02 PM on August 28, 2026:

    I think it is harmless (and intentional?) clang-format behavior. In fact it may be fine or minimally preferable to treat/document this as associated? In fact the current clang-format seems to hint at this:

      IncludeIsMainRegex: '(Test)?$'
    

    Which is the default value added via 13f36c020f0329b5e975282b45292fdf2a495e31.

    The alternatives are certainly worse: Some ugly // clang-format off or a test-specific src/test/.clang-format:

      BasedOnStyle: InheritParentConfig
      IncludeIsMainRegex: 'off^'
    
  7. hebasto approved
  8. hebasto commented at 11:39 AM on August 28, 2026: member

    ACK fa0ebc77d35d63d665bcb5dde8167346d6856a82.

    Thank you for handling this!

  9. DrahtBot added the label Needs rebase on Aug 28, 2026
  10. refactor: Bump old copyright header in univalue
    Noted in the last iwyu PR: https://github.com/bitcoin/bitcoin/pull/35900#pullrequestreview-5040554983
    fa8566152a
  11. ci: Exclude subtrees from iwyu fa3971011d
  12. maflcko force-pushed on Aug 28, 2026
  13. hebasto approved
  14. hebasto commented at 2:45 PM on August 28, 2026: member

    re-ACK fa3971011d1eef383c5b4cc03cc6b278900c0920.

  15. DrahtBot removed the label Needs rebase on Aug 28, 2026

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: 2026-08-31 17:51 UTC

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