Project

Profile

Help

Issue #5831

RPM file arrays sometimes have directive in first element of array

Added by iballou 8 months ago. Updated 3 months ago.

Status:
CLOSED - WORKSFORME
Priority:
Normal
Assignee:
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Katello
Sprint:

Description

For example:

["dir", "/lib/modules/3.10.0-1062.el7.x86_64/kernel/sound/usb/", "line6"]

vs.

["/lib/modules/3.10.0-1062.el7.x86_64/kernel/net/netfilter/", "nft_masq.ko.xz"]

I've also seen "ghost" in the first index of the array which makes it look like a directive for the %files list (http://ftp.rpm.org/max-rpm/s1-rpm-inside-files-list-directives.html).

It seems like a bug that a file without a directive has a 2-entry array but a file with a directive has a 3 entry array. Perhaps they could all have prefixes?

History

#1 Updated by iballou 8 months ago

"ghost" example:

["ghost", "/boot/", "initramfs-3.10.0-1062.el7.x86_64.img"]

#2 Updated by ttereshc 8 months ago

I'd guess this is how createrepo_c parses the metadata. We should check.
Could you provide a link to a remote repo which you synced or an rpm which you uploaded if that's the case?

#3 Updated by iballou 8 months ago

#4 Updated by ppicka 8 months ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to ppicka

#5 Updated by ppicka 8 months ago

It is how the createrepo_c parse the metadata (getting from primary.xml and others). The format for files is (type, path_to_file, filename) and that type is one of "" (regular file), "dir" or "ghost".

Tested with Version: 0.15.1 of createrepo_c.

#6 Updated by ggainey 8 months ago

  • Triaged changed from No to Yes

#7 Updated by ppicka 7 months ago

Today tested with repo [0]
Neither in python shell or httpie/jq encountered short (just two items) version of array.

[0] http://mirror.centos.org/centos-7/7/os/x86_64/

#8 Updated by iballou 7 months ago

I'm seeing NULL instead now too, whatever happens we'll want to make sure that the file fields here stay consistent since we have to parse them out during Katello indexing. As long as the indices don't change we should be good.

#9 Updated by ppicka 7 months ago

  • Status changed from ASSIGNED to CLOSED - WORKSFORME

Closing as working, let's keep this consistent for future processing.

#10 Updated by ggainey 3 months ago

  • Tags Katello added
  • Tags deleted (Katello-P2)

Please register to edit this issue

Also available in: Atom PDF