Project

Profile

Help

Issue #7431

closed

Removing distribution tree cause error on repository version

Added by ppicka over 3 years ago. Updated over 3 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Sprint/Milestone:
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Sprint:
Sprint 83
Quarter:

Description

How to reproduce:

  1. sync repository with dist tree e.g. fixtures[0] (got the repo_version and added dist_tree)
  2. remove dist_tree
  3. look (e.g. http GET) for repo version
AttributeError at /pulp/api/v3/repositories/rpm/rpm/6c56dc14-63f5-4ee1-ac1f-a542add7061a/versions/1/
'NoneType' object has no attribute 'cast'

[0] https://fixtures.pulpproject.org/rpm-distribution-tree/

Actions #1

Updated by ttereshc over 3 years ago

  • Triaged changed from No to Yes
  • Sprint set to Sprint 80
Actions #2

Updated by ppicka over 3 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to ppicka
Actions #3

Updated by rchan over 3 years ago

  • Sprint changed from Sprint 80 to Sprint 81
Actions #4

Updated by fao89 over 3 years ago

I'm not sure about the use case for pulp_rpm, but I believe it needs a fix at pulpcore side, we cannot call cast without assuring we have an object

Actions #5

Updated by ppicka over 3 years ago

That is true, but in the time it should be casted, pulp assume content is there and it should. We should not allow delete content when it is used in repository.

Actions #6

Updated by rchan over 3 years ago

  • Sprint changed from Sprint 81 to Sprint 82
Actions #7

Updated by pulpbot over 3 years ago

  • Status changed from ASSIGNED to POST
Actions #8

Updated by rchan over 3 years ago

  • Sprint changed from Sprint 82 to Sprint 83

Added by ppicka over 3 years ago

Revision 5fb7bee6 | View on GitHub

Comps and disttree removal

User should not be able to remove distribution trees and comps if they are used in repository. If they are not in repo they will be removed with orphan cleanup as other content.

closes: #7431 https://pulp.plan.io/issues/7431

Actions #9

Updated by ppicka over 3 years ago

  • Status changed from POST to MODIFIED
Actions #10

Updated by dalley over 3 years ago

  • Sprint/Milestone set to 3.8.0
Actions #11

Updated by pulpbot over 3 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Also available in: Atom PDF