Bug 1008829 - reassigning user role shows database error
Summary: reassigning user role shows database error
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: API
Version: Nightly
Hardware: Unspecified
OS: Unspecified
unspecified
medium vote
Target Milestone: Unspecified
Assignee: Bryan Kearney
QA Contact: Katello QA List
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-17 07:11 UTC by Ales Dujicek
Modified: 2014-02-18 14:39 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-02-18 14:39:55 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Ales Dujicek 2013-09-17 07:11:19 UTC
Description of problem:

when assigning user_role which is already assigned to user, we get database error

> user assign_role --username bob --role testrole
ERROR:  duplicate key value violates unique constraint "index_roles_users_on_user_id_and_role_id"

Version-Release number of selected component (if applicable):
katello-configure-1.4.5-1.git.3.a9848fc.el6.noarch
katello-common-1.4.6-1.git.143.5712bb8.el6.noarch
katello-cli-1.4.3-1.git.46.a2fefb7.el6.noarch
katello-1.4.6-1.git.143.5712bb8.el6.noarch
katello-repos-1.4.2-1.el6.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
pulp-katello-plugins-0.2-1.el6.noarch
katello-glue-candlepin-1.4.6-1.git.143.5712bb8.el6.noarch
katello-all-1.4.6-1.git.143.5712bb8.el6.noarch
katello-qpid-broker-key-pair-1.0-1.noarch
signo-katello-0.0.21-1.el6.noarch
katello-glue-pulp-1.4.6-1.git.143.5712bb8.el6.noarch
katello-selinux-1.4.4-1.git.1.7abb02b.el6.noarch
katello-qpid-client-key-pair-1.0-1.noarch
katello-glue-elasticsearch-1.4.6-1.git.143.5712bb8.el6.noarch
katello-certs-tools-1.4.4-1.el6.noarch
katello-cli-common-1.4.3-1.git.46.a2fefb7.el6.noarch

How reproducible:
always

Steps to Reproduce:
1.
> user_role create --name testrole
> user create --username bob --password testing --email root@localhost
2.
> user assign_role --username bob --role testrole
User 'bob' assigned to role 'testrole'
> user assign_role --username bob --role testrole
ERROR:  duplicate key value violates unique constraint "index_roles_users_on_user_id_and_role_id"

Comment 4 Bryan Kearney 2014-02-18 14:39:55 UTC
this is against the katello-cli which we are not using any more, closing.


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