EMRY-068: ship the emry CLI in the wheel - #120
Merged
Merged
Conversation
The 0.2.0 wheel shipped only the SDK + native extension, so `emry watch/web/compare/export` weren't runnable after `pip install emry`, and the SDK's live dashboard (which launches `emry`) silently degraded. - Compile the emry-cli binary into python/emry/_bin/ at wheel-build time (scripts/build-cli.sh) and bundle it; expose it as the `emry` console script + `python -m emry` (emry._cli execs the bundled binary). - live.py resolves the bundled binary directly, so the live dashboard works even when the interpreter's bin/ isn't on PATH. - run(name=...) alias for the positional run name. - CI wheels job builds + verifies `emry --version` from a clean install; release builds the binary inside the manylinux_2_28 container. - Bump to 0.2.1.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The 0.2.0 wheel shipped only the SDK +
emry._nativeextension. Theemrycommand is a Rust binary (emry-cli) that maturin never bundled, and there was no console script — sopip install emrygave noemry watch/web/compare/export, and the SDK's live dashboard (which launchesemry) silently degraded.Fix (ruff/uv-style bundling)
scripts/build-cli.shcompilesemryintopython/emry/_bin/at wheel-build time;[tool.maturin] includebundles it (wheel only — the sdist rebuilds from source).emry = emry._cli:main+python -m emry: the shim execs the bundled binary.live.pyresolves the bundled binary directly (works even when the venvbin/isn't on PATH; falls back toemryon PATH for source installs).run(name=...)alias for the positional run name (papercut EMRY-002: Event types + Phase enum #3).wheelsjob builds the CLI and verifiesemry --version+python -m emryfrom a clean--no-indexinstall — so the bundling is proven on every PR.manylinux_2_28container (cmake+perl for rustls/aws-lc-rs) so the bundled binary matches the wheel's glibc floor.Verified locally: built the wheel, installed into a clean venv,
emry --version→emry 0.2.1,python -m emry runs --helpworks, SDK imports,name=alias + both/neither error paths correct. Python coverage 94.4%.Closes #119