mirror of
https://github.com/EDCD/EDMarketConnector.git
synced 2026-11-12 02:22:42 +03:00
Fix version check on Windows
This commit is contained in:
1 parent
73e36ba2c6
commit
dd2bdd15f6
1 file changed
+4
-1
@@ -7,7 +7,8 @@ import argparse
|
||||
import json
|
||||
import requests
|
||||
import sys
|
||||
from os.path import getmtime
|
||||
import os
|
||||
from os.path import dirname, getmtime, join
|
||||
from time import time, sleep
|
||||
from xml.etree import ElementTree
|
||||
|
||||
@@ -58,6 +59,8 @@ try:
|
||||
if args.version:
|
||||
latest = ''
|
||||
try:
|
||||
if sys.platform=='win32' and getattr(sys, 'frozen', False):
|
||||
os.environ['REQUESTS_CA_BUNDLE'] = join(dirname(sys.executable), 'cacert.pem')
|
||||
# Copied from update.py - probably should refactor
|
||||
r = requests.get(update_feed, timeout = 10)
|
||||
feed = ElementTree.fromstring(r.text)
|
||||
|
||||
Reference in new issue
Block a user