github-backup 0.51.1__py3-none-any.whl → 0.51.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.
- github_backup/__init__.py +1 -1
- github_backup/github_backup.py +26 -15
- {github_backup-0.51.1.dist-info → github_backup-0.51.2.dist-info}/METADATA +1 -1
- github_backup-0.51.2.dist-info/RECORD +9 -0
- github_backup-0.51.1.dist-info/RECORD +0 -9
- {github_backup-0.51.1.data → github_backup-0.51.2.data}/scripts/github-backup +0 -0
- {github_backup-0.51.1.dist-info → github_backup-0.51.2.dist-info}/WHEEL +0 -0
- {github_backup-0.51.1.dist-info → github_backup-0.51.2.dist-info}/licenses/LICENSE.txt +0 -0
- {github_backup-0.51.1.dist-info → github_backup-0.51.2.dist-info}/top_level.txt +0 -0
- {github_backup-0.51.1.dist-info → github_backup-0.51.2.dist-info}/zip-safe +0 -0
github_backup/__init__.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "0.51.
|
|
1
|
+
__version__ = "0.51.2"
|
github_backup/github_backup.py
CHANGED
|
@@ -37,22 +37,33 @@ FNULL = open(os.devnull, "w")
|
|
|
37
37
|
FILE_URI_PREFIX = "file://"
|
|
38
38
|
logger = logging.getLogger(__name__)
|
|
39
39
|
|
|
40
|
+
# Setup SSL context with fallback chain
|
|
40
41
|
https_ctx = ssl.create_default_context()
|
|
41
|
-
if
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
)
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
42
|
+
if https_ctx.get_ca_certs():
|
|
43
|
+
# Layer 1: Certificates pre-loaded from system (file-based)
|
|
44
|
+
pass
|
|
45
|
+
else:
|
|
46
|
+
paths = ssl.get_default_verify_paths()
|
|
47
|
+
if (paths.cafile and os.path.exists(paths.cafile)) or (
|
|
48
|
+
paths.capath and os.path.exists(paths.capath)
|
|
49
|
+
):
|
|
50
|
+
# Layer 2: Cert paths exist, will be lazy-loaded on first use (directory-based)
|
|
51
|
+
pass
|
|
52
|
+
else:
|
|
53
|
+
# Layer 3: Try certifi package as optional fallback
|
|
54
|
+
try:
|
|
55
|
+
import certifi
|
|
56
|
+
|
|
57
|
+
https_ctx = ssl.create_default_context(cafile=certifi.where())
|
|
58
|
+
except ImportError:
|
|
59
|
+
# All layers failed - no certificates available anywhere
|
|
60
|
+
sys.exit(
|
|
61
|
+
"\nERROR: No CA certificates found. Cannot connect to GitHub over SSL.\n\n"
|
|
62
|
+
"Solutions you can explore:\n"
|
|
63
|
+
" 1. pip install certifi\n"
|
|
64
|
+
" 2. Alpine: apk add ca-certificates\n"
|
|
65
|
+
" 3. Debian/Ubuntu: apt-get install ca-certificates\n\n"
|
|
66
|
+
)
|
|
56
67
|
|
|
57
68
|
|
|
58
69
|
def logging_subprocess(
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
github_backup/__init__.py,sha256=2AuLzuHMBBPVOM-m0Woty11pTO9ExwPKWRWtj1LvS-g,23
|
|
2
|
+
github_backup/github_backup.py,sha256=ousskr9hBtfKgAh1x78vnSefQhPGqa9K2fLxWLUKdyY,75428
|
|
3
|
+
github_backup-0.51.2.data/scripts/github-backup,sha256=I79TNA67phytRmI9nm_LlD9h2zauXFOsOn9tYyAy9pU,1546
|
|
4
|
+
github_backup-0.51.2.dist-info/licenses/LICENSE.txt,sha256=ML-pLyn1qtAKo_DHMcQ8-p7k3f8cp-IR-mf5B49R2rk,1085
|
|
5
|
+
github_backup-0.51.2.dist-info/METADATA,sha256=zoLPP4sNYwAsnFUXTZR1K1NB5J-i2xQidc9DZ3hbkfk,21544
|
|
6
|
+
github_backup-0.51.2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
7
|
+
github_backup-0.51.2.dist-info/top_level.txt,sha256=Za6fKRAlxZ0b3ZBH_osPqklLe14LetdNAkvAQANT2AA,14
|
|
8
|
+
github_backup-0.51.2.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
|
|
9
|
+
github_backup-0.51.2.dist-info/RECORD,,
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
github_backup/__init__.py,sha256=1aQCHIs4QPNUtw_wChzJwhINvlLDSxS3S3qxxd-DKeU,23
|
|
2
|
-
github_backup/github_backup.py,sha256=2N0crWKzRfkb5ZOlI5pn2NRxSXOmApmdB68noATWAbk,74783
|
|
3
|
-
github_backup-0.51.1.data/scripts/github-backup,sha256=I79TNA67phytRmI9nm_LlD9h2zauXFOsOn9tYyAy9pU,1546
|
|
4
|
-
github_backup-0.51.1.dist-info/licenses/LICENSE.txt,sha256=ML-pLyn1qtAKo_DHMcQ8-p7k3f8cp-IR-mf5B49R2rk,1085
|
|
5
|
-
github_backup-0.51.1.dist-info/METADATA,sha256=rjm9_2D5ivEA1y9NUJhVbKA3C113jd0Jq3ATaGrvdhA,21544
|
|
6
|
-
github_backup-0.51.1.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
7
|
-
github_backup-0.51.1.dist-info/top_level.txt,sha256=Za6fKRAlxZ0b3ZBH_osPqklLe14LetdNAkvAQANT2AA,14
|
|
8
|
-
github_backup-0.51.1.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
|
|
9
|
-
github_backup-0.51.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|