Bug 812897 - Error Messaging: Inconsistent casing in CLI
Error Messaging: Inconsistent casing in CLI
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: subscription-manager (Show other bugs)
5.9
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Alex Wood
IDM QE LIST
:
Depends On:
Blocks: 771748 827225
  Show dependency treegraph
 
Reported: 2012-04-16 09:51 EDT by Matt Reid
Modified: 2013-01-07 22:50 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
No documentation needed.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-01-07 22:50:43 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Matt Reid 2012-04-16 09:51:37 EDT
Description of problem:
In some of the messages we return in the CLI for error cases we prefix the message with "Error:", othertimes we have it in all caps "ERROR:". This is based off the keys.pot file, so I don't have much context around these, but as far as I can tell, they're not special enough/related enough to have different casing.

Version-Release number of selected component (if applicable):
subscription-manager-1.0.0-1.git.9.fc486b4
  
Actual results:

#: ../src/subscription_manager/managercli.py:618
#: ../src/subscription_manager/managercli.py:624
msgid "ERROR: The service-level command is not supported by "
msgstr ""

#: ../src/subscription_manager/managercli.py:810
msgid "ERROR: The --servicelevel option is not supported "
msgstr ""

#: ../src/subscription_manager/managercli.py:842
msgid "ERROR: Server does not support environments."
msgstr ""

#: ../src/subscription_manager/managercli.py:997
msgid "ERROR: The 'release' command is not supported by the server."
msgstr ""

#: ../src/subscription_manager/managercli.py:1117
msgid "ERROR: The --servicelevel option is not "
msgstr ""

as opposed to stuff like:

#: ../src/subscription_manager/managercli.py:571
msgid "Error: you must register or specify --org."
msgstr ""

#: ../src/subscription_manager/managercli.py:574
msgid "Error: This system is currently not registered."
msgstr ""

#: ../src/subscription_manager/managercli.py:612
msgid "Error: Unable to retrieve service levels."
msgstr ""

Expected results:
I would expect that whenever we say error, that it be in the same format, "Error:".

Additional info:
Seems like the last ERROR message above is missing some text.
Comment 1 RHEL Product and Program Management 2012-04-16 22:08:27 EDT
This request was evaluated by Red Hat Product Management for inclusion
in a Red Hat Enterprise Linux release.  Product Management has
requested further review of this request by Red Hat Engineering, for
potential inclusion in a Red Hat Enterprise Linux release for currently
deployed products.  This request is not yet committed for inclusion in
a release.
Comment 2 Alex Wood 2012-04-18 15:10:16 EDT
commit 2f65bc452b7cdc36a87490a7a91dda6627b073fc
Author: Alex Wood <awood@redhat.com>
Date:   Wed Apr 18 14:58:09 2012 -0400

    812897: Use consistent casing for the word "Error"
Comment 4 J.C. Molet 2012-06-19 15:23:51 EDT
xanadu|Projects/subscription-manager|:master ✓ ❯ git show
commit ad12cf3d996357bd619e93375ad5da5509eafce2
Merge: 613a07f bfff510
Author: James Bowes <jbowes@redhat.com>
Date:   Tue Jun 19 13:45:56 2012 -0300

xanadu|Projects/subscription-manager|:master ✓ ❯ grep -i "error: " src/subscription_manager/managercli.py
                print _("Error: CA certificate for subscription service has not been installed.")
            log.error(u"Error: Unable to generate a new identity for the system: %s" % re)
            handle_exception(_("Error: Unable to generate a new identity for the system"), e)
            log.error(u"Error: Unable to retrieve org list from Entitlement Platform: %s" % re)
            handle_exception(_("Error: Unable to retrieve org list from Entitlement Platform"), e)
            print(_("Error: This command requires that you specify an organizaiton with --org"))
            log.error(u"Error: Unable to retrieve environment list from Entitlement Platform: %s" % re)
            handle_exception(_("Error: Unable to retrieve environment list from Entitlement Platform"), e)
                    print(_("Error: you must register or specify --username and --password to list service levels"))
                    print(_("Error: you must register or specify --org."))
            log.error(u"Error: Unable to retrieve service levels: %s" % re)
            handle_exception(_("Error: Unable to retrieve service levels."), e)
            systemExit(-1, _("Error: The service-level command is not supported "
            systemExit(-1, _("Error: The service-level command is not supported by "
        not_supported = _("Error: The service-level command is not supported by "
            print(_("Error: consumer name can not be empty."))
            print(_("Error: Activation keys do not require user credentials"))
            print(_("Error: Activation keys can not be used with previously registered ids."))
            print(_("Error: Must specify an activation key"))
            print(_("Error: Must use --autosubscribe with --servicelevel."))
                systemExit(-1, _("Error: The --servicelevel option is not supported "
            systemExit(-1, _("Error: Server does not support environments."))
            print(_("Error: This command requires that you specify an email address with --email."))
        err_msg = _("Error: The 'release' command is not supported by the server.")
            print _("Error: This command requires that you specify a pool with --pool or use --auto.")
            print _("Error: Only one of --pool or --auto may be used with this command.")
                print _("Error: Quantity must be a positive integer.")
            print(_("Error: Must use --auto with --servicelevel."))
                        systemExit(-1, _("Error: The --servicelevel option is not " + \
                msg = _("Error: '%s' is not a valid serial number") % self.options.serial
            print _("Error: This command requires that you specify one of --serial or --all.")
            print _("Error: This command requires that you specify a certificate with --certificate.")
            print _("Error: This command requires that you use a --list option "
                print _("Error: A valid repo id is required. "
                print _("Error: A valid repo id is required. "
                    _("Error: --list should not be used with any other options for setting or removing configurations.")
                        _("Error: configuration entry designation for removal must be of format [section.name]")
                    sys.stderr.write(_("Error: Section %s and name %s does not exist.") % (section, name))
            print _("Error: --all is only applicable with --available")
            print _("Error: --ondate is only applicable with --available")
            print _("Error: --servicelevel is only applicable with --available or --consumed")



All of these strings use a consistent "Error: " string format.

Marking Verified.
Comment 6 errata-xmlrpc 2013-01-07 22:50:43 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2013-0033.html

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