Bug 621288 - cumin-admin add-user gives ominous IntegrityError traceback when user already exists.
cumin-admin add-user gives ominous IntegrityError traceback when user already...
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: cumin (Show other bugs)
All Linux
medium Severity medium
: 1.3.2
: ---
Assigned To: Justin Ross
Jan Sarenik
Depends On:
Blocks: 595746
  Show dependency treegraph
Reported: 2010-08-04 13:07 EDT by Jeff Needle
Modified: 2011-02-15 08:02 EST (History)
5 users (show)

See Also:
Fixed In Version: cumin-0.1.4448-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2011-02-15 08:02:16 EST
Type: ---
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 Jeff Needle 2010-08-04 13:07:03 EDT
Description of problem:

If you try to add a user via cumin-admin add-user that already exists, you get a pretty ominous and undecipherable traceback.

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

How reproducible:

Steps to Reproduce:
1. # cumin-admin add-user cumin password cumin
User 'cumin' is added

2. Oh, wait, that didn't do what I wanted it to do.

3. # cumin-admin add-user cumin cumin

Actual results:

No handlers could be found for logger "rosemary.sqloperation"
Traceback (most recent call last):
  File "/usr/bin/cumin-admin", line 246, in ?
  File "/usr/bin/cumin-admin", line 59, in main
    handler(app, cursor, opts, args[1:])
  File "/usr/bin/cumin-admin", line 147, in handle_add_user
    except IntegrityError:
NameError: global name 'IntegrityError' is not defined

Expected results:

cumin-admin: what are you, some kind of moron?  That user already exists!  Use <insert some better way to change password> to change the password for an existing user.

Additional info:
Comment 1 Justin Ross 2010-08-12 17:22:19 EDT
Fixed in rev 4206.
Comment 3 Jan Sarenik 2011-02-02 08:43:10 EST
# cumin-admin add-user cumin cumin
User 'cumin' is added
# cumin-admin add-user cumin jasan
No handlers could be found for logger "rosemary.sqloperation"
Error: A user called 'cumin' already exists

Verified with cumin-0.1.4494-1.el5

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