mirror of
https://github.com/blw1138/Zordon.git
synced 2025-12-19 17:58:12 +00:00
Pyinstaller support (#93)
* Add main.spec * Fix issue where fetching supported extensions would crash with no default installation
This commit is contained in:
@@ -9,12 +9,11 @@ SUBPROCESS_TIMEOUT = 5
|
||||
class BaseRenderEngine(object):
|
||||
|
||||
install_paths = []
|
||||
supported_extensions = []
|
||||
|
||||
def __init__(self, custom_path=None):
|
||||
self.custom_renderer_path = custom_path
|
||||
if not self.renderer_path() or not os.path.exists(self.renderer_path()):
|
||||
raise FileNotFoundError(f"Cannot find path to renderer for {self.name()} instance")
|
||||
raise FileNotFoundError(f"Cannot find path to renderer for {self.name()} instance: {self.renderer_path()}")
|
||||
|
||||
if not os.access(self.renderer_path(), os.X_OK):
|
||||
logger.warning(f"Path is not executable. Setting permissions to 755 for {self.renderer_path()}")
|
||||
@@ -43,6 +42,9 @@ class BaseRenderEngine(object):
|
||||
def version(self):
|
||||
raise NotImplementedError("version not implemented")
|
||||
|
||||
def supported_extensions(self):
|
||||
return []
|
||||
|
||||
@staticmethod
|
||||
def downloader(): # override when subclassing if using a downloader class
|
||||
return None
|
||||
@@ -51,7 +53,8 @@ class BaseRenderEngine(object):
|
||||
def worker_class(): # override when subclassing to link worker class
|
||||
raise NotImplementedError("Worker class not implemented")
|
||||
|
||||
def ui_options(self): # override to return options for ui
|
||||
@staticmethod
|
||||
def ui_options(system_info): # override to return options for ui
|
||||
return {}
|
||||
|
||||
def get_help(self): # override if renderer uses different help flag
|
||||
|
||||
Reference in New Issue
Block a user