Skip to content

[Snyk] Security upgrade sharp from 0.32.6 to 0.35.4 - #13252

Open
sestinj wants to merge 1 commit into
mainfrom
snyk-fix-43c22c04406675c4256e2f44c4769b49
Open

sestinj wants to merge 1 commit into
mainfrom
snyk-fix-43c22c04406675c4256e2f44c4769b49

Conversation

@sestinj

@sestinj sestinj commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

snyk-top-banner

Snyk has created this PR to fix 1 vulnerabilities in the npm dependencies of this project.

Snyk changed the following file(s):

  • core/vendor/modules/@xenova/transformers/package.json

Vulnerabilities that will be fixed with an upgrade:

Issue Score
high severity Heap-based Buffer Overflow
SNYK-JS-SHARP-19653587
  731  

Breaking Change Risk

Merge Risk: High

Notice: This assessment is enhanced by AI.


Important

  • Check the changes in this PR to ensure they won't cause issues with your project.
  • Max score is 1000. Note that the real score may have changed since the PR was raised.
  • This PR was automatically created by Snyk using the credentials of a real user.

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.

For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic


Learn how to fix vulnerabilities with free interactive lessons:

🦉 Heap-based Buffer Overflow

…vulnerabilities

The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-JS-SHARP-19653587
@sestinj

sestinj commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

Merge Risk: High

This upgrade from sharp v0.32.6 to v0.35.4 includes multiple significant breaking changes across several minor versions. Developer action is required to ensure compatibility.

Key Breaking Changes:

  • Node.js Version Requirement: Support for Node.js versions below 20.9.0 has been dropped. The target environment must be updated.

    • v0.33.0 dropped support for Node.js 14 and 16, requiring ^18.17.0 or >=20.3.0.
    • v0.35.0 dropped support for Node.js 18, requiring >=20.9.0.
  • API Removals (v0.35.0):

    • The deprecated failOnError constructor property has been removed.
    • The deprecated paletteBitDepth property has been removed from the metadata response.
    • Deprecated properties from the sharpen operation have been removed.
  • Behavioral and API Changes:

    • v0.34.0: Non-animated GIF output now defaults to no-loop instead of a permanent loop.
    • v0.34.0: The removeAlpha operation is now more effective, which may alter output for images with multiple alpha channels.
    • v0.35.0: The format.jp2k property has been renamed to format.jp2 for consistency.

Recommendation:

  1. Verify Node.js Environment: Ensure your deployment environment runs Node.js v20.9.0 or newer.
  2. Code Review: Search your codebase for the removed APIs (failOnError, paletteBitDepth, and old sharpen properties) and refactor as needed.
  3. Test Visual Output: Pay close attention to GIF looping behavior and the visual quality of AVIF images, as the underlying metrics have changed.

Notice 🤖: This content was augmented using artificial intelligence. AI-generated content may contain errors and should be reviewed for accuracy before use.

@sestinj
sestinj requested a review from a team as a code owner September 11, 2026 10:35
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.

2 participants