Project

Profile

Help

Issue #1357

closed

When trying to sync a repository i get "int() argument must be a string or a number, not 'NoneType'"

Added by remix_tj over 8 years ago. Updated about 5 years ago.

Status:
CLOSED - DUPLICATE
Priority:
Normal
Assignee:
-
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
2.6.2 Beta
Platform Release:
OS:
RHEL 6
Triaged:
No
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:

Description

I'm trying to sync the rundeck repository to my Katello 2.3.0 with pulp 2.6.2 and i keep getting the error:

int() argument must be a string or a number, not 'NoneType'

The repository is at:

https://dl.bintray.com/rundeck/rundeck-rpm/

When downloading with reposync everything goes well.

This could be because the repomd.xml file is missing the value for the field <revision>.


Related issues

Related to Pulp - Issue #1263: repomd.xml parsing fails when an empty revision tag is presentCLOSED - CURRENTRELEASEamacdona@redhat.comActions
Actions #1

Updated by remix_tj over 8 years ago

I see on code that in case of missing revision the exception should be handled, but on my syslog i find:

Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:INFO: Parsing metadata.
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) sync failed
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) Traceback (most recent call last):
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/sync.py", line 142, in run
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) metadata_files = self.get_metadata()
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/sync.py", line 226, in get_metadata
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) metadata_files.parse_repomd()
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/repomd/metadata.py", line 165, in parse_repomd
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) self.revision = int(element.text)
Nov 5 17:46:53 vlpisatel001 pulp: pulp_rpm.plugins.importers.yum.sync:ERROR: (25639-25760) TypeError: int() argument must be a string or a number, not 'NoneType'

The exception type handled is ValueError, but in this case is TypeError. That's why the exception is raised without being handled.

As far as i can see, this is fixed on master, but not on releases.

Actions #2

Updated by amacdona@redhat.com over 8 years ago

  • Status changed from NEW to CLOSED - DUPLICATE

You are correct, this has been fixed in master and will be included in the 2.8 release. When a 2.8-beta comes out, it would be very helpful to us if you would use it and confirm that this issue is solved.

Actions #3

Updated by amacdona@redhat.com over 8 years ago

  • Related to Issue #1263: repomd.xml parsing fails when an empty revision tag is present added
Actions #4

Updated by bmbouter about 5 years ago

  • Tags Pulp 2 added

Also available in: Atom PDF