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

Refactor canary auto-generation cli semantics #1085

Merged
merged 1 commit into from
Aug 21, 2024

Conversation

marc-1010
Copy link
Contributor

Issue #, if available:

Description of changes:

  • Canary auto generation will be disabled for empty canary settings. This is intended to prevent auto generation when a key is added to the .rpdk-config when providers are upgrading their rpdk version set.
  • Add an argument local-code-generation to the cfn generate command to enable canary auto generation. This intended to restrict canary autogeneration to specific development use cases. Canary auto-generation should not occur for remote builds.

Unit Test Cases:

  • Canary autogeneration will not occur if the local-code-generation flag is missing or False.
  • Add local-code-generation=True to existing unit tests

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

@marc-1010 marc-1010 marked this pull request as ready for review July 30, 2024 19:52
Copy link
Contributor

@ammokhov ammokhov left a comment

Choose a reason for hiding this comment

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

I am confused what benefits we get from having local-code-generation

@marc-1010
Copy link
Contributor Author

marc-1010 commented Jul 30, 2024

I am confused what benefits we get from having local-code-generation

There is no valid use case/need for re-generating canary code during remote builds. Canaries are not assumed to be a build time generated-source. This cli argument will prevent remote builds from re-generation/overriding canary code during remote host build time. I don't think the burden should be on providers to manually to disable canary generation completely in .rpdk-config to prevent behavior that is unnecessary.

@marc-1010 marc-1010 requested a review from ammokhov August 8, 2024 16:32
@marc-1010 marc-1010 merged commit 0e1551d into aws-cloudformation:master Aug 21, 2024
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants