Bug 675473 - Missing data in message "-Cannot unsubscribe entitlement {0} because"
Summary: Missing data in message "-Cannot unsubscribe entitlement {0} because"
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Candlepin
Classification: Community
Component: candlepin
Version: 0.5
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: ---
Assignee: Bryan Kearney
QA Contact: John Sefler
URL:
Whiteboard:
Depends On:
Blocks: Entitlement-Beta
TreeView+ depends on / blocked
 
Reported: 2011-02-05 21:05 UTC by John Sefler
Modified: 2015-05-14 15:23 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2011-02-23 21:51:22 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2011:0611 0 normal SHIPPED_LIVE new package: subscription-manager 2011-05-18 17:56:21 UTC

Description John Sefler 2011-02-05 21:05:54 UTC
Description of problem:
When trying to unsubscribe a person consumer while systems are consuming entitlements from the subpool, we expect to be blocked.  And we are! However the message seems to be missing the data...

[root@jsefler-betaqa-1 ~]# subscription-manager unsubscribe --all

-Cannot unsubscribe entitlement {0} because:
  system consumer {1} with id {2} has 	he following entitlements:
    Entitlement {0}:
        account number: {0}
        serial number: {0}

The above entitlements were derived from the pool: {0}.
Please unsubscribe from the above entitlements first.


Is this a problem with translation?

Version-Release number of selected component (if applicable):
[root@jsefler-betaqa-1 ~]# rpm -q subscription-manager
subscription-manager-0.93.15-1.git.13.cdc548a.el6.x86_64
[root@jsefler-betaqa-1 ~]# curl -u foo:bar -k https://subscriptions.rhn.webqa.redhat.com:443/subscription/status
{"version":"0.1.34","result":true,"release":"1%{?dist}"}


How reproducible:


Steps to Reproduce:

[root@jsefler-betaqa-1 ~]# subscription-manager register --username=jsefler-qabetaperson-2 --password=redhat --type=person
0760a943-76db-4624-a0b2-1f2917686b44 jsefler-qabetaperson-2
[root@jsefler-betaqa-1 ~]# subscription-manager list --available
+-------------------------------------------+
    Available Subscriptions
+-------------------------------------------+


ProductName:       	Red Hat Enterprise Linux Server Entitlement Beta for
                        Certified Engineers and System Administrators - NOT FOR SALE
ProductId:         	RH3016037                
PoolId:            	8a9b90882dce731d012dd25e1a7804be
Quantity:          	1                        
Expires:           	2011-07-28               


ProductName:       	Red Hat Enterprise Linux Server Entitlement Beta for
                        Certified Engineers and System Administrators - NOT FOR SALE
ProductId:         	RH3016037                
PoolId:            	8a9b90882df297d5012df30f457b009d
Quantity:          	1                        
Expires:           	2011-08-03               

[root@jsefler-betaqa-1 ~]# subscription-manager subscribe --pool=8a9b90882df297d5012df30f457b009d
[root@jsefler-betaqa-1 ~]# subscription-manager clean
All local data removed
[root@jsefler-betaqa-1 ~]# subscription-manager register --username=jsefler-qabetaperson-2 --password=redhat --type=system
b5a58477-9463-4ad1-9b77-3a53661c2555 jsefler-betaqa-1.usersys.redhat.com
[root@jsefler-betaqa-1 ~]# subscription-manager list --available+-------------------------------------------+
    Available Subscriptions
+-------------------------------------------+


ProductName:       	Red Hat Enterprise Linux Server Entitlement Beta for
                        Certified Engineers and System Administrators - NOT FOR SALE
ProductId:         	RH3036913                
PoolId:            	8a9b90882df297d5012df794c90d0619
Quantity:          	10                       
Expires:           	2011-08-03               

[root@jsefler-betaqa-1 ~]# subscription-manager subscribe --pool=8a9b90882df297d5012df794c90d0619
[root@jsefler-betaqa-1 ~]# subscription-manager clean
All local data removed
[root@jsefler-betaqa-1 ~]# subscription-manager register --username=jsefler-qabetaperson-2 --password=redhat --consumerid=0760a943-76db-4624-a0b2-1f2917686b44
0760a943-76db-4624-a0b2-1f2917686b44 jsefler-qabetaperson-2
[root@jsefler-betaqa-1 ~]# subscription-manager unsubscribe --all

-Cannot unsubscribe entitlement {0} because:
  system consumer {1} with id {2} has 	he following entitlements:
    Entitlement {0}:
        account number: {0}
        serial number: {0}

The above entitlements were derived from the pool: {0}.
Please unsubscribe from the above entitlements first.


  
Actual results:


Expected results:


Additional info:

Comment 2 Bryan Kearney 2011-02-07 13:37:16 UTC
Fixed in commit: 6ceda94a45ac5ff9f395f502cc5624c40cb33ef5

Should be available in 0.1.35

Comment 5 John Sefler 2011-02-17 18:04:56 UTC
VERIFYING VERSION...
[root@jsefler-f14-candlepin proxy]# git branch
* master
[root@jsefler-f14-candlepin proxy]# git show-ref master
b73a5635a8189b5b5a962a4c3a9c69a73f421192 refs/heads/master
2cc34e37691e9e06aad2ad3da394dabc24186ca7 refs/remotes/origin/master
[root@jsefler-onprem03 rhn]# curl -k https://jsefler-f14-candlepin.usersys.redhat.com:8443/candlepin/status
{"version":"0.2.6","result":true,"release":"1%{?dist}"}
[root@jsefler-onprem03 rhn]# rpm -q subscription-manager
subscription-manager-0.95.1-1.git.15.c75e560.el6.x86_64


[root@jsefler-onprem03 rhn]# subscription-manager unregister
Cannot unregister person consumer testuser1 because: 
-Cannot unsubscribe entitlement '8a90f8b42e349f20012e34a76157020e' because:
  system consumer 'jsefler-onprem04.usersys.redhat.com' with id
'187546b3-4d90-4d43-b689-a4e6c09fae04' has the following entitlements:
    Entitlement '8a90f8b42e349f20012e34a872ab0214':
        account number: '12331131231'
        serial number: '521,297,963,578,060,232'

These consumed entitlements were derived from subscription pool:
'8a90f8b42e349f20012e349f9cb40149'.
You must first unsubscribe these consumers from these entitlements.

moving to VERIFIED


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