Project

Profile

Help

Task #6772

closed

Collection Import needs to validate data with CollectionSerializer before saving

Added by bmbouter over 2 years ago. Updated over 2 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Sprint/Milestone:
Start date:
Due date:
% Done:

100%

Estimated time:
Platform Release:
Groomed:
No
Sprint Candidate:
No
Tags:
Sprint:
Quarter:

Description

Background

pulpcore recommends all plugin writers validate data with the corresponding serializer before saving with this issue.

pulp_ansible creates CollectionVersion objects from data returned by ansible-lint here. Notice that the CollectionVersionSerializer is never used to validate the model prior to saving.

Solution

Use the CollectionVersionSerializer to validate the model data before saving.

Also available in: Atom PDF