Bug 1451771 - confusing traceback when updated manifest is without subscriptions
Summary: confusing traceback when updated manifest is without subscriptions
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Server
Version: 580
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jan Dobes
QA Contact: Lukáš Hellebrandt
URL:
Whiteboard:
Depends On:
Blocks: sat58-errata
TreeView+ depends on / blocked
 
Reported: 2017-05-17 13:32 UTC by Pavel Studeník
Modified: 2017-10-19 11:57 UTC (History)
2 users (show)

Fixed In Version: spacewalk-backend-2.5.3-152-sat
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-10-19 11:57:19 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2915 0 normal SHIPPED_LIVE Red Hat Satellite 5.8.0 bug fix update 2017-10-19 15:56:50 UTC

Description Pavel Studeník 2017-05-17 13:32:08 UTC
Description of problem:
I have activate satellite with manifest that contained some subscriptions, but after some time the subscriptions were expirated and now manifest is empty. When I try to update manifest I receive following traceback:

>> rhn-satellite-activate --manifest-refresh
09:16:48 Downloading manifest...

ERROR: unhandled exception occurred:
Traceback (most recent call last):
  File "/usr/bin/rhn-satellite-activate", line 38, in <module>
    sys.exit(abs(mod.main() or 0))
  File "/usr/lib/python2.6/site-packages/spacewalk/satellite_tools/rhn_satellite_activate.py", line 475, in main
    cdn_activate = cdn_activation.Activation(options.manifest)
  File "/usr/lib/python2.6/site-packages/spacewalk/cdn_tools/activation.py", line 37, in __init__
    self.manifest = Manifest(manifest_path)
  File "/usr/lib/python2.6/site-packages/spacewalk/cdn_tools/manifest.py", line 75, in __init__
    self._load_entitlements(inner_zip)
  File "/usr/lib/python2.6/site-packages/spacewalk/cdn_tools/manifest.py", line 166, in _load_entitlements
    "ERROR: There has to be at least one entitlements file")
spacewalk.cdn_tools.manifest.IncorrectEntitlementsFileFormatError: ERROR: There has to be at least one entitlements file


I think that user should see better message that subscriptions were expired or removed.


Version-Release number of selected component (if applicable):
spacewalk-backend-tools-2.5.3-131.el6sat.noarch

How reproducible:
always

Steps to Reproduce:
1. Create manifest with subscriptions
2. Activate satellite with them
3. wait until subscription expirated or remove it from manifest on access.redhat.com

Actual results:
ERROR: There has to be at least one entitlements file

Expected results:
Better message with link to some article about redhat manifest or to URL with manifest profile https://access.redhat.com/management/distributors/<manifest UUID> to check your subscriptions

Comment 1 Jan Dobes 2017-07-27 13:57:01 UTC
fixed in spacewalk.git(master):

e9908a6f4a5dc657187bc21981f07e66e93b9d4b

the message can be further improved if needed

Comment 4 Lukáš Hellebrandt 2017-09-14 10:58:24 UTC
Verified with spacewalk-backend-2.5.3-152.

Used reproducer from OP and as step 4, ran:

# rhn-satellite-activate --manifest-refresh
06:56:48 Downloading manifest...

ERROR: No subscriptions were found in manifest.

Please refer to https://access.redhat.com/management/distributors/610e54d7-ebbd-408a-b38e-f501e3996558 for setting up subscriptions.

Comment 6 errata-xmlrpc 2017-10-19 11:57:19 UTC
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.

https://access.redhat.com/errata/RHBA-2017:2915


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