Issue #5831
closedRPM file arrays sometimes have directive in first element of array
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?
Updated by iballou over 3 years ago
"ghost" example:
["ghost", "/boot/", "initramfs-3.10.0-1062.el7.x86_64.img"]
Updated by ttereshc over 3 years 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?
Updated by iballou over 3 years ago
Here's the repo I was using: http://mirror.centos.org/centos-7/7/os/x86_64/
Updated by ppicka over 3 years ago
- Status changed from NEW to ASSIGNED
- Assignee set to ppicka
Updated by ppicka over 3 years 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.
Updated by ppicka about 3 years ago
Today tested with repo [0]
Neither in python shell or httpie/jq encountered short (just two items) version of array.
Updated by iballou about 3 years 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.
Updated by ppicka about 3 years ago
- Status changed from ASSIGNED to CLOSED - WORKSFORME
Closing as working, let's keep this consistent for future processing.
Updated by ggainey almost 3 years ago
- Tags Katello added
- Tags deleted (
Katello-P2)