-
Notifications
You must be signed in to change notification settings - Fork 825
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
Can't add lambda function to my vue2 app using aws amplify cli #13374
Comments
Hello, @Johankoekoepan and thank you for opening this issue. To better assist, I'm going to transfer this issue to the |
Hey @Johankoekoepan 👋 thanks for raising this! As we begin to look at this in more depth I have a couple follow-up questions:
additionally, if you'd like to switch from yarn to npm you can delete the |
Hey man hope it's going well, amplify --version shows 12.7.1 But I use npm, and after i run npm install in the /src directory of my function and try to run amplify push again, it throws this error: ✔ Are you sure you want to continue? (Y/n) · yes |
Hey @Johankoekoepan thanks for clarifying! If you |
Hi @josefaidt, In the end I need a function with other dependencies in it yes, but that didn't work and so now I'm ONLY creating the function in the cli and trying to push it without any code modified in the function like app.js or package.json and it still wont let me push it. Running Running amplify push with ✔ Are you sure you want to continue? (Y/n) · yes Learn more at: https://docs.amplify.aws/cli/project/troubleshooting/ PackagingLambdaFunctionError: Packaging lambda function failed with the error Command failed with exit code 243: npm install --no-bin-links --production |
Hey @Johankoekoepan thanks for clarifying! The exit code being 243 is interesting. What version of Node.js are you using? Can you try deleting the associated node_modules directory and let the CLI attempt to install to a clean directory? |
Hey @josefaidt , I've done an npm install with the node modules and package.lock deleted it still has the exact same behaviour when trying to push. My node version is v18.18.0. |
Following up on this issue, were you able to add the lambda function? |
Closing due to inactivity. @Johankoekoepan if you are still experiencing this issue please reply back to this thread or file a new report and we can investigate further |
|
Before opening, please confirm:
JavaScript Framework
Vue
Amplify APIs
REST API
Amplify Categories
function
Environment information
Describe the bug
I tried adding a lambda function through the aws amplify cli but couldn't successfully push it to the cloud nor build it locally. I've tried looking at stackoverflow questions and github questions but I haven't found a solution that works for me. I tried doing 'npm i' in the src of my lambda function but that doesn't work either.
Expected behavior
It should push the lambda function to the cloud
Reproduction steps
Code Snippet
// Put your code below this line.
Log output
aws-exports.js
No response
Manual configuration
No response
Additional configuration
No response
Mobile Device
No response
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response
The text was updated successfully, but these errors were encountered: