Next Build Stops After Type Validations
I have a dokku deployment set up which when running, no longer successfully builds my app. The logs outputted are the following:
and you can see that it does not output the actual building and optimisation steps, e.g.:
Running the build locally works fine, and deploying the previous working commit still works as expected.
1 Reply
After many hours debugging, I've found the cause and the solution:
It seems that the
aws-sdk
NPM package is breaking deployment silently somehow, with a potential similar/equivalent problem mentioned in this post https://stackoverflow.com/questions/75107933/aws-sdk-contributes-to-build-error-uncaught-typeerror-e-is-not-a-constructor.
The solution is to move to v3 of the JavaScript AWS SDK (https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/index.html), which I have confirmed does not have the same issue when building.