Bug 120026

Summary: up2date crashes with yum when fetching obsolete list
Product: Red Hat Enterprise Linux 3 Reporter: Rainer Traut <rainer.traut>
Component: up2dateAssignee: Adrian Likins <alikins>
Status: CLOSED CURRENTRELEASE QA Contact: Fanny Augustin <fmoquete>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0   
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-08-26 23:49:00 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On:    
Bug Blocks: 119505, 120067    
Attachments:
Description Flags
My sources file none

Description Rainer Traut 2004-04-05 11:42:25 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:1.4.2)
Gecko/20040301

Description of problem:
I have made a yum repository for all rpms from U2 in it.
(dled all 4 isos and put the rpms in one dir)

Up2date ran fine with original version so I updated everything to U2
with my yum repository.
But it crashes when I run up2date now. (Newer up2date, same channel)

[root@localhost root]# up2date -u

Fetching package list for channel: u2...

Fetching http://servername:8080/u2beta/headers/header.info...
########################################
#######################################
Fetching Obsoletes list for channel: u2...
Traceback (most recent call last):
  File "/usr/sbin/up2date", line 1186, in ?
    sys.exit(main() or 0)
  File "/usr/sbin/up2date", line 772, in main
    fullUpdate, dryRun=options.dry_run))
  File "/usr/sbin/up2date", line 1065, in batchRun
    batch.run()
  File "up2dateBatch.py", line 58, in run
  File "up2dateBatch.py", line 99, in __findPackagesToUpdate
  File "packageList.py", line 515, in getPackagesToInstall
  File "packageList.py", line 395, in __findObsoletingPackages
TypeError: int() argument must be a string or a number


Version-Release number of selected component (if applicable):
up2date-4.2.8-1

How reproducible:
Always

Steps to Reproduce:
1. up2date -u
2. see it crash
3.
    

Actual Results:  up2date crashes with:
[root@localhost root]# up2date -u

Fetching package list for channel: u2...

Fetching http://servername:8080/u2beta/headers/header.info...
########################################
#######################################
Fetching Obsoletes list for channel: u2...
Traceback (most recent call last):
  File "/usr/sbin/up2date", line 1186, in ?
    sys.exit(main() or 0)
  File "/usr/sbin/up2date", line 772, in main
    fullUpdate, dryRun=options.dry_run))
  File "/usr/sbin/up2date", line 1065, in batchRun
    batch.run()
  File "up2dateBatch.py", line 58, in run
  File "up2dateBatch.py", line 99, in __findPackagesToUpdate
  File "packageList.py", line 515, in getPackagesToInstall
  File "packageList.py", line 395, in __findObsoletingPackages
TypeError: int() argument must be a string or a number

Expected Results:  Tell me there is nothing to update

Additional info:

Original up2date ran fine. I updated my install with all packages.

Comment 1 Rainer Traut 2004-04-05 11:44:47 UTC
Created attachment 99108 [details]
My sources file

My sources file with just one yum entry.

Comment 2 Adrian Likins 2004-04-05 19:42:36 UTC
Next fedora push should have a fix for this (4.3.15 or higher)

Comment 3 Rainer Traut 2004-04-09 15:33:43 UTC
Sorry, it's still not working:

[root@localhost root]# rpm -qa|grep up2date
up2date-4.3.15-2
up2date-gnome-4.3.15-2
[root@localhost root]# up2date -u

Fetching Obsoletes list for channel: u2beta...
Traceback (most recent call last):
  File "/usr/sbin/up2date", line 1271, in ?
    sys.exit(main() or 0)
  File "/usr/sbin/up2date", line 799, in main
    fullUpdate, dryRun=options.dry_run))
  File "/usr/sbin/up2date", line 1147, in batchRun
    batch.run()
  File "/usr/share/rhn/up2date_client/up2dateBatch.py", line 62, in run
    self.__findPackagesToUpdate()
  File "/usr/share/rhn/up2date_client/up2dateBatch.py", line 108, in
__findPackagesToUpdate
    self.availableUpdates = plist.getPackagesToInstall()
  File "/usr/share/rhn/up2date_client/packageList.py", line 574, in
getPackagesToInstall
    self.__findObsoletingPackages()
  File "/usr/share/rhn/up2date_client/packageList.py", line 454, in
__findObsoletingPackages
    if op & int(obsSense):
TypeError: int() argument must be a string or a number
[root@localhost root]# 

Still same /etc/sysconfig/rhn/sources file.

Comment 4 Adrian Likins 2004-04-12 20:18:23 UTC
You may need to blow away the cached obsoletes files in
/var/spool/up2date

Also, I misread the bug as a fedora bug. Sorry about
pointing you at a fedora update (though, that code
should work). 

I'll make sure the fix goes into the next rhel3 update.

Comment 5 Rainer Traut 2004-04-13 06:03:23 UTC
I emptied the
/var/spool/up2date
directory.

Now it works. Thank you.

Comment 6 Todd Warner 2004-08-26 23:49:00 UTC
Closing then.