Skip to content

Commit

Permalink
Swap http for urllib package
Browse files Browse the repository at this point in the history
Fix #12
  • Loading branch information
Setsugennoao committed May 15, 2024
1 parent e3af221 commit 6b75cbe
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions vsjet/init.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,9 @@ def _get_uninstall_call(package: str) -> int:
return 1

def _get_jet_packages() -> Iterator[tuple[str, str]]:
from http.client import HTTPSConnection
from urllib.request import urlopen

conn = HTTPSConnection('raw.githubusercontent.com', 443)
conn.request(
'GET', f'https://raw.githubusercontent.com/{base_user}'
'/vs-jet/master/requirements.txt'
)

res = conn.getresponse()
res = urlopen(f'https://raw.githubusercontent.com/{base_user}/vs-jet/master/requirements.txt')

for line in res.readlines():
if b'#' in line:
Expand Down

0 comments on commit 6b75cbe

Please sign in to comment.