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(container): compiling error with pnpm #12934

Merged
merged 2 commits into from
Jan 9, 2025
Merged

Conversation

ematipico
Copy link
Member

@ematipico ematipico commented Jan 8, 2025

Changes

Closes #12669
Closes PLT-2733

The main issue was that the astro container runtime was pulling vite code, which is a forbidden behaviour. I managed, somehow, to understand that the code that was pulling vite code was coming from manifest/create.ts, so one of its modules (or modules of modules) was imported, eventually importing a runtime vite function.

Unfortunately, I couldn't understand what's the culprit, so instead, I decided to move the functions needed by the container into two separate files.

Also, I tried to remove any occurrence of normalizePath from vite, and used our internal version, which is the same. That should reduce these mistakes in the future.

Testing

I used the production provided, which I didn't build. Now it builds

Docs

N/A

Copy link

changeset-bot bot commented Jan 8, 2025

🦋 Changeset detected

Latest commit: f4ce75b

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the pkg: astro Related to the core `astro` package (scope) label Jan 8, 2025
Copy link

codspeed-hq bot commented Jan 8, 2025

CodSpeed Performance Report

Merging #12934 will not alter performance

Comparing fix/container-regression (75a5571) with main (fd12a26)

Summary

✅ 6 untouched benchmarks

@ematipico ematipico merged commit 673a518 into main Jan 9, 2025
16 checks passed
@ematipico ematipico deleted the fix/container-regression branch January 9, 2025 09:57
@astrobot-houston astrobot-houston mentioned this pull request Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: astro Related to the core `astro` package (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

astro build fails with pnpm (but works with npm)
2 participants