This repository was archived by the owner on Jun 13, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 6 files changed +13
-6
lines changed Expand file tree Collapse file tree 6 files changed +13
-6
lines changed Original file line number Diff line number Diff line change 1- 25.1.3
1+ 25.1.10
Original file line number Diff line number Diff line change 395395)
396396
397397SHELTER_SHARED_SECRET = get_config ("setup" , "shelter_shared_secret" , default = None )
398+ SHELTER_ENABLED = get_config ("setup" , "shelter_enabled" , default = True )
398399
399400SENTRY_ENV = os .environ .get ("CODECOV_ENV" , False )
400401SENTRY_DSN = os .environ .get ("SERVICES__SENTRY__SERVER_DSN" , None )
Original file line number Diff line number Diff line change 7272]
7373
7474GUEST_ACCESS = get_config ("setup" , "guest_access" , default = True )
75+
76+ SHELTER_ENABLED = get_config ("setup" , "shelter_enabled" , default = False )
Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ freezegun
2626google-cloud-pubsub
2727gunicorn>=22.0.0
2828https://github.com/codecov/opentelem-python/archive/refs/tags/v0.0.4a1.tar.gz#egg=codecovopentelem
29- https://github.com/codecov/shared/archive/c1c9cb24639157fd903e40799c7d364481f42ef7 .tar.gz#egg=shared
29+ https://github.com/codecov/shared/archive/a03c2f987b1f317f0372aa844cebd6b8d207a1f9 .tar.gz#egg=shared
3030https://github.com/photocrowd/django-cursor-pagination/archive/f560902696b0c8509e4d95c10ba0d62700181d84.tar.gz
3131idna>=3.7
3232minio
Original file line number Diff line number Diff line change @@ -202,8 +202,6 @@ googleapis-common-protos[grpc]==1.59.1
202202 # grpcio-status
203203graphql-core == 3.2.3
204204 # via ariadne
205- greenlet == 3.1.1
206- # via sqlalchemy
207205grpc-google-iam-v1 == 0.12.6
208206 # via google-cloud-pubsub
209207grpcio == 1.62.1
@@ -314,7 +312,7 @@ prometheus-client==0.17.1
314312 # shared
315313prompt-toolkit == 3.0.28
316314 # via click-repl
317- proto-plus == 1.22.3
315+ proto-plus == 1.25.0
318316 # via
319317 # google-api-core
320318 # google-cloud-pubsub
@@ -418,7 +416,7 @@ sentry-sdk[celery]==2.13.0
418416 # shared
419417setproctitle == 1.1.10
420418 # via -r requirements.in
421- shared @ https://github.com/codecov/shared/archive/c1c9cb24639157fd903e40799c7d364481f42ef7 .tar.gz
419+ shared @ https://github.com/codecov/shared/archive/a03c2f987b1f317f0372aa844cebd6b8d207a1f9 .tar.gz
422420 # via -r requirements.in
423421simplejson == 3.17.2
424422 # via -r requirements.in
Original file line number Diff line number Diff line change @@ -23,6 +23,9 @@ def get_instance(cls) -> "ShelterPubsub":
2323 return cls ._instance
2424
2525 def __init__ (self ) -> None :
26+ if not settings .SHELTER_ENABLED :
27+ return
28+
2629 if not self .pubsub_publisher :
2730 self .pubsub_publisher = pubsub_v1 .PublisherClient ()
2831 pubsub_project_id : str = settings .SHELTER_PUBSUB_PROJECT_ID
@@ -32,6 +35,9 @@ def __init__(self) -> None:
3235 self .topic_path = self .pubsub_publisher .topic_path (pubsub_project_id , topic_id )
3336
3437 def publish (self , data : Dict [str , Any ]) -> None :
38+ if not settings .SHELTER_ENABLED :
39+ return
40+
3541 try :
3642 self .pubsub_publisher .publish (
3743 self .topic_path ,
You can’t perform that action at this time.
0 commit comments