Bug 974308 - ipa-server-install: print unrecognized option instead of generic help
ipa-server-install: print unrecognized option instead of generic help
Product: Fedora
Classification: Fedora
Component: freeipa (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Rob Crittenden
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-06-13 18:58 EDT by David Jaša
Modified: 2013-06-14 03:36 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-06-14 03:36:07 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description David Jaša 2013-06-13 18:58:43 EDT
Description of problem:
ipa-server-install: print unrecognized option instead of generic help

ipa-server-install invocation can easily get quite long and then it's quite hard to catch a typo that makes i-s-i print help. Printing the actual unrecognized option would be much more helpful

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. remove one leading '-' from some of the long options, e.g.:
ipa-server-install [...] -http_pkcs12=... [...]

Actual results:
i-s-i prints help screen

Expected results:
i-s-i prints something like this:
unrecognized option "-http_pkcs12=..."

Additional info:
Comment 1 Martin Kosek 2013-06-14 03:36:07 EDT
This is how Python's option parser behaves. When it hits -h/--help option, it quits parsing the command line and prints the help:

# ipa-server-install --help --some-garbage -evenmoregarbage
Usage: ipa-server-install [options]

If you had tried any other option which does not begin with "h", you would get the error as expected:

# ipa-server-install -setup-dns
Usage: ipa-server-install [options]

ipa-server-install: error: no such option: -s

I am thus closing this bug as NOTABUG as the command behaves as expected.

Note You need to log in before you can comment on or make changes to this bug.