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

Don't validate --endpoint-url for help subcommand #828

Merged
merged 1 commit into from
Jun 26, 2014

Conversation

jamesls
Copy link
Member

@jamesls jamesls commented Jun 26, 2014

"aws cloudsearchdomain" has --endpoint-url validation because
it's a required option for that service. However, we should
not be validating this when a user is just trying to get
help.

The fix is to move the validation to the operation-args-parsed.*
event, which is after all the help processing code.

I've also added integration tests that actually run the help command
for cloudsearchdomain to verify this behavior works.

Also manually verified that "aws cloudsearchdomain help" works and "aws cloudsearchdomain search help" works as expected. We still get endpoint-url validation when we're not doing help:

$ aws cloudsearchdomain search --search-query foo

--endpoint-url is required for cloudsearchdomain commands

Also, writing a unit test for the help functionality showed a bug when the PATH env var isn't set (which is the case in our unit tests), so you'll see a diff on the help.py module that fixes this so that the newly added unit test can pass.

cc @danielgtaylor

"aws cloudsearchdomain" has --endpoint-url validation because
it's a required option for that service.  However, we should
*not* be validating this when a user is just trying to get
help.

The fix is to move the validation to the operation-args-parsed.*
event, which is after all the help processing code.

I've also added integration tests that actually run the help command
for cloudsearchdomain to verify this behavior works.
@danielgtaylor
Copy link
Contributor

LGTM 🚢-it!

@jamesls jamesls merged commit b65f1b8 into aws:develop Jun 26, 2014
thoward-godaddy pushed a commit to thoward-godaddy/aws-cli that referenced this pull request Feb 12, 2022
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.

2 participants