Skip to content

Commit 892abb6

Browse files
Separate initiating python phases for xeus-python
1 parent 0213cb4 commit 892abb6

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

include/pyjs/pre_js/load_pkg.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -321,3 +321,17 @@ Module["bootstrap_from_empack_packed_environment"] = async function
321321
console.error(e);
322322
}
323323
}
324+
325+
Module["init_python_phases"] = async function (
326+
python_version = [3,11],
327+
prefix,
328+
verbose = true
329+
)
330+
{
331+
if(verbose) {
332+
console.log('Turn on support for running python code for xeus-python');
333+
}
334+
if(verbose){console.log("start init_phase_1");}
335+
await Module.init_phase_1(prefix, python_version, verbose);
336+
Module.init_phase_2(prefix, python_version, verbose);
337+
}

0 commit comments

Comments
 (0)