pulpcore 3.83.0__py3-none-any.whl → 3.83.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pulpcore might be problematic. Click here for more details.
- pulp_certguard/app/__init__.py +1 -1
- pulp_file/app/__init__.py +1 -1
- pulpcore/app/apps.py +1 -1
- pulpcore/app/models/repository.py +48 -38
- {pulpcore-3.83.0.dist-info → pulpcore-3.83.2.dist-info}/METADATA +2 -1
- {pulpcore-3.83.0.dist-info → pulpcore-3.83.2.dist-info}/RECORD +10 -10
- {pulpcore-3.83.0.dist-info → pulpcore-3.83.2.dist-info}/WHEEL +0 -0
- {pulpcore-3.83.0.dist-info → pulpcore-3.83.2.dist-info}/entry_points.txt +0 -0
- {pulpcore-3.83.0.dist-info → pulpcore-3.83.2.dist-info}/licenses/LICENSE +0 -0
- {pulpcore-3.83.0.dist-info → pulpcore-3.83.2.dist-info}/top_level.txt +0 -0
pulp_certguard/app/__init__.py
CHANGED
pulp_file/app/__init__.py
CHANGED
pulpcore/app/apps.py
CHANGED
|
@@ -890,7 +890,15 @@ class RepositoryVersion(BaseModel):
|
|
|
890
890
|
if content_qs is None:
|
|
891
891
|
content_qs = Content.objects
|
|
892
892
|
|
|
893
|
-
|
|
893
|
+
content_ids = self._get_content_ids()
|
|
894
|
+
if isinstance(content_ids, list) and len(content_ids) >= 65535:
|
|
895
|
+
# Workaround for PostgreSQL's limit on the number of parameters in a query
|
|
896
|
+
content_ids = (
|
|
897
|
+
RepositoryVersion.objects.filter(pk=self.pk)
|
|
898
|
+
.annotate(cids=Func(F("content_ids"), function="unnest"))
|
|
899
|
+
.values_list("cids", flat=True)
|
|
900
|
+
)
|
|
901
|
+
return content_qs.filter(pk__in=content_ids)
|
|
894
902
|
|
|
895
903
|
@property
|
|
896
904
|
def content(self):
|
|
@@ -1056,28 +1064,29 @@ class RepositoryVersion(BaseModel):
|
|
|
1056
1064
|
)
|
|
1057
1065
|
repo_content = []
|
|
1058
1066
|
to_add = set(content.values_list("pk", flat=True)) - set(self._get_content_ids())
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1067
|
+
with transaction.atomic():
|
|
1068
|
+
if to_add:
|
|
1069
|
+
self.content_ids += list(to_add)
|
|
1070
|
+
self.save()
|
|
1071
|
+
|
|
1072
|
+
# Normalize representation if content has already been removed in this version and
|
|
1073
|
+
# is re-added: Undo removal by setting version_removed to None.
|
|
1074
|
+
for removed in batch_qs(self.removed().order_by("pk").values_list("pk", flat=True)):
|
|
1075
|
+
to_readd = to_add.intersection(set(removed))
|
|
1076
|
+
if to_readd:
|
|
1077
|
+
RepositoryContent.objects.filter(
|
|
1078
|
+
content__in=to_readd, repository=self.repository, version_removed=self
|
|
1079
|
+
).update(version_removed=None)
|
|
1080
|
+
to_add = to_add - to_readd
|
|
1081
|
+
|
|
1082
|
+
for content_pk in to_add:
|
|
1083
|
+
repo_content.append(
|
|
1084
|
+
RepositoryContent(
|
|
1085
|
+
repository=self.repository, content_id=content_pk, version_added=self
|
|
1086
|
+
)
|
|
1077
1087
|
)
|
|
1078
|
-
)
|
|
1079
1088
|
|
|
1080
|
-
|
|
1089
|
+
RepositoryContent.objects.bulk_create(repo_content)
|
|
1081
1090
|
|
|
1082
1091
|
def remove_content(self, content):
|
|
1083
1092
|
"""
|
|
@@ -1103,23 +1112,24 @@ class RepositoryVersion(BaseModel):
|
|
|
1103
1112
|
)
|
|
1104
1113
|
content_ids = set(self._get_content_ids())
|
|
1105
1114
|
to_remove = set(content.values_list("pk", flat=True))
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1115
|
+
with transaction.atomic():
|
|
1116
|
+
if to_remove:
|
|
1117
|
+
self.content_ids = list(content_ids - to_remove)
|
|
1118
|
+
self.save()
|
|
1119
|
+
|
|
1120
|
+
# Normalize representation if content has already been added in this version.
|
|
1121
|
+
# Undo addition by deleting the RepositoryContent.
|
|
1122
|
+
RepositoryContent.objects.filter(
|
|
1123
|
+
repository=self.repository,
|
|
1124
|
+
content_id__in=content,
|
|
1125
|
+
version_added=self,
|
|
1126
|
+
version_removed=None,
|
|
1127
|
+
).delete()
|
|
1128
|
+
|
|
1129
|
+
q_set = RepositoryContent.objects.filter(
|
|
1130
|
+
repository=self.repository, content_id__in=content, version_removed=None
|
|
1131
|
+
)
|
|
1132
|
+
q_set.update(version_removed=self)
|
|
1123
1133
|
|
|
1124
1134
|
def set_content(self, content):
|
|
1125
1135
|
"""
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pulpcore
|
|
3
|
-
Version: 3.83.
|
|
3
|
+
Version: 3.83.2
|
|
4
4
|
Summary: Pulp Django Application and Related Modules
|
|
5
5
|
Author-email: Pulp Team <pulp-list@redhat.com>
|
|
6
6
|
Project-URL: Homepage, https://pulpproject.org
|
|
@@ -70,6 +70,7 @@ Provides-Extra: google
|
|
|
70
70
|
Requires-Dist: django-storages[google]==1.14.6; extra == "google"
|
|
71
71
|
Provides-Extra: azure
|
|
72
72
|
Requires-Dist: django-storages[azure]==1.14.6; extra == "azure"
|
|
73
|
+
Requires-Dist: azure-storage-blob<12.26.0; extra == "azure"
|
|
73
74
|
Provides-Extra: prometheus
|
|
74
75
|
Requires-Dist: django-prometheus; extra == "prometheus"
|
|
75
76
|
Provides-Extra: kafka
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
pulp_certguard/__init__.py,sha256=llnEd00PrsAretsgAOHiNKFbmvIdXe3iDVPmSaKz7gU,71
|
|
2
2
|
pulp_certguard/pytest_plugin.py,sha256=qhRbChzqN2PROtD-65KuoTfKr5k9T3GPsz9daFgpqpM,852
|
|
3
|
-
pulp_certguard/app/__init__.py,sha256=
|
|
3
|
+
pulp_certguard/app/__init__.py,sha256=q9BSOu9bxBFz2EoNH9L_oph1rcPNOYSNvwAouUImbWY,297
|
|
4
4
|
pulp_certguard/app/models.py,sha256=xy5IWxf0LQxayIDmQw25Y2YhB_NrlTGvuvdY-YW7QBU,8119
|
|
5
5
|
pulp_certguard/app/serializers.py,sha256=3jxWu82vU3xA578Qbyz-G4Q9Zlh3MFLGRHzX62M0RF8,1826
|
|
6
6
|
pulp_certguard/app/utils.py,sha256=O6T1Npdb8fu3XqIkDJd8PQdEFJWPUeQ-i_aHXBl7MEc,816
|
|
@@ -49,7 +49,7 @@ pulp_certguard/tests/unit/test_models.py,sha256=TBI0yKsrdbnJSPeBFfxSqhXK7zaNvR6q
|
|
|
49
49
|
pulp_file/__init__.py,sha256=0vOCXofR6Eyxkg4y66esnOGPeESCe23C1cNBHj56w44,61
|
|
50
50
|
pulp_file/manifest.py,sha256=1WwIOJrPSkFcmkRm7CkWifVOCoZvo_nnANgce6uuG7U,3796
|
|
51
51
|
pulp_file/pytest_plugin.py,sha256=l1PvTxUi5D3uJy4SnHWNhr-otWEYNcm-kc5nSqVJg0Y,10646
|
|
52
|
-
pulp_file/app/__init__.py,sha256=
|
|
52
|
+
pulp_file/app/__init__.py,sha256=nv2sVGVXrrjtJVhGD7V6U-BMZdHADYNAgnjYQqY5xmE,292
|
|
53
53
|
pulp_file/app/modelresource.py,sha256=v-m-_bBEsfr8wG0TI5ffx1TuKUy2-PsirhuQz4XXF-0,1063
|
|
54
54
|
pulp_file/app/models.py,sha256=QsrVg_2uKqnR89sLN2Y7Zy260_nLIcUfa94uZowlmFw,4571
|
|
55
55
|
pulp_file/app/replica.py,sha256=OtNWVmdFUgNTYhPttftVNQnSrnvx2_hnrJgtW_G0Vrg,1894
|
|
@@ -110,7 +110,7 @@ pulpcore/pytest_plugin.py,sha256=skubiEUIevVURr4LnmmVMt_ZeH5vT9mI0yiPUYerMnQ,380
|
|
|
110
110
|
pulpcore/responses.py,sha256=mIGKmdCfTSoZxbFu4yIH1xbdLx1u5gqt3D99LTamcJg,6125
|
|
111
111
|
pulpcore/app/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
112
112
|
pulpcore/app/access_policy.py,sha256=5vCKy6WoHtIt1_-eS5vMaZ7CmR4G-CIpsrB8yT-d88Q,6079
|
|
113
|
-
pulpcore/app/apps.py,sha256=
|
|
113
|
+
pulpcore/app/apps.py,sha256=CqrQ8sW9sFLntd8_iPC7g0rBVWDnUa2aHc-zSdBRXrs,17860
|
|
114
114
|
pulpcore/app/authentication.py,sha256=1LIJW6HIQQlZrliHy__jdzkDEh6Oj7xKgd0V-vRcDus,2855
|
|
115
115
|
pulpcore/app/checks.py,sha256=jbfTF7nmftBbky4AQXHigpyCaGydKasvRUXsd72JZVg,1946
|
|
116
116
|
pulpcore/app/entrypoint.py,sha256=YIfQpM5UxybBTasiEY5ptq--UmqPqjdIGnwmqVsDC7E,4972
|
|
@@ -302,7 +302,7 @@ pulpcore/app/models/openpgp.py,sha256=3R5p8ZBPq63NzaE2_EwCXEMYPUQu7QUWanMcKCOoWk
|
|
|
302
302
|
pulpcore/app/models/progress.py,sha256=osD0cqPWC5oaebKgjpaOLY6tgv1bpjA66ty7nr8TaLU,13499
|
|
303
303
|
pulpcore/app/models/publication.py,sha256=Ltiwylew7OOrobQRjdy1p6NbppBMXD2uX_IC2Ybgl7E,28869
|
|
304
304
|
pulpcore/app/models/replica.py,sha256=i_wPxyPaVWpEVTJNVjJsBarxFauqeagtuwLadsmVz-g,2067
|
|
305
|
-
pulpcore/app/models/repository.py,sha256=
|
|
305
|
+
pulpcore/app/models/repository.py,sha256=SIc21Gex6okxI7OCfHEGIpXpGlypG3z9IgMt5-mkNy0,58056
|
|
306
306
|
pulpcore/app/models/role.py,sha256=dZklNd2VeAw4cT6dyJ7SyTBt9sZvdqakY86wXGAY3vU,3287
|
|
307
307
|
pulpcore/app/models/status.py,sha256=72oUOJ7BnCAw3uDbc-XuI72oAyP2llCoBic4zb2JP78,3683
|
|
308
308
|
pulpcore/app/models/storage.py,sha256=2b-DQWaO31NqjV6FiISALegND-sQZAU7BVAsduUvm3o,6780
|
|
@@ -532,9 +532,9 @@ pulpcore/tests/unit/stages/test_artifactdownloader.py,sha256=qB1ANdFmNtUnljg8fCd
|
|
|
532
532
|
pulpcore/tests/unit/stages/test_stages.py,sha256=H1a2BQLjdZlZvcb_qULp62huZ1xy6ItTcthktVyGU0w,4735
|
|
533
533
|
pulpcore/tests/unit/viewsets/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
534
534
|
pulpcore/tests/unit/viewsets/test_viewset_base.py,sha256=W9o3V6758bZctR6krMPPQytb0xJuF-jb4uBWTNDoD_U,4837
|
|
535
|
-
pulpcore-3.83.
|
|
536
|
-
pulpcore-3.83.
|
|
537
|
-
pulpcore-3.83.
|
|
538
|
-
pulpcore-3.83.
|
|
539
|
-
pulpcore-3.83.
|
|
540
|
-
pulpcore-3.83.
|
|
535
|
+
pulpcore-3.83.2.dist-info/licenses/LICENSE,sha256=dhnHU8rJXUdAIgIjveSKAyYG_KzN5eVG-bxETIGrNW0,17988
|
|
536
|
+
pulpcore-3.83.2.dist-info/METADATA,sha256=H7p6-06DVRkFtXi_V7p_I7e5rxAxhQ8ABdy6o4IF3Hg,4380
|
|
537
|
+
pulpcore-3.83.2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
538
|
+
pulpcore-3.83.2.dist-info/entry_points.txt,sha256=OZven4wzXzQA5b5q9MpP4HUpIPPQCSvIOvkKtNInrK0,452
|
|
539
|
+
pulpcore-3.83.2.dist-info/top_level.txt,sha256=6h-Lm3FKQSaT_nL1KSxu_hBnzKE15bcvf_BoU-ea4CI,34
|
|
540
|
+
pulpcore-3.83.2.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|