Skip to content

Hero and docs runtimes take env_set from boarddev (lands with the wasm rebuild) - #62

Merged
bdbarnett merged 1 commit into
mainfrom
env-to-boarddev
Oct 8, 2026
Merged

bdbarnett merged 1 commit into
mainfrom
env-to-boarddev

Conversation

@bdbarnett

Copy link
Copy Markdown
Contributor

PyDevices/pydevices#131 moves env_get, env_int, env_float, env_bool and env_set from displaydev to boarddev as a hard break. The hero runtime, the docs runtime, watch.py and signal_gen.py now import them from boarddev.

Don't merge this on its own. These pages run the vendored /vendor/micropython/micropython.wasm (served by PyDevices.github.io), which has pydevices frozen in. Today's wasm has the old boarddev, with no env_set, so this change would take every hero and docs demo offline. Merge it in the same commit or sitting as the wasm rebuild that freezes #131's pydevices (pin move in micropython-pydevices, rebuild, re-vendor into PyDevices.github.io). Until then the current wasm and the current JS agree with each other and keep working.

That rebuild also fixes the examples gallery, which boots this site's wasm. After PyDevices/pydevices-examples#183 merges, the gallery's env-using examples need the new wasm.

Not tested in a browser: there's no wasm with the new pydevices to test against yet. The change is the import line in four files.

pydevices moved env_get, env_int, env_float, env_bool and env_set from
displaydev to boarddev with no re-export (a hard break). The pages run on
the vendored wasm with pydevices frozen in, so this lands with the wasm
rebuild that freezes the new pydevices, not before.
@bdbarnett

Copy link
Copy Markdown
Contributor Author

This repo is the source. scripts/generate_sites.py copies assets/js/hero-runtime.js and docs-runtime.js (and the hero apps) into PyDevices.github.io, and PyDevices/PyDevices.github.io#17 carries the same four lines. I checked the copies with cmp and they're byte-identical to the files here, so regenerating would produce exactly that diff. Merge both together, with the wasm rebuild.

@bdbarnett

Copy link
Copy Markdown
Contributor Author

generator-idempotency fails here as expected. It regenerates PyDevices.github.io from this branch and diffs the result against PyDevices.github.io main, and the only difference is the four import lines in PyDevices/PyDevices.github.io#17. Merge #17 first (or at the same moment) and this check passes.

@bdbarnett

Copy link
Copy Markdown
Contributor Author

The rebuilt runtime landed in PyDevices/PyDevices.github.io#17 (eb5db2b), with that site's generated copy of these four files. Ran in Chromium against it: every hero reaches ready and draws with no console errors, including package_matrix, benchmark_deck and polyhedron. generator-idempotency passes now that the site matches.

@bdbarnett
bdbarnett merged commit 2a6528c into main Oct 8, 2026
11 of 12 checks passed
@bdbarnett
bdbarnett deleted the env-to-boarddev branch October 8, 2026 09:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant