ggcode 1.3.67__tar.gz → 1.3.69__tar.gz
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.
- {ggcode-1.3.67 → ggcode-1.3.69}/PKG-INFO +1 -1
- {ggcode-1.3.67 → ggcode-1.3.69}/ggcode.egg-info/PKG-INFO +1 -1
- ggcode-1.3.69/ggcode_release_installer/__init__.py +1 -0
- {ggcode-1.3.67 → ggcode-1.3.69}/ggcode_release_installer/cli.py +1 -10
- {ggcode-1.3.67 → ggcode-1.3.69}/pyproject.toml +1 -1
- {ggcode-1.3.67 → ggcode-1.3.69}/tests/test_cli.py +6 -0
- ggcode-1.3.67/ggcode_release_installer/__init__.py +0 -1
- {ggcode-1.3.67 → ggcode-1.3.69}/README.md +0 -0
- {ggcode-1.3.67 → ggcode-1.3.69}/ggcode.egg-info/SOURCES.txt +0 -0
- {ggcode-1.3.67 → ggcode-1.3.69}/ggcode.egg-info/dependency_links.txt +0 -0
- {ggcode-1.3.67 → ggcode-1.3.69}/ggcode.egg-info/entry_points.txt +0 -0
- {ggcode-1.3.67 → ggcode-1.3.69}/ggcode.egg-info/top_level.txt +0 -0
- {ggcode-1.3.67 → ggcode-1.3.69}/setup.cfg +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "1.3.69"
|
|
@@ -10,7 +10,6 @@ import shutil
|
|
|
10
10
|
import stat
|
|
11
11
|
import subprocess
|
|
12
12
|
import sys
|
|
13
|
-
import ssl
|
|
14
13
|
import tarfile
|
|
15
14
|
import tempfile
|
|
16
15
|
import urllib.parse
|
|
@@ -87,16 +86,8 @@ def metadata_path(directory: Path) -> Path:
|
|
|
87
86
|
return directory / METADATA
|
|
88
87
|
|
|
89
88
|
|
|
90
|
-
def _build_ssl_context() -> ssl.SSLContext:
|
|
91
|
-
ctx = ssl.create_default_context()
|
|
92
|
-
ctx.check_hostname = False
|
|
93
|
-
ctx.verify_mode = ssl.CERT_NONE
|
|
94
|
-
return ctx
|
|
95
|
-
|
|
96
|
-
|
|
97
89
|
def _urlopen(url: str) -> object:
|
|
98
|
-
|
|
99
|
-
return urllib.request.urlopen(url, context=ctx)
|
|
90
|
+
return urllib.request.urlopen(url)
|
|
100
91
|
|
|
101
92
|
|
|
102
93
|
def download(url: str) -> bytes:
|
|
@@ -30,6 +30,12 @@ class ResolveTargetTests(unittest.TestCase):
|
|
|
30
30
|
with patch.object(cli.platform, "machine", return_value=""):
|
|
31
31
|
self.assertEqual(cli.resolve_target(), ("windows", "x86_64"))
|
|
32
32
|
|
|
33
|
+
def test_urlopen_uses_default_tls_verification(self) -> None:
|
|
34
|
+
response = unittest.mock.Mock()
|
|
35
|
+
with patch.object(cli.urllib.request, "urlopen", return_value=response) as mocked:
|
|
36
|
+
self.assertIs(cli._urlopen("https://github.com/topcheer/ggcode"), response)
|
|
37
|
+
mocked.assert_called_once_with("https://github.com/topcheer/ggcode")
|
|
38
|
+
|
|
33
39
|
def test_resolve_release_version_follows_latest_redirect(self) -> None:
|
|
34
40
|
response = unittest.mock.Mock()
|
|
35
41
|
response.geturl.return_value = "https://github.com/topcheer/ggcode/releases/tag/v9.9.9"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "1.1.20"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|