Story #5757
closed
As a user, I can expect that an empty repository version will always be created first on repo creation.
Status:
CLOSED - CURRENTRELEASE
Description
Katello relies on being able to create a repository and a publication before any content has been added to the repository. Since pulpcore no longer creates a repository version when no changes are being made, users are unable to create an 'empty' repository version. As a result, a publication can't be created either. In order to keep the behaviour of repository version creation consistent, it would be best if pulpcore simply created an empty repository version when a repository is created.
- Sprint/Milestone set to 3.0.0
- Description updated (diff)
Each plugin is responsible for handling the requests to create a Repository resource. Pulpcore should provide a post_save() hook for the Repository master model. This hook should create a RepositoryVersion for the newly created Repository.
https://docs.djangoproject.com/en/2.2/ref/signals/#post-save
- Groomed changed from No to Yes
- Sprint set to Sprint 62
We could probably accomplish this without overriding the post_save signal. We could simply override the save method to call super() and then create a RepositoryVersion.
We should also consider starting the version numbering with 0. A newly created repository has last_version set to 0 by default. After the repository version 0 is created, the repository would not need to be updated. If the empty repository version is number 1, then the Repository.last_version field needs to be updated.
- Status changed from NEW to ASSIGNED
- Assignee set to daviddavis
- Status changed from ASSIGNED to POST
- Status changed from POST to MODIFIED
- % Done changed from 0 to 100
- Status changed from MODIFIED to POST
- Status changed from POST to MODIFIED
- Status changed from MODIFIED to POST
- Status changed from POST to MODIFIED
- Status changed from MODIFIED to CLOSED - CURRENTRELEASE
- Tags Katello added
- Tags deleted (
Katello-P1)
Also available in: Atom
PDF
Fix tests for new initial repo version change
ref #5757 https://pulp.plan.io/issues/5757