-
Notifications
You must be signed in to change notification settings - Fork 4k
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
(cli-lib-alpha): should be able to disable cloud assembly version check #33338
Comments
This PR does a couple of updates. - Update the dependency on `@aws-cdk/cli-lib-alpha` due to aws/aws-cdk#33338 - Update the devDependency on `aws-cdk-lib` to the latest version - Update the examples deps to the latest version - Add some renovate rules to automate this This is needed because the library will throw an error if the user is using a version of `aws-cdk-lib` that is above the version of `@aws-cdk/cli-lib-alpha` so we need to keep this version up to date.
Thank you @corymhall I'll bring it up to the team. |
This PR does a couple of updates. - Update the dependency on `@aws-cdk/cli-lib-alpha` due to aws/aws-cdk#33338 - Update the devDependency on `aws-cdk-lib` to the latest version - Update the examples deps to the latest version - Add some renovate rules to automate this This is needed because the library will throw an error if the user is using a version of `aws-cdk-lib` that is above the version of `@aws-cdk/cli-lib-alpha` so we need to keep this version up to date.
This PR does a couple of updates. - Update the dependency on `@aws-cdk/cli-lib-alpha` due to aws/aws-cdk#33338 - Update the devDependency on `aws-cdk-lib` to the latest version - Update the examples deps to the latest version - Add some renovate rules to automate this This is needed because the library will throw an error if the user is using a version of `aws-cdk-lib` that is above the version of `@aws-cdk/cli-lib-alpha` so we need to keep this version up to date.
@corymhall Generally i'm not opposed to allow this flexibility, especially since this is programatic access, and especially since skipping the version check is already supported inside But I'm having trouble understanding the use-case. You mention:
In that case, can't you run I'm leaving this as a |
Thanks @corymhall In It sounds like you don't really need the CLI functionality though. Could you just call
yourself? If not what's missing from it? For [Programmatic Toolkit] we can look at making this an option. I'll need to check what the consequences are if we do that. |
I need the CLI functionality to produce the context for me. Essentially the use case for pulumi-cdk is that we will synthesize the Cloud Assembly and then use the information there to map each CFN resource to a Pulumi resource. We could just call An alternative approach I guess would be to expose the logic of populating missing context in here as a function that I could call to get the context and pass to |
Ah that makes sense. For the [Programmatic Toolkit] I was actually already considering making the context lookup a public feature. This might just be the justification for it. I'm also not at all against adding this new option. For our planning: What kind of urgency are we talking about here? |
No urgency on my side yet. I think I can work around it for now by always upgrading the |
Describe the feature
When you use the
AwsCdkCli.fromCloudAssemblyDirectoryProducer()
it defaults to enforcing a version check on the CloudAssembly. You should be able to disable the version check.Use Case
For my use case I need it to create a CloudAssembly, but I don't want it to do a version check. I am using the
AwsCdkCli
tosynth
and then I will read the resultingcdk.out
directory and pull the information I need from it. By enforcing a version check it requires me to keep the version of this library always up to date, otherwise users get an error if they are using a new version ofaws-cdk-lib
.Proposed Solution
With the current implementation of
fromCloudAssemblyDirectoryProducer
it looks like we might not even need to create acxapi.CloudAssembly
. We might be able to change this lineaws-cdk/packages/@aws-cdk/cli-lib-alpha/lib/cli.ts
Line 128 in 873233b
to be:
Other Information
No response
Acknowledgements
CDK version used
2.178.0
Environment details (OS name and version, etc.)
Any
The text was updated successfully, but these errors were encountered: