Updates _make_package to accept an attestations parameter, which receives the list of attestations for the distribution (from _split_inputs).
When --attestations is set and attestations is nonempty, the supplied attestations are passed into the constructed PackageFile.
Internally, PackageFile reads each attestation as JSON and compounds it onto a JSON array to send as the attestations field during upload, per PEP 740.
WIP, needs more tests.Summary of changes:
_make_package
to accept anattestations
parameter, which receives the list of attestations for the distribution (from_split_inputs
).--attestations
is set andattestations
is nonempty, the supplied attestations are passed into the constructedPackageFile
.PackageFile
reads each attestation as JSON and compounds it onto a JSON array to send as theattestations
field during upload, per PEP 740.See #1094.