qontract-reconcile 0.10.2.dev26__py3-none-any.whl → 0.10.2.dev27__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: qontract-reconcile
3
- Version: 0.10.2.dev26
3
+ Version: 0.10.2.dev27
4
4
  Summary: Collection of tools to reconcile services with their desired state as defined in the app-interface DB.
5
5
  Project-URL: homepage, https://github.com/app-sre/qontract-reconcile
6
6
  Project-URL: repository, https://github.com/app-sre/qontract-reconcile
@@ -580,7 +580,7 @@ reconcile/utils/external_resource_spec.py,sha256=bhH_xneFwATdFumTPkiQmcVKYI0gcaW
580
580
  reconcile/utils/external_resources.py,sha256=YzTb0xAcNdmKO326mGQy7BmST56CZcdru4lX7ai_7kw,7579
581
581
  reconcile/utils/filtering.py,sha256=S4PbMHuFr3ED0P2Q_ea5CAaB7FimI62B-F5YTaKrphA,402
582
582
  reconcile/utils/git.py,sha256=wzVIYAeKlMGW538U1mkJWUI6h_mFRUY4lawh2AR8hw4,2345
583
- reconcile/utils/github_api.py,sha256=oMInVIga9OITL7l5EWzs4lGXK0xAYhUznhjgXKjmmA0,2492
583
+ reconcile/utils/github_api.py,sha256=y3fxty7FKvfhdzfHgGSaIstL6A_Y2loUcMiyIK5TMDg,2750
584
584
  reconcile/utils/gitlab_api.py,sha256=SR0graae7UBZyLLKA7yGsOqKm7dXFe5cexcaa1SokQo,28486
585
585
  reconcile/utils/gpg.py,sha256=EKG7_fdMv8BMlV5yUdPiqoTx-KrzmVSEAl2sLkaKwWI,1123
586
586
  reconcile/utils/gql.py,sha256=C0thIm_k9MBldfqwHzyqtYZk9sIvMdm9IbbnXLGwjD8,14158
@@ -766,7 +766,7 @@ tools/saas_promotion_state/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJ
766
766
  tools/saas_promotion_state/saas_promotion_state.py,sha256=UfwwRLS5Ya4_Nh1w5n1dvoYtchQvYE9yj1VANt2IKqI,3925
767
767
  tools/sre_checkpoints/__init__.py,sha256=CDaDaywJnmRCLyl_NCcvxi-Zc0hTi_3OdwKiFOyS39I,145
768
768
  tools/sre_checkpoints/util.py,sha256=zEDbGr18ZeHNQwW8pUsr2JRjuXIPz--WAGJxZo9sv_Y,894
769
- qontract_reconcile-0.10.2.dev26.dist-info/METADATA,sha256=FQlxMkY263vqg5hREv8fhSw-0OGZW--vx-icJvxLaZM,24665
770
- qontract_reconcile-0.10.2.dev26.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
771
- qontract_reconcile-0.10.2.dev26.dist-info/entry_points.txt,sha256=JniHZPadNOILPyfSl0LF2YSp3Db7K2_W2CN7i9f3Gos,540
772
- qontract_reconcile-0.10.2.dev26.dist-info/RECORD,,
769
+ qontract_reconcile-0.10.2.dev27.dist-info/METADATA,sha256=Nr3x_-2IN6jO8C6UVvoDJmObBt8_Y6OZ54Ok0UsHikA,24665
770
+ qontract_reconcile-0.10.2.dev27.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
771
+ qontract_reconcile-0.10.2.dev27.dist-info/entry_points.txt,sha256=JniHZPadNOILPyfSl0LF2YSp3Db7K2_W2CN7i9f3Gos,540
772
+ qontract_reconcile-0.10.2.dev27.dist-info/RECORD,,
@@ -3,11 +3,7 @@ from pathlib import Path
3
3
  from types import TracebackType
4
4
  from urllib.parse import urlparse
5
5
 
6
- from github import (
7
- Commit,
8
- Github,
9
- UnknownObjectException,
10
- )
6
+ from github import Commit, Github, GithubException, UnknownObjectException
11
7
  from sretoolbox.utils import retry
12
8
 
13
9
  GH_BASE_URL = os.environ.get("GITHUB_API", "https://api.github.com")
@@ -75,6 +71,13 @@ class GithubRepositoryApi:
75
71
  # -> for now staying backwards compatible
76
72
  return None
77
73
  return content.decoded_content
74
+ except GithubException as e:
75
+ # handling a bug in the upstream GH library
76
+ # https://github.com/PyGithub/PyGithub/issues/3179
77
+ if e.status == 404:
78
+ return None
79
+ else:
80
+ raise e
78
81
  except UnknownObjectException:
79
82
  return None
80
83