Il 20/11/22 11:05, Neal Gompa ha scritto:
> On Sun, Nov 20, 2022 at 4:32 AM Mattia Verga via devel
> [<devel@lists.fedoraproject.org>](mailto:devel@lists.fedoraproject.org)
> wrote:
>
>> Is there any guide that explains fields of the updateinfo.xml files
>> which are generated in repositories?
>>
>> I'm trying to figure out
>> https://github.com/fedora-infra/bodhi/issues/2487
>> and I think we
>> currently have weird data in updates. For example, looking to the
>> 'issued' and 'modified' dates of few updates I see that the issued date
>> is greater than the modified date... that's because Bodhi modifies the
>> issued date with the timestamp of when the update is pushed to the
>> repository, rather than using the submission date.
>>
>> I don't think that field is meant to be modified and I suppose it can
>> lead yum/dnf to screw up. Is there any expert that can point me in the
>> right direction here?
>
> The closest thing to a guide is this schema documentation file I found
> long ago from python-Updateinfo:
> https://pagure.io/python-Updateinfo/blob/master/f/docs/updateinfo.xsd
> In terms of a human expert, Pat Riehecky from CentOS is your best bet
> since he analyzed the format and built python-Updateinfo for
> Scientific Linux.
>
> I think you're right about issued and modified dates, though. That
> said, the issued date is normally supposed to be when it's released to
> the repository, I believe. But if we have both issued and modified,
> then issued should be when it's *first* published (first time it goes
> out of pending).
Well, if issued date is meant to be the date when the update is pushed to a
repo, it will be changed from when the update is pushed to testing repo or to
stable repo. Is that the intended behavior?
Nevertheless, I think Bodhi is currently producing faulty metadata, because the
updateinfo file is made before recording changes to the updates. So:
- at the first compose when an update is pushed from pending to testing, the
metadata reports `status="pending"` and both issued date and updated date are
set to `date_submitted`
- in a later compose, metadata is changed to `status="testing"` and issued date
is set to `date_pushed` (which is more recent than updated date)
- at the first compose that marks the update push to stable, the status remains
`status="testing"` and issued date is reverted back to `date_submitted`
(because for some reason Bodhi set `date_pushed` to None)
- finally, later composes we have the correct `status="stable"`, but with a
issued date set to `date_pushed` (of the previous compose) and a modified date
which is usually the original `date_submitted`
I think all of those date changes are the cause of the original issue reported
for EPEL7, where yum screws up about metadata reporting bad updates. I suppose
dnf just ignores those kind of errors, but the underling problem is still there.
I am quite worried about touching such critical code in Bodhi composer before
someone else confirms my thought...
Mattia
_______________________________________________
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct:
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives:
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it:
https://pagure.io/fedora-infrastructure/new_issue