Skip to content

Conversation

y987425112
Copy link
Contributor

Because of the different file separators in different operating
systems, the schemazip task in Windows system cannot be executed.
Now it has been repaired

Because of the different file separators in different operating
systems, the schemazip task in Windows system cannot be executed.
Now it has been repaired
@y987425112
Copy link
Contributor Author

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label Nov 5, 2019
@sbrannen sbrannen changed the title Fix a package file path error Allow schemaZip Gradle task to execute on MS Windows Nov 5, 2019
@sbrannen
Copy link
Member

sbrannen commented Nov 5, 2019

The error in the linked Stack Overflow question shows this happening for Spring Framework 4.3.0.

I can confirm that this also occurs for 5.1.x.

* What went wrong:
Failed to capture fingerprint of input files for task ':distZip' property 'rootSpec$1$3' during up-to-date check.
> Failed to create MD5 hash for file 'C:\dev\spring-framework\build\distributions\spring-framework-5.1.11.BUILD-SNAPSHOT-schema.zip' as it does not exist.

Note, however, that the build against master (i.e., 5.2.x) passes on Windows.

@sbrannen sbrannen added type: task A general task and removed status: waiting-for-triage An issue we've not yet triaged or decided on labels Nov 5, 2019
@y987425112
Copy link
Contributor Author

y987425112 commented Nov 6, 2019

I made a mistake. I built the old code.

Failed to create MD5 hash for file 'E:\gitRepository\spring\spring-framework\build\distributions\spring-framework-5.1.4.BUILD-SNAPSHOT-schema.zip' as it does not exist.

Running environment

build command: gradlew build
Operating System: Windows 10 Professional 64-bit (10.0, Build 18363) (18362.19h1_release.190318-1202)
java version: 1.8.0_231 64bit
jdk version : 1.8.0_231 64bit
spring source version: brance master commit 81d77b9

@y987425112 y987425112 closed this Nov 6, 2019
@sbrannen
Copy link
Member

sbrannen commented Nov 6, 2019

Reopening to decide if the team wants to fix the build on Windows for 5.1.x or previous branches.

@sbrannen
Copy link
Member

sbrannen commented Nov 12, 2019

@y987425112, @husterchen, and @vananiev,

It would be very helpful to us if you could answer the following questions.

  • What version of MS Windows are you using?
  • What version of Java are you using?
  • How are you executing the Gradle build?
  • Are you executing gradlew or gradlew.bat?
  • Are you executing the build from a DOS prompt (i.e., the cmd terminal), via Windows PowerShell, via a "Git for Windows" terminal, via a "Windows Subsystem for Linux" terminal, via a Cygwin terminal, or some other way?

@y987425112
Copy link
Contributor Author

y987425112 commented Nov 12, 2019

@sbrannen

  1. What version of MS Windows are you using?
    -- Windows 10 Professional 64-bit (10.0, Build 18363) (18362.19h1_release.190318-1202)
  2. What version of Java are you using?
    -- 1.8.0_231 64bit
  3. How are you executing the Gradle build?
    -- gradlew build
  4. Are you executing gradlew or gradlew.bat?
    -- only executing gradlew build
  5. Are you executing the build from a DOS prompt (i.e., the cmd terminal), via Windows PowerShell, via a "Git for Windows" terminal, via a "Windows Subsystem for Linux" terminal, via a Cygwin terminal, or some other way?
    -- only cmd

@sbrannen
Copy link
Member

sbrannen commented Nov 13, 2019

Known Failures

4.3.x

Failed to capture snapshot of input files for task 'distZip' during up-to-date check.
java.io.FileNotFoundException: C:\dev\spring-framework\build\distributions\spring-framework-4.3.26.BUILD-SNAPSHOT-schema.zip (The system cannot find the file specified)

5.0.x

Failed to create MD5 hash for file 'C:\dev\spring-framework\build\distributions\spring-framework-5.0.16.BUILD-SNAPSHOT-schema.zip'.

5.1.x

Failed to create MD5 hash for file 'C:\dev\spring-framework\build\distributions\spring-framework-5.1.11.BUILD-SNAPSHOT-schema.zip' as it does not exist.

5.2.x

Failed to create MD5 hash for file 'C:\dev\spring-framework\build\distributions\spring-framework-5.2.2.BUILD-SNAPSHOT-schema.zip' as it does not exist.

@sbrannen
Copy link
Member

This has been merged into master in 4e5ae54 and will be backported to 5.1.x, 5.0.x, and 4.3.x.

Thanks!

sbrannen pushed a commit that referenced this pull request Nov 13, 2019
Prior to this commit, the schemaZip Gradle task failed to find Spring
schema files on MS Windows due to path separators hard coded to forward
slashes that are not compatible with the Windows operating system.

Consequently, a full build failed on Windows since the distZip task was
not able to locate the zipped schema archive that the schemaZip task
failed to create.

This commit fixes this by updating the schemaZip task to search for
schema files using backslashes as well as forward slashes.

Closes gh-23933
sbrannen pushed a commit that referenced this pull request Nov 13, 2019
Prior to this commit, the schemaZip Gradle task failed to find Spring
schema files on MS Windows due to path separators hard coded to forward
slashes that are not compatible with the Windows operating system.

Consequently, a full build failed on Windows since the distZip task was
not able to locate the zipped schema archive that the schemaZip task
failed to create.

This commit fixes this by updating the schemaZip task to search for
schema files using backslashes as well as forward slashes.

Closes gh-23933
sbrannen pushed a commit that referenced this pull request Nov 13, 2019
Prior to this commit, the schemaZip Gradle task failed to find Spring
schema files on MS Windows due to path separators hard coded to forward
slashes that are not compatible with the Windows operating system.

Consequently, a full build failed on Windows since the distZip task was
not able to locate the zipped schema archive that the schemaZip task
failed to create.

This commit fixes this by updating the schemaZip task to search for
schema files using backslashes as well as forward slashes.

Closes gh-23933
@y987425112 y987425112 deleted the dev branch November 15, 2019 01:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: backported An issue that has been backported to maintenance branches type: bug A general bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants