We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
When attempting to Open a json or yaml file containing the contents outputted by the cdk synth command, an error is returned.
json
yaml
cdk synth
v4.15.5
tpl, err := goformation.Open(filepath) if err != nil { return "", fmt.Errorf("Unable to Open CF Template [%w]", err) }
Resources: AppLBListener908F43BE: Type: AWS::ElasticLoadBalancingV2::Listener Properties: DefaultActions: - FixedResponseConfig: ContentType: text/plain MessageBody: Hello, world. StatusCode: "200" Type: fixed-response Port: 443 Protocol: HTTPS SslPolicy: ELBSecurityPolicy-FS-1-2-Res-2019-08 Metadata: aws:cdk:path: Example1Stack/AppLB/Listener/Resource CDKMetadata: Type: AWS::CDK::Metadata Properties: Modules: aws-cdk=1.73.0,@aws-cdk/assets=1.73.0,@aws-cdk/aws-cloudwatch=1.73.0,@aws-cdk/aws-ec2=1.73.0,@aws-cdk/aws-elasticloadbalancingv2=1.73.0,@aws-cdk/aws-events=1.73.0,@aws-cdk/aws-iam=1.73.0,@aws-cdk/aws-kms=1.73.0,@aws-cdk/aws-logs=1.73.0,@aws-cdk/aws-s3=1.73.0,@aws-cdk/aws-s3-assets=1.73.0,@aws-cdk/aws-ssm=1.73.0,@aws-cdk/cloud-assembly-schema=1.73.0,@aws-cdk/core=1.73.0,@aws-cdk/cx-api=1.73.0,@aws-cdk/region-info=1.73.0,jsii-runtime=node.js/v15.2.0 Metadata: aws:cdk:path: Example1Stack/CDKMetadata/Default
No error to be returned
Received the following error:
json: Unmarshal(nil)
Note: If I remove the CDKMetadata resource, the Open(...) succeeds.
CDKMetadata
Open(...)
The text was updated successfully, but these errors were encountered:
I've run into this as well. Being able to process the output of cdk synth would be nice.
Something that is working for me as a workaround is cdk synth --version-reporting false This causes synth to not output the CDKMetadata block.
cdk synth --version-reporting false
Having a reasonable error message would also be super nice. I had to trace quite deep to figure out what was happening.
Sorry, something went wrong.
Hi,
I'm facing also with it. which is the state of this issue?
No branches or pull requests
When attempting to Open a
json
oryaml
file containing the contents outputted by thecdk synth
command, an error is returned.Package Version
v4.15.5
Example Code
Example CF Template Content
Expected
No error to be returned
Got
Received the following error:
Note: If I remove the
CDKMetadata
resource, theOpen(...)
succeeds.The text was updated successfully, but these errors were encountered: