I am working on a full stack app with Next.js, Tailwind css and Amplify Gen2. I created an amplify function and am trying to sync my changes with my backend sandbox in AWS but I keep getting a
Failed to bundle asset error
Can someone please help me out?
I tried deleting my sandbox from AWS amplify but that didn’t work.
2
Answers
Came across the same error, and just needed to make sure that the
amplifyconfiguration.json
file was copied over. https://docs.amplify.aws/gen2/build-a-backend/data/customize-authz/grant-lambda-function-access-to-api/#:~:text=%7D-,The,you%20can%20import%20the%20file%20into%20your%20function%20as%20shown%20above.,-Note%3A%20WheneverAmplify docs explaining the need to copy config
Import of config highligted
I also met your issue. My suggestion is to use –debug when ran the command "npx ampx –debug sandbox". Normally, I missed the library. Therefore, please check all of the errors in debug then rerun again.
Hope it can help you