Reclaim space for repository fails with Cannot delete some instances of model 'Artifact' because they are referenced through protected foreign keys: 'ContentArtifact.artifact'."
Description of problem:
- Reclaim space for repository fails with the following error.
~~~
Task paused with error: "("Cannot delete some instances of model 'Artifact' because they are referenced through protected foreign keys: 'ContentArtifact.artifact'.", {<ContentArtifact: pk=452959ad-c045-4e85-bf9f-6651ba37f57d>})"
~~~
Version-Release number of selected component (if applicable):
tfm-pulpcore-python3-pulpcore-3.16.14-1.el7pc.noarch
tfm-pulpcore-python3-pulp-rpm-3.17.10-2.el7pc.noarch
satellite-6.11.4.1-1.el7sat.noarch
Actual results:
- The reclaim space task on Satellite for a repository fails with the following message
~~~
023-02-10T10:36:24 [E|bac|69a59329] ("Cannot delete some instances of model 'Artifact' because they are referenced through protected foreign keys: 'ContentArtifact.artifact'.",
{<ContentArtifact: pk=452959ad-c045-4e85-bf9f-6651ba37f57d>}) (Katello::Errors::Pulp3Error)
~~~
Expected results:
- Reclaim space should complete without any errors.
Description of problem: - Reclaim space for repository fails with the following error. ~~~ Task paused with error: "("Cannot delete some instances of model 'Artifact' because they are referenced through protected foreign keys: 'ContentArtifact.artifact'.", {<ContentArtifact: pk=452959ad-c045-4e85-bf9f-6651ba37f57d>})" ~~~ Version-Release number of selected component (if applicable): tfm-pulpcore-python3-pulpcore-3.16.14-1.el7pc.noarch tfm-pulpcore-python3-pulp-rpm-3.17.10-2.el7pc.noarch satellite-6.11.4.1-1.el7sat.noarch Actual results: - The reclaim space task on Satellite for a repository fails with the following message ~~~ 023-02-10T10:36:24 [E|bac|69a59329] ("Cannot delete some instances of model 'Artifact' because they are referenced through protected foreign keys: 'ContentArtifact.artifact'.", {<ContentArtifact: pk=452959ad-c045-4e85-bf9f-6651ba37f57d>}) (Katello::Errors::Pulp3Error) ~~~ Expected results: - Reclaim space should complete without any errors.