Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions src/pubtools/_pulp/tasks/copy_repo.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,11 +148,14 @@ def str_to_content_type(content_type_id):
# criteria for all non-rpm content types
# unit_fields are ignored as they are small in size and the repos have
# small unit counts for non-rpm content types
criteria.append(
Criteria.with_field(
"content_type_id", Matcher.in_(sorted(non_rpm_content_types))
if non_rpm_content_types:
# type_id filter with empty list includes all the content types.
# hence, check for the presence of non-rpm content types.
criteria.append(
Criteria.with_field(
"content_type_id", Matcher.in_(sorted(non_rpm_content_types))
)
)
)

# criteria for rpm content types
# unit_fields to keep a check on memory consumption with large rpm unit
Expand Down
Loading