Skip to content

Commit fa64593

Browse files
Update to new empack mount points (#104)
* Update to new empack mount points * Promise.ALL * fix * undo wrong "fix" * Fix possible undefined mounts * Stupide hobbit joufflu --------- Co-authored-by: Thorsten Beier <[email protected]>
1 parent c5e724d commit fa64593

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

include/pyjs/pre_js/load_pkg.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,7 @@ Module["bootstrap_from_empack_packed_environment"] = async function
260260
// fetch json with list of all packages
261261
let empack_env_meta = await fetchJson(packages_json_url);
262262
let all_packages = empack_env_meta.packages;
263+
let all_mount_points = empack_env_meta.mounts || [];
263264
let prefix = empack_env_meta.prefix;
264265

265266
if(verbose){
@@ -285,7 +286,10 @@ Module["bootstrap_from_empack_packed_environment"] = async function
285286
if(verbose){
286287
console.log("fetchAndUntarAll");
287288
}
288-
let shared_libs = await Promise.all(packages.map(pkg => fetchAndUntar(package_tarballs_root_url, python_is_ready_promise, pkg, verbose)));
289+
let shared_libs = await Promise.all([
290+
...packages.map(pkg => fetchAndUntar(package_tarballs_root_url, python_is_ready_promise, pkg, verbose)),
291+
...all_mount_points.map(pkg => fetchAndUntar(package_tarballs_root_url, python_is_ready_promise, pkg, verbose))
292+
]);
289293

290294
if(verbose){
291295
console.log("init_phase_2");

0 commit comments

Comments
 (0)