Bundled desktop runtime¶
Documentation · User guide · Development
The standalone app includes a relocatable CPython 3.13.18, build 20261026, for Apple Silicon, from Astral Python Build Standalone. Official distribution documentation describes the self-contained installations. This replaces the packaged app's previous dependence on the Mac's repository and .venv; the source launcher still uses the existing development environment.
v2/runtime.lock.json pins the Python install archive, the matching full archive used for third-party license texts, the unmodified root requirements hash, all 13 macOS dependency wheels, and bundled license files. NumPy/Pygame/Matplotlib and transitive versions match the original requirements.txt exactly. The original .venv is never upgraded. Both environments passed the same 431 original tests.
tools/prepare_desktop_runtime.py downloads into ~/Library/Caches/ArtificialEvolution2/desktop-runtime/, checks every expected hash, rejects unreviewed wheels, installs the checked wheels into a fresh temporary runtime outside Desktop/iCloud and copies it into Contents/Resources/python/. The app includes CPython's license and runtime dependency license texts under python/licenses/, plus wheel dist-info and vendored license files. Committed license texts came from the pinned matching full archive. The application's MIT license and Godot/asset notices remain bundled.
All original root Python files, including tests for source-hash consistency, and original JSON presets are copied byte-for-byte into Contents/Resources/engine/. The existing v2 bridge is copied at its original relative path. Nothing is rewritten into GDScript. engine-manifest.json records the copied files' hashes and the base source commit; hashes identify the exact working-tree snapshot even when the build precedes its final commit. The runtime copy's native binaries are ad-hoc signed individually before the outer application signature.
Godot starts its owned interpreter with -E -s -B: Python environment overrides and user site packages are ignored and bytecode is not written into the bundle. The adapter uses the application user data directory for Matplotlib caches, TCP endpoints and exports. A separate runtime-only sitecustomize.py gives independent original 2D launches a user cache under ~/Library/Caches/ArtificialEvolution2/, so the unchanged original plotting defaults cannot write into the signed engine folder. The original engine remains the sole owner of numerical decisions, movement, survival and evolution.
The standalone validator extracts the actual signed ZIP outside the checkout and denies the application and its Python child read access to this repository, /opt/homebrew and /usr/local. It removes development path overrides, uses a system-only PATH, and supplies deliberately invalid PYTHONHOME/PYTHONPATH. It checks original source hashes, seven-mode export/replay, original 2D CLI compatibility, unchanged development settings and the app signature after all runs. This is local engineering validation, not external replication or Apple notarization.
The V2.0.0 release declares macOS 14 as its minimum, matching the locked NumPy wheel. End-to-end native validation is on macOS 27 / Apple M3; the dependency floor is not evidence of testing every older OS. See installation compatibility.