File tree Expand file tree Collapse file tree 2 files changed +1
-12
lines changed Expand file tree Collapse file tree 2 files changed +1
-12
lines changed Original file line number Diff line number Diff line change 11#!/usr/bin/env python
22# -*- coding: utf-8 -*-
33
4- # you may use "NODE" in settings.py to specify a custom node binary, and you may use NODE_PATH in settings.py
5- # to specify a custom node_modules path (that has the necessary node modules mathjax-node, ...).
6- #
74# Your installation of nodejs with the following packages: mathjax-node svg2png (install them using
85# npm).
96
1512from subprocess import Popen
1613import os
1714
18- from mathics import settings
19-
2015import socket
2116import json
2217import struct
@@ -116,8 +111,6 @@ def __init__(self):
116111 def _create_client (self ):
117112 try :
118113 popen_env = os .environ .copy ()
119- if settings .NODE_MODULES :
120- popen_env ["NODE_PATH" ] = os .path .expandvars (settings .NODE_MODULES )
121114
122115 server_path = os .path .join (
123116 os .path .dirname (os .path .realpath (__file__ )), 'server.js' )
@@ -127,7 +120,7 @@ def abort(message):
127120 raise WebEngineUnavailable (error_text + message )
128121
129122 process = Popen (
130- [os . path . expandvars ( settings . NODE ) , server_path ],
123+ ['node' , server_path ],
131124 stdout = subprocess .PIPE ,
132125 env = popen_env )
133126
Original file line number Diff line number Diff line change 1313DEBUG = True
1414TEMPLATE_DEBUG = DEBUG
1515
16- # node.js based layout engine
17- NODE = 'node' # path to node binary; default 'node' assumes it is in PATH
18- NODE_MODULES = None # overrides NODE_PATH environment variable if not None
19-
2016# set only to True in DEBUG mode
2117DEBUG_MAIL = True
2218PROPAGATE_EXCEPTIONS = True
You can’t perform that action at this time.
0 commit comments