#4224 Match longest extension first for archivetype
Merged by tkopecek. Opened by mikem.
mikem/koji archivetype-priority  into  master

Download 4224.patch

This addresses a longstanding bug in get_archive_type. In cases of layered extensions, the code would match a shorter extension before a longer one. E.g. ".gz" would match before ".tar.gz". We have avoided such overlapping archivetypes for this reason, however we can't control what instances do.

Fixes https://pagure.io/koji/issue/4291

Prompted by #4219

lgtm, thanks!

1 new commit added

  • make sure extension matching is case insensitive

1 new commit added

  • fix unit test

:thumbsup:

Metadata Update from @tkopecek:
- Pull-request tagged with: testing-ready

Metadata Update from @tkopecek:
- Pull-request untagged with: testing-ready
- Pull-request tagged with: testing-basic

Metadata Update from @mfilip:
- Pull-request tagged with: testing-done

Commit fd1c3839 fixes this pull-request

Pull-Request has been merged by tkopecek

Metadata