Repository navigation
Closed
Description
Summary
Sweeping audit found ~10 items of orphaned source files, build scripts, and
empty directories that survived the Rust-migration and Docker-purge (#55)
refactors. None are referenced by any live code path or workflow. Removing
them reduces noise and prevents future confusion.
Verified by grepping for inbound references across *.py, *.rs, *.toml,
*.yml, *.sh, *.md, and Cargo.toml. Excluded .venv/ and
.claude/worktrees/ from the grep.
HIGH confidence — orphan Python modules
src/fastled/cli_test_interactive.py— zero inbound imports. Manual
interactive test script added in commit 41b6206. Hardcoded paths
(../fastled,examples/FxWave2d) suggest a dev-only convenience that
was never wired into the test suite.src/fastled/paths.py— definesHEREandPROJECT_ROOTconstants
that nothing imports.
HIGH confidence — Docker remnants missed by #55
The "purge Docker references" PR (#55, Apr 12) missed these:
entrypoint.sh— Docker container entrypoint. Sources
/emsdk/emsdk_env.sh(container path) and calls
fastled_wasm_compiler.cli_update_from_master(a module from a separate
package that only exists inside the container).compiler/run.py— Docker compile-server entry point. Imports
fastled_wasm_compiler(separate package, not in this repo).compiler/debug.sh— instructs the user to run it from/js
(container working directory)..dockerignore— only contains cache exclusions
(**/.mypy_cache/,**/.ruff_cache/) which belong in.gitignore.
MEDIUM-HIGH confidence
chrome_vscode_bridge_design_task.md— one-off design draft
beginning "Here's a refined chrome_vscode_bridge_design_task.md file for
your repo. Feel free to adjust paths, placeholders, or formatting…".
Zero references anywhere else in the repo.upload_package.sh— manual PyPI upload helper. Superseded by
publish_release.yml's automated PyPI publish step. Zero inbound
references.
LOW priority — empty directories
fastled/(root-level, empty dir, last modified 2025-03-21)templates/(root-level, empty dir, last modified 2024-12-14)
Both are untracked-empty leftovers from previous layouts.
Out of scope (verified live)
For the record, these look dead but aren't:
_cargo,_rustc,_rustfmt— Rust toolchain trampolines (used during
local dev to prefer rustup-managed binaries over Chocolatey).build_site.py— used bybuild_webpage.yml:27.build_exe.py— used bypublish_release.yml.*.specfiles at root — locally-generated PyInstaller artifacts,
not tracked in git.demo/,site/,fastled/(the populated one atsrc/fastled/),
crates/,examples/,tests/— all live.
Suggested removal in a single PR
Single sweep:
git rm src/fastled/cli_test_interactive.py
git rm src/fastled/paths.py
git rm entrypoint.sh
git rm compiler/run.py compiler/debug.sh
git rm .dockerignore
git rm chrome_vscode_bridge_design_task.md
git rm upload_package.sh
rmdir fastled templates
Run bash test and bash lint after — neither should regress, since none
of these are imported.
Metadata
Metadata
Assignees
Labels
No labels
Activity
zackees commentedon May 12, 2026
Follow-up: additional Python elimination after Rust migration
Second-pass audit of
src/fastled/*.pylooking for files now superseded by the Rust crates (crates/fastled-cli,crates/fastled-py,crates/fastled-tauri). PR #61 already handled the orphan modules from the original sweep (cli_test.py,cli_test_interactive.py,install/test_install.py, plusTools/CompileOrLink/_handle_ino_cpp). Still pending from this issue:src/fastled/paths.pyand the non-Python items (shell scripts,.dockerignore, draft markdown, emptyfastled/dir).NEW HIGH-CONFIDENCE removal
src/fastled/filewatcher.py— full file (~300 lines)tests/unit/test_filechanger.py, which exists only to test this module.compile_native.py:95-99explicitly state: ""The HTTP server and file watching are now handled by the Rust CLI.""crates/fastled-cli/).tests/unit/test_filechanger.py— only consumer ofFileWatcherProcess.watchdog>=6.0.0frompyproject.toml—filewatcher.pyis the only importer ofwatchdogin the entire codebase.Investigated but kept (not removable yet)
src/fastled/open_browser.pyTest.spawn_http_serverin__init__.py(public Python API surface). It already shells out to the Rust CLI / Tauri viewer, so it's already a thin wrapper — but the public-API contract keeps it alive.src/fastled/frontend_esbuild.pytoolchain/internal_wasm_build.py:1514andtoolchain/emscripten.py:792(copy_frontend_to_output). Would need a Rust replacement for those callers before this can go.The remaining Python surface (
app.py,args.py,parse_args.py,compile_native.py,build_service.py,project_init.py,select_sketch_directory.py,keyboard.py,interrupts.py,util.py,emoji_util.py,spinner.py,string_diff.py,settings.py,sketch.py,debug_symbols.py,print_filter.py) is all live — entry-point chain, build orchestration, or CLI/UX helpers. Python is already minimal post-migration.Proposed PR scope (Python-only)
Plus removing
"watchdog>=6.0.0"frompyproject.toml.Non-Python items from this issue (
entrypoint.sh,compiler/run.py,compiler/debug.sh,.dockerignore,chrome_vscode_bridge_design_task.md,upload_package.sh, emptyfastled/dir) are out of scope for the Python sweep — they belong in a separate cleanup pass.chore: shrink Python footprint after Rust migration (refs #59)
chore: shrink Python footprint after Rust migration (refs #59) (#62)
chore(rust): own emscripten install in the Rust CLI (refs #59)
chore(rust): own esbuild install in the Rust CLI; drop fasteners (refs …
zackees commentedon May 13, 2026
Update: PR #62 — Rust now owns emscripten + esbuild installs
PR #62 has been extended to actually move the toolchain downloads into Rust (not just delete dead deps). Live there now: #62
Commits in the PR:
wait_for_serverHTTP probe dropped (redundant with the Rust URL printout).ensure_emscripten_installed()incrates/fastled-cli/src/install.rs— manifest fetch + multipart SHA-256-verified download +.tar.zstextract +.emscriptenconfig. Wired intocompile_and_serve()ahead of the Python invocation; setsFASTLED_EMSCRIPTEN_DIR. Uses thectcb-manifestcrate fromclang-tool-chain-binsfor the manifest schema. Dropsclang-tool-chainandpyzstd.ensure_esbuild_installed()— same shape for the esbuild npm tarball; newextract_member_from_tgzarchive helper. Dropsfasteners(last consumer removed).Python runtime deps: 8 → 2
watchdog,watchfiles,disklru,zccache,progress,rapidfuzz,clang-tool-chain,fastenershttpx,zcmds_win32(Windows-only)Still pending (deferred to follow-up PRs)
What keeps
httpxalive:src/fastled/project_init.py—--initflow downloads the FastLED repo zip. Needs a Rustensure_fastled_repo(ref)port that handles ref resolution (latest-release via GitHub API, branch, tag, commit SHA) + extract + return local path. Then--initis handled fully in Rust and Python'sApi.project_initshells to it.src/fastled/playwright/chrome_extension_downloader.py— runtime Chrome Web Store fetch for the C++ DevTools extension in the Tauri viewer. Needs a Rustensure_chrome_extension()port + Tauri viewer integration.These are tractable but each is a real Rust feature that deserves its own review surface. PR #62 stops at the toolchain installs because those have the cleanest test surface (cold-cache install test, no UX side-effects).
Note:
open_browser.pyRust portDiscussed during PR work: the Python
open_browser.pyis now a thin shim (_find_fastled_cli, subprocess launch, URL parse, optional viewer/browser launch). The Rust CLI'scompile_and_servealready covers most of this natively. The Python public API surface (Test.spawn_http_serverconsumed bytests/integration/test_animartrix_e2e.py) keeps the Python shim alive. Full removal would mean either deletingTest.spawn_http_serveror rewriting the integration test against the Rust binary directly — orthogonal to httpx removal, file separately if pursued.chore: move all HTTP downloads from Python to Rust; drop httpx (closes …
chore: remove Docker remnants + dead shell scripts (refs #59) (#70)