Comments (4)
Hi @mikybars your issue is a regression on our part in v4 I believe, so we will get a fix published shortly.
As for what you are seeing @sean-legitscript on v3 there haven't been any changes so not sure what could be causing that. Could you try adding the property provider.logs.frameworkLambda: true
in your serverless.yml
, then you should be able to see the logs in Cloudwatch for the custom resource lambda.
from serverless.
@mikybars We updated v4 with a fix for this, if you want to run serverless update
and try again?
from serverless.
Yep, it seems to be working now. No more hangs. Good job ;)
from serverless.
Thanks @sean-legitscript for reporting this as I was about to do the same thing 😅
In my case I have a PreSignUp
hook set up for an existing (this fact is relevant) Cognito user pool and I was experiencing the same hangs that you describe.
After one week or so of painful debugging (1+ hour feedback loops) I can say that I finally figured it out and had it working. I don't want to bore anyone here with the gritty details but the problem lies within the custom-resources
code provided by the serverless framework when you add the existing: true
property in your config. This code, which is auto-generated as part of the package
phase inside the .serverless
folder, is responsible for provisioning custom resources in AWS. As I had the opportunity to find out this code is wrong:
export default {
handler: handlerWrapper(handler, 'CustomResourceExistingCognitoUserPool')
};
As far as I'm concerned (I'm not a JS guy) ES6 modules are not supported in Node.js environments, which use CommonJS syntax instead:
module.exports = {
handler: handlerWrapper(handler, 'CustomResourceExistingCognitoUserPool')
};
Btw, this would have been way easier to find out should the lambda function responsible for provisioning the custom resource had had a log group set up in CloudWatch in the first place. I guess anyone expected this to ever fail 🤷🏾
I can offer myself to fix this, btw 🙂
from serverless.
Related Issues (20)
- Documentation is not updated about the v3 HOT 1
- Encountering "Internal Serverless Error" in commands HOT 3
- Menu Overlap Issue in Documentation HOT 2
- Show helpful errors when the build type (e.g. `esbuild`) is missing in the `build` section
- `sls info -v` not showing stack outputs HOT 2
- Cannot parse 'serverless.ts' after upgrading to v4 HOT 4
- Missing Package @serverlessinc/sf-core HOT 1
- V4.1.0: Error fetching release: EACCES: permission denied, open /usr/local/lib/node_modules/serverless/node_modules/.bin/serverless-darwin-amd64-0.0.2 HOT 3
- Serverless 4.x doesn't seem to update or work HOT 7
- sls deploy issue HOT 1
- Make inputTransformers and inputPath available when CfnRule target is event bus HOT 1
- No forceInclude equivalent in the new build.esbuild configuration HOT 7
- Invalid option in build call buildConcurrency HOT 1
- Parsing issue around build.esbuild.exclude and build.esbuild.external HOT 1
- Dev command does not work when custom IAM role set HOT 1
- AWS SSO doesn't seem to work with SERVERLESS_LICENSE_KEY HOT 2
- [windows][v4] serverless invoke local is failing to load handlers HOT 1
- Params top-level property is not loading when defined in a file HOT 1
- Detected unrecognized CLI options: "--d".
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from serverless.