From fa8566152a057a585ea2f642b795756d87f2f38a Mon Sep 17 00:00:00 2001 From: MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> Date: Thu, 27 Aug 2026 18:49:04 +0200 Subject: [PATCH 1/2] refactor: Bump old copyright header in univalue Noted in the last iwyu PR: https://github.com/bitcoin/bitcoin/pull/35900#pullrequestreview-5040554983 --- src/univalue/lib/univalue.cpp | 2 +- src/univalue/lib/univalue_get.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/univalue/lib/univalue.cpp b/src/univalue/lib/univalue.cpp index 6aeff001e76..39dcfdcab1b 100644 --- a/src/univalue/lib/univalue.cpp +++ b/src/univalue/lib/univalue.cpp @@ -1,5 +1,5 @@ // Copyright 2014 BitPay Inc. -// Copyright 2015 Bitcoin Core Developers +// Copyright (c) 2015-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or https://opensource.org/licenses/mit-license.php. diff --git a/src/univalue/lib/univalue_get.cpp b/src/univalue/lib/univalue_get.cpp index e82ac4cbaed..5fd33ad3609 100644 --- a/src/univalue/lib/univalue_get.cpp +++ b/src/univalue/lib/univalue_get.cpp @@ -1,5 +1,5 @@ // Copyright 2014 BitPay Inc. -// Copyright 2015 Bitcoin Core Developers +// Copyright (c) 2015-present The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or https://opensource.org/licenses/mit-license.php. From fa3971011d1eef383c5b4cc03cc6b278900c0920 Mon Sep 17 00:00:00 2001 From: MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> Date: Fri, 28 Aug 2026 11:57:25 +0200 Subject: [PATCH 2/2] ci: Exclude subtrees from iwyu --- ci/test/03_test_script.sh | 9 ++++++++- src/test/fuzz/minisketch.cpp | 4 +++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/ci/test/03_test_script.sh b/ci/test/03_test_script.sh index 9c911f98c30..3a19838624f 100755 --- a/ci/test/03_test_script.sh +++ b/ci/test/03_test_script.sh @@ -234,7 +234,7 @@ fi if [[ "${RUN_IWYU}" == true ]]; then # TODO: Consider enforcing IWYU across the entire codebase. - FILES_WITH_ENFORCED_IWYU='/src/((bench|common|consensus|crypto|index|init|kernel|primitives|script|univalue/(lib|test)|util|zmq)/.*|node/(blockstorage|interfaces|miner|mining_args|utxo_snapshot)|rpc/mining|clientversion|core_io|signet|init)\.cpp' + FILES_WITH_ENFORCED_IWYU='/src/((bench|common|consensus|crypto|index|init|kernel|primitives|script|univalue/(lib|test)|util|zmq)/.*|node/(blockstorage|interfaces|miner|mining_args|utxo_snapshot)|test/fuzz/minisketch|rpc/mining|clientversion|core_io|signet|init)\.cpp' jq --arg patterns "$FILES_WITH_ENFORCED_IWYU" 'map(select(.file | test($patterns)))' "${BASE_BUILD_DIR}/compile_commands.json" > "${BASE_BUILD_DIR}/compile_commands_iwyu_errors.json" jq --arg patterns "$FILES_WITH_ENFORCED_IWYU" 'map(select(.file | test($patterns) | not))' "${BASE_BUILD_DIR}/compile_commands.json" > "${BASE_BUILD_DIR}/compile_commands_iwyu_warnings.json" @@ -254,6 +254,13 @@ if [[ "${RUN_IWYU}" == true ]]; then 2>&1 || true } | tee /tmp/iwyu_ci.out python3 "/include-what-you-use/fix_includes.py" --nosafe_headers < /tmp/iwyu_ci.out + python3 -c ' +import runpy +import subprocess + +subtrees = runpy.run_path("test/lint/lint_ignore_dirs.py")["SHARED_EXCLUDED_SUBTREES"] +subprocess.run(["git", "restore", "--", *subtrees], check=True) +' git diff -U1 | ./contrib/devtools/clang-format-diff.py -binary="clang-format-${IWYU_LLVM_V}" -p1 -i -v } diff --git a/src/test/fuzz/minisketch.cpp b/src/test/fuzz/minisketch.cpp index 919f4b4b21d..ac74b6c304d 100644 --- a/src/test/fuzz/minisketch.cpp +++ b/src/test/fuzz/minisketch.cpp @@ -3,14 +3,16 @@ // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include -#include + #include #include #include #include +#include #include #include +#include namespace {