Getting the below error while running any cdk cli command:
Maximum call stack size exceeded
(node:46265) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 beforeExit listeners added to [process]. Use emitter.setMaxListeners() to increase limit
(Use `node --trace-warnings ...` to show where the warning was created)
Subprocess exited with error 1
sample code using cdk cli against:
import { Stack, Construct, StackProps } from '@aws-cdk/core';
import * as s3 from '@aws-cdk/aws-s3'
export class MyFirstS3Stack extends Stack {
constructor(scope: Construct, id: string, props?: StackProps) {
super(scope,id,props);
new s3.Bucket(this,'MyFirstBucket');
}
}