Skip to content

reported depths do not reflect any changes made during the same run #300

Closed

Description

@RBusarow

If executing moduleCheckAuto with depths enabled, the reported depths will reflect the state of the project before any fixes were applied for the other rules.

One possible fix would be to have the FindingFactory differentiate between rules which may apply fixes and those which are report-only. This could be done by tagging the rules with a marker interface like ReportOnly.

If auto-correct is enabled, then the runner can run the rules which apply fixes first, then take a second pass (everything's cached anyway) for the report-only rules.

If auto-correct is disabled, then everything can be run at once.

DepthRule is currently the only one that is strictly report-only, and on a 300 module project, it executes in under a second. Running it in a second pass should have a very negligible performance impact.

Activity

  1. added
    bug
    on Nov 23, 2021
  2. added a commit that references this issue on Dec 4, 2021
    99e24b0
  3. added a commit that references this issue on Dec 4, 2021
    6a7ef82
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions