Issue #7414
closedChecksum model for distribution tree allows null value for a checksum
Description
The Checksum model for distribution tree allows a null
value for the checksum
field.. The checksum
field is a part of uniqueness constraint. Since it's allowed to be null
, and every null
is unique, it's possible to have duplicates.
There is a spec (somewhat outdated) https://release-engineering.github.io/productmd/treeinfo-1.0.html which seems to say that checksums should always be present.
I'm not sure about real world examples when checksum type is null
for this model, however the data migration needs to consider that theoretical possibility.
Updated by ttereshc over 4 years ago
- Triaged changed from No to Yes
- Sprint set to Sprint 80
Updated by ppicka about 4 years ago
- Status changed from NEW to ASSIGNED
- Assignee set to ppicka
Updated by ppicka about 4 years ago
Noticed that in case of checksum missing e.g.
[checksums]
images/pxeboot/upgrade.img = sha256:30e14955ebf1352266dc2ff8067e68104607e750abb9d3b36582b8af909fcb58
images/pxeboot/vmlinuz =
productmd.treeinfo.TreeInfo used in our parsing will count hash.
fixtures/rpm-distribution-tree/addons/dolphin/repodata/repomd.xml
entry like this fail the sync
in this case do we want manual migration when 'null' can't (shouldn't) happen, and we do not save repomd.xml file to re-count its hash?
Updated by pulpbot about 4 years ago
- Status changed from ASSIGNED to POST
Added by ppicka about 4 years ago
Updated by ppicka about 4 years ago
- Status changed from POST to MODIFIED
Applied in changeset c56bac11c7c000ca51646f94f9f3b1127a63b5f0.
Updated by pulpbot about 4 years ago
- Status changed from MODIFIED to CLOSED - CURRENTRELEASE
Checksum to not allow null
Removing allow_null from checksum field from checksum model.
closes: #7414 https://pulp.plan.io/issues/7414 [nocoverage]