-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Update sharp to 0.33 to fix issue with Alpine Linux #10684
Conversation
It was impossible for me to use the Astro image service in an Alpine Linux docker container. Even though I would install sharp `0.33.3` in my app, pnpm would download version `0.32.6`, which doesn't work in Alpine Linux container. Currently, I have to override the downloaded version in my package.json. For more details see: - lovell/sharp#4054 - https://discord.com/channels/830184174198718474/1224861729792458803/1224861729792458803 This PR updates the version of the `sharp` dependency to `^0.33` and thus makes Astro compatible with Alpine Linux.
🦋 Changeset detectedLatest commit: be1979b 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 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Blocking this because it's a breaking change. Sharp's 0.33.0 engines
contract is stricter than Astro's, requiring a higher version of Node 18 and 20 than Astro, and not supporting Node 19 at all.
As such, for a certain percentage of users, Sharp would just not get installed ever unless they forced the install. Last time we updated to 0.33.0 (because I didn't know its checks were stricter than us, ha), we ended up with a bunch of support threads from people running outdated versions of Node.
Now that we upgraded our Node contract in 4.6.0, we can do this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, this looks great!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this helpful contribution @PeterDraex ! I've just updated the changeset message to be a tiny bit more explicit. Especially since this is being released with a minor version of Astro, we try to give the changesets a little extra love and attention as people are checking more closely! 🙌
@PeterDraex would you mind rebasing with |
…ithastro#10693) * Add disableremoteplayback attribute to VideoHTMLAttributes interface * Move disableremoteplayback from VideoHTMLAttributes to MediaHTMLAttributes * Create olive-camels-greet.md * Update packages/astro/astro-jsx.d.ts --------- Co-authored-by: Erika <[email protected]>
…withastro#10694) * test(@astrojs/node) wait for server listening in trailing-slash tests * fix missing waitServerListen * fix import statement --------- Co-authored-by: Emanuele Stoppa <[email protected]>
…and `build:ci:no-cache` to skip caching for build as well (withastro#10696) * chore: add test:citgm command that would run tests without caching * adding build ci with no cache
* fix(withastro#10399, PLT-1786): improve notification contrast on hover * chore: add changeset
Co-authored-by: Emanuele Stoppa <[email protected]>
…o#10754) Co-authored-by: Oliver Speir <[email protected]>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* db: export 'alias' from drizzle-orm/sqlite-core * chore: changeset * fix: changeset target --------- Co-authored-by: Ben Holmes <[email protected]>
* chore: configuration * chore: update main commands * chore: revert formatting package.json * chore: rebase
…us during view transition navigation. (withastro#10799) * Fixes an issue with persisted non-text input fields that have the focus during view transition navigation. * better check
* add tests that reveal issue * fix trailing slash root page issue * add changeset
…ithastro#10773) * optimization(runtime): create smaller objects for each Astro global * add changeset * Make slots lazy --------- Co-authored-by: bluwy <[email protected]>
…ro#10763) * Invalidate CC cache manifest when lockfile or config changes * Close the handle and increment manifest version * debug info * Provide a reason for cache busting * Handle compile metadata missing * Try it this way * Copy over cached assets as well * Only restore chunks when cache is valid * Better handle invalid caches * Explain when there is no content manifest * Add tests * debugging * Remove debugging * Update packages/astro/src/core/build/plugins/plugin-content.ts Co-authored-by: Bjorn Lu <[email protected]> * Update packages/astro/src/core/build/plugins/plugin-content.ts Co-authored-by: Bjorn Lu <[email protected]> * Review comments * Add chunks path constant --------- Co-authored-by: Bjorn Lu <[email protected]>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
…e blog starter template (withastro#10814) Currently the 4th point on home page says: "Check out the included blog posts in src/pages/blog/". It the path here should be "src/content/blog/".
@matthewp Done. I've also updated sharp version in |
Yes, thank you! |
Changes
This PR updates the version of the
sharp
dependency to^0.33
and thus makes Astro compatible with Alpine Linux containers.It was impossible for me to use the Astro image service in an Alpine Linux docker container. Even though I would install sharp
0.33.3
in my app, pnpm would download version0.32.6
, which doesn't work in Alpine Linux container. I have to override the downloaded version in my package.json.For more details about the issue see:
Testing
Docs
This resolves existing bug. No documentation needed.