Uploaded image for project: 'Beam'
  1. Beam
  2. BEAM-6339

In certain cases, spotlessJava fails to work

Details

    • Improvement
    • Status: Resolved
    • P4
    • Resolution: Fixed
    • None
    • Not applicable
    • build-system
    • None

    Description

      Encounter following error when certain criteria exists in new code: 

       

      > Task :beam-runners-google-cloud-dataflow-java:spotlessJava FAILED

       

      FAILURE: Build failed with an exception.

      • What went wrong:
        Execution failed for task ':beam-runners-google-cloud-dataflow-java:spotlessJava'.
        > You have a misbehaving rule which can't make up its mind.
        This means that spotlessCheck will fail even after spotlessApply has run.

      This is a bug in a formatting rule, not Spotless itself, but Spotless can
      work around this bug and generate helpful bug reports for the broken rule
      if you add 'paddedCell()' to your build.gradle as such:

      spotless {
      format 'someFormat',

      { ... paddedCell() }

      }

      The next time you run spotlessCheck, it will put helpful bug reports into
      'runners/google-cloud-dataflow-java/build/spotless-diagnose-java', and spotlessApply
      and spotlessCheck will be self-consistent from here on out.

      For details see https://github.com/diffplug/spotless/blob/master/PADDEDCELL.md

      Attachments

        Issue Links

          Activity

            People

              ruoyun Ruoyun Huang
              ruoyun Ruoyun Huang
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h
                  1h