Bug 769176 - traceback when spacewalk-repo-sync synces package into incompatible arch channel
Summary: traceback when spacewalk-repo-sync synces package into incompatible arch channel
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Server
Version: 541
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
Assignee: Michael Mráka
QA Contact: Red Hat Satellite QA List
URL:
Whiteboard:
Depends On:
Blocks: sat541-triage sat550-lowbug
TreeView+ depends on / blocked
 
Reported: 2011-12-20 07:24 UTC by Jan Hutař
Modified: 2012-05-09 12:25 UTC (History)
3 users (show)

Fixed In Version: spacewalk-backend-1.2.13-69
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-04-05 12:26:30 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0457 0 normal SHIPPED_LIVE Red Hat Network Satellite server spacewalk-backend bug fix update 2012-04-05 16:24:34 UTC

Description Jan Hutař 2011-12-20 07:24:58 UTC
Description of problem:
When you have channel with arch X and repo with packages of arch Y and you attempt to sync that repo to the channel, you obtain error message (good) and traceback (bad) and spacewalk-repo-sync ends on first error like this (bad).


Version-Release number of selected component (if applicable):
In both these versions:
spacewalk-backend-tools-1.2.13-58.el5sat
spacewalk-backend-tools-1.2.13-61.el5sat


How reproducible:
always


Steps to Reproduce:
1. Have repo "myrepo" with x86_64 packages configured on satellite
2. Assign that repo to channel "myrepo-channel"
3. Run the sync:
# spacewalk-repo-sync -c myrepo-channel
Repo http://<fqdn>/pub/myrepo/ has 3 packages.
1/3 : libreoffice-langpack-el-3.4.3.2-11.fc16-1.x86_64
Package arch x86_64 incompatible with channel myrepo-channel
Traceback (most recent call last):
  File "/usr/bin/spacewalk-repo-sync", line 72, in ?
    sys.exit(abs(main() or 0))
  File "/usr/bin/spacewalk-repo-sync", line 66, in main
    sync.main()
  File "/usr/share/rhn/satellite_tools/reposync.py", line 103, in main
    self.import_packages(plugin, url)
  File "/usr/share/rhn/satellite_tools/reposync.py", line 192, in import_packages
    finally_remove(localpath)
UnboundLocalError: local variable 'localpath' referenced before assignment


Actual results:
Traceback


Expected results:
Error message should be shown but s-r-c should try to sync next package.

Comment 1 Michael Mráka 2011-12-20 08:34:00 UTC
It's already been fixed in Spacewalk, see bug 679109.

Comment 2 Jan Pazdziora 2012-04-02 07:45:39 UTC
Adding to errata https://errata.devel.redhat.com/errata/stateview/13014.

Comment 3 Jan Pazdziora 2012-04-02 07:47:10 UTC
Cherry picked to SATELLITE-5.4, 8a6d81d32d501df84f7098d84683a916731fcb74.

Comment 6 errata-xmlrpc 2012-04-05 12:26:30 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.

http://rhn.redhat.com/errata/RHBA-2012-0457.html


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