Bug 621288 - cumin-admin add-user gives ominous IntegrityError traceback when user already exists.
Summary: cumin-admin add-user gives ominous IntegrityError traceback when user already...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: cumin
Version: 1.3
Hardware: All
OS: Linux
medium
medium
Target Milestone: 1.3.2
: ---
Assignee: Justin Ross
QA Contact: Jan Sarenik
URL:
Whiteboard:
Depends On:
Blocks: 595746
TreeView+ depends on / blocked
 
Reported: 2010-08-04 17:07 UTC by Jeff Needle
Modified: 2011-02-15 13:02 UTC (History)
5 users (show)

Fixed In Version: cumin-0.1.4448-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-02-15 13:02:16 UTC


Attachments (Terms of Use)

Description Jeff Needle 2010-08-04 17:07:03 UTC
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 ?
    main()
  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 21:22:19 UTC
Fixed in rev 4206.

Comment 3 Jan Sarenik 2011-02-02 13:43:10 UTC
# 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.