Skip to content
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

feat(cfnspec): cloudformation spec v50.0.0 #17844

Merged
merged 8 commits into from
Dec 8, 2021
Merged

Conversation

robertd
Copy link
Contributor

@robertd robertd commented Dec 4, 2021

Generated by running ./scripts/bump-cfnspec.sh. Needed some additions required for #17840.

Closes #17858 (duplicate)


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

@gitpod-io
Copy link

gitpod-io bot commented Dec 4, 2021

@robertd
Copy link
Contributor Author

robertd commented Dec 6, 2021

@rix0rrr It looks like a newly announced service (AWS::Evidently::Project) is not liking cfnspec's tests.

@skinny85
Copy link
Contributor

skinny85 commented Dec 6, 2021

@robertd yeah, we need a patch removing it. Would that be something you could do? Look for the other patches in that directory for inspiration, like this.

@robertd
Copy link
Contributor Author

robertd commented Dec 6, 2021

@robertd yeah, we need a patch removing it. Would that be something you could do? Look for the other patches in that directory for inspiration, like this.

Thanks @skinny85. I was just troubleshooting this on my end.

These two are the offenders:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-evidently-project.html#cfn-evidently-project-datadelivery
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-evidently-project-datadeliveryobject.html#cfn-evidently-project-datadeliveryobject-s3

I'm looking at the patch you provided.... How do I pick prefix number for it?

@robertd
Copy link
Contributor Author

robertd commented Dec 6, 2021

@skinny85 Please review and let me know what you think.

@robertd
Copy link
Contributor Author

robertd commented Dec 6, 2021

I'm not 100% sure why build is failing on amplify now as I'm able to build that module on my box just fine.

➜  aws-amplify git:(cfnspec) ../../../scripts/buildup --resume
************************************************************
 buildup usage:
 - execute 'buildup --resume' to resume after failure
 - execute 'buildup' to restart the build from the start

 for advanced usage, see /Users/rdjurasaj/code/robertd/aws-cdk/scripts/foreach.sh
************************************************************
starting new session ('@aws-cdk/aws-amplify' and its dependencies)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/tools/@aws-cdk/eslint-plugin: yarn build  (43 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/tools/@aws-cdk/pkglint: yarn build  (42 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/tools/@aws-cdk/yarn-cling: yarn build  (41 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/awslint: yarn build  (40 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/tools/@aws-cdk/cdk-build-tools: yarn build  (39 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/cloud-assembly-schema: yarn build  (38 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/cfnspec: yarn build  (37 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/region-info: yarn build  (36 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/tools/@aws-cdk/cfn2ts: yarn build  (35 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/cx-api: yarn build  (34 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/cloudformation-diff: yarn build  (33 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/core: yarn build  (32 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/cdk-assets: yarn build  (31 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/assertions: yarn build  (30 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/assert-internal: yarn build  (29 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/aws-cdk: yarn build  (28 remaining)
---------------------------------------------------------------------------------/Users/rdjurasaj/code/robertd/aws-cdk/tools/@aws-cdk/cdk-integ-tools: yarn build  (27 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-sam: yarn build  (26 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-signer: yarn build  (25 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-iam: yarn build  (24 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/assets: yarn build  (23 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-codestarnotifications: yarn build  (22 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-kms: yarn build  (21 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-cloudwatch: yarn build  (20 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-events: yarn build  (19 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-codeguruprofiler: yarn build  (18 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-autoscaling-common: yarn build  (17 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-ecr: yarn build  (16 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-s3: yarn build  (15 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-ssm: yarn build  (14 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-applicationautoscaling: yarn build  (13 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-sqs: yarn build  (12 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-ecr-assets: yarn build  (11 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-s3-assets: yarn build  (10 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-sns: yarn build  (9 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-logs: yarn build  (8 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-codecommit: yarn build  (7 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-ec2: yarn build  (6 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-efs: yarn build  (5 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-lambda: yarn build  (4 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-secretsmanager: yarn build  (3 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-codebuild: yarn build  (2 remaining)
---------------------------------------------------------------------------------
/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-amplify: yarn build  (1 remaining)
done (queue is empty). reseting queue:
state cleared. you are free to start a new command.
************************************************************
buildup done
************************************************************
➜  aws-amplify git:(cfnspec) lr build && lr test
info cli using local version of lerna
lerna notice cli v4.0.0
lerna notice filter including "@aws-cdk/aws-amplify"
lerna info filter [ '@aws-cdk/aws-amplify' ]
lerna info Executing command in 1 package: "yarn run build"
@aws-cdk/aws-amplify: yarn run v1.22.17
@aws-cdk/aws-amplify: $ cdk-build
@aws-cdk/aws-amplify: WARNING: Unable to represent attribute type {"PrimitiveType":"Boolean"} as a native type
@aws-cdk/aws-amplify: (node:8183) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-amplify/node_modules/yaml/package.json.
@aws-cdk/aws-amplify: Update this package.json to use a subpath pattern like "./*".
@aws-cdk/aws-amplify: (Use `node --trace-deprecation ...` to show where the warning was created)
@aws-cdk/aws-amplify: warning JSII6: A "peerDependency" on "@aws-cdk/aws-codebuild" at "0.0.0" means you should take a "devDependency" on "@aws-cdk/aws-codebuild" at "0.0.0" (found "undefined")"
@aws-cdk/aws-amplify: warning JSII6: A "peerDependency" on "@aws-cdk/aws-codecommit" at "0.0.0" means you should take a "devDependency" on "@aws-cdk/aws-codecommit" at "0.0.0" (found "undefined")"
@aws-cdk/aws-amplify: warning JSII6: A "peerDependency" on "@aws-cdk/aws-iam" at "0.0.0" means you should take a "devDependency" on "@aws-cdk/aws-iam" at "0.0.0" (found "undefined")"
@aws-cdk/aws-amplify: warning JSII6: A "peerDependency" on "@aws-cdk/aws-kms" at "0.0.0" means you should take a "devDependency" on "@aws-cdk/aws-kms" at "0.0.0" (found "undefined")"
@aws-cdk/aws-amplify: warning JSII6: A "peerDependency" on "@aws-cdk/aws-secretsmanager" at "0.0.0" means you should take a "devDependency" on "@aws-cdk/aws-secretsmanager" at "0.0.0" (found "undefined")"
@aws-cdk/aws-amplify: warning JSII6: A "peerDependency" on "@aws-cdk/core" at "0.0.0" means you should take a "devDependency" on "@aws-cdk/core" at "0.0.0" (found "undefined")"
@aws-cdk/aws-amplify: warning JSII6: A "peerDependency" on "constructs" at "^3.3.69" means you should take a "devDependency" on "constructs" at "3.3.69" (found "undefined")"
@aws-cdk/aws-amplify: Build times for @aws-cdk/aws-amplify: Total time (14.0s) | /Users/rdjurasaj/code/robertd/aws-cdk/node_modules/jsii/bin/jsii (7.7s) | cfn2ts (0.3s)
@aws-cdk/aws-amplify: Done in 14.23s.
lerna success run Ran npm script 'build' in 1 package in 14.4s:
lerna success - @aws-cdk/aws-amplify
info cli using local version of lerna
lerna notice cli v4.0.0
lerna notice filter including "@aws-cdk/aws-amplify"
lerna info filter [ '@aws-cdk/aws-amplify' ]
lerna info Executing command in 1 package: "yarn run test"
@aws-cdk/aws-amplify: yarn run v1.22.17
@aws-cdk/aws-amplify: $ cdk-test
@aws-cdk/aws-amplify: PASS test/branch.test.js (22.154 s)
@aws-cdk/aws-amplify: PASS test/domain.test.js (22.282 s)
@aws-cdk/aws-amplify: PASS test/app.test.js (22.689 s)
@aws-cdk/aws-amplify: =============================== Coverage summary ===============================
@aws-cdk/aws-amplify: Statements   : 96.61% ( 114/118 )
@aws-cdk/aws-amplify: Branches     : 85.71% ( 78/91 )
@aws-cdk/aws-amplify: Functions    : 90% ( 36/40 )
@aws-cdk/aws-amplify: Lines        : 96.52% ( 111/115 )
@aws-cdk/aws-amplify: ================================================================================
@aws-cdk/aws-amplify: Test Suites: 3 passed, 3 total
@aws-cdk/aws-amplify: Tests:       21 passed, 21 total
@aws-cdk/aws-amplify: Snapshots:   0 total
@aws-cdk/aws-amplify: Time:        23.446 s
@aws-cdk/aws-amplify: Ran all test suites.
@aws-cdk/aws-amplify: Verifying integ.app-codecommit.js against integ.app-codecommit.expected.json ... OK.
@aws-cdk/aws-amplify: Verifying integ.app.js against integ.app.expected.json ... OK.
@aws-cdk/aws-amplify: Tests successful. Total time (27.3s) | /Users/rdjurasaj/code/robertd/aws-cdk/node_modules/jest/bin/jest.js (24.6s) | cdk-integ-assert (2.6s)
@aws-cdk/aws-amplify: Done in 27.53s.
lerna success run Ran npm script 'test' in 1 package in 27.7s:
lerna success - @aws-cdk/aws-amplify
➜  aws-amplify git:(cfnspec)

@robertd
Copy link
Contributor Author

robertd commented Dec 6, 2021

Scratch my comment above... it's amplofybuilder that's throwing an error. Investigating....

edit:

Here is the new error.

/Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-amplifyuibuilder: yarn build  (1 remaining)
yarn run v1.22.17
$ cdk-build
[2021-12-06T15:21:33.625] [ERROR] jsii/compiler - Compilation errors prevented the JSII assembly from being created
warning JSII6: A "peerDependency" on "@aws-cdk/core" at "0.0.0" means you should take a "devDependency" on "@aws-cdk/core" at "0.0.0" (found "undefined")"
lib/index.ts:2:15 - error TS2307: Cannot find module './aws-amplifyuibuilder.generated' or its corresponding type declarations.

2 export * from './aws-amplifyuibuilder.generated';
                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: /Users/rdjurasaj/code/robertd/aws-cdk/node_modules/jsii/bin/jsii --silence-warnings=reserved-word --add-deprecation-warnings exited with error code 1
Build failed.!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error: last command failed. fix problem and resume by executing: /Users/rdjurasaj/code/robertd/aws-cdk/scripts/foreach.sh
directory:    /Users/rdjurasaj/code/robertd/aws-cdk/packages/@aws-cdk/aws-amplifyuibuilder
➜  aws-amplifyuibuilder git:(cfnspec)

@robertd
Copy link
Contributor Author

robertd commented Dec 6, 2021

Interestingly... wrong import statement was generated by cfnspecs.

Original:

// AWS::AmplifyUIBuilder CloudFormation Resources:
export * from './aws-amplifyuibuilder.generated';

Updated:

// AWS::AmplifyUIBuilder CloudFormation Resources:
export * from './amplifyuibuilder.generated';

@skinny85
Copy link
Contributor

skinny85 commented Dec 6, 2021

Interestingly... wrong import statement was generated by cfnspecs.

Original:

// AWS::AmplifyUIBuilder CloudFormation Resources:
export * from './aws-amplifyuibuilder.generated';

Updated:

// AWS::AmplifyUIBuilder CloudFormation Resources:
export * from './amplifyuibuilder.generated';

I'm pretty sure this PR: #16692 broke that. Previously, the code was:

    const lowcaseModuleName = moduleBaseName.toLocaleLowerCase();

Now it's:

    const lowcaseModuleName = module.moduleName.toLocaleLowerCase();

Instead of lowercasing the base name of the module, we're now lowercasing the entire module name. And hence aws-amplifyuibuilder.generated instead of amplifyuibuilder.generated.

Thanks for noticing!

@skinny85
Copy link
Contributor

skinny85 commented Dec 6, 2021

@robertd would you mind changing this line to be const lowcaseModuleName = module.moduleBaseName.toLocaleLowerCase(); instead?

@robertd
Copy link
Contributor Author

robertd commented Dec 6, 2021

@robertd would you mind changing this line to be const lowcaseModuleName = module.moduleBaseName.toLocaleLowerCase(); instead?

@skinny85 I've applied your suggestion and I've reran ./scripts/bump-cfnspec.sh.

@robertd
Copy link
Contributor Author

robertd commented Dec 7, 2021

@rix0rrr Please review when time permits. 😄 Thanks!

skinny85
skinny85 previously approved these changes Dec 7, 2021
Copy link
Contributor

@skinny85 skinny85 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution @robertd!

@mergify
Copy link
Contributor

mergify bot commented Dec 7, 2021

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify mergify bot dismissed skinny85’s stale review December 8, 2021 16:34

Pull request has been modified.

@mergify
Copy link
Contributor

mergify bot commented Dec 8, 2021

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject89A8053A-LhjRyN9kxr8o
  • Commit ID: 07d5a24
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify mergify bot merged commit cd3f24e into aws:master Dec 8, 2021
@mergify
Copy link
Contributor

mergify bot commented Dec 8, 2021

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

mergify bot pushed a commit that referenced this pull request Dec 9, 2021
aws-cloudformation/cloudformation-coverage-roadmap#133 just shipped.

Docs: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-instance.html#cfn-ec2-instance-propagatetagstovolumeoncreation

Waiting on cloudfromation specs to get bumped to the latest version. Depends on #17844.

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
@robertd robertd mentioned this pull request Dec 12, 2021
2 tasks
@robertd robertd deleted the cfnspec branch January 20, 2022 16:03
TikiTDO pushed a commit to TikiTDO/aws-cdk that referenced this pull request Feb 21, 2022
Generated by running `./scripts/bump-cfnspec.sh`. Needed some additions required for aws#17840.

Closes aws#17858 (duplicate)

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
TikiTDO pushed a commit to TikiTDO/aws-cdk that referenced this pull request Feb 21, 2022
aws-cloudformation/cloudformation-coverage-roadmap#133 just shipped.

Docs: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-instance.html#cfn-ec2-instance-propagatetagstovolumeoncreation

Waiting on cloudfromation specs to get bumped to the latest version. Depends on aws#17844.

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants