Skip to content

Commit

Permalink
no not copy wasm
Browse files Browse the repository at this point in the history
  • Loading branch information
DerThorsten committed Nov 13, 2023
1 parent 2f21a78 commit 092a4c9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
14 changes: 8 additions & 6 deletions lite/jupyterlite_xeus_python/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,7 @@ def build_and_pack_emscripten_env( # noqa: C901, PLR0912, PLR0915
build_worker: bool = False,
force: bool = False,
log=None,
extension_mode: bool = False,
):
"""Build a conda environment for the emscripten platform and pack it with empack."""
if packages is None:
Expand Down Expand Up @@ -344,11 +345,12 @@ def build_and_pack_emscripten_env( # noqa: C901, PLR0912, PLR0915
)

# Copy xeus-python output
for file in ["xpython_wasm.js", "xpython_wasm.wasm"]:
if not XEUS_PYTHON_LOCAL_BUILD:
shutil.copyfile(prefix_path / "bin" / file, Path(output_path) / file)
else:
shutil.copyfile(XEUS_PYTHON_BUILD_DIR / file, Path(output_path) / file)
if not extension_mode:
for file in ["xpython_wasm.js", "xpython_wasm.wasm"]:
if not XEUS_PYTHON_LOCAL_BUILD:
shutil.copyfile(prefix_path / "bin" / file, Path(output_path) / file)
else:
shutil.copyfile(XEUS_PYTHON_BUILD_DIR / file, Path(output_path) / file)

# Copy worker code and process it
if build_worker:
Expand Down Expand Up @@ -448,4 +450,4 @@ def start():
if __name__ == "__main__":
# raise NotImplementedError()
build_all()
raise NotImplementedError()
#raise NotImplementedError()
1 change: 1 addition & 0 deletions lite/jupyterlite_xeus_python/env_build_addon.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ def post_build(self, manager):
empack_config=self.empack_config,
output_path=self.cwd.name,
log=self.log,
extension_mode=True,
)

# Find the federated extensions in the emscripten-env and install them
Expand Down

0 comments on commit 092a4c9

Please sign in to comment.