Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-6669

[Build] Scala style check errror on Windows

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.3.0, 1.4.0
    • Fix Version/s: 1.3.1, 1.4.0
    • Component/s: None
    • Labels:
      None
    • Environment:

      Windows

      Description

      When build the source code on Windows, a scala style check error happend.
      Here is the error messages.

      [INFO]
      [INFO] — scalastyle-maven-plugin:0.8.0:check (default) @ flink-scala_2.10 —
      error file=E:\github\flink\flink-scala\src\main\scala\org\apache\flink\api\scala\utils\package.scala message=Input length = 2
      Saving to outputFile=E:\github\flink\flink-scala\target\scalastyle-output.xml
      Processed 78 file(s)
      Found 1 errors
      Found 0 warnings
      Found 0 infos
      Finished in 1189 ms
      [INFO] ------------------------------------------------------------------------
      [INFO] Reactor Summary:
      [INFO]
      [INFO] force-shading ...................................... SUCCESS [ 37.206 s]
      [INFO] flink .............................................. SUCCESS [03:27 min]
      [INFO] flink-annotations .................................. SUCCESS [ 3.020 s]
      [INFO] flink-shaded-hadoop ................................ SUCCESS [ 0.928 s]
      [INFO] flink-shaded-hadoop2 ............................... SUCCESS [ 15.314 s]
      [INFO] flink-shaded-hadoop2-uber .......................... SUCCESS [ 13.085 s]
      [INFO] flink-shaded-curator ............................... SUCCESS [ 0.234 s]
      [INFO] flink-shaded-curator-recipes ....................... SUCCESS [ 3.336 s]
      [INFO] flink-shaded-curator-test .......................... SUCCESS [ 2.948 s]
      [INFO] flink-metrics ...................................... SUCCESS [ 0.286 s]
      [INFO] flink-metrics-core ................................. SUCCESS [ 9.065 s]
      [INFO] flink-test-utils-parent ............................ SUCCESS [ 0.327 s]
      [INFO] flink-test-utils-junit ............................. SUCCESS [ 1.452 s]
      [INFO] flink-core ......................................... SUCCESS [ 54.277 s]
      [INFO] flink-java ......................................... SUCCESS [ 25.244 s]
      [INFO] flink-runtime ...................................... SUCCESS [03:08 min]
      [INFO] flink-optimizer .................................... SUCCESS [ 14.540 s]
      [INFO] flink-clients ...................................... SUCCESS [ 14.457 s]
      [INFO] flink-streaming-java ............................... SUCCESS [ 58.130 s]
      [INFO] flink-test-utils ................................... SUCCESS [ 19.906 s]
      [INFO] flink-scala ........................................ FAILURE [ 56.634 s]
      [INFO] flink-runtime-web .................................. SKIPPED

      I think this is caused by the Windows default encoding. When I set the inputEncoding to UTF-8 in scalastyle-maven-plugin, the error don't happen.

      1. FLINK-6669.patch
        0.5 kB
        Jinjiang Ling

        Issue Links

          Activity

          Hide
          githubbot ASF GitHub Bot added a comment -

          GitHub user lingjinjiang opened a pull request:

          https://github.com/apache/flink/pull/3967

          FLINK-6669 set inputEncoding to UTF-8 in scalastyle-maven-plugin

          When build the source code on Windows, a scala style check error happend.
          It may be caused by the Windows default encoding. When set the inputEncoding to UTF-8 in scalastyle-maven-plugin, the error don't happen.

          https://issues.apache.org/jira/browse/FLINK-6669

          You can merge this pull request into a Git repository by running:

          $ git pull https://github.com/lingjinjiang/flink master

          Alternatively you can review and apply these changes as the patch at:

          https://github.com/apache/flink/pull/3967.patch

          To close this pull request, make a commit to your master/trunk branch
          with (at least) the following in the commit message:

          This closes #3967


          commit 505dfc5ae8140bc1be02fee610fd0f4de3e59a4a
          Author: lingjinjiang <lingjinjiang@gmail.com>
          Date: 2017-05-23T02:51:46Z

          FLINK-6669 set inputEncoding to UTF-8 in scalastyle-maven-plugin


          Show
          githubbot ASF GitHub Bot added a comment - GitHub user lingjinjiang opened a pull request: https://github.com/apache/flink/pull/3967 FLINK-6669 set inputEncoding to UTF-8 in scalastyle-maven-plugin When build the source code on Windows, a scala style check error happend. It may be caused by the Windows default encoding. When set the inputEncoding to UTF-8 in scalastyle-maven-plugin, the error don't happen. https://issues.apache.org/jira/browse/FLINK-6669 You can merge this pull request into a Git repository by running: $ git pull https://github.com/lingjinjiang/flink master Alternatively you can review and apply these changes as the patch at: https://github.com/apache/flink/pull/3967.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #3967 commit 505dfc5ae8140bc1be02fee610fd0f4de3e59a4a Author: lingjinjiang <lingjinjiang@gmail.com> Date: 2017-05-23T02:51:46Z FLINK-6669 set inputEncoding to UTF-8 in scalastyle-maven-plugin
          Hide
          Zentol Chesnay Schepler added a comment -

          I can't reproduce this. Could you try replacing the infinity symbol on line 99 in flink\flink-scala\src\main\scala\org\apache\flink\api\scala\utils\package.scala?

          Show
          Zentol Chesnay Schepler added a comment - I can't reproduce this. Could you try replacing the infinity symbol on line 99 in flink\flink-scala\src\main\scala\org\apache\flink\api\scala\utils\package.scala ?
          Hide
          lingjinjiang Jinjiang Ling added a comment -

          Chesnay Schepler
          As I delete the infinity symbol, then the buid success.

          The default encoding type of mine is GBK (Simplified_chinese), and I change it to asc ii, the build also success.

          So, I think the infinity symbol is different in GBK caused this error.

          Show
          lingjinjiang Jinjiang Ling added a comment - Chesnay Schepler As I delete the infinity symbol, then the buid success. The default encoding type of mine is GBK (Simplified_chinese), and I change it to asc ii, the build also success. So, I think the infinity symbol is different in GBK caused this error.
          Hide
          Zentol Chesnay Schepler added a comment -

          Great, so we've found the actual issue. I expect this to come up again in the future so I'll merge the PR as is.

          Show
          Zentol Chesnay Schepler added a comment - Great, so we've found the actual issue. I expect this to come up again in the future so I'll merge the PR as is.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user zentol commented on the issue:

          https://github.com/apache/flink/pull/3967

          merging.

          Show
          githubbot ASF GitHub Bot added a comment - Github user zentol commented on the issue: https://github.com/apache/flink/pull/3967 merging.
          Hide
          Zentol Chesnay Schepler added a comment -

          1.4: f827d730e40ac1c71fe974d4fd674e55ad530cdb

          Show
          Zentol Chesnay Schepler added a comment - 1.4: f827d730e40ac1c71fe974d4fd674e55ad530cdb
          Hide
          Zentol Chesnay Schepler added a comment -

          adding it to 1.3 as well.

          Show
          Zentol Chesnay Schepler added a comment - adding it to 1.3 as well.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user zentol commented on the issue:

          https://github.com/apache/flink/pull/3967

          @jinmingjian I've merged the change to master, could you close this PR?

          Show
          githubbot ASF GitHub Bot added a comment - Github user zentol commented on the issue: https://github.com/apache/flink/pull/3967 @jinmingjian I've merged the change to master, could you close this PR?
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user lingjinjiang commented on the issue:

          https://github.com/apache/flink/pull/3967

          @zentol Thank for your review. I'll close it.

          Show
          githubbot ASF GitHub Bot added a comment - Github user lingjinjiang commented on the issue: https://github.com/apache/flink/pull/3967 @zentol Thank for your review. I'll close it.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user lingjinjiang closed the pull request at:

          https://github.com/apache/flink/pull/3967

          Show
          githubbot ASF GitHub Bot added a comment - Github user lingjinjiang closed the pull request at: https://github.com/apache/flink/pull/3967
          Hide
          Zentol Chesnay Schepler added a comment -

          1.3: 401e997593631399e4311511f942692a0187e4bb

          Marked as fixed for 1.3.1 as I'm not sure if it will be included in 1.3.

          Show
          Zentol Chesnay Schepler added a comment - 1.3: 401e997593631399e4311511f942692a0187e4bb Marked as fixed for 1.3.1 as I'm not sure if it will be included in 1.3.

            People

            • Assignee:
              lingjinjiang Jinjiang Ling
              Reporter:
              lingjinjiang Jinjiang Ling
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development