Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix package validation on Windows #358

Merged
merged 11 commits into from
Jun 23, 2022
Merged

Conversation

jsoriano
Copy link
Member

@jsoriano jsoriano commented Jun 22, 2022

What does this PR do?

Use path instead of path/filepath for operations on paths for files in fs.FS filesystems.

fs.FS uses / as path separator also in Windows, so operations with paths in these filesystems should be done with path instead of filepath.

Add a fork for gojsonschema with a fix for references on Windows using fs.FS.

A new testing stage is added for Windows to validate these changes.

Why is it important?

To fix validation of packages in Windows.

Checklist

Related issues

@jsoriano jsoriano self-assigned this Jun 22, 2022
@elasticmachine
Copy link

elasticmachine commented Jun 22, 2022

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2022-06-22T18:28:23.940+0000

  • Duration: 10 min 17 sec

🤖 GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

@jsoriano jsoriano force-pushed the test-on-windows branch 2 times, most recently from 1e3c1e7 to eb514b5 Compare June 22, 2022 10:46
.ci/Jenkinsfile Outdated Show resolved Hide resolved
.ci/Jenkinsfile Show resolved Hide resolved
.ci/Jenkinsfile Show resolved Hide resolved
.ci/Jenkinsfile Show resolved Hide resolved
.ci/Jenkinsfile Outdated Show resolved Hide resolved
@jsoriano jsoriano changed the title Add testing stage on windows Fix package validation on Windows Jun 22, 2022
@jsoriano jsoriano marked this pull request as ready for review June 22, 2022 18:39
@jsoriano jsoriano requested a review from a team as a code owner June 22, 2022 18:39
@@ -23,3 +23,5 @@ require (
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f // indirect
golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7 // indirect
)

replace github.com/xeipuuv/gojsonschema => github.com/elastic/gojsonschema v1.2.1-0.20220622182608-92eeb544ec83
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice finding :)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It took me a while to find that there were a problem there 🙂

@jsoriano jsoriano merged commit b6d9e8e into elastic:main Jun 23, 2022
@jsoriano jsoriano deleted the test-on-windows branch June 23, 2022 08:57
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.

Seeing the formatting error in package build[In windows machine]
4 participants