Bug 1256918 - rhn-push fails when rpm has a package group specified as None (PATCH)
rhn-push fails when rpm has a package group specified as None (PATCH)
Status: CLOSED CURRENTRELEASE
Product: Spacewalk
Classification: Community
Component: Server (Show other bugs)
2.3
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Grant Gainey
Red Hat Satellite QA List
: Patch
Depends On: 1218762
Blocks: 465198 sat570-triage space24
  Show dependency treegraph
 
Reported: 2015-08-25 14:14 EDT by Grant Gainey
Modified: 2015-10-08 09:27 EDT (History)
6 users (show)

See Also:
Fixed In Version: spacewalk-backend-2.4.16-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1218762
Environment:
Last Closed: 2015-10-08 09:27:05 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Grant Gainey 2015-08-25 14:14:46 EDT
+++ This bug was initially created as a clone of Bug #1218762 +++

Description of problem:

rhn push fails to upload a rpm when the package group is None. the following stack trace occurs and 500 is thrown: 

Exception Handler Information
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/spacewalk/server/apacheUploadServer.py", line 100, in _wrapper
    ret = function(req)
  File "/usr/share/rhn/upload_server/handlers/package_push/package_push.py", line 124, in handler
    relative_path=self.rel_package_path, org_id=self.org_id)
  File "/usr/lib/python2.6/site-packages/spacewalk/server/rhnPackageUpload.py", line 129, in push_package
    header_end=a_pkg.header_end, channels=channels)
  File "/usr/lib/python2.6/site-packages/spacewalk/server/importlib/mpmSource.py", line 225, in create_package
    header_end=header_end, channels=channels)
  File "/usr/lib/python2.6/site-packages/spacewalk/server/importlib/headerSource.py", line 451, in createPackage
    channels)
  File "/usr/lib/python2.6/site-packages/spacewalk/server/importlib/headerSource.py", line 152, in populate
    self['package_group'] = self['package_group'].rstrip()
AttributeError: 'NoneType' object has no attribute 'rstrip'

will be adding a patch to the bz. 

--- Additional comment from Shannon Hughes on 2015-05-05 15:36:08 EDT ---

patch to handle package groups that are not set in the rpm meta data. I believe this might have to do with the rpm build version. When I build a rpm with no Group then it shows up as Unspecified so modified to the import lib code to handle in the same way.
Comment 1 Grant Gainey 2015-08-25 16:07:17 EDT
spacewalk.github fcd7882388ef62c6272922daa6966e3733d4a4fb
Comment 2 Jan Dobes 2015-10-08 09:27:05 EDT
Spacewalk 2.4 has been released.

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