Commit 0362d2c2 authored by Floreal Cabanettes's avatar Floreal Cabanettes
Browse files

Fix for pyinstaller

parent 9f6df81e
......@@ -33,8 +33,9 @@ def launch(mode="webserver", debug=False):
# Init Flask:
if getattr(sys, 'frozen', False):
template_folder = os.path.join(sys._MEIPASS, 'templates')
app = Flask(__name__, template_folder=template_folder, static_url_path='/static')
template_folder = os.path.join(sys.executable, '..', 'templates')
static_folder = os.path.join(sys.executable, '..', 'static')
app = Flask(__name__, template_folder=template_folder, static_folder=static_folder)
app = Flask(__name__, static_url_path='/static')
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment