Copyright year calculation with merge commits
- Dominant language
- Java
- Stars
- 5.6k
- Forks
- 559
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 34
Description
Copyright year calculation currently takes the date of the merge commit, even if that particular file merged cleanly.
It causes a specific failure in spotlessCheck (I used Gradle plugin, but the issue is likely not related to Gradle): when branches being merged were changed in the previous year (e.g. 2025) and both had correct copyright end year, checked by Spotless at the time of their respective commits, and when the merge itself happens in the new year (e.g. 2026), Spotless insists that the 2025 copyright year from the clean merge is now incorrect and requires a manual change to 2026.
The expected outcome is that the clean, non-conflicting merge commit does not advance the copyright end year.
Merge commit that actively changes a file (to resolve conflicts or otherwise) should still advance the end year.
Contributor guide
Research direction
Start by locating the copyright year calculation and the tests or fixtures covering merge commits; the issue names no files or entry points. Reproduce the described Spotless check with branches changed in different years and a clean merge. Done means a clean merge does not advance the end year, while a merge that changes the file still does.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100