MCPcopy Create free account
hub / github.com/FastLED/FastLED / _clear_linked_output

Function _clear_linked_output

ci/wasm_build.py:1577–1589  ·  view source on GitHub ↗

Remove stale linked artifacts after a hard link failure.

(sketch_cache_dir: Path, output_js: Path)

Source from the content-addressed store, hash-verified

1575
1576
1577def _clear_linked_output(sketch_cache_dir: Path, output_js: Path) -> None:
1578 """Remove stale linked artifacts after a hard link failure."""
1579 output_dir = output_js.parent
1580 stale_paths = [
1581 sketch_cache_dir / "fastled.js",
1582 sketch_cache_dir / "fastled.wasm",
1583 sketch_cache_dir / "fastled.wasm.dwarf",
1584 output_js,
1585 output_js.with_suffix(".wasm"),
1586 output_dir / "fastled.wasm.dwarf",
1587 ]
1588 for path in stale_paths:
1589 path.unlink(missing_ok=True)
1590
1591
1592def _copy_from_dist(dist_dir: Path, output_dir: Path) -> None:

Callers 1

link_wasmFunction · 0.85

Calls 1

unlinkMethod · 0.80

Tested by

no test coverage detected