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

cdk: cdk CLI should abort in case an invalid option is provided #27723

Open
saste opened this issue Oct 27, 2023 · 0 comments
Open

cdk: cdk CLI should abort in case an invalid option is provided #27723

saste opened this issue Oct 27, 2023 · 0 comments
Labels
cli Issues related to the CDK CLI effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2 package/tools Related to AWS CDK Tools or CLI

Comments

@saste
Copy link

saste commented Oct 27, 2023

Describe the bug

cdk COMMAND should fail in case a provided option is not known.

For example cdk synth --foo-bar or cdk synth --output-file out.json should fail so that the user is able to spot a mistake in the command.

Expected Behavior

The command should fail in case a specified option is unknown.

Current Behavior

The command ignores the failure and proceeds, the mistyped or unknown option is ignored.

In case of typos, the user will realize later, only after some investigation.

Reproduction Steps

Run cdk synth --foo-bar or any command with an unknown/mistyped command line option.

Possible Solution

Implement a check in case of invalid options, or at least a big warning so that the user can notice the issue.

Additional Information/Context

No response

CDK CLI Version

any, but tested with cdk 2.101.0.

Framework Version

No response

Node.js Version

any

OS

macos

Language

TypeScript, Python, .NET, Java, Go

Language Version

No response

Other information

No response

@saste saste added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Oct 27, 2023
@github-actions github-actions bot added the package/tools Related to AWS CDK Tools or CLI label Oct 27, 2023
@khushail khushail added needs-review p2 effort/medium Medium work item – several days of effort and removed needs-triage This issue or PR still needs to be triaged. labels Oct 31, 2023
@khushail khushail added effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. and removed needs-review effort/medium Medium work item – several days of effort bug This issue is a bug. labels Nov 1, 2023
@pahud pahud added the cli Issues related to the CDK CLI label May 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli Issues related to the CDK CLI effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2 package/tools Related to AWS CDK Tools or CLI
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants