Closed terrymun closed 9 months ago
Hi @terrymun 👋 , thanks for raising this!
I was not able to reproduce this error when working with either v13.5.2
or v13.5.3
. Are you actively running into this issue with v13.5.2
?
Since the issue mitigates with v13.5.1
, I wonder if this is some sort of a breaking change from Next.js?
This issue has not received a response in a while. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.
This issue has been automatically locked.
Before opening, please confirm:
App Id
d179m7yexeqiqu
AWS Region
eu-west-1
Amplify Hosting feature
Frontend builds
Frontend framework
Next.js
Next.js version
13.5.2
Next.js router
App Router
Describe the bug
When trigger a preview build on AWS Amplify, the build process runs successfully all the way until the end of postBuild, where a
CustomerError
is thrown complaining about thesharp
dependency:Expected behavior
The frontend build should work successfully without throwing an error, as the
sharp
dependency should've been provided by AWS Amplify as documented: https://docs.aws.amazon.com/amplify/latest/userguide/ssr-Amplify-support.html#image-optimizationReproduction steps
13.5.2
Notice that postBuild step fails with the following error message at the very end:
!!! CustomerError: Required dependency file not found: /codebuild/output/src3916445156/src/kids-frontend/node_modules/sharp/build/Release/sharp-darwin-arm64v8.node
Build Settings
Log output
Additional information
Downgrading to
next@13.5.1
resolves the issue.