Commit graph

4 commits

Author SHA1 Message Date
Antoine Lambert
05cd1de1cd cpan: Fix module version extraction for some edge cases
CPAN API can return versions that are not of str type: either
int or float.

When version equals 0, it means that version failed to be parsed
by CPAN so we try to extract it from release name in that case.

Otherwise we ensure to convert the version to str type.

Related to T2833
2022-10-11 15:24:34 +02:00
Antoine Lambert
f57b8f3a2c cpan: Improve listing process by querying the metacpan release endpoint
Instead of querying the metacpan distribution endpoint to list origins,
prefer to use the release endpoint instead enabling to list all artifacts
associated to CPAN packages by scrolling results.

Compared to previous implementation, it enables to compute a last_update
date for all CPAN packages but also to obtain artifact sha256 checksums
that will be used by the CPAN loader to check downloads integrity.

As the multiple versions of a module are spread across multiple pages
from the CPAN API, origins are sent to the scheduler once all pages
processed, it is also faster to proceed that way.

Related to T2833
2022-10-11 15:24:34 +02:00
Antoine Lambert
fa1205c4df Send package artifact checksums to loaders when info is available
In listers collecting artifacts for each package to load, add artifacts
checksums, when that info is available, in parameters sent to loaders
in order to check downloaded artifact integrity.
2022-09-30 18:44:11 +02:00
Franck Bret
a4aec3894e Cpan: List Perl module origins from cpan.org
Related T2833
2022-09-27 14:29:33 +02:00