Skip to content

SONARJAVA-7293 Revert "Update ruling results for PR #6445" - #6467

Closed
romainbrenguier wants to merge 10 commits into
romain/rc-451from
revert-6465-fix/update-ruling-for-romain/rc-451
Closed

romainbrenguier wants to merge 10 commits into
romain/rc-451from
revert-6465-fix/update-ruling-for-romain/rc-451

Conversation

@romainbrenguier

Copy link
Copy Markdown
Contributor

Reverts #6465

@hashicorp-vault-sonar-prod hashicorp-vault-sonar-prod Bot changed the title Revert "Update ruling results for PR #6445" SONARJAVA-7293 Revert "Update ruling results for PR #6445" Nov 3, 2026
@hashicorp-vault-sonar-prod

hashicorp-vault-sonar-prod Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

SONARJAVA-7293

@gitar-bot

gitar-bot Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
CI failed: Two unrelated ruling QA failures: a diff2html-cli out-of-memory crash in the Ubuntu report step (unclear relation to the PR) and a malformed eclipse-jetty SARIF expected file causing an S1451 check failure on Windows (not related to the PR).

Overview

Two unique error templates across 2 logs from the Ruling QA jobs for commit a665b05. Both failures appear unrelated to the revert's changes and no change-related failure was established.

Failures

diff2html-cli heap exhaustion during diff report generation (confidence: high)

  • Type: tooling
  • Affected jobs: 125944084215
  • Related to change: unclear
  • Root cause: The Generate Diff Report step ran diff2html-cli on its/ruling/target/test.diff; Node hit its ~4 GB heap limit and aborted with exit code 134. The logs do not show why the diff needed that much memory, and no diff size or contents are provided to link it to the revert.
  • Suggested fix: Check the generated its/ruling/target/test.diff size. Make report generation split or limit large diffs. If the runner has enough memory, raise the Node heap for diff2html-cli and rerun.

Malformed SARIF in eclipse-jetty expected results breaks S1451 check (confidence: high)

  • Type: test
  • Affected jobs: 125944083811
  • Related to change: no
  • Root cause: The S1451 (FileHeaderCheck) could not load the previous SARIF result for its/ruling/src/test/resources/expected/eclipse-jetty. Jackson reported an invalid token at line 30, column 26. The file-by-file fallback then failed with a duplicate symbol-table save for jetty-jmx/src/main/java/module-info.java, which appears to be a downstream cascade. The PR deletes nine SARIF files under java-time-example-less-threshold, not eclipse-jetty, so it does not explain this failure.
  • Suggested fix: Inspect and correct the malformed SARIF under its/ruling/src/test/resources/expected/eclipse-jetty (likely the S1451 result) and validate it as JSON. Rerun the ruling test. If the duplicate symbol-table error persists after the SARIF fix, investigate the analyzer's fallback handling for module-info.java.

Summary

  • Change-related failures: None confirmed. The diff2html OOM is unclear, and the eclipse-jetty SARIF failure is explicitly unrelated.
  • Infrastructure/flaky failures: None identified as flaky. The diff2html OOM is a tooling/resource failure.
  • Recommended action: Fix the malformed eclipse-jetty SARIF and rerun the ruling test. Separately, check the diff size for the Ubuntu report step and address the Node heap limit. Confirm whether the revert itself affects the ruling output before merging.
Code Review ⚠️ Changes requested 0 closed / 1 findings

🟡 Medium risk · Deleting nine expected SARIF fixtures could leave ruling results unvalidated for those rules; the changes are limited to test resources.

Reverts the ruling results update from PR #6465, removing the expected SARIF baselines under expected/java-time-example-less-threshold/. Changes requested: JavaRulingTest.java_time_example_incremental still analyzes that project and will fail with no expected baseline, so the test and its source project reference should be reverted in the same PR, or the expected files kept or regenerated.

⚠️ Bug: Revert drops expected results while java_time_example_incremental runs

📄 its/ruling/src/test/resources/expected/java-time-example-less-threshold/java-S8694.sarif 📄 its/ruling/src/test/resources/expected/java-time-example-less-threshold/java-S109.sarif

This PR deletes every expected SARIF file under expected/java-time-example-less-threshold/, but it leaves JavaRulingTest.java_time_example_incremental (lines 358-389) as is. That test still analyzes the java-time-example-less-threshold sources, and its own comment says S8694 "raises issues" there. executeBuildWithCommonProperties points sonar.lits.dump.old at expected/<projectName>, and assertNoDifferences (lines 567-570) requires the LITS differences file to be empty. With no expected baseline, every issue found (S8694, S109, S2201, etc.) shows up as a new difference, so the ruling test fails. If the incremental ruling scenario is being backed out, revert the test (and its source project reference) in the same PR. Otherwise keep these expected files, or regenerate them.

🤖 Prompt for agents
Code Review: Reverts the ruling results update from PR #6465, removing the expected SARIF baselines under `expected/java-time-example-less-threshold/`. Changes requested: `JavaRulingTest.java_time_example_incremental` still analyzes that project and will fail with no expected baseline, so the test and its source project reference should be reverted in the same PR, or the expected files kept or regenerated.

1. ⚠️ Bug: Revert drops expected results while java_time_example_incremental runs
   Files: its/ruling/src/test/resources/expected/java-time-example-less-threshold/java-S8694.sarif, its/ruling/src/test/resources/expected/java-time-example-less-threshold/java-S109.sarif

   This PR deletes every expected SARIF file under `expected/java-time-example-less-threshold/`, but it leaves `JavaRulingTest.java_time_example_incremental` (lines 358-389) as is. That test still analyzes the `java-time-example-less-threshold` sources, and its own comment says S8694 "raises issues" there. `executeBuildWithCommonProperties` points `sonar.lits.dump.old` at `expected/<projectName>`, and `assertNoDifferences` (lines 567-570) requires the LITS differences file to be empty. With no expected baseline, every issue found (S8694, S109, S2201, etc.) shows up as a new difference, so the ruling test fails. If the incremental ruling scenario is being backed out, revert the test (and its source project reference) in the same PR. Otherwise keep these expected files, or regenerate them.

Verification Rules 1/1 met PRs 2 inspected

Functional validation No results

Rules 1 passed 2 not applicable

✅ Repository license compliance

Broader impact PRs 2 inspected
Cross-PR 2 PRs inspected 0 open impacts

PR 6445: RC-451 Migrate Java ruling expectations to SARIF Inspected
PR 85: RC-354: Expectation update tool improvements Inspected

Auto-approval Not enabled

Set up

For more verification details, comment gitar display:verbose.

Tip

Comment Gitar fix CI or enable auto-apply: gitar auto-apply:on

Options

Auto-apply is off → Gitar will not commit updates to this branch.
Display: compact → Showing compact verification results.
Unblock → Override a blocking verdict and allow merging.

Comment with these commands to change the behavior for this request:

Auto-apply Compact Unblock
gitar auto-apply:on         
gitar display:verbose         
gitar unblock         

Was this helpful? React with 👍 / 👎 | Gitar

@github-actions

github-actions Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Ruling Diff Summary

Detected changes in 9 rule files: 0 issues removed, 421 issues added.

S109 (java) on java-time-example-less-threshold - 0 issues removed, 242 issues added - new ruling file

Added src/main/java/example/AppointmentService.java (line 12, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         7 | import java.time.YearMonth;
         8 | 
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {
>>>     12 |     LocalDate.of(2024, Month.JANUARY, 10);
        13 |     LocalDate.of(2024, Month.FEBRUARY, 15);
        14 |     LocalDate.of(2024, Month.MARCH, 20);
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);

Added src/main/java/example/AppointmentService.java (line 12, column 39, end column 41)

Assign this magic number 10 to a well-named constant, and use the constant instead.
         7 | import java.time.YearMonth;
         8 | 
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {
>>>     12 |     LocalDate.of(2024, Month.JANUARY, 10);
        13 |     LocalDate.of(2024, Month.FEBRUARY, 15);
        14 |     LocalDate.of(2024, Month.MARCH, 20);
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);

Added src/main/java/example/AppointmentService.java (line 13, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         8 | 
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {
        12 |     LocalDate.of(2024, Month.JANUARY, 10);
>>>     13 |     LocalDate.of(2024, Month.FEBRUARY, 15);
        14 |     LocalDate.of(2024, Month.MARCH, 20);
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);
        18 |     LocalDateTime.of(2024, Month.JULY, 4, 10, 0);

Added src/main/java/example/CalendarUtils.java (line 13, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class CalendarUtils {
        11 | 
        12 |   void compute() {
>>>     13 |     LocalDate.of(2024, Month.FEBRUARY, 14);
        14 |     LocalDate.of(2024, Month.MARCH, 8);
        15 |     LocalDate.of(2024, Month.APRIL, 22);
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);

Added src/main/java/example/CalendarUtils.java (line 13, column 40, end column 42)

Assign this magic number 14 to a well-named constant, and use the constant instead.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class CalendarUtils {
        11 | 
        12 |   void compute() {
>>>     13 |     LocalDate.of(2024, Month.FEBRUARY, 14);
        14 |     LocalDate.of(2024, Month.MARCH, 8);
        15 |     LocalDate.of(2024, Month.APRIL, 22);
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);

Added src/main/java/example/CalendarUtils.java (line 14, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         9 | 
        10 | public class CalendarUtils {
        11 | 
        12 |   void compute() {
        13 |     LocalDate.of(2024, Month.FEBRUARY, 14);
>>>     14 |     LocalDate.of(2024, Month.MARCH, 8);
        15 |     LocalDate.of(2024, Month.APRIL, 22);
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 8, 8, 8);

Added src/main/java/example/EventScheduler.java (line 13, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class EventScheduler {
        11 | 
        12 |   void plan() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 20);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 28);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);

Added src/main/java/example/EventScheduler.java (line 13, column 39, end column 41)

Assign this magic number 20 to a well-named constant, and use the constant instead.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class EventScheduler {
        11 | 
        12 |   void plan() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 20);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 28);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);

Added src/main/java/example/EventScheduler.java (line 14, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         9 | 
        10 | public class EventScheduler {
        11 | 
        12 |   void plan() {
        13 |     LocalDate.of(2024, Month.JANUARY, 20);
>>>     14 |     LocalDate.of(2024, Month.FEBRUARY, 28);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);
        19 |     LocalDateTime.of(2024, Month.MAY, 5, 5, 5);

Added src/main/java/example/HolidayChecker.java (line 13, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class HolidayChecker {
        11 | 
        12 |   void check() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 1);
        14 |     LocalDate.of(2024, Month.MAY, 1);
        15 |     LocalDate.of(2024, Month.JULY, 14);
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);

Added src/main/java/example/HolidayChecker.java (line 14, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         9 | 
        10 | public class HolidayChecker {
        11 | 
        12 |   void check() {
        13 |     LocalDate.of(2024, Month.JANUARY, 1);
>>>     14 |     LocalDate.of(2024, Month.MAY, 1);
        15 |     LocalDate.of(2024, Month.JULY, 14);
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);
        19 |     LocalDateTime.of(2024, Month.JANUARY, 6, 0, 0);

Added src/main/java/example/HolidayChecker.java (line 15, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
        10 | public class HolidayChecker {
        11 | 
        12 |   void check() {
        13 |     LocalDate.of(2024, Month.JANUARY, 1);
        14 |     LocalDate.of(2024, Month.MAY, 1);
>>>     15 |     LocalDate.of(2024, Month.JULY, 14);
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);
        19 |     LocalDateTime.of(2024, Month.JANUARY, 6, 0, 0);
        20 |     LocalDateTime.of(2024, Month.APRIL, 1, 12, 0);

Added src/main/java/example/ReportGenerator.java (line 13, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class ReportGenerator {
        11 | 
        12 |   void generate() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 31);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 29);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);

Added src/main/java/example/ReportGenerator.java (line 13, column 39, end column 41)

Assign this magic number 31 to a well-named constant, and use the constant instead.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class ReportGenerator {
        11 | 
        12 |   void generate() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 31);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 29);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);

Added src/main/java/example/ReportGenerator.java (line 14, column 18, end column 22)

Assign this magic number 2024 to a well-named constant, and use the constant instead.
         9 | 
        10 | public class ReportGenerator {
        11 | 
        12 |   void generate() {
        13 |     LocalDate.of(2024, Month.JANUARY, 31);
>>>     14 |     LocalDate.of(2024, Month.FEBRUARY, 29);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);
        19 |     LocalDateTime.of(2024, Month.MARCH, 31, 23, 59);
S1120 (java) on java-time-example-less-threshold - 0 issues removed, 10 issues added - new ruling file

Added src/main/java/example/AppointmentService.java (line 11, column 1, end column 20)

Make this line start after 4 spaces instead of 2 in order to indent the code consistently. (Indentation level is at 4.)
         6 | import java.time.MonthDay;
         7 | import java.time.YearMonth;
         8 | 
         9 | public class AppointmentService {
        10 | 
>>>     11 |   void schedule() {
        12 |     LocalDate.of(2024, Month.JANUARY, 10);
        13 |     LocalDate.of(2024, Month.FEBRUARY, 15);
        14 |     LocalDate.of(2024, Month.MARCH, 20);
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);

Added src/main/java/example/AppointmentService.java (line 12, column 1, end column 43)

Make this line start after 8 spaces instead of 4 in order to indent the code consistently. (Indentation level is at 4.)
         7 | import java.time.YearMonth;
         8 | 
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {
>>>     12 |     LocalDate.of(2024, Month.JANUARY, 10);
        13 |     LocalDate.of(2024, Month.FEBRUARY, 15);
        14 |     LocalDate.of(2024, Month.MARCH, 20);
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);

Added src/main/java/example/CalendarUtils.java (line 12, column 1, end column 19)

Make this line start after 4 spaces instead of 2 in order to indent the code consistently. (Indentation level is at 4.)
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class CalendarUtils {
        11 | 
>>>     12 |   void compute() {
        13 |     LocalDate.of(2024, Month.FEBRUARY, 14);
        14 |     LocalDate.of(2024, Month.MARCH, 8);
        15 |     LocalDate.of(2024, Month.APRIL, 22);
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);

Added src/main/java/example/CalendarUtils.java (line 13, column 1, end column 44)

Make this line start after 8 spaces instead of 4 in order to indent the code consistently. (Indentation level is at 4.)
         8 | import java.time.YearMonth;
         9 | 
        10 | public class CalendarUtils {
        11 | 
        12 |   void compute() {
>>>     13 |     LocalDate.of(2024, Month.FEBRUARY, 14);
        14 |     LocalDate.of(2024, Month.MARCH, 8);
        15 |     LocalDate.of(2024, Month.APRIL, 22);
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);

Added src/main/java/example/EventScheduler.java (line 12, column 1, end column 16)

Make this line start after 4 spaces instead of 2 in order to indent the code consistently. (Indentation level is at 4.)
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class EventScheduler {
        11 | 
>>>     12 |   void plan() {
        13 |     LocalDate.of(2024, Month.JANUARY, 20);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 28);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);

Added src/main/java/example/EventScheduler.java (line 13, column 1, end column 43)

Make this line start after 8 spaces instead of 4 in order to indent the code consistently. (Indentation level is at 4.)
         8 | import java.time.YearMonth;
         9 | 
        10 | public class EventScheduler {
        11 | 
        12 |   void plan() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 20);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 28);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);

Added src/main/java/example/HolidayChecker.java (line 12, column 1, end column 17)

Make this line start after 4 spaces instead of 2 in order to indent the code consistently. (Indentation level is at 4.)
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class HolidayChecker {
        11 | 
>>>     12 |   void check() {
        13 |     LocalDate.of(2024, Month.JANUARY, 1);
        14 |     LocalDate.of(2024, Month.MAY, 1);
        15 |     LocalDate.of(2024, Month.JULY, 14);
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);

Added src/main/java/example/HolidayChecker.java (line 13, column 1, end column 42)

Make this line start after 8 spaces instead of 4 in order to indent the code consistently. (Indentation level is at 4.)
         8 | import java.time.YearMonth;
         9 | 
        10 | public class HolidayChecker {
        11 | 
        12 |   void check() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 1);
        14 |     LocalDate.of(2024, Month.MAY, 1);
        15 |     LocalDate.of(2024, Month.JULY, 14);
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);

Added src/main/java/example/ReportGenerator.java (line 12, column 1, end column 20)

Make this line start after 4 spaces instead of 2 in order to indent the code consistently. (Indentation level is at 4.)
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class ReportGenerator {
        11 | 
>>>     12 |   void generate() {
        13 |     LocalDate.of(2024, Month.JANUARY, 31);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 29);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);

Added src/main/java/example/ReportGenerator.java (line 13, column 1, end column 43)

Make this line start after 8 spaces instead of 4 in order to indent the code consistently. (Indentation level is at 4.)
         8 | import java.time.YearMonth;
         9 | 
        10 | public class ReportGenerator {
        11 | 
        12 |   void generate() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 31);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 29);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);
S113 (java) on java-time-example-less-threshold - 0 issues removed, 5 issues added - new ruling file

Added src/main/java/example/AppointmentService.java (file-level)

Add a new line at the end of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.LocalDate;
         4 | import java.time.LocalDateTime;
         5 | import java.time.Month;
         6 | import java.time.MonthDay;
         7 | import java.time.YearMonth;
         8 | 
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {

Added src/main/java/example/CalendarUtils.java (file-level)

Add a new line at the end of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.DayOfWeek;
         4 | import java.time.LocalDate;
         5 | import java.time.LocalDateTime;
         6 | import java.time.Month;
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class CalendarUtils {
        11 | 

Added src/main/java/example/EventScheduler.java (file-level)

Add a new line at the end of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.DayOfWeek;
         4 | import java.time.LocalDate;
         5 | import java.time.LocalDateTime;
         6 | import java.time.Month;
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class EventScheduler {
        11 | 

Added src/main/java/example/HolidayChecker.java (file-level)

Add a new line at the end of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.DayOfWeek;
         4 | import java.time.LocalDate;
         5 | import java.time.LocalDateTime;
         6 | import java.time.Month;
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class HolidayChecker {
        11 | 

Added src/main/java/example/ReportGenerator.java (file-level)

Add a new line at the end of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.DayOfWeek;
         4 | import java.time.LocalDate;
         5 | import java.time.LocalDateTime;
         6 | import java.time.Month;
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class ReportGenerator {
        11 | 
S1228 (java) on java-time-example-less-threshold - 0 issues removed, 1 issues added - new ruling file

Added java-time-example (file-level)

Add a 'package-info.java' file to document the 'example' package
(source file not found in checkout: java-time-example)
S1451 (java) on java-time-example-less-threshold - 0 issues removed, 5 issues added - new ruling file

Added src/main/java/example/AppointmentService.java (file-level)

Add or update the header of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.LocalDate;
         4 | import java.time.LocalDateTime;
         5 | import java.time.Month;
         6 | import java.time.MonthDay;
         7 | import java.time.YearMonth;
         8 | 
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {

Added src/main/java/example/CalendarUtils.java (file-level)

Add or update the header of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.DayOfWeek;
         4 | import java.time.LocalDate;
         5 | import java.time.LocalDateTime;
         6 | import java.time.Month;
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class CalendarUtils {
        11 | 

Added src/main/java/example/EventScheduler.java (file-level)

Add or update the header of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.DayOfWeek;
         4 | import java.time.LocalDate;
         5 | import java.time.LocalDateTime;
         6 | import java.time.Month;
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class EventScheduler {
        11 | 

Added src/main/java/example/HolidayChecker.java (file-level)

Add or update the header of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.DayOfWeek;
         4 | import java.time.LocalDate;
         5 | import java.time.LocalDateTime;
         6 | import java.time.Month;
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class HolidayChecker {
        11 | 

Added src/main/java/example/ReportGenerator.java (file-level)

Add or update the header of this file.
>>> FILE-LEVEL ISSUE
         1 | package example;
         2 | 
         3 | import java.time.DayOfWeek;
         4 | import java.time.LocalDate;
         5 | import java.time.LocalDateTime;
         6 | import java.time.Month;
         7 | import java.time.MonthDay;
         8 | import java.time.YearMonth;
         9 | 
        10 | public class ReportGenerator {
        11 | 
S1481 (java) on java-time-example-less-threshold - 0 issues removed, 4 issues added - new ruling file

Added src/main/java/example/CalendarUtils.java (line 31, column 15, end column 18)

Remove this unused "day" local variable.
        26 |     YearMonth.of(2025, 4);
        27 |     YearMonth.of(2025, 7);
        28 |     YearMonth.of(2025, Month.OCTOBER);
        29 |     MonthDay.of(2, 14);
        30 |     MonthDay.of(5, 1);
>>>     31 |     DayOfWeek day = DayOfWeek.MONDAY;
        32 |     DayOfWeek.of(5);
        33 |     LocalDate.of(2025, 11, 3);
        34 |   }
        35 | }

Added src/main/java/example/EventScheduler.java (line 31, column 15, end column 18)

Remove this unused "day" local variable.
        26 |     YearMonth.of(2024, 8);
        27 |     YearMonth.of(2025, 3);
        28 |     YearMonth.of(2025, Month.JULY);
        29 |     MonthDay.of(6, 21);
        30 |     MonthDay.of(9, 22);
>>>     31 |     DayOfWeek day = DayOfWeek.WEDNESDAY;
        32 |     DayOfWeek.of(6);
        33 |     LocalDate.of(2025, 10, 15);
        34 |   }
        35 | }

Added src/main/java/example/HolidayChecker.java (line 31, column 15, end column 18)

Remove this unused "day" local variable.
        26 |     YearMonth.of(2024, 12);
        27 |     YearMonth.of(2025, 5);
        28 |     YearMonth.of(2025, Month.DECEMBER);
        29 |     MonthDay.of(7, 14);
        30 |     MonthDay.of(11, 1);
>>>     31 |     DayOfWeek day = DayOfWeek.FRIDAY;
        32 |     DayOfWeek.of(7);
        33 |     LocalDate.of(2025, 8, 10);
        34 |   }
        35 | }

Added src/main/java/example/ReportGenerator.java (line 31, column 15, end column 18)

Remove this unused "day" local variable.
        26 |     YearMonth.of(2024, 9);
        27 |     YearMonth.of(2024, 12);
        28 |     YearMonth.of(2025, Month.MARCH);
        29 |     MonthDay.of(12, 31);
        30 |     MonthDay.of(3, 31);
>>>     31 |     DayOfWeek day = DayOfWeek.SUNDAY;
        32 |     DayOfWeek.of(4);
        33 |     LocalDate.of(2025, 11, 30);
        34 |   }
        35 | }
S1854 (java) on java-time-example-less-threshold - 0 issues removed, 4 issues added - new ruling file

Added src/main/java/example/CalendarUtils.java (line 31, column 19, end column 37)

Remove this useless assignment to local variable "day".
        26 |     YearMonth.of(2025, 4);
        27 |     YearMonth.of(2025, 7);
        28 |     YearMonth.of(2025, Month.OCTOBER);
        29 |     MonthDay.of(2, 14);
        30 |     MonthDay.of(5, 1);
>>>     31 |     DayOfWeek day = DayOfWeek.MONDAY;
        32 |     DayOfWeek.of(5);
        33 |     LocalDate.of(2025, 11, 3);
        34 |   }
        35 | }

Added src/main/java/example/EventScheduler.java (line 31, column 19, end column 40)

Remove this useless assignment to local variable "day".
        26 |     YearMonth.of(2024, 8);
        27 |     YearMonth.of(2025, 3);
        28 |     YearMonth.of(2025, Month.JULY);
        29 |     MonthDay.of(6, 21);
        30 |     MonthDay.of(9, 22);
>>>     31 |     DayOfWeek day = DayOfWeek.WEDNESDAY;
        32 |     DayOfWeek.of(6);
        33 |     LocalDate.of(2025, 10, 15);
        34 |   }
        35 | }

Added src/main/java/example/HolidayChecker.java (line 31, column 19, end column 37)

Remove this useless assignment to local variable "day".
        26 |     YearMonth.of(2024, 12);
        27 |     YearMonth.of(2025, 5);
        28 |     YearMonth.of(2025, Month.DECEMBER);
        29 |     MonthDay.of(7, 14);
        30 |     MonthDay.of(11, 1);
>>>     31 |     DayOfWeek day = DayOfWeek.FRIDAY;
        32 |     DayOfWeek.of(7);
        33 |     LocalDate.of(2025, 8, 10);
        34 |   }
        35 | }

Added src/main/java/example/ReportGenerator.java (line 31, column 19, end column 37)

Remove this useless assignment to local variable "day".
        26 |     YearMonth.of(2024, 9);
        27 |     YearMonth.of(2024, 12);
        28 |     YearMonth.of(2025, Month.MARCH);
        29 |     MonthDay.of(12, 31);
        30 |     MonthDay.of(3, 31);
>>>     31 |     DayOfWeek day = DayOfWeek.SUNDAY;
        32 |     DayOfWeek.of(4);
        33 |     LocalDate.of(2025, 11, 30);
        34 |   }
        35 | }
S2201 (java) on java-time-example-less-threshold - 0 issues removed, 100 issues added - new ruling file

Added src/main/java/example/AppointmentService.java (line 12, column 15, end column 17)

The return value of "of" must be used.
         7 | import java.time.YearMonth;
         8 | 
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {
>>>     12 |     LocalDate.of(2024, Month.JANUARY, 10);
        13 |     LocalDate.of(2024, Month.FEBRUARY, 15);
        14 |     LocalDate.of(2024, Month.MARCH, 20);
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);

Added src/main/java/example/AppointmentService.java (line 13, column 15, end column 17)

The return value of "of" must be used.
         8 | 
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {
        12 |     LocalDate.of(2024, Month.JANUARY, 10);
>>>     13 |     LocalDate.of(2024, Month.FEBRUARY, 15);
        14 |     LocalDate.of(2024, Month.MARCH, 20);
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);
        18 |     LocalDateTime.of(2024, Month.JULY, 4, 10, 0);

Added src/main/java/example/AppointmentService.java (line 14, column 15, end column 17)

The return value of "of" must be used.
         9 | public class AppointmentService {
        10 | 
        11 |   void schedule() {
        12 |     LocalDate.of(2024, Month.JANUARY, 10);
        13 |     LocalDate.of(2024, Month.FEBRUARY, 15);
>>>     14 |     LocalDate.of(2024, Month.MARCH, 20);
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);
        18 |     LocalDateTime.of(2024, Month.JULY, 4, 10, 0);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 22, 9, 30);

Added src/main/java/example/CalendarUtils.java (line 13, column 15, end column 17)

The return value of "of" must be used.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class CalendarUtils {
        11 | 
        12 |   void compute() {
>>>     13 |     LocalDate.of(2024, Month.FEBRUARY, 14);
        14 |     LocalDate.of(2024, Month.MARCH, 8);
        15 |     LocalDate.of(2024, Month.APRIL, 22);
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);

Added src/main/java/example/CalendarUtils.java (line 14, column 15, end column 17)

The return value of "of" must be used.
         9 | 
        10 | public class CalendarUtils {
        11 | 
        12 |   void compute() {
        13 |     LocalDate.of(2024, Month.FEBRUARY, 14);
>>>     14 |     LocalDate.of(2024, Month.MARCH, 8);
        15 |     LocalDate.of(2024, Month.APRIL, 22);
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 8, 8, 8);

Added src/main/java/example/CalendarUtils.java (line 15, column 15, end column 17)

The return value of "of" must be used.
        10 | public class CalendarUtils {
        11 | 
        12 |   void compute() {
        13 |     LocalDate.of(2024, Month.FEBRUARY, 14);
        14 |     LocalDate.of(2024, Month.MARCH, 8);
>>>     15 |     LocalDate.of(2024, Month.APRIL, 22);
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 8, 8, 8);
        20 |     LocalDateTime.of(2024, Month.SEPTEMBER, 9, 9, 9);

Added src/main/java/example/EventScheduler.java (line 13, column 15, end column 17)

The return value of "of" must be used.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class EventScheduler {
        11 | 
        12 |   void plan() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 20);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 28);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);

Added src/main/java/example/EventScheduler.java (line 14, column 15, end column 17)

The return value of "of" must be used.
         9 | 
        10 | public class EventScheduler {
        11 | 
        12 |   void plan() {
        13 |     LocalDate.of(2024, Month.JANUARY, 20);
>>>     14 |     LocalDate.of(2024, Month.FEBRUARY, 28);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);
        19 |     LocalDateTime.of(2024, Month.MAY, 5, 5, 5);

Added src/main/java/example/EventScheduler.java (line 15, column 15, end column 17)

The return value of "of" must be used.
        10 | public class EventScheduler {
        11 | 
        12 |   void plan() {
        13 |     LocalDate.of(2024, Month.JANUARY, 20);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 28);
>>>     15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);
        19 |     LocalDateTime.of(2024, Month.MAY, 5, 5, 5);
        20 |     LocalDateTime.of(2024, Month.JUNE, 6, 6, 6);

Added src/main/java/example/HolidayChecker.java (line 13, column 15, end column 17)

The return value of "of" must be used.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class HolidayChecker {
        11 | 
        12 |   void check() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 1);
        14 |     LocalDate.of(2024, Month.MAY, 1);
        15 |     LocalDate.of(2024, Month.JULY, 14);
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);

Added src/main/java/example/HolidayChecker.java (line 14, column 15, end column 17)

The return value of "of" must be used.
         9 | 
        10 | public class HolidayChecker {
        11 | 
        12 |   void check() {
        13 |     LocalDate.of(2024, Month.JANUARY, 1);
>>>     14 |     LocalDate.of(2024, Month.MAY, 1);
        15 |     LocalDate.of(2024, Month.JULY, 14);
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);
        19 |     LocalDateTime.of(2024, Month.JANUARY, 6, 0, 0);

Added src/main/java/example/HolidayChecker.java (line 15, column 15, end column 17)

The return value of "of" must be used.
        10 | public class HolidayChecker {
        11 | 
        12 |   void check() {
        13 |     LocalDate.of(2024, Month.JANUARY, 1);
        14 |     LocalDate.of(2024, Month.MAY, 1);
>>>     15 |     LocalDate.of(2024, Month.JULY, 14);
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);
        19 |     LocalDateTime.of(2024, Month.JANUARY, 6, 0, 0);
        20 |     LocalDateTime.of(2024, Month.APRIL, 1, 12, 0);

Added src/main/java/example/ReportGenerator.java (line 13, column 15, end column 17)

The return value of "of" must be used.
         8 | import java.time.YearMonth;
         9 | 
        10 | public class ReportGenerator {
        11 | 
        12 |   void generate() {
>>>     13 |     LocalDate.of(2024, Month.JANUARY, 31);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 29);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);

Added src/main/java/example/ReportGenerator.java (line 14, column 15, end column 17)

The return value of "of" must be used.
         9 | 
        10 | public class ReportGenerator {
        11 | 
        12 |   void generate() {
        13 |     LocalDate.of(2024, Month.JANUARY, 31);
>>>     14 |     LocalDate.of(2024, Month.FEBRUARY, 29);
        15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);
        19 |     LocalDateTime.of(2024, Month.MARCH, 31, 23, 59);

Added src/main/java/example/ReportGenerator.java (line 15, column 15, end column 17)

The return value of "of" must be used.
        10 | public class ReportGenerator {
        11 | 
        12 |   void generate() {
        13 |     LocalDate.of(2024, Month.JANUARY, 31);
        14 |     LocalDate.of(2024, Month.FEBRUARY, 29);
>>>     15 |     LocalDate.of(2024, Month.MARCH, 31);
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);
        19 |     LocalDateTime.of(2024, Month.MARCH, 31, 23, 59);
        20 |     LocalDateTime.of(2024, Month.JUNE, 30, 23, 59);
S8694 (java) on java-time-example-less-threshold - 0 issues removed, 50 issues added - new ruling file

Added src/main/java/example/AppointmentService.java (line 20, column 28, end column 29)

Use a "java.time.Month" enum constant instead of this int literal.
        15 |     LocalDate.of(2024, Month.APRIL, 5);
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);
        18 |     LocalDateTime.of(2024, Month.JULY, 4, 10, 0);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 22, 9, 30);
>>>     20 |     LocalDateTime.of(2024, 9, 1, 8, 0);
        21 |     LocalDateTime.of(2024, 10, 31, 23, 0);
        22 |     LocalDateTime.of(2024, Month.NOVEMBER, 5, 17, 0);
        23 |     LocalDateTime.of(2024, 12, 25, 15, 0);
        24 |     YearMonth.of(2024, 1);
        25 |     YearMonth.of(2024, 3);

Added src/main/java/example/AppointmentService.java (line 21, column 28, end column 30)

Use a "java.time.Month" enum constant instead of this int literal.
        16 |     LocalDate.of(2024, Month.MAY, 1);
        17 |     LocalDate.of(2024, Month.JUNE, 18);
        18 |     LocalDateTime.of(2024, Month.JULY, 4, 10, 0);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 22, 9, 30);
        20 |     LocalDateTime.of(2024, 9, 1, 8, 0);
>>>     21 |     LocalDateTime.of(2024, 10, 31, 23, 0);
        22 |     LocalDateTime.of(2024, Month.NOVEMBER, 5, 17, 0);
        23 |     LocalDateTime.of(2024, 12, 25, 15, 0);
        24 |     YearMonth.of(2024, 1);
        25 |     YearMonth.of(2024, 3);
        26 |     YearMonth.of(2024, 6);

Added src/main/java/example/AppointmentService.java (line 23, column 28, end column 30)

Use a "java.time.Month" enum constant instead of this int literal.
        18 |     LocalDateTime.of(2024, Month.JULY, 4, 10, 0);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 22, 9, 30);
        20 |     LocalDateTime.of(2024, 9, 1, 8, 0);
        21 |     LocalDateTime.of(2024, 10, 31, 23, 0);
        22 |     LocalDateTime.of(2024, Month.NOVEMBER, 5, 17, 0);
>>>     23 |     LocalDateTime.of(2024, 12, 25, 15, 0);
        24 |     YearMonth.of(2024, 1);
        25 |     YearMonth.of(2024, 3);
        26 |     YearMonth.of(2024, 6);
        27 |     YearMonth.of(2024, Month.SEPTEMBER);
        28 |     YearMonth.of(2024, 11);

Added src/main/java/example/CalendarUtils.java (line 21, column 28, end column 30)

Use a "java.time.Month" enum constant instead of this int literal.
        16 |     LocalDate.of(2024, Month.MAY, 9);
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 8, 8, 8);
        20 |     LocalDateTime.of(2024, Month.SEPTEMBER, 9, 9, 9);
>>>     21 |     LocalDateTime.of(2024, 10, 10, 10, 10);
        22 |     LocalDateTime.of(2024, 11, 11, 11, 11);
        23 |     LocalDateTime.of(2024, Month.DECEMBER, 12, 12, 12);
        24 |     LocalDateTime.of(2025, 1, 15, 7, 0);
        25 |     YearMonth.of(2025, 2);
        26 |     YearMonth.of(2025, 4);

Added src/main/java/example/CalendarUtils.java (line 22, column 28, end column 30)

Use a "java.time.Month" enum constant instead of this int literal.
        17 |     LocalDate.of(2024, Month.JUNE, 21);
        18 |     LocalDate.of(2024, Month.JULY, 14);
        19 |     LocalDateTime.of(2024, Month.AUGUST, 8, 8, 8);
        20 |     LocalDateTime.of(2024, Month.SEPTEMBER, 9, 9, 9);
        21 |     LocalDateTime.of(2024, 10, 10, 10, 10);
>>>     22 |     LocalDateTime.of(2024, 11, 11, 11, 11);
        23 |     LocalDateTime.of(2024, Month.DECEMBER, 12, 12, 12);
        24 |     LocalDateTime.of(2025, 1, 15, 7, 0);
        25 |     YearMonth.of(2025, 2);
        26 |     YearMonth.of(2025, 4);
        27 |     YearMonth.of(2025, 7);

Added src/main/java/example/CalendarUtils.java (line 24, column 28, end column 29)

Use a "java.time.Month" enum constant instead of this int literal.
        19 |     LocalDateTime.of(2024, Month.AUGUST, 8, 8, 8);
        20 |     LocalDateTime.of(2024, Month.SEPTEMBER, 9, 9, 9);
        21 |     LocalDateTime.of(2024, 10, 10, 10, 10);
        22 |     LocalDateTime.of(2024, 11, 11, 11, 11);
        23 |     LocalDateTime.of(2024, Month.DECEMBER, 12, 12, 12);
>>>     24 |     LocalDateTime.of(2025, 1, 15, 7, 0);
        25 |     YearMonth.of(2025, 2);
        26 |     YearMonth.of(2025, 4);
        27 |     YearMonth.of(2025, 7);
        28 |     YearMonth.of(2025, Month.OCTOBER);
        29 |     MonthDay.of(2, 14);

Added src/main/java/example/EventScheduler.java (line 21, column 28, end column 29)

Use a "java.time.Month" enum constant instead of this int literal.
        16 |     LocalDate.of(2024, Month.APRIL, 15);
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);
        19 |     LocalDateTime.of(2024, Month.MAY, 5, 5, 5);
        20 |     LocalDateTime.of(2024, Month.JUNE, 6, 6, 6);
>>>     21 |     LocalDateTime.of(2024, 7, 7, 7, 7);
        22 |     LocalDateTime.of(2024, 10, 15, 14, 0);
        23 |     LocalDateTime.of(2024, Month.JANUARY, 30, 18, 0);
        24 |     LocalDateTime.of(2025, 3, 3, 3, 3);
        25 |     YearMonth.of(2024, 5);
        26 |     YearMonth.of(2024, 8);

Added src/main/java/example/EventScheduler.java (line 22, column 28, end column 30)

Use a "java.time.Month" enum constant instead of this int literal.
        17 |     LocalDate.of(2024, Month.AUGUST, 20);
        18 |     LocalDate.of(2024, Month.SEPTEMBER, 10);
        19 |     LocalDateTime.of(2024, Month.MAY, 5, 5, 5);
        20 |     LocalDateTime.of(2024, Month.JUNE, 6, 6, 6);
        21 |     LocalDateTime.of(2024, 7, 7, 7, 7);
>>>     22 |     LocalDateTime.of(2024, 10, 15, 14, 0);
        23 |     LocalDateTime.of(2024, Month.JANUARY, 30, 18, 0);
        24 |     LocalDateTime.of(2025, 3, 3, 3, 3);
        25 |     YearMonth.of(2024, 5);
        26 |     YearMonth.of(2024, 8);
        27 |     YearMonth.of(2025, 3);

Added src/main/java/example/EventScheduler.java (line 24, column 28, end column 29)

Use a "java.time.Month" enum constant instead of this int literal.
        19 |     LocalDateTime.of(2024, Month.MAY, 5, 5, 5);
        20 |     LocalDateTime.of(2024, Month.JUNE, 6, 6, 6);
        21 |     LocalDateTime.of(2024, 7, 7, 7, 7);
        22 |     LocalDateTime.of(2024, 10, 15, 14, 0);
        23 |     LocalDateTime.of(2024, Month.JANUARY, 30, 18, 0);
>>>     24 |     LocalDateTime.of(2025, 3, 3, 3, 3);
        25 |     YearMonth.of(2024, 5);
        26 |     YearMonth.of(2024, 8);
        27 |     YearMonth.of(2025, 3);
        28 |     YearMonth.of(2025, Month.JULY);
        29 |     MonthDay.of(6, 21);

Added src/main/java/example/HolidayChecker.java (line 21, column 28, end column 29)

Use a "java.time.Month" enum constant instead of this int literal.
        16 |     LocalDate.of(2024, Month.NOVEMBER, 1);
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);
        19 |     LocalDateTime.of(2024, Month.JANUARY, 6, 0, 0);
        20 |     LocalDateTime.of(2024, Month.APRIL, 1, 12, 0);
>>>     21 |     LocalDateTime.of(2024, 8, 15, 0, 0);
        22 |     LocalDateTime.of(2024, 11, 11, 11, 0);
        23 |     LocalDateTime.of(2024, Month.MARCH, 8, 9, 0);
        24 |     LocalDateTime.of(2025, 2, 2, 2, 2);
        25 |     YearMonth.of(2024, 4);
        26 |     YearMonth.of(2024, 12);

Added src/main/java/example/HolidayChecker.java (line 22, column 28, end column 30)

Use a "java.time.Month" enum constant instead of this int literal.
        17 |     LocalDate.of(2024, Month.APRIL, 1);
        18 |     LocalDate.of(2024, Month.DECEMBER, 26);
        19 |     LocalDateTime.of(2024, Month.JANUARY, 6, 0, 0);
        20 |     LocalDateTime.of(2024, Month.APRIL, 1, 12, 0);
        21 |     LocalDateTime.of(2024, 8, 15, 0, 0);
>>>     22 |     LocalDateTime.of(2024, 11, 11, 11, 0);
        23 |     LocalDateTime.of(2024, Month.MARCH, 8, 9, 0);
        24 |     LocalDateTime.of(2025, 2, 2, 2, 2);
        25 |     YearMonth.of(2024, 4);
        26 |     YearMonth.of(2024, 12);
        27 |     YearMonth.of(2025, 5);

Added src/main/java/example/HolidayChecker.java (line 24, column 28, end column 29)

Use a "java.time.Month" enum constant instead of this int literal.
        19 |     LocalDateTime.of(2024, Month.JANUARY, 6, 0, 0);
        20 |     LocalDateTime.of(2024, Month.APRIL, 1, 12, 0);
        21 |     LocalDateTime.of(2024, 8, 15, 0, 0);
        22 |     LocalDateTime.of(2024, 11, 11, 11, 0);
        23 |     LocalDateTime.of(2024, Month.MARCH, 8, 9, 0);
>>>     24 |     LocalDateTime.of(2025, 2, 2, 2, 2);
        25 |     YearMonth.of(2024, 4);
        26 |     YearMonth.of(2024, 12);
        27 |     YearMonth.of(2025, 5);
        28 |     YearMonth.of(2025, Month.DECEMBER);
        29 |     MonthDay.of(7, 14);

Added src/main/java/example/ReportGenerator.java (line 21, column 28, end column 29)

Use a "java.time.Month" enum constant instead of this int literal.
        16 |     LocalDate.of(2024, Month.JUNE, 30);
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);
        19 |     LocalDateTime.of(2024, Month.MARCH, 31, 23, 59);
        20 |     LocalDateTime.of(2024, Month.JUNE, 30, 23, 59);
>>>     21 |     LocalDateTime.of(2024, 9, 30, 23, 59);
        22 |     LocalDateTime.of(2024, 12, 31, 23, 59);
        23 |     LocalDateTime.of(2025, Month.JUNE, 30, 23, 59);
        24 |     LocalDateTime.of(2025, 9, 30, 23, 59);
        25 |     YearMonth.of(2024, 6);
        26 |     YearMonth.of(2024, 9);

Added src/main/java/example/ReportGenerator.java (line 22, column 28, end column 30)

Use a "java.time.Month" enum constant instead of this int literal.
        17 |     LocalDate.of(2024, Month.SEPTEMBER, 30);
        18 |     LocalDate.of(2024, Month.DECEMBER, 31);
        19 |     LocalDateTime.of(2024, Month.MARCH, 31, 23, 59);
        20 |     LocalDateTime.of(2024, Month.JUNE, 30, 23, 59);
        21 |     LocalDateTime.of(2024, 9, 30, 23, 59);
>>>     22 |     LocalDateTime.of(2024, 12, 31, 23, 59);
        23 |     LocalDateTime.of(2025, Month.JUNE, 30, 23, 59);
        24 |     LocalDateTime.of(2025, 9, 30, 23, 59);
        25 |     YearMonth.of(2024, 6);
        26 |     YearMonth.of(2024, 9);
        27 |     YearMonth.of(2024, 12);

Added src/main/java/example/ReportGenerator.java (line 24, column 28, end column 29)

Use a "java.time.Month" enum constant instead of this int literal.
        19 |     LocalDateTime.of(2024, Month.MARCH, 31, 23, 59);
        20 |     LocalDateTime.of(2024, Month.JUNE, 30, 23, 59);
        21 |     LocalDateTime.of(2024, 9, 30, 23, 59);
        22 |     LocalDateTime.of(2024, 12, 31, 23, 59);
        23 |     LocalDateTime.of(2025, Month.JUNE, 30, 23, 59);
>>>     24 |     LocalDateTime.of(2025, 9, 30, 23, 59);
        25 |     YearMonth.of(2024, 6);
        26 |     YearMonth.of(2024, 9);
        27 |     YearMonth.of(2024, 12);
        28 |     YearMonth.of(2025, Month.MARCH);
        29 |     MonthDay.of(12, 31);

@sonarqube-next

sonarqube-next Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Quality Gate passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0 Dependency risks
No data about Coverage
No data about Duplication

See analysis details on SonarQube

@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

⚖️ Ruling update ready for review: #6468

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant