Skip to content

Conversation

@t-hamano
Copy link
Contributor

@t-hamano t-hamano commented Nov 4, 2025

What?

This PR fixes the Gutenberg build CI failures occurring in the wordpress-develop repository.

Example of a failed CI: https://github.com/WordPress/wordpress-develop/actions/runs/19058795688/job/54435503272

Why? How?

The getAllPackages() function retrieves all packages using a regular expression pattern. However, on Windows, the path separator is a backslash, and the glob method will not work correctly as is.

This is a common problem, and it can be solved by using normalizePath.

Testing Instructions

On a Windows host OS, check out this branch and run npm run build. The build should succeed.

@t-hamano t-hamano added [Type] Build Tooling Issues or PRs related to build tooling OS Issues Issues or PRs that are related to OS specific problems labels Nov 4, 2025
@t-hamano t-hamano marked this pull request as ready for review November 4, 2025 06:53
@github-actions
Copy link

github-actions bot commented Nov 4, 2025

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: t-hamano <[email protected]>
Co-authored-by: mukeshpanchal27 <[email protected]>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@t-hamano
Copy link
Contributor Author

t-hamano commented Nov 4, 2025

The cause is clear, and the fix is minor, so I'd like to merge this PR once the CI checks have passed.

Copy link
Member

@mukeshpanchal27 mukeshpanchal27 left a comment

Choose a reason for hiding this comment

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

@t-hamano t-hamano merged commit 98258c4 into trunk Nov 4, 2025
43 checks passed
@t-hamano t-hamano deleted the build-windows-path branch November 4, 2025 07:20
@github-actions github-actions bot added this to the Gutenberg 22.1 milestone Nov 4, 2025
@aduth
Copy link
Member

aduth commented Nov 4, 2025

I seem to be making a habit of breaking builds on Windows lately 😬 (caused by #72941)

Appreciate you fixing this, and am working in #72946 to try to catch these types of issues more proactively.

@t-hamano
Copy link
Contributor Author

t-hamano commented Nov 4, 2025

I'm one of the few Windows developers around, so I'd be happy to help if you need anything 😄

@aduth
Copy link
Member

aduth commented Nov 4, 2025

I'm one of the few Windows developers around, so I'd be happy to help if you need anything 😄

Thanks! I may take you up on that offer in #72946, at least for a review. I'm still trying to work through the issues there, but it's a bit of "guess and check" work without having a Windows setup 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

OS Issues Issues or PRs that are related to OS specific problems [Type] Build Tooling Issues or PRs related to build tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants