changed indentation from tabs to spaces

This commit is contained in:
2021-09-22 09:17:12 -05:00
parent 5c02a67ac7
commit 4bdba42eab
129 changed files with 9224 additions and 9230 deletions

View File

@@ -8,7 +8,7 @@ from . import fix_win32com
from . import fix_libloader
def setup():
fix_requests.fix()
# if hasattr(sys, "frozen"):
fix_libloader.fix()
fix_win32com.fix()
fix_requests.fix()
# if hasattr(sys, "frozen"):
fix_libloader.fix()
fix_win32com.fix()

View File

@@ -12,25 +12,25 @@ from libloader import com
fixed=False
def patched_getmodule(modname):
mod=__import__(modname)
return sys.modules[modname]
mod=__import__(modname)
return sys.modules[modname]
def load_com(*names):
global fixed
if fixed==False:
gencache._GetModule=patched_getmodule
com.prepare_gencache()
fixed=True
result = None
for name in names:
try:
result = gencache.EnsureDispatch(name)
break
except com_error:
continue
if result is None:
raise com_error("Unable to load any of the provided com objects.")
return result
global fixed
if fixed==False:
gencache._GetModule=patched_getmodule
com.prepare_gencache()
fixed=True
result = None
for name in names:
try:
result = gencache.EnsureDispatch(name)
break
except com_error:
continue
if result is None:
raise com_error("Unable to load any of the provided com objects.")
return result
def fix():
com.load_com = load_com
com.load_com = load_com

View File

@@ -7,6 +7,6 @@ import logging
log = logging.getLogger("fixes.fix_requests")
def fix():
log.debug("Applying fix for requests...")
os.environ["REQUESTS_CA_BUNDLE"] = os.path.join(paths.app_path(), "cacert.pem")#.encode(paths.fsencoding)
# log.debug("Changed CA path to %s" % (os.environ["REQUESTS_CA_BUNDLE"]))#.decode(paths.fsencoding)))
log.debug("Applying fix for requests...")
os.environ["REQUESTS_CA_BUNDLE"] = os.path.join(paths.app_path(), "cacert.pem")#.encode(paths.fsencoding)
# log.debug("Changed CA path to %s" % (os.environ["REQUESTS_CA_BUNDLE"]))#.decode(paths.fsencoding)))

View File

@@ -1,6 +1,6 @@
from __future__ import unicode_literals
import win32com.client
def fix():
if win32com.client.gencache.is_readonly == True:
win32com.client.gencache.is_readonly = False
win32com.client.gencache.Rebuild()
if win32com.client.gencache.is_readonly == True:
win32com.client.gencache.is_readonly = False
win32com.client.gencache.Rebuild()