scripted-diff: [doc] Unify stale copyright headers #34084

pull maflcko wants to merge 2 commits into bitcoin:master from maflcko:2506-doc-copy changing 990 files +990 −990
  1. maflcko commented at 9:13 pm on December 16, 2025: member

    Historically, the upper year range in file headers was bumped manually or with a script.

    This has many issues:

    • The script is causing churn. See for example commit 306ccd4, or drive-by first-time contributions bumping them one-by-one. (A few from this year: #32008, #31642, #32963, …)
    • Some, or likely most, upper year values were wrong. Reasons for incorrect dates could be code moves, cherry-picks, or simply bugs in the script.
    • The upper range is not needed for anything.
    • Anyone who wants to find the initial file creation date, or file history, can use git log or git blame to get more accurate results.
    • Many places are already using the -present suffix, with the meaning that the upper range is omitted.

    To fix all issues, this bumps the upper range of the copyright headers to -present.

    Further notes:

    • Obviously, the yearly 4-line bump commit for the build system (c.f. b537a2c02a9921235d1ecf8c3c7dc1836ec68131) is fine and will remain.
    • For new code, the date range can be fully omitted, as it is done already by some developers. Obviously, developers are free to pick whatever style they want. One can list the commits for each style.
    • For example, to list all commits that use -present: git log --format='%an (%ae) [%h: %s]' -S 'present The Bitcoin'.
    • Alternatively, to list all commits that use no range at all: git log --format='%an (%ae) [%h: %s]' -S '(c) The Bitcoin'.
  2. DrahtBot added the label Refactoring on Dec 16, 2025
  3. DrahtBot commented at 9:14 pm on December 16, 2025: 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/34084.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK l0rinc, rkrux, janb84
    Approach ACK stickies-v

    If your review is incorrectly listed, please copy-paste <!–meta-tag:bot-skip–> into the comment that the bot should ignore.

    Conflicts

    No conflicts as of last run.

  4. scripted-diff: [doc] Unify stale copyright headers
    -BEGIN VERIFY SCRIPT-
    
     sed --in-place --regexp-extended \
       's;( 20[0-2][0-9])(-20[0-2][0-9])? The Bitcoin Core developers;\1-present The Bitcoin Core developers;g' \
       $( git grep -l 'The Bitcoin Core developers' -- ':(exclude)COPYING' ':(exclude)src/ipc/libmultiprocess' ':(exclude)src/minisketch' )
    
    -END VERIFY SCRIPT-
    fa5f297748
  5. maflcko force-pushed on Dec 16, 2025
  6. DrahtBot added the label CI failed on Dec 16, 2025
  7. DrahtBot commented at 9:22 pm on December 16, 2025: contributor

    🚧 At least one of the CI tasks failed. Task lint: https://github.com/bitcoin/bitcoin/actions/runs/20282910432/job/58249415928 LLM reason (✨ experimental): Lint failure: a subtree was touched without a proper subtree merge.

    Try to run the tests locally, according to the documentation. However, a CI failure may still happen due to a number of reasons, for example:

    • Possibly due to a silent merge conflict (the changes in this pull request being incompatible with the current code in the target branch). If so, make sure to rebase on the latest commit of the target branch.

    • A sanitizer issue, which can only be found by compiling with the sanitizer and running the affected test.

    • An intermittent issue.

    Leave a comment here, if you need help tracking down a confusing failure.

  8. DrahtBot removed the label CI failed on Dec 16, 2025
  9. stickies-v commented at 12:36 pm on December 17, 2025: contributor
    Approach ACK. I’ve moved to a dateless copyright notice for new code, personally. The scripted-diff keeping the initial publication dates seems like the approach with the least friction.
  10. rkrux approved
  11. rkrux commented at 1:17 pm on December 17, 2025: contributor

    ACK fa5f29774872d18febc0df38831a6e45f3de69cc

    Previously, I had noticed that the copyright dates were updated in the files that were affected in the pull requests by few contributors. Fixing all in one go appears to be a good idea to me.

    I built and ran the functional tests, all work. The Github UI is crashing due to the size of the diff, thus I checked out the code locally and opened the commit diff in a file to count the number of occurrences of “The Bitcoin Core developers” phrase that matches with the number of files changed.

    Also skimmed over the diff once to see the content.

  12. DrahtBot requested review from stickies-v on Dec 17, 2025
  13. l0rinc commented at 1:53 pm on December 18, 2025: contributor

    This is tangentially related to #29445 - I don’t really mind either way, I just want to stop the stupid headers distracting code review.

    I have reviewed the change by:

    This is officially the most boring PR ever! Looking forward to never having to touch or review the headers again :D

    Nit: if you need to touch again, please consider:

    ACK fa5f29774872d18febc0df38831a6e45f3de69cc

  14. test: [doc] Manually unify stale headers fa4cb13b52
  15. maflcko commented at 2:38 pm on December 18, 2025: member

    Nit: if you need to touch again, please consider:

    Thanks, addressed those that are in scope for the issues listed in the pull request description. The others seem unrelated and can be addressed in a different pull request either now or later, if there is need to.

  16. l0rinc commented at 2:54 pm on December 18, 2025: contributor
    ACK fa4cb13b52030c2e55c6bea170649ab69d75f758
  17. DrahtBot requested review from rkrux on Dec 18, 2025
  18. fanquake referenced this in commit 9272fd517f on Dec 18, 2025
  19. rkrux approved
  20. rkrux commented at 10:05 am on December 19, 2025: contributor
    re-ACK fa4cb13b52030c2e55c6bea170649ab69d75f758
  21. janb84 commented at 1:37 pm on December 19, 2025: contributor

    ACK fa4cb13b52030c2e55c6bea170649ab69d75f758

    Did some regex searches & spot checks. Looks good.

    This is officially the most boring PR ever! Looking forward to never having to touch or review the headers again :D

    Fully agree with this. Lets never need to do this again, the file churn it causes is pointless.

  22. fanquake referenced this in commit 74d6efe9c2 on Dec 19, 2025
  23. fanquake commented at 4:52 pm on December 19, 2025: member
    Opened a followup to fix the 1 file difference, and remove the management script in #34119.
  24. fanquake merged this on Dec 19, 2025
  25. fanquake closed this on Dec 19, 2025


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: 2025-12-20 06:12 UTC

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