mirror of
https://github.com/koush/scrypted.git
synced 2026-04-26 18:00:21 +01:00
server: normalize fs path
This commit is contained in:
@@ -96,7 +96,10 @@ export class PythonRuntimeWorker extends ChildProcessWorker {
|
||||
const setup = () => {
|
||||
const types = require.resolve('@scrypted/types');
|
||||
const PYTHONPATH = types.substring(0, types.indexOf('types') + 'types'.length);
|
||||
const fsDir = path.join(options.unzippedPath, 'fs');
|
||||
fs.mkdirSync(fsDir, { recursive: true });
|
||||
this.worker = child_process.spawn(pythonPath, args, {
|
||||
cwd: fsDir,
|
||||
// stdin, stdout, stderr, peer in, peer out
|
||||
stdio: ['pipe', 'pipe', 'pipe', 'pipe', 'pipe'],
|
||||
env: Object.assign({
|
||||
|
||||
Reference in New Issue
Block a user