Uploaded image for project: 'Infrastructure'
  1. Infrastructure
  2. INFRA-1499

createrepo on opensuse fails with "Parsing other.xml error"

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Critical
    • Resolution: Cannot Reproduce
    • Component/s: etc
    • Labels:
      None
    • Similar Issues:

      Description

      Daniel Beck reported that some of the packages in 2.105 didn't push out correctly. After a bit of investigation, the problem is isolated to a failure to update OpenSUSE package repository.

      Specifically, the following command fails:

      $ ssh mirrorbrain@pkg.jenkins.io createrepo --update -o /var/www/pkg.jenkins.io.staging/opensuse /srv/releases/jenkins/opensuse/
      Spawning worker 0 with 1 pkgs
      Workers Finished
      Saving Primary metadata
      Saving file lists metadata
      Saving other metadata
      Generating sqlite DBs
      I/O error : No such file or directory
      
      (process:3872): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory.
      This indicates a bug in someone's code. You must ensure an error is NULL before it's set.
      The overwriting error message was: Parsing other.xml error: attributes construct error
      
      
      (process:3872): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory.
      This indicates a bug in someone's code. You must ensure an error is NULL before it's set.
      The overwriting error message was: Parsing other.xml error: Couldn't find end of Start Tag package line 57821
      
      
      (process:3872): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory.
      This indicates a bug in someone's code. You must ensure an error is NULL before it's set.
      The overwriting error message was: Parsing other.xml error: Premature end of data in tag otherdata line 2
      
      Traceback (most recent call last):
        File "/usr/share/createrepo/genpkgmetadata.py", line 308, in <module>
          main(sys.argv[1:])
        File "/usr/share/createrepo/genpkgmetadata.py", line 280, in main
          mdgen.doRepoMetadata()
        File "/usr/lib/python2.7/dist-packages/createrepo/__init__.py", line 1003, in doRepoMetadata
          rp.getOtherdata(complete_path, csum)
        File "/usr/lib/python2.7/dist-packages/sqlitecachec.py", line 61, in getOtherdata
          self.repoid))
      TypeError: Parsing other.xml error: AttValue: ' expected
      

      I assume the other.xml in question is /var/www/pkg.jenkins.io.staging/opensuse/.repodata/other.xml.gz but this file passes the well-formedness check when gunzip-ed. As an experiment I've rerun the command after deleting this other.xml.gz but the output was the same.

      I did a bit of Google search but I'm not finding anything that helps me here. If somebody can debug this a bit and at least unambiguously identify which file is failing to parse, I think that'd really help me resolve this. This kind of XML parsing error is often a result of some invalid characters (like CR/LF) in attribute values, which is often a result of XML document produced via printf.

        Attachments

          Activity

          Hide
          kohsuke Kohsuke Kawaguchi added a comment -

          Line 57821 of other.xml after gunzip is here for reference. It is well-formed.

          Show
          kohsuke Kohsuke Kawaguchi added a comment - Line 57821 of other.xml  after gunzip  is here for reference. It is well-formed.
          Hide
          olblak Olivier Vernin added a comment -

          After some investigation, I couldn't find any solution but the problem only seems to affect the directory '/srv/releases/jenkins/opensuse/'

          Show
          olblak Olivier Vernin added a comment - After some investigation, I couldn't find any solution but the problem only seems to affect the directory '/srv/releases/jenkins/opensuse/'
          Hide
          danielbeck Daniel Beck added a comment -

          Interestingly, all packages for 2.106 passed the build. For 2.105, only OS X is missing. I haven't heard this was worked on by anyone. Could someone update this issue as needed?

          Show
          danielbeck Daniel Beck added a comment - Interestingly, all packages for 2.106 passed the build. For 2.105, only OS X is missing. I haven't heard this was worked on by anyone. Could someone update this issue as needed?
          Hide
          olblak Olivier Vernin added a comment -

          Does this mean that it's working now?

          Show
          olblak Olivier Vernin added a comment - Does this mean that it's working now?
          Hide
          kohsuke Kohsuke Kawaguchi added a comment -

          Yeah, apparently the same command that used to fail now passes OK. Not sure what if anything has changed. I'm marking this closed.

          Show
          kohsuke Kohsuke Kawaguchi added a comment - Yeah, apparently the same command that used to fail now passes OK. Not sure what if anything has changed. I'm marking this closed.

            People

            • Assignee:
              olblak Olivier Vernin
              Reporter:
              kohsuke Kohsuke Kawaguchi
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: