Changelog
[Unreleased] Latest
Codegen + dev-host parity (flux-codegen-core, flux-parity, flux-syntax, flux-types, runtimes/ios) — [verified]
- FLUX-078 — codegen-driven native glue + parity guards. The dev-host adapter
registries (
FluxUiKit.adapters,AdapterKit.AdapterRegistry), host VM opcode tables (Opcode.kt,OpCodes.swift), and capability registries (CapabilityRegistry) were hand-ported duplicates of the authoritative Rust tables and had drifted, shipping silent on-device faults (FLUX-053IS_NULL, FLUX-072LIST_*).flux-codegen-core/src/native_gen.rs(new) emits the exact registry/table text fromHostAdapterSpec(new, inprimitives.rs),Opcode::ALL, andCAPABILITY_IDL— the single source of truth for the dev-host wiring.flux-parity/tests/native_kit_parity.rs(new) parses the checked-in native files (include_str!, no toolchain) and asserts they match the generated output: adapters/capabilities per platform, opcodes by equality againstOpcode::ALL. Future drift failscargo nextestbefore it reaches a device.- Drift the guards caught and was fixed at source:
flux-syntax::opcode::Opcode::ALLextended to include the 4LIST_*opcodes (was stale57 → 61;flux-vm-refalready handled them);runtimes/ios/.../OpCodes.swiftgainedisNull(0xD1);CAPABILITY_IDLgained the deterministic(2, 99)Storage.devReferenceAsyncmethod (iOS had hand-assigned the id, violating ADR-0045). - ADR-0058 records the decision. Verification:
cargo nextest -p flux-codegen-core -p flux-paritygreen (10 + 6 parity tests);swiftc -parseon the editedOpCodes.swiftclean. - Scope note: the generator derives the registry/table wiring only; the per-platform adapter bodies remain hand-written (genuinely platform-specific). Build-time emission into the native dirs is intentionally out of scope (parallel ownership + unverifiable native compilation).
Stdlib — ScrollView primitive (FLUX-056, PRD-N family) — DONE
- Registered
ScrollView(→ScrollView/ScrollView, a scrollable viewport for its children) in the single-source ADR-0047 codegen registry as aContainer, seeded it in theflux-typesprelude, declared it in stdlib (stdlib/scrollview.flux), and added aScrollViewAdapterto both dev-host adapter kits (AndroidScrollViewAdapter.kt+ iOSScrollViewAdapter.swift), registered inFluxUiKit.adapters/AdapterKit.AdapterRegistry. The parityregistry_covers_every_prelude_primitiveguard and thenative_kit_paritykit-match guard were extended so the new primitive cannot silently desync.- Props:
orientation: Option[String]("vertical"default,"horizontal"selects the scroll axis) — read through the FNV-1a prop index (SCROLL_ORIENTATION), never a hardcoded positional index. The Android host renderer wraps the children in averticalScroll/horizontalScrollCompose modifier (ShadowTreeRenderer.RenderScrollView); the iOS adapter maps it to aUIScrollViewcarrying the reconciled children. - A
flux-paritydev/release trace test (flux_056_scrollview_pins_dev_release_mapping) pins the dev vs Swift vs Kotlin node mapping (vertical default + explicit horizontal) so the primitive is first-class on all three render paths. - This lands the
ScrollViewprimitive that unblocks FLUX-056’s 1k/10k-item scroll benchmark (the remaining work is the benchmark harness wiring, which is deferred per the issue — MLP has no virtualization). The stdlibScrollView/virtualized Listroadmap gap (criterion #1) is now closed for the non-virtualized primitive.
- Props:
Incremental lowering + content-addressed wire IDs (flux-syntax, flux-ir, flux-devserver) — [verified]
- FLUX-074 — content-addressed subtree IDs + incremental lowering. Editing
text above a node no longer flips its wire-tree
NodeId, and a recompile that edits one file re-lowers only that file.flux-syntax/src/ids.rs: addedcontent_addressed_id()(FNV-1a-32, same family/seed ascompute_node_id) and madefnv1a32pubso derived id spaces stay in agreement.flux-ir/src/arena.rs: addedIRArena::content_address() -> AHashMap<NodeId, NodeId>, an acyclic two-pass re-key (bottom-up parent-independent local id, then top-down mix of parent’s final id + position to break sibling collisions). It ignores spans, preserves props/handlers/closures/string table, and re-keys the ADR-0027 signal-graph side-tables (signal_deps/prop_thunk/prop_layout/item_slot); returns the old→new map so callers re-key external id-keyed state.flux-devserver/src/pipeline.rs:compile_tree()now content-addresses the merged wire tree and remaps the pipelineprop_thunkstable in lockstep (FLUX-074 item A). It also gained a per-file lower cache +lower_count()metric: unchanged files skip parse/type-check/lower on recompile (FLUX-074 item B, bounded work).- Tests:
arena(3) cover id stability across source move, change-on-content-edit, and side-table/closures preservation;pipeline(2) cover end-to-end id stability across a text-above edit and single-file incremental re-lower. AGENTS.md§3.2 updated to describe the two id spaces (canonical span-based bridge vs content-addressed wire ids).flux-parityB.3 stays green (only id values shift, which parity does not compare). No protocol bump — hosts still consume opaqueu32.
Android: ForEach remove-wrong-row — FLUX-092 — [verified]
- The Kotlin
reconcileForEachtore down and rebuilt every row on each list mutation, and from the second mutation onwardadapter.update()ran against a destroyed view (T-330). Fixed by unifying the row/child id derivation to the FNV-1a + marker-bit scheme (tests/isa-vectors/foreach_ids.json, cross-platform Rust/Swift/Kotlin parity). Residual identity-drift bug is tracked as C12;native_kit_parity.rscovers the adapter-drift gate.
2026-08-29 — Flux syntax highlighting: grammar rebuild + compiler-driven LSP tokens
Docs site + LSP (flux-lsp, flux-parser) — [verified]
- Grammar rebuild (was stale).
website/src/flux-grammar.mjs(a hand-written regex shiki grammar) no longer matched the live parser: it listedcomponent/return/for/while/struct/enum/impl/pub/where/export/inas keywords (none are real), missedwhen/otherwise/use/capability/untrack/resource/await/ createRef/provide/useContext/compo, and used#comments while the lexer uses//. Rebuilt aswebsite/src/flux.tmLanguage.json(TextMate JSON) driven directly fromflux-parser’sTokenKindkeyword set, and wiredastro.config.mjsto it; the stale.mjsis deleted. - Doc examples used the dead brace syntax.
counter-example+adding-a-primitive(root +fr+es) had been written againstcomponent Counter { … }withstateandfn()handlers; rewrote them to the real indentation grammar (compo/$count:/Column gap:/onClick|| { … }) so the snippets parse against the current compiler. - Compiler-driven semantic tokens (FLUX-024 / PRD-O).
flux-parsernow exposes its lexer publicly (TokenKind,Token,LexError,lex,tokenize,keyword_kind) so consumers can reuse the real surface grammar.flux-lspadds atextDocument/semanticTokens/fullprovider (crates/flux-lsp/src/semantic_tokens.rs) that highlights keywords, string/number literals, and//comments using the actual lexer — not a second regex grammar — and advertises the legend ininitialize.- Scope note: highlighting is lexer-driven, so type names,
null/None/Some, and component/prop identifiers are not distinguished from plain identifiers (the lexer cannot tell them apart); a parser/AST-aware pass is FLUX-027 territory. - Verification:
cargo clippy -p flux-parser -p flux-lsp --all-targets -D warningsclean;cargo nextest run -p flux-parser -p flux-lsp68/68 green;cargo docclean; shiki tokenizes a real.fluxsample through the newflux.tmLanguage.json(compo→ keyword color).
- Scope note: highlighting is lexer-driven, so type names,
[Unreleased] — Release evidence gate / contract freeze
Release — 1.0 beta evidence gate / contract freeze (FLUX-069, PRD-U) — DONE
- The 1.0 cut is a set of evidence criteria (roadmap §1), not a feature list.
FLUX-069 implements the machine-enforced half of that gate; the human-evidence
half (dogfood report, closed-beta time-to-diagnose/fix vs RN/Flutter, bug-bash
log) is the checklist in
docs/release/1.0-evidence.md, filled by the release manager as evidence arrives, and gates the manualv1.0.0tag. release-gate.ymlaggregates the existing component quality gates — Rust (rust-check), iOS (ios-check), Android (android-check), toolchain compat matrix (compat-matrix), perf budget (perf-harness), save→photon e2e (benchmarks:save-photon), wire fuzz (wire-fuzz) — behind onerelease-gatestatus check, so a single green check represents the whole quality bar. Each callee gainedworkflow_call:(additive) so it still runs standalone on push/PR.- New blocking
contract-freezejob runsscripts/release-gate/check-contract-freeze.sh, enforcing the PRD-U contract freeze: the wire protocol version (PROTOCOL_VERSION, Appendix D / ADR-0056) and adapter contract version (§3.5) must be consistent across the Rust server and both native hosts, matching the frozen values indocs/release/contract-versions.toml. A mismatch is a build-breaking change and fails the gate (finds a stale host after a three-site version bump). The manifest supports an optionalpin = "<tag>"to freeze the gate to a 1.0-RC / 1.0 tag. - Verification:
check-contract-freeze.shpasses on the current tree (wire=2 / adapter=1 across server + both hosts); the negative path (a host bumped to wire=3) fails as designed; YAML validated (every callee declaresworkflow_call:and is referenced). No production code changed — CI + docs only, within the LANE-U (docs/,.github/,scripts/) ownership. - Android gate hardened to HARD.
android-check.ymland the Android cells ofcompat-matrix.ymlpreviously ran their Gradle/kotlinc steps withcontinue-on-errorbecause the GitHub-hosted runners lackedplatforms;android-37(this repo pinscompileSdk = 37). That is now stale: the liveactions/runner-imagesreadme showsubuntu-24.04preinstallsandroid-37.0/37.1/37.2-beta+ Build-tools 37.0.0. Both Android jobs now run onubuntu-24.04with the SDK-install, kotlinc codegen check, and:adapters:ui-kotlin:test :runtimes:android:app:teststeps as HARD gates (nocontinue-on-error). The iOS compat cells stay best-effort (Xcode version availability is a separate runner concern, not a code-correctness gate).
Android host VM — IS_NULL opcode port (FLUX-053) + Counter tap-handler binding — DONE [verified]
IS_NULLopcode missing from the Kotlin host VM. The Rust reference VM (flux-vm-ref) and the ISA golden vectors emitIS_NULL(0xD1, 2-operand dst/src) for null-safe access (FLUX-053), but the Kotlin host VM enum (Opcode.kt) had no entry. Decoding any0xD1vector threwINVALID_DISPATCH, soIsaConformanceTest.is_null_{true,false}failed. AddedIS_NULL(0xD1, 2)toOpcode.ktand the interpreter case inStepResult.kt, mirroring the oracle exactly (dst = (src == Null)).IsaConformanceTestnow 74/0.- Counter tap handler never bound (fixture prop-name drift).
CounterIncrementE2ETestdecoded fine but renderedtapped 0 timesafter a tap: the button’sonPresshandler was emitted on the wire under FNV-1a("onClick")=20360, while the hostPropsIndex.BUTTON_ON_PRESSderives FNV-1a("onPress")=10279 (the canonical Flux prop name, perstdlib/button.flux+examples/counter/main.flux). The mismatch lefthandlerId=0so the tap did nothing.gen_frames.rshad hardcoded anonClickinline source that drifted fromexamples/counter; corrected it toonPressand regeneratedcounter_init_frame.binfrom the canonical source so the button binds.CounterIncrementE2ETestnow 1/0; full:hostsuite 163/0. - Verification:
./gradlew :runtimes:android:host:test→ 163 passed, 0 failed. - Host VM list-mutation opcodes ported (FLUX-072). The same
opcode-parity discipline also covers the Kotlin host VM list opcodes
0x85-0x88(ListPush / ListInsert / ListRemove / ListClear), ported from the Rust reference VM soForEach/list-driven UI evaluates on-device (f6f2b17). These are the VM-level support behind the FLUX-072 host-sideForEachexpansion.
Language — use module resolution end-to-end (FLUX-054 follow-on) — DONE
- Module imports now resolve through a single
usedirective end-to-end:flux-typesgained the resolution pass (checker.rs, +338 lines) andflux-devserver::Pipelineintegrates it (pipeline.rs);flux-ir/flux-lsp/flux-cliwere consolidated so import syntax lowers to the oneuseform (parser.rs/ast.rs/lexer.rs/fmt/decl.rssimplified,doc.rstrimmed). - The spec (
mlp-spec.md/mlp-appendices.md) was updated to the single-usemodule-import surface.cargo nextest run --workspacegreen (597/597) after the resolution pass landed. - Commits:
5b9fa61(resolution),6cb88b7(consolidate on singleuse).
LANE-P — DevTools live telemetry bridge (PRD-P) — DONE [verified]
- Live telemetry host → server → gpui DevTools, end-to-end. The host emits
FRAME_TELEMETRY(0x10) frames over the existing:7331WS;DevToolsRouter(multiplexed ontoShared.devtools_router) enriches and broadcasts them to the gpui DevTools client on:7333. Verified on iOS Sim: host sends 0x10 frames on every tap, serverroute_telemetryincrements, gpui holds the ESTABLISHED:7333connection and reconstructs timeline/live state viaflux-ir-serde. - gpui frozen-window fix. The pinned gpui version’s
AsyncFnOncespawn trait rejects every&mut AsyncAppcapture form (E0282 / “not general enough”), so the spawn-based repaint drain could not compile. Replaced with a spawn-free repaint loop inDevToolsRoot::render: whiletimeline_len()grows it callswindow.request_animation_frame(), so every pane re-renders live on each tap without a 60fps idle spin. - Dev server: binds the devtools WS on
0.0.0.0:7333(DEFAULT_DEVTOOLS_PORT); iOS host default dev server URL isws://127.0.0.1:7331(sim only forwards :7331). - iOS host observability:
FluxWebSocketTransportappends connect/send events toDocuments/flux_host.log(os_log captured nothing in CI’s headless sim env).
DevTools — Component Tree populated (FLUX-039) — DONE [verified: rust]
- Root cause. Neither host ever emitted
TelemetryEvent::ViewMutation— the constructor + wire encoder existed in both iOS (Telemetry.swift) and Android (Telemetry.kt) but had zero call sites, soview_framesstayed empty and the DevTools Component Tree rendered nothing. - Android host now emits
ViewMutationat node create (0x03Insert), update (0x02+DirtyReconciler.reconcileDirty) and remove (0x04), guarded by a non-nullTelemetryBridge.sink. The host crate is Android-free and drives in-memory adapter views, so the layoutframeisnil(geometry pending); node presence is still recorded. - iOS host now emits
ViewMutationat node create and on every update inShadowTreeReconciler, carrying the realUIViewlayout frame (iOS has real UIKit views), guarded by#if DEBUG. - DevTools reconstructor records node presence on every
ViewMutation(frame optional) instead of requiringSome(rect); the Component Tree rendersnode present · geometry pendingwhen the host cannot measure geometry. parent_idwire field (follow-up).ViewMutationnow carriesparent_id(raw + enriched encode/decode influx-ir-serde), so the DevTools can rebuild the parent/child hierarchy instead of a flat list. Both hosts emit it (ShadowTreeReconciler.reconcilethreadsparentId; Android emitsparents[id] ?? 0). The DevToolsComponentTreeViewresolves parent links and renders an indented tree (chevrons mark branches) rather than a text wall.- Snapshot-on-connect (follow-up). The host replays its current shadow tree
when DevTools attaches: iOS
ShadowTreeReconciler.emitSnapshot()walksnodeTablefrom the root and re-emitsViewMutation(add)for every built node, fired at the end ofapply()and onfluxDevtoolsConnect. This removes the timing dependency — the tree populates immediately on DevTools connect instead of only after the next mount/tap. - Instant repaint (follow-up).
DevToolsRoot::rendernow re-arms an animation frame whenever a host is connected, so freshly ingested telemetry (VM steps, signals, layout frames) is reflected immediately — including while the DevTools window is in the background — instead of only after a refocus.
The entries below land the work committed since the changelog was last updated
(a8c86d0, 2026-08-27).
LANE-A / LANE-B — router navigation + positional Screen route-prop blind spot — DONE
- iOS runtime: router-aware reconciler + VM ip-advance fix, dispatch debug probes
stripped, router screen name-detection (
2bbfb61,a503719,79a588f). Router.navigate(signal 97) wired to the visible screen on both hosts (9c30d4ciOS,91605d2Android); AndroidFluxTreeViewthreadsrouterVersion(49178b5); router renders only the active Screen on a real tap, accepting a rawStrValsignal 97 (3975237,303ee45,9840ab5,b3905dc).- Added
RouterUITapTestsUI test target (1cf0fb3) plus on-device positional-Screennavigation trap tests for iOS and Android (822f25c,0afc406) and a Rust parity gate pinning the route-prop blind spot (c625a02,792cf73).
LANE-C — Clipboard & Geolocation capabilities — DONE
- Registered Clipboard (cap 4) and Geolocation (cap 5) in the type checker and added
them to the MLP manifest (
798fd03,1bca9d5).
LANE-D — wire fuzzing harness + wire hardening — DONE
- Added a wire-fuzzing harness + CI (
2aac405);flux-ir-serdegained a frame-size ceiling and bytecode validation (99c443d).
LANE-E — flux build release gate — DONE
flux buildnow invokes the native toolchain and fails on non-zero exit; release-leaking debug logs gated behind#if DEBUG(6947bec,d1ffbd8). Tracing palette brightened for readability on blue terminals (86f6c7e).
LANE-H — large-tree benchmarks — DONE
- Added large-tree benchmarks measured against the §3.10 budgets (
680a9fb).
LANE-I — unified FluxError hierarchy + permission gate — DONE
- Introduced a unified
FluxErrorhierarchy with a permission gate influx-types/flux-devserver; fixed the umbrella left half-disabled by LANE-D (b972da4,c758e13).
Codegen — unified data-driven release codegen (ADR-0047) — DONE
- Unified data-driven release codegen via
flux-codegen-core; emit one specialised native type per generic instantiation and fully shape the six previously-bare primitives (8f5c5d5,5cea19d,12f2d97). Emit valid SwiftUI / Compose for sum types +match(fcbd673,6d706c0).flux-devserverexposes the merged monomorphization set (d18dc20).
IR — Patch::Reattach applied, secondary string-intern region (Phase 1/3/5 follow-ups) — DONE
bdcfa64monomorphise generics + add the Reattach patch;9012554InstanceRegistry::try_reattachfor state-preserving structural edits;a667998applyPatch::Reattachto preserve instance state on iOS / Android;3173e0bsecondary host string-intern region so ids never alias.
Async wire — end-to-end suspension test — DONE
4c2d5deend-to-end async suspension over theAwaitSuspend/Resumewire against the real reference VM.
Docs / ADR — reconcile to real code — DONE
- ADR-0048 (iOS declarative dev tier) + §0.2 status correction (
9cd9e72); AGENTS.md §0.2 / §0.4 / §2.1 / §3.2 reconciled to real code (1d3dd91,61559a9); specPatch::Reattach/AwaitSuspend/Resumeframes (ecb82b3); adapter prop-index and adapter-count claims corrected (a1e5ed6,5bba904,ce29276); flux-architecture diagram interactivity + readability (73608ce,f974e70,9b0e508); README / website / repo-URL fixes (3012103,512b220,4c1b5da).
Language — structural record typing (FLUX-054 / ADR-0052) — DONE
- Records are now structural (width-subtyping): a value carrying extra fields is
assignable where a narrower record type is expected (
unify_recordsno longer requires equal field counts). A narrower value missing a required field is still rejected with a precise diagnostic (crates/flux-types/src/unify.rs). - Added anonymous record literals
{ x: 1, y: 2 }(FLUX-054 / ADR-0052): the parser emitsExprKind::Recordwith an empty name when a{ ... }primary’s entries are allident: exprand there is noname =>block-param header; the checker already lowersExprKind::Recordto a structuralTcType::Record(crates/flux-parser/src/parser.rs). - ADR-0052 records the structural-vs-nominal decision and scope boundary (no new VM opcode
or IR node; codegen already walks
ExprKind::Recordfields).
Codegen — async handler emission (FLUX-064) — DONE
- Release codegen now emits a suspending wrapper around
awaiting capability-call handlers: Kotlin wraps theonClickbody inGlobalScope.launch { ... }, Swift wraps it inTask { ... }. Sync handlers (noawait) stay plain() -> Unit/() -> Voidclosures, so the release path can suspend on a real capability without blocking the UI thread (crates/flux-codegen-{kotlin,swift}/src/backend_impl.rs,button_open). - Added
import kotlinx.coroutines.*to the Kotlin codegen compile-check preamble and a focused emission test asserting the wrap on both backends.
Stdlib — layout primitives (FLUX-037, PRD-N family) — DONE
- Registered
Stack(→ZStack/Box, z-order overlay),Grid(→Grid/LazyVerticalGrid),Spacer(→Spacer), andSafeArea(→SafeArea/Scaffold) in the single-source ADR-0047 primitive registry (crates/flux-codegen-core/src/primitives.rs) and seeded them in the type-checker prelude (crates/flux-types/src/prelude.rs). The parity guard (registry_covers_every_prelude_primitive/registry_has_no_unknown_entries) was extended both directions and stays green. - Added a Kotlin codegen trace test asserting each lowers to its native view. The native host view bodies (UIKit/SwiftUI + Compose) read these registry names; their render mapping is the same contract the other primitives use.
Stdlib — Image primitive (FLUX-039) — PARTIAL
- The
Imageprimitive is already registered in the ADR-0047 registry (urlprimary prop, KotlinImage(painterResource(...))/ SwiftImage(uiImage: UIImage(named:))) and seeded in the prelude; a Kotlin codegen trace test now pins thatImage(src)lowers to the native image binding (crates/flux-codegen-kotlin/tests/pipeline.rs). - REMAINING (host-side, native lane): the actual local/remote cache (Coil on Android,
URLCacheon iOS) is a host concern that lives inruntimes/android/host+runtimes/iosand is out of this crate’s scope; not compile-verified here.
Stdlib — gestures (FLUX-041, PRD-N family) — PARTIAL
- Registered
Gesture(akind+onGesturecontainer) in the ADR-0047 registry and seeded it in the prelude; parity guard extended both directions and stays green. A Kotlin codegen trace test pins it lowers to a native container (Box) carrying its child subtree. - REMAINING (host-side, native lane): attaching the matching
UIGestureRecognizer(iOS) /Modifier.pointerInput(Android) for eachkindis wired inruntimes/android/host+runtimes/iosand is out of this crate’s scope; not compile-verified here.
Capabilities — six concrete native capabilities (FLUX-045, LANE-C) — PARTIAL
- Declared the six deferred capabilities (Push, Biometric, Background, FileSystem, DeepLink,
Sensors) in
stdlib/capabilities.fluxwith// requires:annotations, and registered them inCAPABILITY_IDL(crates/flux-types/src/capabilities.rs) with stable ids 6..=11 andPermissionKindgates (Notification / Biometric / Background / FileSystem / None / Sensors). Extendedrequired_permission+ the permission token table accordingly. - Wired both host
HelloFrameGENERATED capability tables (runtimes/ios/FluxHost/Sources/FluxHost/HelloFrame.swiftandruntimes/android/host/.../wire/HelloFrame.kt) so the dev handshake advertises the new caps. Thecapability_idlparity tests (swift_registry_matches_idl,kotlin_registry_matches_idl,stdlib_capabilities_mirror_idl_names) stay green — the single-source manifest is intact. - Added
flux045_six_concrete_capabilities_wiredregression test; updated the pre-existingrequired_permission_matches_manifest/CAPABILITY_IDL.len() == 5assertions (now 11). - REMAINING (host-side, native lane, parallel-owned): the real
CapabilityRegistry::register(...)bodies (thecall(args, signals)implementations on both hosts —UNUserNotificationCenter,LocalAuthentication,BGTaskScheduler,FileManager,UIApplication.open,CMMotionManager; Push/Background settle a result cell viaAsyncResolver, ADR-0045). Those runtime files are owned by the runtime agents and are not edited/compile-verified from this crate pass.
Stdlib — form primitives (FLUX-040, PRD-N family) — PARTIAL
- Registered
Switch/Checkbox/Slider/Picker/DatePicker/TextAreain the ADR-0047 registry with avalue/onChangesignal contract (same asTextField) and seeded them in the prelude; parity guard extended both directions and stays green. A Kotlin codegen trace test pins each lowers to its native control (Switch/Checkbox/Slider/DropdownMenu/DatePickerDialog/TextField). - REMAINING (host-side, native lane): the native controls’ actual behavior (toggle writes its
signal, picker selection, etc.) is wired in
runtimes/android/host+runtimes/iosand is out of this crate’s scope; not compile-verified here.
IR — B.3 handler-lowering gap closed (FLUX-063) — DONE
- The 6 B.3 examples the issue flagged (b32, b33, b35, b36, b38, b310) with
unsupported handler operand/expressionnow lower throughflux-irwithout error; the lowering gap had already been closed in-tree (the bytecode.rs handler emitter covers method/constructor calls, capability calls, and...spreads). Pinned with a permanent regression testcrates/flux-parity/tests/b3_lowering.rsasserting all 10 B.3 examples lower cleanly, so the gap cannot silently reopen.
CI — mutation testing + toolchain matrix (FLUX-067) — DONE
- Added
.github/workflows/mutation-testing.yml: acargo-mutantsjob overflux-differandflux-vm-ref(installed from crates.io, NOT a manifest dependency per the issue). Informational (continue-on-error: true) until the surviving-mutant set is triaged, then promoted to a hard gate. - Added
.github/workflows/compat-matrix.yml: an Xcode min+max (iOS) and AGP x Kotlin min+max (Android) matrix reusing the ios-check/android-check build steps, so version drift is surfaced instead of assumed.
Release — flux build toolchain invoke + distribution (FLUX-068) — PARTIAL
- The core of FLUX-068 —
flux buildactually invokes the native toolchain — was already implemented incrates/flux-cli/src/build.rs: it emits generated sources first, then spawnsxcodebuild/./gradlewand FAILS on a non-zero exit (release gate), with an emit-only fallback + actionable log when the toolchain is absent. Covered by three unit tests (absent / passing / failing toolchain). - Added
.github/workflows/artifact-publish.yml: the CI/publish step producingFluxHost.xcframework(macOS runner) and the:runtimes:android:hostAAR (linux runner), uploaded as release artifacts — closing the ADR-0036 packaging-gap publish path. - REMAINING (owned by the native iOS/Android lanes): the
docs/embed-flux.md“Embed Flux in an existing app” guide. (The host-side fail-closedPROTOCOL_VERSIONhandshake is now done — see the FLUX-050 subsection below; it was delivered and verified on both simulators.)
BLOCKED — release crash reporting (FLUX-035) — RESOLVED below
- Original note: the deliverable is native Swift/Kotlin crash reporters in the release
hosts (
runtimes/ios,runtimes/android), which were parallel-owned runtime dirs the boundary contract forbade editing. Superseded: the native halves landed (3d166c0iOS,a01f29dAndroid) —CrashReporter.swift/CrashReporter.kt(release-only#if !DEBUG) now map a crash into the PRD-KFluxErrortaxonomy. See the reconciled[Unreleased]section (FLUX-035 — DONE).
BLOCKED — large-list scroll benchmark (FLUX-056) — primitive UNBLOCKED, benchmark still BLOCKED
- Updated: the
ScrollViewprimitive (PRD-N) now exists — registered in the ADR-0047 codegen registry, seeded in theflux-typesprelude, declared in stdlib (stdlib/scrollview.flux), and wired into both dev-host adapter kits (ScrollViewAdapteron Android + iOS) with aflux-paritydev/release trace test pinning the mapping. So the “no ScrollView primitive” blocker is resolved. - The remaining blocker for FLUX-056 proper is the 1k/10k-item virtualized
scroll benchmark harness wiring. Per the issue, MLP has no virtualization
(
ForEachis explicitly non-virtualized), so the benchmark would measure diff/reconcile latency, not scroll — authoring it is deferred.flux-perf-harness(PRD-J / FLUX-066) exists as a crate and is wired into CI, so that dependency is resolved. Issue remainsstatus: blockedfor the benchmark leg; the primitive leg is DONE (see the[Unreleased]ScrollViewentry).
DONE — timeline / flamegraph (FLUX-059)
- The
timelineview (crates/flux-devtools-ui/src/views/timeline.rs) now renders a budget-aware flamegraph of the render-perfMetricRecordstream (PRD-J / FLUX-066), not just the scrubber counter. Implementation:- A new
PerfRecordvariant on the existing0x10telemetry frame (flux-ir-serde::TelemetryEvent::PerfRecord/EnrichedTelemetryEvent::PerfRecord, tag0x07) carries the verbatimMetricRecordJSON — no new wire field.TelemetryEvent::perf_record(json)constructs it. Encoded/decoded + enriched round-trip covered byflux-ir-serdetests. DevToolsState::ingest_perf_recordparses each record (bounded ring buffer; malformed JSON dropped with a warning, never panics) andhandle_telemetryroutesPerfRecordevents into it.perf_record.rsgroups records by(Scenario, MetricKind)into lanes whose bar width = p95 ÷ §3.10 ceiling, green within budget / red over (sameBudgets::v1()CI gates PRD-J enforces).- Tests:
perf_record::flame_rows(empty state, over/under budget, latest-wins dedup, distinct lanes) +state::ingest_perf_record+state::handle_telemetry_perf_record_event_feeds_flamegraph.
- A new
- Follow-up (DONE):
flux-devservernow broadcastsPerfRecordframes.Pipeline::perf_records()builds the server-sideSave → pixelsbreakdown from the real per-compilePhaseTimings(parse+type_check+lower+diff+serialize →MetricKind::SaveToPhoton; serialize alone →MetricKind::PatchRoundTrip) with the lowered node count astree_size,Scenario::LoopbackE2e.compile_and_broadcast(watcher hot path) andinitial_compileboth broadcast each record asTelemetryEvent::perf_record(json)viaDevToolsRouter::route_telemetryon:7333, so the flamegraph fills from the first compile, not just after an edit.flux-perf-harnesspromoted from dev-dep to a regular dependency offlux-devserver. Tests:pipeline::tests::perf_records_*+debug_bridge::tests::router_broadcasts_perf_record_to_subscribers. - Verification note:
cargo test -p flux-devtools-ui --libpasses (45/45, incl. the 8 FLUX-059 flamegraph/ingest tests) once the workspace tree is green — the earlier block was concurrent in-flight breakage incrates/flux-ir/src/lower/mod.rs(another agent’s LANE work, outside this issue’s scope) which brokeflux-ir, a transitive dep offlux-devtools-ui. Independent layers also green:flux-perf-harnesstests green;flux-ir-serde(wire variant + round-trip tests) clippy-clean + all suites green. No fabricated green.
DONE — DevTools log viewer + network inspector (FLUX-060, LANE-P) — verified
- Log viewer — DONE (verified): pure
LogBuffer/LogEntry/LogLevelmodel (time_travel/log_buffer.rs, 4 tests), wired intoDevToolsState(logs: RwLock<LogBuffer>+ingest_log/log_snapshot, 1 test). The gpuiLogViewerView(views/log_viewer.rs, 1 test) was restored and is now mounted as theLogspane in theDevToolsRoot3×2 grid (it had been dropped in2647f09and was not actually mounted; this issue’s earlier “DONE” claim was stale — the model existed but no view rendered it). - Network inspector — DONE (unblocked by FLUX-047): FLUX-047 (HTTP capability)
is now
done, so real HTTP traffic exists to inspect. Implementation:- New
NetworkRequest/NetworkResponsewire variants on the0x10telemetry frame (flux-ir-serde::TelemetryEvent/EnrichedTelemetryEvent, tags0x05/0x06) — no new wire field, length-prefixed like the other events.NetworkRequestcarriesrequest_id/method/url/body/capability_id;NetworkResponsecarriesrequest_id/status_code/latency_ms/body/result_kind(ADR-0044 cell state,0=Pending/1=Ready/2=Error). Encoded/ decoded/enriched round-trips + tag-byte conformance covered byflux-ir-serdetests (network_events_carry_expected_wire_tags,network_events_round_trip_enriched). - Pure
NetworkLog/NetworkRecord/NetworkPhasemodel (time_travel/network_log.rs, 6 tests): a bounded FIFO that pairs a response with its request byrequest_id; a response with no retained request is dropped (no fabricated row). - Wired into
DevToolsState(net: RwLock<NetworkLog>+ingest_network_request/ingest_network_response/network_snapshot) and fed through the singlehandle_telemetryingest path (so the wire client needs no second call site). Tests:ingest_network_pairs_request_and_response,handle_telemetry_feeds_network_log,wire_client::ingest_network_frame_feeds_network_log. - gpui
NetworkInspectorView(views/network_inspector.rs, 1 test) mounted as theNetworkpane in theDevToolsRoot3×2 grid, showingmethod url → status (latency)per exchange, pending until the response lands.
- New
- Live broadcast — DONE (2026-08-30 follow-up): both hosts now emit
NetworkRequest/NetworkResponsearound theHttpcapability (FLUX-047) so the inspector shows real outbound traffic end-to-end, not just fixtures:- Android
HttpCapabilities.makeHttpResolveremitsTelemetryEvent.NetworkRequest(capability id14) before the call andTelemetryEvent.NetworkResponse(status_code/latency_ms/result_kind=1Ready /2Error) after it. - iOS
HttpAsyncResolver.resolvedoes the same viafluxDevtoolsEmit. - Wire layout is bit-identical across Kotlin/Swift/Rust (tag
0x05/0x06, length-prefixed,u16string length prefix). Pinned by the Rusthost_network_telemetry_decodes_to_network_eventstest and the AndroidTelemetryNetworkTestagainst the same canonical byte array. - Fixed a version divergence: the Android host telemetry frame defaulted to
PROTOCOL_VERSION = 1whileflux-ir-serderequires2, so the dev server silently dropped host frames. Bumped AndroidtoFrameBytesdefault to0x02to match iOS (0x02) and Rust.
- Android
- Verification:
cargo nextest run -p flux-devtools-ui --lib→ 45/45 green (incl. all FLUX-060 tests);cargo nextest run -p flux-ir-serde→ 68/68 green (incl. the new network wire tests);cargo clippyclean on both crates’ own files. TheDevToolsRootbody is now a 3×2 grid: row 1 VM / Signals / Timeline, row 2 Component Tree / Logs / Network. Host Kotlin/Swift are not compiled here (no Android toolchain; Swift emit-byte generator verified viaswiftc), but the wire contract is locked by the shared canonical-byte Rust + Android tests.
PARTIAL — DevTools multi-device connect (FLUX-061, LANE-P)
- Multi-device session model — DONE (verified):
DevToolsStategained a per-hostsessions: RwLock<BTreeMap<HostKey, DeviceSession>>map +activerouting key.set_hostinserts/updates a session keyed by theHostAnnounceidentity and marks it active;handle_telemetryroutes into the active session (ownReconstructedStateTimelineBuffer) while mirroring into the legacy single-host fields sotimeline_len/vm_state/state_atstay stable. Accessors:session_keys,session_count,session_state,active_host_key. Testtwo_hosts_make_two_sessionsproves two distinct hosts yield two independent sessions.cargo test -p flux-devtools-ui --lib→ 24/24 green; fmt + clippy clean. No server change needed.
- Per-event attribution — BLOCKED (protocol gap): the issue’s “keyed by the
EnrichedTelemetryEventsource” is not satisfiable today — neitherEnrichedTelemetryEventnor the telemetry frames carry a host/source discriminator (verified influx-ir-serde/src/telemetry.rs), and:7333broadcasts one merged stream. True per-event attribution needs an ADR-0039 wire extension (host id onHostAnnounce+ per-event source tag); the session container is ready to consume it.
DONE — DevTools on-device verification (FLUX-062, LANE-P) — [verified]
- End-to-end data-path proof, no mocks of the DevTools side. New integration test
crates/flux-devtools-ui/tests/on_device_verification.rsdrives the real DevTools WebSocket client (connect+ingest_message— the exact code theflux-devtoolsdesktop binary uses) against a real wire feed built from the shared codecflux-ir-serde. The “host” emits authenticTelemetry(0x10) andHostAnnounce(0x12) frames — the same byte shapes the production dev server broadcasts afterroute_telemetry/announce_host, and the same bytes the real iOS/Android hosts produce. Two tests assert every view is live:on_device_every_view_renders_live_data: named component tree (Column/Button/Text— Louis’s historical “empty tree” gap), signal value + dependency edge, VM IP/registers, timeline advance + time-travel scrub, host identity, network exchange pair, and aPerfRecord→flamegraph record.on_device_multi_device_two_sessions(FLUX-061): two distinct hosts → two independent sessions with their own timelines.cargo test -p flux-devtools-ui --test on_device_verification→ 2 passed.
- Real binary exercised.
flux-devtoolsdesktop binary builds and launches against a live:7333telemetry source (crates/flux-devtools-ui/examples/host_emulator.rs, a standalone wire-contract host); process comes up alive and holds the connection. - Honest limitations (documented in the issue): (1) the full native iOS/Android UI
app is not booted in this env — the DevTools data path it feeds is the identical
0x10/0x12wire contract this harness already exercises; booting the complete VM/UI app is the remaining on-device step (FLUX-036 / FLUX-069). (2) a rendered screenshot of the DevTools window could not be captured — this is a headless Mac whose display framebuffer is not capturable (screencapture→ “could not create image from display”); only the iOS Simulator’s virtual surface is real. The data-path proof stands on production code.
PARTIAL — render-perf harness (PRD-J, LANE-J)
- New crate
crates/flux-perf-harness(pure Rust, 12/12 tests green; fmt + clippy-D warningsclean). Provides the sharedMetricRecordschema (Scenario×MetricKind× p50/p95/mean latency + optional sizes, stable JSON), a deterministicHarnessDriverover a fixedFixtureTreewith aMeasureFnhook for host adapters, and the CI gate predicate encoding the §3.10 budgets (NodeMutationp95 ≤ 3ms, …). This is the substrate ADR-0048 Phase 0/1 needs and unblocks FLUX-056/059/065 (their missingMetricRecord/harness now exists). - Measurement runs — REMAINING (host-side): timing the iOS
FluxUIKitreconciler and the AndroidShadowTreeRendererrequires theruntimes/adapters (which supplyMeasureFnclosures) to wire in; those dirs are in-flight parallel work and need a device/simulator +xcodebuild/kotlinc, unavailable here. The per-tier numbers that close the ADR-0048 decision are produced by those adapters, not this crate.
BLOCKED — iOS render-tier convergence decision (FLUX-065) — still BLOCKED
- Updated: the render-perf harness (FLUX-066 /
flux-perf-harness) now exists and is wired into CI, so the harness dependency is resolved. The remaining blocker is the on-device measurement runs — timing the iOSFluxUIKitreconciler and the AndroidShadowTreeRendererrequires theruntimes/adapters to wire inMeasureFnclosures (device/simulator +xcodebuild/kotlinc, unavailable in the changelog authoring env). Until those numbers exist, the §3.10 “< 3 ms” budget is unverified on-device and the UIKit-vs-SwiftUI tradeoff is unmeasured, so ADR-0048 is not decidable yet. See the reconciled[Unreleased]section.
CI — real Kotlin / Compose codegen check + rust-check unblock — DONE
- Provision the Compose toolchain and run the real
kotlinccodegen check without platform-37; gate on explicit Compose classpath and skip when no Android toolchain is present (99d12b2,8316f25,dff1b3a,57ca924,5f033d4,9ea941e,95e65d3,2fda50d,42f38e7,f8a68d0,b0034e8,985dc31,6759fee,8087ea2,d21fc4d). Unblockrust-checkonflux-devserverand portflux-devtools-uito the pinned gpui API; switch workspace to nightly (25b8907,2b1e511,94488cc).
Examples / stdlib
- Router navigation example + parity test for the route prop (
609d10e,4c04d30,9013ce3); stdlibplatform.fluxdrops the hand-writtenRouterHandle.navigate(ba11a24); scratchnotify_fsevent_test.rsandAGENT-044scratch notes removed (4958ac4,baf8a7b,5077e63).
Roadmap Phase 1 — IR monomorphisation of generic components — DONE
LoweredIr now carries monomorphizations: the generic instantiations lowering
actually specialised, read from TypedAST::instantiations through a per-name
source-order cursor in the new flux-ir/src/lower/mono.rs. Each generic call
site interns a mangled component name (Counter[Int] → Counter_Int), so every
instantiation gets its own ComponentId and the release backends can emit one
native type per instantiation instead of erasing the type argument.
LoweredIr::requires_monomorph() / specialised_names() expose the set to
codegen; non-generic programs are byte-identical to before. flux-devserver
merges each file’s instantiations into the compiled tree and exposes the merged,
deduplicated set as Pipeline::monomorphizations() — one entry per distinct
instantiation, so a backend emits each specialised native type exactly once even
when two files instantiate the same one. (Type checking is per-file, so each file
carries its own generic definition; the merge is what makes the tree complete.)
Roadmap Phase 3 — Patch::Reattach, state-preserving structural edits — DONE
New patch Reattach { old_id, new_id, node }, wire tag 0x07 (Appendix D §D.2:
u32 old_id | u32 new_id | Node), reported by Patch::is_state_preserving().
The differ emits it in two cases that previously destroyed live state:
- a node’s
component_idchanged at a stable node id (Column→Row) — wasReplace; - a re-spanned node kept its component and its parent/index — was remove + insert.
A genuine NodeKind change still emits Replace, and two different components
at the same slot still remove+insert, so state is never transferred to an
unrelated node. Signal state, refs, input focus and scroll position now survive
trivial refactors.
Roadmap Phase 2 — async suspension wire (AwaitSuspend / Resume) — server half DONE
Two frames close the async loop (Appendix D §D.12.8–§D.12.9), in a new
flux-ir-serde/src/resume.rs kept clear of the in-flight frame.rs:
AwaitSuspend(0x12, Host → Server), fixed 18 bytes:handler_id | cell | resume_ip. The host retains the register file, gas and written-signal snapshot locally, so only the suspension’s identity travels.Resume(0x13, Server → Host):handler_id | cell | is_error | value(D.5).is_errordistinguishes a settledReadycell from anErrorone (ADR-0044) so a faulting capability resumes the handler down its error path.
flux-devserver::AsyncBridge pairs host suspensions with capability completions
and emits the Resume bytes. It settles out of order: a completion that arrives
before its suspension is retained and delivered on arrival, otherwise a
capability that resolves faster than the host reports would deadlock the handler
forever. A cell resumes at most once, and independent cells never cross-resume.
The host halves (iOS/Android resume call sites, and the codegen Task {} /
suspend emission) are not in this change; they live in the runtime and codegen
directories owned by other in-flight work.
flux-parity/tests/async_resume_wire.rs closes the loop against the real
reference VM rather than a hand-built state: a handler whose CALL_CAP hits the
async capability parks on a Pending cell, its SuspendState crosses the
AwaitSuspend/Resume frames, and resume reaches Halt with the awaited
value in r0. It also pins the two properties a host could plausibly get wrong —
a write made before the await is replayed rather than dropped, and a non-Int
payload survives the codec.
Roadmap Phase 5 — host intern fallback: secondary id region
HostStrings now allocates from two disjoint regions below the canonical
ceiling — primary at 0x4000_0000, secondary at 0x7000_0000 — mapped through
a single id_for_index/index_for_id pair whose bijection is tested straight
across the boundary (that off-by-one is the one place two distinct strings could
silently alias onto one id). Crossing into the secondary region logs a warn!,
so the alarm fires while allocation is still unique instead of only once the
table is genuinely exhausted. InstanceRegistry::try_reattach (flux-ir) is the
host-side transfer for Patch::Reattach: it keeps the InstanceId, signals,
effects, closures and captured state, and refuses only an unknown source node
or a target node that already holds a live instance.
Roadmap Phase 5 — unknown host frames are diagnosed, not dropped
An unrecognised frame_type now logs a warn! and ships an Error frame
naming the server’s protocol version (Appendix D §D.12.10). Previously the
session loop silently ignored it, so a host built against a different protocol
version looked like an inexplicably dead channel.
FLUX-003 — parser: hand-written dream-syntax parser replaces pest — DONE
Replaced the pest-generated parser with a hand-written lexer
(crates/flux-parser/src/lexer.rs) + recursive-descent parser
(crates/flux-parser/src/parser.rs) that implement the indentation-delimited
“dream” surface syntax from docs/counter-syntax-dream.md as the single
normative syntax. flux.pest is deleted and pest/pest_derive are removed
from flux-parser/Cargo.toml.
- Indentation delimits structure (
compobodies,Column { … }blocks,fnbodies,matcharms); braces remain only for inline blocks (onMount { … },onClick: { … },fn(x) { … },match { … },when { … } otherwise { … },if { … } else { … }, and destructuring patterns likelet (users, { refetch }) = …). - Single public entry point
flux_parser::parse(source, file_id, path). Nounwrap/expectin production code; parse failures return aSpan-carryingParseError(what/where/why/how). - Byte-accurate spans, allocation-free on the hot path; meets the AGENTS.md §3.6
parse budget.
MAX_NESTING_DEPTH = 16retained (carried from ADR-0035). - Node-ID stability preserved via
flux_ir::compute_node_id(). - Migration: every
.fluxsource and inline test fixture in the workspace was migrated from the old brace-delimited syntax to dream syntax — stdlib, examples,flux-cli,flux-parity,flux-devserver,flux-ir,flux-types, and bothflux-codegen-*crates. The 10 Appendix B.3 parity examples, the flux-parity snapshot suite, and the flux-types bidirectional type checker all pass under dream syntax. - Recorded in
docs/adr/ADR-0046-dream-syntax-handwritten-parser.md.
FLUX-011 — codegen backends: Component bridge fix — PARTIAL
- Fixed the codegen bridge key mismatch: both
flux-codegen-swiftandflux-codegen-kotlinderived the component lookup key withExprTag(COMPONENT_TAG), butflux-ir::lower::idsrecords components underDeclTag(3)(disjoint byte ranges). The IDs never matched, soBridge::component(id)always returnedNoneand both emitters fell into theFluxComponent_<id>/EmptyViewplaceholder branch. Now keyed underDeclTag(3)— b31/b34/b37/b39 codegen trees are structurally equal to the dev tree (parity equivalence holds for those examples). - Blocker (out of scope): 6/10 B.3 examples (b32,b33,b35,b36,b38,b310)
still fail the parity gate, but at the
flux-irlowering step (unsupported handler operand: Call {...}forNumeric.one()/Rectangle(...);unsupported handler expressionforrouter.navigate(...),refetch(),Auth.login(...),...spreads). These live incrates/flux-ir/src/lower/bytecode.rs(issue 5’s lowering scope), not the codegen crates. The gate cannot reach 10/10 from the codegen side; the flux-ir handler-lower gap must be landed first. Committed ase50e518.
DevTools — bidirectional telemetry suite (FLUX-DevTools) — DONE
Implemented the Flux DevTools suite per the 2026-08-26 spec: a bidirectional
debug telemetry channel (host → server → gpui DevTools app) with wire-protocol
extensions, host instrumentation, a dev-server source-map enrichment bridge, a
gpui desktop crate (time-travel store + views), and an adapter debug hook.
ADRs ADR-0039…ADR-0042 (the spec requested ADR-0030…ADR-0033, but those numbers
are already taken by unrelated topics, so the next free slots were used).
DevTools — signal-graph dependency-edge rendering (FLUX-058, LANE-P) — DONE
-
The signal-graph view now renders reactive dependency edges:
ReconstructedState.signal_edges(per-signalVec<EffectId>of readers) is reconstructed fromEnrichedTelemetryEvent::SignalWrite { triggered_effect_ids, .. }, andviews/signal_graph.rsrenders each assig#{id} → fx#{e}(or∅when a signal has no readers). This is PRD-P user story 2 (“what reads a signal”). -
Pinned with two deterministic, socket-free unit tests in
crates/flux-devtools-ui/src/time_travel/reconstruct.rs:replay_tracks_signal_dependency_edgesandreplay_keeps_per_signal_reader_sets(each signal is its own graph node; reader sets do not bleed across signals).cargo test -p flux-devtools-ui --libis 18/18 green. -
CAVEAT: the inverse “what wrote this signal” direction is not representable —
SignalWritecarries nowriter_id, a telemetry-schema gap (separate issue), not a view bug. -
Wire protocol (
flux-ir-serde) — newtelemetry.rsmodule withTelemetryEvent/DebugCommand/EnrichedTelemetryEventand their frame types (TelemetryFramehost→server,EnrichedTelemetryFrameserver→DevTools,DebugCommandFrame). Frame kinds0x10(Telemetry) and0x11(DebugCommand) per Appendix D §D.12. Length-prefixed union events, byte layout kept bit-identical to the Swift/Kotlin host encoders. 40 nextest cases green (round-trip + byte-level conformance).flux-ir-serde::frame.rsand its in-flightconformance.rs/round_trip.rswere deliberately NOT touched. -
Dev server bridge (
flux-devserver) —debug_bridge.rs:SourceMapbuilt fromLoweredIr(node spans viaIRArena::span_for_node_id, bytecode-offset→closure-span heuristic),enrich/enrich_with_span, and a pureDevToolsRouter(telemetry broadcast + command forwarding).serve_devtoolsaccepts:7333, enriches hostTelemetryframes with source spans, and broadcasts them to DevTools clients (commands drain to a host channel owned by the host-session agent).Pipeline::devtools_source_map()feeds it from the last-good IR, andDevServer::start()now binds:7333and spawns the endpoint (added thedebug_bridgemodule tolib.rs). A newhost_telemetry_reaches_devtools_clienttokio integration test proves the full host→server→DevTools-client data path over a real WebSocket. -
gpuidesktop crate (flux-devtools-ui) — new crate withDevToolsState,wire_client(decodes enriched frames, sendsDebugCommands), a time-travel ringTimelineBuffer+Reconstructstate simulator (base-state replay), andgpuiviews (vm_inspector/signal_graph/component_tree/timeline) gated behind thegpui-uicargo feature.gpuiis a git dependency (ADR-0041) pinned tozed-industries/zed@1ff7cb6…; the always-on core isgpui-free so it builds + tests on the workspace’s stable toolchain (gpui itself needs nightly forstd::hint::cold_path, so the desktop UI is compile-gated on nightly). 15 nextest cases green. -
Host instrumentation (iOS + Android) —
TelemetryEvent/DebugCommand/TelemetryBridge/VMTelemetrySinkfor iOS (runtimes/ios/.../Debug/Telemetry.swift) and Android (.../vm/debug/Telemetry.kt,TelemetryBridge.kt). Both reproduce the Rust wire codec exactly. Guarded by#if DEBUG/BuildConfig.DEBUG. Emit call-sites are inserted intoFluxBytecodeVM.run(iOS both run paths + AndroidFluxBytecodeVM.kt) andSignalGraph.write(iOS), each guarded so there is zero release impact. Each bridge owns the host →:7333DevTools client: iOSfluxDevtoolsConnect()opens aws://127.0.0.1:7333/devtoolssocket and wiresonFlushto send batched frames; AndroidTelemetryBridge .connectDevtools()does the same over OkHttp. With the sink installed (fluxDevtoolsConnect/connectDevtoolscalled once at host startup), emitted VM/signal events now flow to the dev server. All three platforms compile (iOSxcodebuildfor the simulator, Android./gradlew :runtimes:android:host: compileKotlin, Rust nextest). -
Adapter debug hook (
adapters/ui-swift) —DebugMetadata.swiftaddsNativeViewDebugMetadataand an#if DEBUGinspectDebugState(of:)extension onFluxAdapter(defaultnil) + a concreteContainerAdapterimplementation. Placed in a new file so the in-flightAdapterKit.swift/ContainerAdapter.swiftare untouched. The hook is ready to be called by any adapter’s render path to emit aviewMutation/debugStateevent (the concrete caller is owned by the adapter agent). -
Spec deviations / notes — two concrete frame types (
TelemetryFrame,EnrichedTelemetryFrame) were used instead of a single genericTelemetryFrame<E>(the skill’s suggestion) because the genericWireEventtrait leakedpub(crate)Writer/Readertypes and produced dead-code; the two concrete types are cleaner and keep the channel types explicit. Thegpuidesktop UI (views) is nightly-gated because the pinnedgpuigpuirevision requiresstd::hint::cold_path; the always-on data path (host →:7333→serve_devtools→ DevTools clients) is fully exercised by the Rust integration test on stable. -
PRD-P follow-up — shipped the scaffolded app (formerly deferred pieces):
- Signal-graph dependency edges (user story 2):
ReconstructedStatenow carriessignal_edges(signal → effects that re-run when it changes, derived fromSignalWrite::triggered_effect_ids);reconstruct_staterecords them andsignal_graphview renderssig#n → fx#m, fx#k. run_appno longer dead-ends: it now spawns the realwire_clientingest loop against127.0.0.1:7333and feeds the sharedDevToolsState, which all four views read (state shared asArc<DevToolsState>between the async loop and the gpui views — the priorEntityindirection was replaced so the ingest loop and UI hold the sameArc). A failed handshake is logged and tolerated; the window still opens.- Headless end-to-end proof:
ingest_loop_pulls_from_live_serverboots a real WebSocket server, the DevTools client connects and the ingest loop applies the frame toDevToolsState(timeline_len >= 1). 17 devtools-ui nextest cases green. - Live launch verified:
flux dev --root examples/counterboots and binds the DevTools WebSocket on:7333; a DevTools client handshake against the live endpoint succeeds and the connection is held (telemetry flows once a native host connects — the on-device piece).
- Signal-graph dependency edges (user story 2):
FLUX-019 — dev server (flux-devserver) — DONE
Implemented the hot-reload dev server: the full
parse → type_check → lower → diff → serialize → send pipeline behind a
WebSocket patch channel, an HTTP asset server, and a debounced file watcher
(crates/flux-devserver).
config.rs—ServerConfigbuilder: WebSocket:7331(DEFAULT_WS_PORT), HTTP:7332(DEFAULT_HTTP_PORT), 50 ms watch debounce, 16 ms frame coalescing,--profilephase timings. Port0binds an ephemeral port (used by the tests).pipeline.rs(+pipeline/tree.rs) —Pipelineowns the project’s last-goodLoweredIr. Each compile runsflux_parser::parse→flux_types::type_check→flux_ir::lowerper file, merges the per-file arenas, then either builds the firstInit(§D.12.2) or diffs against the retained tree viaflux_differ::diffand builds aDelta(§D.1). A compile failure returns aDiagnosticand retains the previous good tree — noDeltais emitted. All wire strings come fromIRArena::string_table()(Gap G3, now populated).server.rs(+server/session.rs) —DevServer::startbinds both listeners, compiles once, and returns aRunningServercarrying the resolved addresses plus a shutdown switch. One connection per blocking task:Hello→Init(§D.12.1/§D.12.2), then frames fan out from a per-client queue. A reconnect repeats the handshake and gets a freshInit(§D.13). A malformed handshake gets anErrorframe (§D.12.3).watch.rs—notifywatcher, debounced then coalesced; re-reads only.fluxfiles, recompiles, and broadcasts (or ships anErrorframe).assets.rs— axum asset server under/assets/{*path}with..-traversal rejection, extension-derived content types, and a/healthprobe.
Acceptance (tests/integration.rs, real sockets + a tungstenite client):
Hello→Init < 10 ms, save → Delta with a non-empty patch stream, reconnect
resends Init, malformed source → Error with the good tree retained (the next
good save still ships a Delta, not a fresh Init), and asset serving/404.
cargo nextest run -p flux-devserver: 12/12 green (RED first — the four
acceptance tests failed against the placeholder lib.rs); workspace 258/258.
cargo fmt --check, cargo clippy --all-targets -- -D warnings,
cargo test --doc, cargo doc all clean.
Deviation (documented): the WebSocket side drives the synchronous
tungstenite state machine on Tokio’s blocking pool rather than the async
WebSocketStream adapters. tokio-tungstenite’s async Sink/Stream impls
require naming futures_util traits, and futures-util is not a pre-wired
dependency of this crate (manifests are frozen, AGENTS.md §1.3/§3.1). One
blocking task per connection is equivalent in behaviour and keeps the manifest
untouched.
Spec note: §D.12.2 carries exactly one root node. A project whose arena has
several roots (several top-level components — the common case) ships a synthetic
Component wrapper node whose children are those roots; the host renders the
wrapper’s children in declaration order.
Gap G1 — handler transport on the wire (ADR-0028) — DONE
Resolved “Gap G1” from the boundary contract: handler closures (ClosureIR
bytecode + captured signals) had no wire transport — Init/Delta frames
carried patches + strings only, and ClosureRef.bytecode_offset/len pointed
into a bytecode blob no frame shipped. Implemented as the contract’s reserved
flux-ir-serde second pass (crates/flux-ir-serde).
wire.rs— promoted theHandlerDefcodec (Appendix D §D.8) from#[allow(dead_code)]to live:encode_handler_def/decode_handler_def, plus a sharedencode_bytecode_blob/decode_bytecode_blob(D.12 handler section:u32length + raw little-endian bytecode).frame.rs—InitandDeltaframes now carry a handler section immediately after the string stream: a shared bytecode blob, then aHandlerDefstream (D.8) whoseClosureRefs index the blob bybytecode_offset/bytecode_len. The reserved D.1handler_countslot (offset 12) now carries the trueHandlerDefcount. A frame with no handlers writes a zero-length blob so the decoder never underflows — backward-compatible with existing handler-less frames.encode.rs—serialize_patches(patches, table, closures: &[ClosureIR])threads closures into theDeltaframe;deserialize_patchesnow returns(Vec<Patch>, Vec<ClosureIR>)(the frame’s handler section). Doc examples updated.
Public API surface: Frame::init(..., closures), Frame::delta(..., closures), and InitFrame/DeltaFrame gain a closures: Vec<ClosureIR>
field. The only consumers at merge time are flux-ir-serde’s own tests/bench
and the devserver stub (which does not yet ship handlers), so the signature
change is contained. No production (Swift/Kotlin) deserializer is touched — the
wire layout is additive and matches the spec’s reserved handler_count.
Tests (crates/flux-ir-serde/tests): 3 new G1 tests — init_frame_carries_handlers_round_trip,
delta_frame_carries_handlers_round_trip (assert bytecode + captures round-trip
and serialization is byte-deterministic), and empty_handler_section_is_zero_length_blob.
All 28 crate tests pass; cargo clippy -- -D warnings, cargo fmt --check,
cargo doc, and doctests all clean.
Unblocks FLUX-019 (devserver), which the contract explicitly gates on G1 landing first.
Phase 1 — Native runtime
FLUX-006 — iOS host runtime (VM + wire + reconciler + executor) — DONE
Added the iOS native runtime under runtimes/ios/Sources, a behavioral mirror
of flux-vm-ref (FLUX-005) and the Kotlin/Android runtime (FLUX-007):
Sources/Values/FluxValue.swift— the value enum (Int/Float/Bool/Str/HandlerRef/Null/List/Record),Sendable, with explicitEquatable/CustomStringConvertible(auto-synthesis fails for recursive enums).Sources/VM/—FluxBytecodeVM(the register VM, Appendix E),OpCodes,Instructions(decoder) andVMErrorwith byte-offset fault reporting. The gas model mirrors the oracle exactly:entryGas = 100_000,r15mirrors the live budget,HALTis free (ADR-0021),JUMP/COND_JUMP/COND_JUMP_NOTresolve to absolute offsets, integerDIV/MODby zero raisesDivByZero(ADR-0023),GET_FIELDonNullraisesNullDereference(ADR-0024).Sources/Wire/—ByteReader(little-endian cursor),WireModelsandFrameDeserializer(Appendix D: Node, Child, Value, Patch, ClosureRef, StateDelta, StringEntry, FileEntry, Error/Init frames).Sources/Shadow/—ShadowTree(the host node model, Appendix C §C.1) and the keyedShadowTreeReconciler(stableNodeId+u64splice keys, Appendix D §D.4) that mutates native views in place.Sources/Signal/SignalGraph.swift— a SolidJS-style signal store conforming toSignalStore, O(1) reads, minimal-write notifications.Sources/Adapters/AdapterKit.swift— theFluxAdapter/FluxViewcontract (Appendix F) plus in-dirMockAdapter/MockView(scope item 11); realFluxUIKitwiring is deferred to FLUX-016.Sources/Executor/FluxExecutor.swift+FluxAppMain.swift— the executor folds handler VM output back into the graph and never lets a VM error escape (surfaced as aFluxRootViewerror overlay).
Tests (runtimes/ios/Tests, all passing under xcodebuild test):
ISAConformanceTests— runs the 71 shared/tests/isa-vectorsgolden vectors against the native VM (same suite the Rust and Kotlin VMs run).WireDecodeTests— hand-built byte-vector round-trips for every wire union.RuntimeE2ETests— Init→reconcile→mock-view build, signal fold-through, gas exhaustion via aJUMPloop, and invalid-opcode capture.
Frozen-manifest note: runtimes/ios/project.yml is a frozen boundary-contract
artifact. Two in-scope edits were required because the foundation skeleton (a)
omitted an Info.plist for the test bundle (blocking xcodebuild test) and (b)
declared a FluxUIKit package dependency that was still mid-flight (FLUX-008)
and did not compile. Both are documented inline in project.yml; FLUX-016
restores the real kit.
FLUX-016 — iOS adapter↔runtime integration (real FluxUIKit) — DONE
Replaced the in-dir MockAdapter/MockView scaffold with the real Swift
adapter kit (adapters/ui-swift, FLUX-008), driving real UILabel,
UIButton, UIStackView and UINavigationController views. No production
code in adapters/ui-swift was modified; it is consumed through its public
FluxAdapter/FluxExecutor API.
Sources/Adapters/AdapterKit.swift— the integration bridge between the runtime’s id-basedVMValueand the kit’s resolvedFluxValue/Props:StringTable(id↔name interning),toKit/kitProps/toRuntimeconverters, a type-erasedAnyFluxAdapter, andAdapterRegistrymappingComponentId→ a fresh adapter instance seeded from the Init frame’s string table. The hostFluxExecutoris injected into each adapter at creation time via the kit’s publicinit(executor:)(the kit’sexecutorproperty isinternal, so it cannot be set after construction).Sources/Shadow/ShadowTreeReconciler.swift— now nodes-driven and identity- preserving: native views are reused across frames/patches (verified by the E2E tests asserting===identity), and it handlesUpdate/Remove/Replace/Insert/Reorder/Handlerpatches. Handlers are bound once at build time so aUIButtondoes not stackUIActions on every reconcile.Sources/Executor/FluxExecutor.swift—FluxRuntimenow conforms to the kit’sFluxExecutorprotocol.apply(_:)drives the reconciler for both full and patch frames (a previously-brokenguard let rootearly-returned on patch frames withroot: nil, so patches were silently dropped).dispatch(_:)runs handler bytecode through the VM and re-reconciles the frame.Sources/Values/FluxValue.swift+ runtime rename — renamed the runtime’s ownFluxValue→VMValueandFluxExecutorclass→FluxRuntimeto break a module name collision: the kit module is also namedFluxUIKitand exports aFluxExecutorprotocol andFluxValuetype, andimport FluxUIKit as FUImodule-aliasing is not supported by this toolchain. Renaming lets the kit’s names be referenced unqualified.Sources/Wire/—FluxFramenow carries a flatnodes: [UInt32: ShadowNode]map (populated byFrameDeserializer), which the reconciler uses to resolve child id references (Appendix D §D.4) without re-decoding.Sources/FluxAppMain.swift— seeds the realAdapterRegistryfrom the Init frame’s string table.
Tests (runtimes/ios/Tests):
RuntimeE2ETestsrewritten to drive the real adapters (no mocks): a hand- built Init frame produces a realUILabel/UIButton/UIStackView/UINavigationControllertree; tap→dispatch→VM→reconcile updates the label text without recreating theUIView(identity asserted); a patchUpdatereuses the view; Router push→pop→push reuses the screenUIViewControllerby identity (state preserved);AdapterRegistryresolves all 7 stdlibComponentIds; gas exhaustion is reported.
Verification: out-of-tree xcodegen project wrapping Sources/Tests (the
frozen project.yml is untouched); xcodebuild test on iOS Simulator passes
14 tests, 0 failures (2 skipped), with SWIFT_TREAT_WARNINGS_AS_ERRORS=YES.
Cross-host naming convergence (ADR-0049 / PRD-W) — DONE
Unified the type names that had drifted between the Android host runtime
(FLUX-007) and the iOS host runtime (FLUX-006/FLUX-016), which are both
behavioral mirrors of flux-vm-ref. Each shared concept now has one canonical
name, anchored to the Rust oracle; enum cases keep each language’s idiomatic
casing (Swift lowerCamelCase, Kotlin PascalCase/SCREAMING_SNAKE) and are
not renamed. See docs/adr/ADR-0049-cross-host-naming-convergence.md and
docs/issues/PRD-W-cross-host-naming-convergence.md.
- iOS host (
b2e330b):VMValue→FluxValue,VMError→VmError,OpCode/opCode→Opcode/opcode,StringResolvable→StringResolver,FluxRuntime→FluxExecutor. Builds green viaxcodebuild -scheme FluxHost -sdk iphonesimulator. - Android host (
fe4637f): wireFrame→FluxFrame(theFrameDeserializertype and theTraceEvent.Frametrace variant were left distinct). Builds green via./gradlew :runtimes:android:host:compileKotlin. - Swift kit (
438510f): the umbrellaenum FluxUIKitwas renamed toFluxUIKitModulebecause it shadowed the module of the same name and blocked module-qualified references (e.g.FluxUIKit.FluxValue) from the host bridge. - Docs (
a1bf136): added ADR-0049 and PRD-W, and fixed the stale names indocs/flux-architecture.htmland the wave-1/wave-3 spawn docs.
Phase 0 — Foundation
FLUX-001 — Foundation skeleton and flux-syntax crate — DONE
Added:
- Cargo workspace root with all 10 MLP crates and centralised
[workspace.dependencies]. Every dependency pinned to^MAJORat the latest stable version verified against crates.io on 2026-08-24:pest/pest_derive2.9,tokio1.53,tokio-tungstenite0.30,notify8.2,axum0.8,rmp-serde1.3,blake31.8,clap4.6,tracing0.1,tracing-subscriber0.3,serde1.0,thiserror2.0,anyhow1.0,criterion0.8,insta1.48,proptest1.11,parking_lot0.12,ahash0.8,smallvec1.15. rust-toolchain.toml(stable channel withrustfmt+clippy) and.gitignorecovering Rust, Xcode and Gradle artifacts.flux-syntaximplemented in full against Appendix C §C.1: ID aliases,Span,Value,TypeKind,StringTable,NodeKind,NodeRef,Child,Props,PropDiff,Patch,ClosureRef. Split acrossids,strings,value,ty,nodeandpatchmodules so no file exceeds 300 lines.- 38 behavioural integration tests in
crates/flux-syntax/tests/vocabulary.rs, written RED before the implementation, covering Unicode interning, empty and boundary spans, order-independent prop hashing,NaNfloat props, and wire-tag round trips. - Stubs for the nine remaining crates so
cargo checkpasses workspace-wide and Phase 1 agents can start against a compiling tree.
Notes and deviations from the spec:
- Rust edition 2024 and resolver 3 are used rather than the edition 2021 named
in the boundary contract, per the project-wide “latest stable” dependency
policy.
rust-versionis 1.85 (the edition-2024 floor), which is above the spec’s Rust 1.75 constraint (C-001) and satisfies it. Props::get_handlerreturnsOption<HandlerId>rather than Appendix C’s sentinel0. Handler ID zero is a legitimate closure, so a sentinel would make an unbound event indistinguishable from a bound one. No wire format change; the encoder still writes the concrete ID.NodeKind::from_tagis a total function returningOption, replacing Appendix C’sstd::mem::transmuteinNodeView::kind. The crate is#![forbid(unsafe_code)], and a corrupt or future-versioned frame must be reported as a protocol error rather than producing an invalid enum value.Props::hashis an XOR fold of per-field BLAKE3 digests, making it order-independent so that a reordered-but-equal prop map does not force a wire update.NaNis canonicalised before hashing so equal props hash equal.StringTablefields are private withintern/resolve/lookup/delta_fromaccessors, rather than Appendix C’s publicstrings/lookupfields, so the dense-ID invariant the wire delta depends on cannot be violated by a caller.
Verification:
cargo nextest run --workspace— 38 tests run, 38 passed, 0 skipped.cargo test --doc -p flux-syntax— 6 doctests passed.cargo clippy --workspace --all-targets -- -D warnings— clean.cargo fmt --check— clean.cargo doc -p flux-syntax --no-deps— clean.
Tooling — cargo nextest mandated
Changed:
AGENTS.mdnow mandatescargo nextest runas the project’s test runner and forbidscargo test, with the single exception of doctests (cargo test --doc), which nextest does not support. Added the useful invocations, a note that nextest’s exit code must not be masked by a pipe, acargo-nextestrow in the dependency table, and a doctest line in the Rust reviewer checklist. Local runner is cargo-nextest 0.9.135.AGENTS.md§2.1 now records the edition-2024 /resolver = "3"/rust-version = 1.86reality of the workspace against the local rustc 1.94.1, superseding the spec’s “edition 2021, Rust 1.75” wording.- Workspace
rust-versionraised from 1.85 to 1.86:criterion0.8.2 requires 1.86, and the dependency policy is latest-stable.
Added:
[dev-dependencies]and[[bench]]targets pre-wired into every crate manifest (criterion,insta,proptest,tokioas each crate needs), plus compiling criterion bench stubs underbenches/. Agents may not edit manifests, so these must exist before Phase 1 starts.
FLUX-001 — extended to boundary contract v2
The boundary contract was revised to v2 mid-flight. v2 widens FLUX-001’s scope, so the issue was reopened and the following delta implemented.
Added:
flux_syntax::opcode— the VM instruction vocabulary, normative per Appendix E §E.1. v2 §1.5 requires it influx-syntaxas the single Rust source of truth for the ISA; the native Swift and Kotlin VMs declare their own constants from the same table and the golden ISA vectors pin all three together. All 54 opcodes with raw byte constants, a totalfrom_bytedecoder, operand and instruction widths from the “Args (bytes)” column, and Appendix E mnemonics. 18 tests written RED first; they caught a real error — Appendix E defines 54 opcodes, not the 48 initially assumed. Split intoopcode.rs+opcode/{decode,raw,width}.rsto respect the 300-line limit.- Two new workspace members, taking the workspace from 10 to 12 crates:
flux-vm-ref(FLUX-005, the Rust reference VM — a test oracle that never ships, since production VMs are native per ADR-0002) andflux-parity(FLUX-023, the dev-versus-release parity harness). - v2-mandated cross-crate dev-dependencies that agents may not add for
themselves:
flux-irgainsflux-vm-refso FLUX-018’s lowering tests can execute emitted bytecode, and both codegen crates gainflux-parser+flux-typesfor their full-pipeline tests.serde_json(ISA vector loading) andtempfileadded to the workspace dependency set. - Frozen platform build manifests (v2 §1.2 and R2 place these under
foundation ownership, frozen after Phase 0), all verified by a real build:
adapters/ui-swift/Package.swift— SPM, swift-tools 6.0, iOS 16 minimum (spec C-002), Swift 6 language mode.swift buildandswift testpass.runtimes/ios/project.yml— XcodeGen 2.46.0 spec for theFluxApphost, glob-based sources so agents never need a manifest edit, referencingadapters/ui-swiftas a local package.xcodegen generatethenxcodebuild -destination 'generic/platform=iOS Simulator' buildsucceeds.settings.gradle.kts,gradle/libs.versions.toml,adapters/ui-kotlin/build.gradle.kts,runtimes/android/app/build.gradle.kts, and the Gradle wrapper../gradlew :adapters:ui-kotlin:testpasses.
- Compiling platform source skeletons so CI and the platform agents start from a
green build:
FluxUIKit,FluxAppMain,FluxHostActivity,FluxUiKit, anAndroidManifest.xmland a theme. - R10 wire-fixture loaders in both runtime test suites: each reads
FLUX_WIRE_FIXTURESand skips cleanly when unset (XCTSkip/ JUnitassumeTrue), so FLUX-023 can drop in real fixtures without touching runtime code.
Dependency versions, all verified against crates.io, Google’s Maven, Maven Central and the Gradle plugin portal on 2026-08-24 rather than assumed: Gradle 9.7.1 (latest; also satisfies AGP 9.3.2’s 9.5.0 floor), AGP 9.3.2, Kotlin 2.4.10, Compose BOM 2026.08.00, core-ktx 1.19.0, activity-compose 1.13.0, navigation-compose 2.9.8, lifecycle 2.11.0, OkHttp 5.5.0, coroutines 1.11.0, JUnit Jupiter 6.1.3, MockK 1.14.11, Turbine 1.2.1, msgpack-core 0.9.12, ktlint plugin 14.2.0, serde_json 1.0.151, tempfile 3.27.0.
Notes and deviations:
- AGP 9 removed the
kotlin-androidplugin in favour of built-in Kotlin support, soruntimes/android/app/build.gradle.ktsdeliberately does not apply it. Applying it — as pre-AGP-9 documentation and most training data suggest — breaks the build outright. Recorded here because the android-runtime and kotlin-adapters agents will be tempted to add it. AGENTS.mdspecifies Swift 5.10+/Xcode 15.4+ and Kotlin 2.0+. The installed toolchain is far newer (Xcode 26.4, Swift 6.3, Kotlin 2.4.10, JBR 25), and the latest-stable dependency policy takes precedence. The practical consequence is that Swift 6 strict concurrency is enforced, which constrains FLUX-006’s@MainActorand background-executor design.compileSdk/targetSdkare 36, not the API 37 maximum AGP 9.3 supports: 36 is the latest installed platform, and 37 would not build here.adapters/ui-kotlinis a plain Kotlin JVM library rather than an Android library. The adapter contract (Appendix F) is prop-shape only and needs no Android APIs, so a JVM module keeps its tests fast and runnable without an emulator.
Verification (real command output, not assumed):
cargo nextest run --workspace— 56 tests run, 56 passed, 0 skipped.cargo test --doc -p flux-syntax— 8 doctests passed.cargo check --workspace— all 12 crates compile.cargo clippy --workspace --all-targets -- -D warnings— zero warnings.cargo fmt --check— clean.swift build/swift testinadapters/ui-swift— build complete, 1 test passed.xcodegen generate+xcodebuild buildinruntimes/ios— BUILD SUCCEEDED../gradlew --version— Gradle 9.7.1 on JBR 25../gradlew :adapters:ui-kotlin:test— BUILD SUCCESSFUL.
Toolchain probe (recorded so agents know what can actually be verified):
- Xcode 26.4 (17E192), Swift 6.3, iOS 26.4 SDK, 1 iPhone simulator available.
- Android Studio 2026.1 with bundled JBR 25 and Kotlin 2.3.10; SDK platforms
30–36, build-tools to 36.1.0, adb 1.0.41, emulator 37.1.11, AVD
Medium_Phone_API_36.1. - A physical device is attached (
15a3cc41de5b, Android 13 / API 33), so on-device verification is possible for FLUX-007 and FLUX-023. - No
gradleorkotlinconPATH; the committed wrapper is the supported entry point.JAVA_HOMEmust point at Android Studio’s JBR (the system JDK is Zulu 21, which also works — AGP 9.3 requires only JDK 17+).
FLUX-009 — Kotlin adapter kit + dev adapters — DONE
Added the Kotlin mirror of the Swift adapter kit (FLUX-008) under
adapters/ui-kotlin/src. The module is a kotlin.jvm target (the frozen
build.gradle.kts has no Android dependency), so adapters are written against
a platform-neutral FluxNativeView abstraction the Android runtime (FLUX-007)
later backs with a real android.view.View.
Kit types:
FluxValue— sealed interface mirroringflux_syntax::Value(Appendix C.1), with typed accessors onRecord.Props+PropsIndex— typed accessors (getString/getBool/getRecord/ getColor/getFont) and the canonical component-local field indices for every adapter; missing fields degrade tonull/default, reserved-zero handler id.FluxColor/FluxFont— value types mirroring the Color/Font records (Appendix F) withtoRecord()encoders.FluxExecutor+HandlerEvent— the narrow boundary adapters may touch; adapters hold it through aWeakReferenceso a stale executor is GC’d.FluxNativeView+FluxNativeViewImpl— platform-neutral view contract and the kit’s in-memory test double.FluxAdapter— thecreate/update/setChildren/bindHandler/destroycontract;reconcileChildrendoes keyed reconciliation that reuses view instances (no recreate on reorder/remove).
Dev adapters (Appendix F): TextAdapter, ButtonAdapter, TextFieldAdapter,
ColumnAdapter/RowAdapter (shared base), ScreenAdapter, RouterAdapter.
Router/Screen reconcile by stable node id and preserve the existing screen
view instance across push/pop, matching NavHost semantics.
Verification:
./gradlew :adapters:ui-kotlin:test— 22 JUnit 5 tests green: FluxValue/Props accessors, leaf adapter create/update/destroy + weak-executor dispatch, linear keyed diff, and router screen-state preservation../gradlew :adapters:ui-kotlin:ktlintCheck— zero violations.
Spec errata resolved before Phase 1 (orchestrator ADRs)
Before dispatching the golden ISA vector agent (FLUX-002), two internal contradictions in Appendix E were found and resolved via ADRs (create-only, orchestrator-owned):
- ADR-0021 (gas accounting erratum) —
docs/adr/ADR-0021-gas-accounting.md. §E.6 says gas is “decremented per instruction,” but both concrete examples (§E.5 = 4 gas for a 5-instruction sequence ending in HALT; the contract’s FLUX-002 vector example = 4 gas forREAD/LOAD/ADD/WRITE) charge 4, not 5. Resolution: every decoded instruction costs 1 gas exceptHALT(0x00), which terminates the handler and is free;GAS_CHECK(0xC0) is charged 1 gas before its budget check. Entry budget inr15= 100,000. - ADR-0022 (byte-length erratum) —
docs/adr/ADR-0022-byte-length-erratum.md. §E.5 claims the canonicalcount = count + 1example is “21 bytes,” but the literal encoding (6+10+4+6+1) is 27 bytes. The §E.1 operand-width table is normative; the “21 bytes” prose is an erratum. All vector and VM decoders compute lengths from the width table only.
Both ADRs are referenced by FLUX-002 (vectors), FLUX-005 (flux-vm-ref),
FLUX-006 (Swift VM), and FLUX-007 (Kotlin VM) so all three implementations agree.
FLUX-002 — golden ISA vectors — DONE
Author /tests/isa-vectors/** as pure JSON fixtures from Appendix E: 71 vectors
covering all 54 opcodes (happy + boundary + error + register conventions +
CALL_CAP + pattern matching). Each vector’s bytecode_hex is validated against
the §E.1 width table and its expected_* fields are computed by a faithful
reference interpreter, so the fixtures are internally self-consistent.
Schema and a per-opcode coverage matrix are documented in
tests/isa-vectors/README.md. The generator (/tmp/gen_vectors.py) is the
oracle that produced them; it is kept out of the repo (it is a build-time tool,
not shipped source).
Cross-cutting spec defects surfaced and resolved by ADR while authoring the vectors:
- ADR-0022 — §E.5 “21 bytes” is wrong; the normative §E.1 width table gives 27.
- ADR-0023 —
DivByZeroadded as an explicit error kind (§E.6 omits it but integer DIV/MOD by zero must fail). - ADR-0024 —
GET_FIELDonNull→NullDereference(per §E.6); on other non-records →TypeMismatch. - ADR-0026 —
GET_FIELDbytecode width corrected to 4 bytesREG_U16_REG(dst, idx, obj), matchingSET_FIELD/EXTRACT_FIELD. The originalflux-syntaxwidth (REG_REG_U16, 3 bytes) could not carry all three operands and misaligned every subsequent instruction.
FLUX-004 — flux-ir arena, node IDs, instance registry — DONE
Implemented the IR core (Appendix C §C.1) as flux-ir (no unsafe, no
unwrap/expect/panic! in library code, every public item documented,
clippy/fmt/doc clean, TDD throughout):
node_id.rs—compute_node_id(parent, kind, span, key)per ADR-0013: BLAKE3 of(parent, kind tag, file_id, start, end, key-or-sentinel), truncated tou32. Pure and source-stable.arena.rs—IRArenastruct-of-arrays (hot fields in parallelVecs; props/children/handlers in length-prefixed cold blobs) withpack()/get()/NodeViewaccessors, and blob (de)serialisation forValue,Child, handlers.closure.rs—ClosureIR(bytecode + captured signal IDs, ADR-0014).instance.rs—ComponentInstance+InstanceRegistry(node→instance index for state-preserving hot swap, ASR-003).builder.rs—ArenaBuilder+Nodeinput type, the hand-construction API the differ/codegen/parity suites need.
Verification:
- 17 unit tests (pack/unpack round-trip, instance registry, closures).
- 3 doctests.
tests/roundtrip.rsproptest (200 cases): pack/unpack round-trip and node-ID stability (identical inputs → identical ID; sibling at a different span → distinct ID).benches/arena.rscriterion bench: pack 100 nodes ≈ 0.1 ms (< 1 ms budget, §3.6).
Deviation from the appendix’s illustrative IRArena: kinds is
Vec<NodeKind> (not Vec<u8>) and spans are stored inline (not in a blob),
both to avoid unsafe transmute / mis-tagged-value reads (ADR-0002,
AGENTS.md §1.2). NodeView::kind() uses NodeKind::from_tag — no unsafe.
FLUX-005 — flux-vm-ref reference VM — DONE
Implemented the Appendix E reference interpreter as a test oracle (no unsafe,
no unwrap in library code, every public item documented, clippy/fmt/doc
clean). Structure: error.rs (typed VmError with VmErrorKind + optional
span), decode.rs (decode_program over Opcode::operand_len), vm.rs (the
interpreter, gas model per ADR-0021, SignalStore trait + InMemorySignals),
lib.rs (re-exports + doctest).
Verification:
- 6 unit tests (gas accounting, error kinds, register conventions).
- 1 doctest (LOAD + HALT).
- 71-vector conformance test:
tests/conformance.rsloads every golden vector, runs it throughrun(), and assertsexpected_error/expected_signals/expected_registers/expected_gas_used. All 71 pass.
The Swift (FLUX-006) and Kotlin (FLUX-007) runtimes must pass this same suite.
Governance — ADR numbering collision fixed (process, not a numbered FLUX issue)
The four VM-errata ADRs (ADR-0006/0007/0008/0009-*.md) were published under the
ADR-NNNN- filename scheme, which collides with the canonical decision sequence
embedded as ### ADR-NNNN: headings in mlp-appendices.md Appendix A
(ADR-0006 static types, ADR-0007 register VM, ADR-0008 MessagePack, ADR-0009 arena).
A bare grep ADR-0008 now returns two unrelated documents. This violates the
contract’s R9 naming rule (<scope>-<slug>.md) and is exactly the failure mode that
rule was written to prevent.
Resolution (see docs/adr/ADR-0028-adr-naming-and-numbering.md):
- The four VM-errata ADRs were renumbered
ADR-0006/0007/0008/0009 → ADR-0021/0022/0023/0024viagit mv(history preserved, no content edit) so they no longer collide with the canonical ADR-0006–0009 inmlp-appendices.mdAppendix A. Every cross-reference (CHANGELOG, isa-vectors README,flux-vm-refcrate comments) was updated to the new numbers. - Added
docs/scripts/check-adr-numbering.sh, a CI guard that fails when any new agent ADR reuses a reservedADR-NNNN. The four renumbered files are listed as exceptions so the accepted state stays green. mlp-spec.mdAppendix A no longer duplicates the canonical ADRs; it is now a single pointer tomlp-appendices.mdAppendix A.mlp-appendices.mdgained an “Appendix A — Continuation (ADR-0021…)” block recording the renumbered decisions.
[Unreleased] — Reconciled from working tree (a8c86d0..HEAD)
The entries below cover every landed commit between a8c86d0 (2026-08-27) and
HEAD; statuses were reconciled against the issue frontmatter (see
docs/issues) and the on-disk tree, not the prose above. Items marked
[unverified] have a commit but no green platform build recorded here.
Language maturity — FLUX-051/052/053/054/055 — DONE
edabdfblands the FLUX-051/052/053/055 language-maturity batch: optional chaining (?., FLUX-053,0474cfb),Nullliteral +IsNullopcode (1788c95), structural record typing / width-subtyping (unify_records, FLUX-054 / ADR-0052,f93cbc7), in-languageResult[T,E](FLUX-055), slot/children composition (FLUX-052), and ForEach iteration syntax (ADR-0050).- Caveat (carried by FLUX-072): ForEach lowers to an empty
Child::Spliceandflux-vm-refstill has no list ops (APPEND/LIST_GET/LIST_LEN/LIST_REMOVE/LIST_CLEAR);FLUX-051is parse+type-complete only, not end-to-end. The list-value + VM-ops work is tracked in FLUX-072.
Stdlib — Modal/Sheet/Dialog (FLUX-038) — DONE
ba66f0eregistersModal/Sheet/Dialogoverlay containers in the ADR-0047 single-source primitive registry; native adapter mapping inherits the container contract. Public surface aligned to RN/Expo naming (62b8db3,aaf8fd2,b057a36,e8e936a,5a047fa) —TextField→TextInput,onClick→onPress; stale adapters deleted (fd1bb00,5f0fd48).
Stdlib — animation + design tokens (FLUX-042/043) — DONE
606bd94adds theAnimateprimitive (wraps the child subtree in the backend’swithAnimation) and the design-token theme extension (DesignTokenregistry influx-codegen-core/src/primitives.rs);ea28fc6aligns dev/release tree shape.
Stdlib — form primitives (FLUX-040) — PARTIAL
c4a6dc4registersSwitch/Checkbox/Slider/Picker/DatePicker/TextAreain the ADR-0047 registry + prelude with avalue/onChangesignal contract; Kotlin codegen trace test pins each to its native control. REMAINING (host-side): native control behavior (toggle writes its signal, picker selection) is not wired inruntimes/android/host/runtimes/iosyet.
Stdlib — gestures (FLUX-041) — PARTIAL
396c800registersGesture(kind+onGesture) in the registry + prelude; codegen trace test pins it to a native container. REMAINING (host-side):UIGestureRecognizer/Modifier.pointerInputwiring is not in the hosts yet.
Stdlib — Image (FLUX-039) — DONE
882215dpinsImagelowers to its native binding; nativeImageAdapter.swift/ImageAdapter.ktexist. The host-side local/remote cache is now wired (FLUX-039 completion):- Android:
ImageCache(LRU + single-flight, OkHttp-backed) lives in the pure-JVM:hostmodule with 6/6 JVM unit tests (cache hit on repeat load, concurrent-same-URL single-flight, distinct-URL each-once, failure-not-cached, LRU eviction, clear).ShadowTreeRenderergained the missingimagecase (RenderImage) — previouslyImagefell through to an empty container, so it rendered nothing; it now resolves+decodes the bitmap via the sharedFluxSession.imageCache, with a placeholder while loading and a red box on failure (BR-003). - iOS:
ImageCacheactor backed by a dedicatedURLCache(disk + memory) plus single-flight, inFluxUIKit;ImageAdapterloads through it instead of an ad-hocURLSession.sharedtask. Unit tests added (ImageCacheTests). - Caching is a host concern (no new wire field); the primitive only carries
src. Both hosts build/run: Android:host+:appcompile green, iOSFluxAppbuilds for the simulator under Swift 6 strict concurrency.
- Android:
Capabilities — six concrete native caps (FLUX-045) — PARTIAL
597f969declares Push/Biometric/Background/FileSystem/DeepLink/Sensors instdlib/capabilities.flux(caps 6..=11) +CAPABILITY_IDLwith permission gates; hostHelloFrametables advertise them; parity tests green. REMAINING (host-side): the realCapabilityRegistry::register(...)bodies (UNUserNotificationCenter,LocalAuthentication,BGTaskScheduler,FileManager,UIApplication.open,CMMotionManager; Push/Background settle a result cell viaAsyncResolver) are not in the hosts yet.
Capabilities — WebView + NativeModule escape hatch (FLUX-048/046) — DONE
b99ead7addsWebView(cap 12) +NativeModule(cap 13) tostdlib/capabilities.fluxwith deterministic id derivation;0756ded/ed696c5register them in the iOS/Android dev registries;e947967adds theWebHostnative adapters + parity tests;bcb46c0records ADR-0057 (threat model) + the native-module escape-hatch guide (FLUX-050/049/046).
Capabilities — permission gate + fail-closed handshake (FLUX-049/050) — DONE
1fefed6/31c1435wirePermissionCheckerintoCALL_CAPon Android/iOS;ed696c5/31c1435add the fail-closedPROTOCOL_VERSIONhandshake (FLUX-050, ADR-0056 verified on both simulators);04c0110/26d0e4dadd permission-gate + version-mismatch round-trip tests;6ca0c3dfixes TextInput keystrokes sticking;67c6a1afixesBUTTON_ON_CLICK→BUTTON_ON_PRESSto unblock the APK build;238344fadds the Flux To-Do example.
LSP — crate + type-check + VS Code extension (FLUX-024/025/026/027) — DONE
cc61d41scaffoldscrates/flux-lsponasync-lsp;339eb1dadds type-check diagnostics (diagnostics_with_typesreusesflux-types);4b805c4adds the spawnableflux-lspbinary;b153fa1ships theeditors/vscodeextension (semantic tokens + LSP client + hot-reload status + run-on-device);050eb37addsflux lsp <file>to the CLI;3c783b0adds a loopbackpublishDiagnosticsintegration test. Goto/hover/completion (FLUX-027) live ingoto_def.rs/hover.rs/completion.rs.
DevTools — log viewer + multi-device + signal-graph (FLUX-060/061/058) — PARTIAL
cf6494dships the structured log viewer (fifth pane,LogBuffermodel, 23/23 green);3d0604dships the multi-device session map (sessionskeyed byHostAnnounce, 24/24 green) — per-event attribution still BLOCKED on a wire host-id tag (ADR-0039 gap).32c65bdrenders signal-graph dependency edges (FLUX-058, 18/18 green).f0a3952/18589e4revamp the gpui UI (gpui-component, host identity,1a6f349pane polish).- Network inspector (FLUX-060) still BLOCKED: no
TelemetryEvent::NetworkRequestvariant and FLUX-047 (HTTP cap) is not incapabilities.flux, so there is no real traffic to inspect.
Docs / guides / website (FLUX-030/031/032/033/036) — DONE
1be0333wires the en/es/fr i18n-drift checker intopnpm test:i18nwith a failure-path test (FLUX-030);f35d438/1b286b9/adeb801/67cfe7fadd getting-started + per-primitive cookbook, troubleshooting keyed toFluxError, RN/Flutter migration guides, and state-management/app-i18n/showcase guides (FLUX-031/033/032/036);f79547cadds the docs-ecosystem coverage checker. README (3012103,f9b9c59) and repo URLs (4c1b5da,512b220) grounded in the real codebase.
Headless app-test harness (FLUX-034) — DONE
65807d5adds a user-facing.fluxtest API over the parity pipeline (render_component,find_first/count/find_all,run_tap/run_input) — the foundation for PRD-R’s package-level testing.
Perf harness + CI (PRD-J / FLUX-066 / FLUX-067) — DONE
0a18fb7stands upcrates/flux-perf-harness(MetricRecord schema + §3.10 gate);f2cb45bwires it into CI (.github/workflows/perf-harness.yml+scripts/ run-perf-harness.sh).16a38eeadds mutation testing + toolchain compat matrix (FLUX-067);6a9ffbf/8c3a526/6b9b3c9/71c264c/91e3874/a0eab67/f5a4ef7add criterion benches with budget assertions across parser/types/vm/ ir-serde/codegen/devserver.
On-device render-perf harness wired (FLUX-066) — DONE
- The Rust core previously only shipped a demonstration record (
ci_run). The harness now measures real numbers:crates/flux-perf-harness/tests/on_device_real_measurement.rsdrives the harness’s ownHarnessDriverthrough a genuineMeasureFntiming the reference VM (flux-vm-ref) dispatch of a counter handler, and gates the result against the §3.10VmDispatchbudget.examples/ci_ondevice.rsloads host-producedMetricRecordJSON and runs the §3.10 budget gate over the real measurements, exiting non-zero on regression.- Android (
runtimes/android/host):RenderPerfHarnessTestbuilds a 50-leaf fixture tree (each leaf subscribed to a distinct signal via the ADR-0027signal_metasection, now emitted byFrameBuilder.signalMetaEntry), timesShadowTree.reconcileDirtyover 200 iterations on the JVM host, emits aMetricRecordJSON, and asserts the §3.10node-mutationp95 ≤ 3 ms. Measured: p50≈0.012 ms, p95≈0.018 ms on a 50-leaf tree — well within budget. - iOS (
runtimes/ios,FluxAppTests/RenderPerfHarnessTests): same harness against the realShadowTreeReconciler.reconcileDirtyon a booted simulator, emitting the sameMetricRecordshape.
scripts/run-perf-harness.shnow also runs the host measurements (Android on the plain JVM; iOS on a booted simulator) and gates the collected records viaci_ondevice..github/workflows/perf-harness.ymlsplits into a Linux job (Rust core + Android:host) and a macOS job (iOS simulator).- Pre-existing build breaks unblocked to verify the wiring: the iOS
FluxHosttarget had a duplicateFluxErrorExcerpttype (wire vs presentation) that broke the whole package — renamed the wire-side toWireErrorExcerpt(WireModels/ShadowTree/FrameDeserializer); andadapters/ui-swift’sgestureEnvKeyneedednonisolated(unsafe)under Swift 6 strict concurrency. (These were latent at HEAD and blocked every iOS host build/test.) - Unblocks: FLUX-065 (iOS convergence decision now has measured data) and
FLUX-059 (DevTools flamegraph has a real
MetricRecordsource). The §3.10 “native mutation < 3ms” budget is now verified on both platforms via the host harness (replaces the prior “unverified” caveat).
Node-ID non-crypto hash (FLUX-071) — DONE
cd96cdbreplaces BLAKE3 with FNV-1a-32 incompute_node_id(FLUX-071); spec updated (a0084f2).71c264cadds acompute_node_idmicro-bench.
Router / async hosts / cross-host naming (LANE-A/B, ADR-0049) — DONE
- Router navigate wired to visible screen on both hosts (
9c30d4c,91605d2); on-device positional-Screennavigation trap tests (0afc406,822f25c); async-resolver bridges Pending cells to real async work on Android/iOS (14557ae,06d7e7d,323f082,8fbe5db); cross-host naming convergence (ADR-0049) renamesVMValue→FluxValue,OpCode→Opcode,FluxRuntime→FluxExecutor, AndroidFrame→FluxFrame, kit umbrellaFluxUIKit→FluxUIKitModule(b2e330b,fe4637f,438510f,a69b4bb).
Release — artifact publish (FLUX-068) — DONE
06b1fe5adds.github/workflows/artifact-publish.ymlproducingFluxHost.xcframework+ the:runtimes:android:hostAAR as release artifacts (closes the ADR-0036 packaging path). Thedocs/embed-flux.md“Embed Flux” guide remains unwritten (REMAINING).
BLOCKED — items with no tree presence
- FLUX-047 (HTTP cap + structured persistence):
capability Http/Persistis absent fromstdlib/capabilities.flux(grep count 0) andCAPABILITY_IDL— not started; this also keeps FLUX-060’s network inspector blocked. - FLUX-056 (large-list scroll benchmark): blocked — no
ScrollView/ virtualizedListprimitive exists (stdlib is still 8+ registered primitives, no scroll view); needs FLUX-073-style work. - FLUX-029 (incremental
didChange): only a stub note influx-lsp/src/ lib.rs; no debounced re-analysis committed. - FLUX-062 (DevTools on-device verification): no beta/on-device-evidence commit; the §13 “ship it, not scaffold it” gate is open.
- FLUX-069 (beta/dogfood/bug-bash): machine-enforced release gate landed —
release-gate.ymlaggregates the component quality gates + a blockingcontract-freezejob (PRD-U wire/adapter version freeze, enforced byscripts/release-gate/check-contract-freeze.sh). Human-evidence half (dogfood report, closed-beta time-to-fix, bug-bash log) is thedocs/release/1.0-evidence.mdchecklist gating the manualv1.0.0tag.
Unowned roadmap gaps (no FLUX-0XX yet — RC blockers)
- ScrollView / virtualized
List(roadmap §1 criterion #1) — the non-virtualizedScrollViewprimitive landed (FLUX-056,[Unreleased]); the virtualizedListbenchmark leg remains deferred (MLP has no virtualization). FLUX-056/FLUX-072 depend on it. Iconprimitive (PRD-N §4) — no issue, absent from stdlib.flux doctorCLI (roadmap §5) — no issue; CLI exposes only init/dev/build/doc.- Full spec reconciliation (AGENTS.md §0.7) — mlp-spec/appendices vs real code only partially reconciled; no owning issue.
- iOS convergence PORT (roadmap §1 #5) — FLUX-065 owns the decision only; if ADR-0048 says “port”, the FluxUIKit port has no issue.
Agent-delivered work (tracked by orchestrator — NOT yet committed by this agent)
The following were produced by concurrently-dispatched flux-N agents. They are recorded here for progress tracking only; this agent did not write, modify, or commit any of the code below (the owning agents / orchestrator handle those directories per the boundary contract). Status reflects the live working tree at the time of writing, not a verified test pass — uncommitted code is marked as such.
FLUX-009 — Kotlin adapter kit + dev adapters — DONE (committed)
Fully implemented and committed across adapters/ui-kotlin/src/** (22 files):
FluxValue, FluxColor/FluxFont, Props typed accessors, FluxNativeView
abstraction + in-memory test double, FluxExecutor boundary + HandlerEvent,
FluxAdapter contract, and dev adapters (Text, Button, TextField, Column/Row with
keyed child reconciliation, Screen, Router). Test suites cover FluxValue record,
Props accessors, Text/Button/TextField, Column/Row keyed diff, Router/Screen state
preservation. All commits prefixed feat(kotlin-adapters) / test(kotlin-adapters)
under refs FLUX-009. (See 62a5fdf and the chain beneath it.)
FLUX-006 — iOS host app runtime — DONE (committed)
Delivered into runtimes/ios/Sources/** and runtimes/ios/Tests/** by the
ios-runtime agent: FluxAppMain.swift entry point, Sources/VM/ (native
FluxBytecodeVM per Appendix E), Sources/Values/ (Flux value types), and
Tests/ISAConformanceTests.swift + ISAVector.swift (shared-vector conformance
target). runtimes/ios/project.yml was also updated. Committed to main as
3ad2246 (VM + wire + reconciler + executor).
FLUX-007 — Android host app runtime — DONE (committed)
Delivered into runtimes/android/app/src/** by the android-runtime agent:
FluxHostActivity.kt host entry, src/main/kotlin/.../vm/ (Kotlin
FluxBytecodeVM per Appendix E), src/main/kotlin/.../wire/ (Appendix D frame
codec), src/main/kotlin/.../shadow/ (shadow tree + reconciler). Test suite under
src/test/kotlin/.../: IsaConformanceTest, FluxBytecodeVmTest, wire/ frame
builder/deserializer + WireFixtureContractTest, EndToEndTest. Committed to
main as fa80b45 (native host runtime) + 15b191f (finalized
WireFixtureContractTest assertions).
FLUX-010 — standard library .flux sources — IN PROGRESS (uncommitted)
12 .flux modules landed in stdlib/: prelude, traits, color, font,
text, button, text_field, column, row, router, platform,
capabilities. These are source-only (parse-checked by the parser once FLUX-003
lands); per R8 the directory is write-only for the stdlib agent. Uncommitted in
the working tree at time of writing.
FLUX-008 — Swift adapter kit + dev adapters — DONE
Implemented the shared adapter kit and the seven dev-mode adapters in
adapters/ui-swift (no try!/try?, no force-unwraps in library code,
every public item documented, swift test clean, TDD throughout):
- Kit contract types the runtime (FLUX-006) consumes:
FluxValue(mirrorsflux_syntax::Value, Appendix C.1),Props(flat(PropIdx, FluxValue)map with O(1) typed accessors + stable content hash),FluxColor/FluxFount/FluxAlignment(canonical record decoders for Appendix FColor/Font/Alignment),FluxEvent(handler dispatch payload),FluxExecutor(the executor the adapters call back into via a weak reference), and theFluxAdapterprotocol (create/update/setChildren/bindHandler/destroy). - Seven dev adapters per Appendix F:
Text→UILabel,Button→UIButton(dispatches boundonClickvia the weak executor ontouchUpInside),Column/Row→UIStackView(keyed-by-identity child reconciliation that preserves view state across reorders),TextField→UITextField(controlled value + edit dispatch toonChange),Router→UINavigationController(push/pop reconciles screens by identity, preserving a screen’s view controller and state while present),Screen→UIViewController(hosts its content subtree). - Adapters hold the executor
weak;TextFieldAdapterretains itself on the field via object association so its delegate survivescreate(). No retain cycles; everyweakis documented.
Verification (real command output, not assumed — the package targets
iOS 16 so it builds/tests under xcodegen + xcodebuild for the iOS
Simulator, the path the frozen Package.swift documents):
xcodebuild -scheme FluxUIKit -destination 'generic/platform=iOS Simulator' test— 29 tests, 0 failures, 0 warnings, TEST SUCCEEDED.- Tests cover: Props accessors + order-independent hash, Color/Font decode/clamp/missing-field, per-adapter create/update/destroy, button tap dispatch + weak-executor no-retain, text-field edit dispatch, keyed child insert/remove/preserve, router push/pop state preservation.
Notes and deviations:
FluxAdapter.Viewis constrained toAnyObject(notUIView) soRouter/Screencan manageUINavigationController/UIViewController;setChildrentakes[AnyObject]and each adapter casts toUIVieworUIViewControlleras appropriate.- The frozen
Package.swiftis untouched (boundary contract R2). The verification harness used an out-of-treexcodegenproject wrapping the Sources/Tests; no manifest was modified.
FLUX-014 — flux-differ keyed tree differ — DONE
Implemented diff(old: &IRArena, new: &IRArena) -> Vec<Patch> (udomdiff-style
keyed reconciliation over stable NodeIds). Depends only on flux-syntax and
flux-ir (both done); no new dependencies, no unsafe, no unwrap in library
code, every public item documented, clippy/fmt/doc clean.
Structure: diff.rs (diff + helpers to_ref, find_parent_and_index,
child_ids, child_order, props_equal, props_diff, handlers_equal,
emit_replace, emit_handler, closure_ref), lib.rs (re-exports + algorithm
doc). Also added IRArena::all_ids() iterator to flux-ir (needed by the differ).
Reconciliation rules:
- Both-present nodes: kind/component change →
Replace; prop-only →Update(PropDiff); handler-body-only →Handler(state-preserving fast path); same child set but different order → singleReorder(not remove+insert). - A parent whose child set merely grew/shrank is not replaced — the
added/removed children are covered by
Insert/Remove, avoiding spurious whole-subtree replaces. - Missing-from-new →
Remove; new-to-new →Insert { parent, index, node }.
Verification:
- 7 unit tests (identical→empty; canonical Replace/Update/Insert/Remove/Reorder each emit exactly one minimal patch; diff-then-apply reconstructs the tree).
tests/roundtrip.rsproptest (200 cases): diff-then-apply == new tree over randomized star trees of varying size/content. The test-onlyapplyreconstructs an id→NodeRefmap and appliesInsertpatches in(parent, index)order so out-of-order patch delivery still yields correct child ordering.benches/diff.rscriterion bench: 50-node prop-mutation diff ≈ 41.6 µs (well under the 1 ms budget, §3.6).
FLUX-013 — flux-ir-serde wire protocol — DONE
Implemented the Appendix D binary wire codec and typed frames. Depends only on
flux-syntax and flux-ir (both done); blake3 for content addressing is
pre-wired; no unsafe, no unwrap/expect in library code, every public item
documented, clippy/fmt/doc clean.
Structure:
-
wire.rs— little-endian primitive reader/writer (Reader/Writer),encode_*/decode_*forValue,Child,Node,PropDiff,ClosureRef,Patch(tags 0x01–0x06),StringEntry, plus the reservedStateDelta/SourceMapDeltacodecs (Appendix D §D.10–D.11) andHandlerDefencoder. -
encode.rs—serialize_patches(&[Patch], &StringTable) -> Vec<u8>anddeserialize_patches(&[u8]) -> Result<Vec<Patch>, WireError>(inverse ofserialize_patches), plushash_props/hash_closure(BLAKE3, deterministic, NaN canonicalized). -
frame.rs—FrameAPI +FrameKindand the five typed frames:Hello(Frame::hello/from_hello_bytes),Init(Frame::init/from_init_bytes, round-trips aStringTableby exact id),Delta(Frame::delta/from_delta_bytes),Error(Frame::error/from_error_bytes,span: Option<Span>),Heartbeat(Frame::heartbeat/from_heartbeat_bytes).Frame-header conformance (corrected 2026-08-24): the earlier draft unified every frame under the D.1 header with a
flagsbyte and an inventedbit3 = Hello. That deviated from Appendix D. The shipped code follows D.12 exactly: amagic(4) version(1) frame_type(1)prefix (frame_type0x01Hello /0x02Init /0x03Error /0x04Delta /0x05Heartbeat), then a type-specific payload — Hello has no sequence number; Init/Error carryseqat offset 6; the Delta frame uses the D.1 header (seq,flagsbitfield,patch_count/handler_count/string_countat offsets 11–15). Init’sstring_countis a u32 per D.12.2.tests/conformance.rsasserts these exact offsets and the D.2/D.5 patch/value tags byte-for-byte.
Encoding details matching Appendix D §D.1–D.8 exactly: Value 1-byte tag
(Int 1, Float 2, Bool 3, Str 4, HandlerRef 5, List 6, Record 7)
with i64/f64/string-id/handler-id payloads; Child tag 0x01 Node(u32) /
0x02 Splice(u16 count, (u64 key, u32 id)*); Node id/kind/component + prop
vec + child vec + handler vec + span; Patch tags per §D.2; ClosureRef hash +
bytecode offset/len + captured-signal vec + span.
Verification:
tests/round_trip.rs— every patch variant round-trips through serialize/deserialize; everyValuevariant (incl. NaN, nested List/Record, Splice) preserves order;Initreconstructs theStringTablewith exact ids (resolve("Increment") == Some("Increment"));Errorpreserves code/message/ span;Hello/Heartbeatround-trip platform/device/capabilities.tests/proptest_round_trip.rs— 200 randomized patch sets serialize/deserialize to byte-identical output (deterministic), andhash_props/hash_closureare stable across calls.benches/serialize.rscriterion bench: 50-node patch serialize ≈ 1.58 µs (≪ 1 ms budget, §3.6);Initframe for a 50-node tree ≈ 3.6 KB (≪ 20 KB acceptance, §D.13).
Note: flux-ir-serde is not on the dispatched flux-N active list; it was a
1-file stub and is now fully implemented to advance the Rust pipeline.
FLUX-003 — flux-parser surface parser — DONE
Implemented the Flux surface parser: .flux source to a typed Ast whose
every node carries a flux_syntax::Span. Built on pest generated from a
grammar that now matches Appendix B §B.1–B.2 1:1 (the spec was reconciled to
the tested grammar on 2026-08-24, so flux.pest and Appendix B cannot drift;
tests/appendix_b_examples.rs asserts all ten §B.3 examples).
Structure (every file ≤ 300 lines, no unsafe, no unwrap in library code,
clippy/fmt/doc clean, all public items documented):
flux.pest— the grammar.ast.rs,ast/types.rs,ast/expr.rs,ast/pattern.rs— typed surface tree.error.rs—ParseErrorwith message/hint/span/line-column;render()emits the what/where/why/how format of AGENTS.md §3.7.lower.rs+lower/{decls,types,exprs/*}— panic-free lowering (a malformed pair returns aParseError, never unwraps).prescan.rs— lexical pre-scan so an unterminated string or unclosed brace points at the opening token (pest backtracks out of a partial match), and a nesting-depth guard (G6) that rejects pathological input with a diagnostic instead of overflowing the stack.
Coverage:
tests/appendix_b_examples.rs— every §B.3 example parses, with shape assertions (not just parse success).tests/stdlib.rs— all twelvestdlib/*.fluxfiles parse (covers G1/G2/G4).tests/diagnostics.rs— errors carry what/where/why/how.tests/edge_cases.rs— empty input, i64 bounds, Unicode strings, span fidelity, nesting limit.tests/properties.rs— proptest: spans stay inside the source, arbitrary text never panics, i64 literals round-trip, error locations are in-bounds.benches/parse.rs— 500-line file parses in 2.25 ms (budget 5 ms, §3.6); 100 lines in 459 µs.
docs/adr/ADR-0035-parser-grammar-extensions.md records the reconciliation and the
remaining parser-internal concern (G6 depth limit).
Addendum (2026-08-24): the module-level state form (module_state,
Decl::State) that the first reconciliation added for stdlib/platform.flux
was reverted. File scope has no state form; platform.flux now exposes the
platform tag as fn platform() -> String { … } (queried via platform()),
and Appendix B.3.8’s conditional is if platform() == "ios". The Decl::State
variant and module_state rule were removed from both flux.pest and
Appendix B.
FLUX-015 — standard-library validation harness — DONE
Added a stdlib validation harness (no new crate; a tool that parse-checks the
shipped .flux sources so regressions in the 12 stdlib modules surface before
dev-server round-trips). Committed as 6bb0f13:
stdlib/parse-check.sh— drives the checker over everystdlib/*.flux.stdlib/tools/parse_check.rs— loads each module throughflux-parser, fails the build on the first parse error, and asserts the ten Appendix B §B.3 examples still parse.stdlib/tools/fixtures/invalid.flux— a deliberately malformed fixture proving the checker rejects bad input (not a silent pass).
Verification: bash stdlib/parse-check.sh exits 0 over all 12 modules
(prelude, traits, color, font, text, button, text_field, column,
row, router, platform, capabilities).
FLUX-017 — Android adapter↔runtime integration — DONE
Wired the real Kotlin adapter kit (FLUX-009) into the FLUX-007 Android runtime.
Committed as 0426c00 + 8263e17:
AdapterRegistrymappingComponentId→ adapter instance, built from the string table delivered in theInitframe.- The runtime’s E2E test was repointed from the in-dir mock adapters to the real
FluxAdapterkit: hand-builtInitframe → realTextView/Button/LinearLayout(vertical/horizontal) /EditTexthierarchy; tap → dispatch → VM → reconciler → view updated without view recreation (view identity preserved across the update). - Router E2E: push → edit state → pop → state preserved (the adapter kit’s Router/Screen preserve screen view state by identity).
Verification:
AdapterRegistryTest.kt— registry resolves everyComponentIdthe frame declares.EndToEndTest.kt— real-adapter build + tap-dispatch + view-identity preservation + router state preservation, all green.WireFixtureContractTest.kt— finalized assertions (committed15b191f).
ADR-0025 — custom binary wire frames (Gap 3) — DONE
Resolved the wire-format documentation gap: flux-ir-serde ships a custom
little-endian binary codec, but ADR-0008 and the spec prose (mlp-spec
§14.1/§18.x/§20.6/§21.1, mlp-appendices §D narrative + glossary) still said
MessagePack. Committed as 4186372:
docs/adr/ADR-0025-wire-binary-frames.md— records the deviation, supersedes ADR-0008’s MessagePack choice, and notesrmp-serdeis now an unused dependency.- Corrected all narrative MessagePack claims in
mlp-spec.mdandmlp-appendices.md(the ADR-0008 body was left intact per the never-edit-existing-ADRs rule; ADR-0025 supersedes it). - Satisfies DoD §9 (every spec deviation needs an ADR).
ADR-0027 — node-ID single-source bridge (Gap 2) — DONE
Established one canonical compute_node_id in flux-syntax so the type checker
and the IR produce identical NodeId values for identical source constructs —
required for FLUX-018 lowering to join TypedAST.types to IR nodes by ID.
Committed as 1d52b57 + 1c9705f + 6bc37c6:
flux-syntax::compute_node_id— canonical BLAKE3 implementation (theflux-irlayout, so existing IR/differ/wire hashes stay stable), re-exported.flux-ir::compute_node_id— now delegates (publicNodeKindAPI unchanged, byte-identical output) + bridge testdelegates_to_flux_syntax_canonical.flux-types::compute_node_id— now delegates (signatureu64→Option<Key>); edits are in the FLUX-012 agent’s working tree and land with that issue.- Cross-crate equivalence proven by
flux-irandflux-types(matches_canonical_flux_syntax) tests.
This replaced a divergent FNV fork in flux-types that omitted span.file_id —
without the bridge, lowering would have silently failed to look up types.
FLUX-011 — CI pipelines — DONE
Added GitHub Actions workflows that enforce the AGENTS.md Definition-of-Done
gates automatically as crates land. Committed as 8ac2655 + 7b223b3
85b0e47+402fbb3(all underci(flux-011)):
.github/workflows/rust-check.yml—cargo fmt --all -- --check,cargo clippy --all-targets --all-features -- -D warnings,cargo test --workspace --all-targets,cargo doc --no-deps --workspace. Globs are workspace-wide, so a crate is covered the moment its real source lands (Phase 1+) with no manifest edit..github/workflows/ios-check.yml— XcodeGen +xcodebuild testfor the iOS runtime/adapters, plusswift testfor the Swift package..github/workflows/android-check.yml—./gradlewKotlin + Android test..github/workflows/adr-numbering.yml— the ADR-naming guard (fails when a new agent ADR reuses a reservedADR-NNNN), paired withdocs/scripts/check-adr-numbering.shand the ADR-renumbering governance (ADR-0021…0024).
All workflows run on push (any branch) and PR to main, with docs/**,
runtimes/**, adapters/**, **.md path-ignored where appropriate so doc-only
changes don’t trigger the Rust/iOS/Android builds.
FLUX-012 — flux-types bidirectional type checker — DONE
Implemented the Flux bidirectional (constraint-based) type checker per
FLUX-012, consuming flux-parser’s AST and flux-syntax’s TypeKind.
checker.rs— HM(X) inference with unification variables, constrained (generic) variables carrying trait bounds, env-based name resolution, a trait/ADT/component/fn collection pre-pass so earlier declarations can call later ones, generic-component instantiation with concrete type-argument recording, arithmetic/Show/Eqtrait enforcement, offside-free block/binary/field/call handling, module-constant (Color.red) resolution,Numeric.zero/onereturningNumeric-constrained variables.unify.rs— substitution-based unification with occurs-check and cycle-safe constrained-variable handling (preserves the constraint on the canonical variable).traits.rs— closed-worldNumeric/Eq/Showresolution; arithmetic now rejects operands whose trait bound does not includeNumeric.kind.rs/env.rs/scheme.rs—TcTypeinternal repr, env bindings, generalisation/instantiation scaffolding.error.rs— span-carryingTypeErrorwith actionable messages.prelude.rs— prelude traits/fns/components (Show/Eq/Numeric,platform, etc.).exhaust.rs— match exhaustiveness overTcType.lib.rs— public APItype_check(ast) -> Result<TypedAST, TypeError>andTypedAST { ast, types, instantiations }; re-exports.tests/typecheck.rs— all 10 Appendix B.3 examples + diagnostics (span/mismatch/unbound/non-exhaustive) + bothCounter[Int]/Counter[Float]instantiations + module-constant and trait-bound negative tests.benches/typecheck.rs— 500-line fixture benchmark → 544 µs (< 3 ms budget, §3.6).
Verification (all gates green, run locally):
cargo fmt --check— clean.cargo clippy -p flux-types --all-targets -- -D warnings— zero warnings.cargo test -p flux-types— 1 unit + 16 integration + 3 doctests, all pass.cargo doc -p flux-types --no-deps— clean.cargo bench— 544 µs for a 500-line file.
FLUX-003 (follow-up) — if/else lowering bug fixed
flux-parser’s if_expr lowering wrapped an else { block } in a bogus
Call { callee: Elided, trailing: Some(block) }, which is not a real call
and forced every downstream consumer to special-case it. Fixed in
lower/exprs/control.rs so else { block } lowers to a block-valued
expression (the grammar’s zero-argument-lambda “block as expression” form),
mirroring when_expr’s clean handling. flux-types dropped its
Elided-callee workaround and instead infers an else zero-arg-lambda as a
block so it unifies with the then branch. A regression test
(b38_else_block_lowers_to_block_not_elided_call) locks the fix in.
Crate ownership note (directory-bound agents)
These workspace crates are owned by other agents (built by their named flux-N agent, not by this one, to avoid directory collisions under the parallel-agent contract):
flux-devserver— implemented (FLUX-019, DONE, this file).flux-codegen-swift/flux-codegen-kotlin— codegen backends (FLUX-011, bridge fix in this file; lowering gaps owned byflux-ir).flux-cli— implemented (dev command +flux-parity-tracebin shipped influx-parity).flux-parity— implemented (FLUX-023, COMPLETE, this file).- CI (FLUX-011) — orchestrator-owned.
All of the above are merged and verified; “ownership” here refers to the write-ownership boundary in AGENTS.md §3.1, not to unfinished work.
FLUX-023 — flux-parity structural parity harness (COMPLETE)
Implemented the flux-parity crate proving structural parity between the
dev-path surface AST and the Swift/Kotlin codegen backends for all ten
Appendix B.3 examples, plus the T16 trace-diff tooling (ADR-0027).
src/reduce.rs(from_ast) builds the language-neutralViewNodetree directly from the parsed AST — the lowerer rejects 6/10 B.3 handler/property forms, andflux-irmust not be modified, so the AST (what codegen itself derives from) is the faithful dev-side source of truth.src/equivalence.rs(structurally_equal) normalizes away platform text differences: condition whitespace, route quotes, synthetic layout wrappers (dev’s single-childColumnvs codegen’s inlined children), andif/whenbranch ordering (compared as an unordered bag).src/relation.rsreportsParityStatus::{Supported, LowererUnsupported}: whenLower::lowersucceeds, full three-way parity is asserted; when it fails, the scenario is surfaced as a documented lowerer capability boundary (graceful, no panic) rather than a harness regression.- 4 examples lower+codegen fully (b31, b34, b37, b39) → real three-way parity.
6 (b32, b33, b35, b36, b38, b310) →
LowererUnsupported, dev tree from AST.
T16 trace-diff (ADR-0027 / reconcile-trace-format v1):
src/trace.rs+src/trace/json.rscanonicalize each JSONL frame (sorted keys, compact whitespace,spandropped because it is a host-specific line:col that is not part of the canonical frame) and compare two traces exactly, returning the first divergence with line context.src/bin/flux-parity-trace.rsexposesflux-parity-trace trace diff [--phase <1|2|3>] <left.jsonl> <right.jsonl>(exit 0 = match, 1 = first divergence, 2 = usage/I/O error). No new dependency; a tiny self-contained JSON parser lives insrc/trace/json.rsbecauseserde_jsonis not declared in the crate manifest (no manifest edits allowed per boundary contract).tests/trace-goldens/holds the golden corpus: 5 required scenarios (counter_1000,noop_dispatch,pure_subtree,cond_flip,unrelated_signal) × 3 phases × 2 platforms (swift + kotlin), plusforeach_grow(gated by OQ-3 — ForEach splices are empty for the MLP per FLUX-014). Each pair is canonically identical (differing only in droppedspan), so the comparison proves cross-platform reconciliation parity.
Verification (all gates green, run locally against committed flux-ir):
cargo fmt -p flux-parity -- --check— clean.cargo clippy -p flux-parity --all-targets -- -D warnings -A clippy::useless_conversion— zero warnings.cargo nextest run -p flux-parity— 27 passed (16 parity + 11 trace_diff).cargo doc -p flux-parity --no-deps— clean.- CLI smoke test:
trace diffexits 0 on a matching pair, 1 with a divergence report on a mismatched pair.
Artifact 6 (Rust perf, doc perf-followup.md) — MEASURED & CLOSED, not shipped:
the 5 listed micro-optimizations are speculative churn. No flux-parity CI perf
baseline exists, and the recognizer/tokenizer runs once over ~hundred-line
files and is dominated by the external flux-ir lower/codegen, not by string
handling. Gate condition (CI step >5% faster or profiling >30% allocs in those
paths) is not met → per the task’s “otherwise record measurements and close —
do NOT ship speculative churn” instruction, Artifact 6 is closed without changes.
Note: the shared working tree currently has an uncommitted, broken flux-ir
edit (another agent’s in-flight work in arena.rs/bytecode.rs/lower/mod.rs)
that fails to compile; this blocks the whole-workspace build and transitively
flux-parity’s dependency compile, but does not involve flux-parity code
(verified by stashing those 3 files and confirming flux-parity is independently
green: clippy clean + 27/27 tests). flux-ir is out of lane and was not modified.
Recently completed (post-FLUX-023, orchestrator-tracked)
The following landed after the FLUX-023 tracking entry above and were not yet
folded into the per-issue sections. Recorded here so the [Unreleased] section
stays current.
-
FLUX-022 —
flux-cli(init/dev/build) — DONE (ea4a157). The dev/build entrypoints the docs-site and examples-e2e work depend on. Deviation (logged): added crate deps as.workspace = true(minimal, owned-crate, accepted per the manifest-freeze rule). -
P1 — iOS runtime fixes (dirty-set reconcile + perf) — DONE (
2d03d78skip-unchanged updates + lifecycle re-entrancy;2402b37dirty-set reconcile on dispatch;c1407dfcache decoded bytecode + generic signal store;d2d9182/edc4edefurther iOS perf). Reconciler now reconciles only the dirty set on dispatch, reusing the ADR-0027 dependency model. -
P3 —
flux-irarena prop/child hashes + VM control-flow — DONE (cb509a7arena prop/child hashes + if/when/match bytecode emission;0e3480eO(1) prop-hash skip bench ≈ 29 µs on identical subtrees). VM now lowersif/when/matchwith control-flow opcodes (previously a silent compile_handler no-op), closing the gap the parity oracle exposed. -
P4 —
Imageadapter (Appendix F.8) — DONE (8e6c169SwiftImageAdapter→UIImageViewwith HTTP asset load + graceful fallback;6f26341KotlinImageAdapter+ registry registration;a47bd99register the Swift adapter in the component registry via FLUX-016’s bridge). -
PE-C — codegen indent table — DONE (
55a24f0). Replaced per-lineindent.repeat()with a precomputed table in both codegen backends. -
PE-D — devserver immutable asset caching — DONE (
a6ac4f4). AddedCache-Control: immutable+ ETag conditional caching to the asset server. -
PE-E — examples + headless e2e + packaging ADR — DONE (
e785200). Addedexamples/counter/main.fluxand a headless full-pipeline e2e test that drivesflux-devserver→ wire → host. Recorded the runtime-packaging gap indocs/adr/ADR-0036-runtime-packaging-gap.md. -
FA-DEVSERVER — signal_deps-aware minimal-patch dispatch (ADR-0027, server half) — DONE (
d68bcca).DependencyIndex(signal → nodes) + minimalPatch::Updateemission scoped todependents[S]; degrades to coarse frame whensignal_depsis absent. 32/32 tests green. Flag-gated behind an injectedsignal_depsseam until FA-IRWIRE lands the real field. (FA-IRWIRE has now landed —dec2b2e— so the seam is replaced by reading arenasignal_depsdirectly.) -
FA-IRWIRE — per-node signal_deps + prop_thunk (ADR-0027 T13/T14) — DONE (
dec2b2e).flux-irIRArenagainedsignal_deps/prop_thunk/prop_layoutside-tables withNodeViewaccessors (kept offNodeRefsoflux-differkeeps building).lower/bytecode.rsgainedcompile_prop_thunk(reuses theEmitter; itsREAD_SIGNALcaptures ARE thesignal_deps— single source of truth) andStrsupport (LOAD_STR_CONST), so literal-string props and string-signal writes compile.lower/mod.rsemits metadata after every node pack.flux-ir-serdereservedFLAG_NODE_HAS_SIGNAL_DEPS(bit 6, provisional pending Appendix D ratification — OQ-2) and a gatedsignal_metasection on Init/Delta; decode rejects a thunk with empty deps (INV-1).flux-devserverderivesDependencyIndexfrom arenasignal_depsand shipssignal_metawhen present (completes the seam FA-DEVSERVER was flag-gated behind). Full workspacecargo nextest329 passed; build/doc/clippy/fmt clean. Also unblocked the whole-workspace build (the prior in-flight flux-ir break is resolved). -
FA-DOCS — Flux documentation site (Starlight + pnpm) — DONE (
4129b38). Single Starlight project, EN/ES i18n (Starlight-native, no Lingui), ADR ingestion fromdocs/adr, Swift/Kotlin<Tabs>, and a recorded-dispatch replayDispatchTracePlayer(consumes the reconcile-trace-format v1 trace, NOT a fake web compilation). Lives inwebsite/. -
FA-RENDER — host render-mount + library packaging — DONE (all phases) (
a412706iOS: mount reconciled shadow tree to real UIKit views via aUIViewControllerRepresentable;c08fbfaAndroid: bind shadow tree to real Compose UI viaAndroidView, replacing theFlux host readyplaceholder). This closes the long-standing gap where the reconciler built an internal tree that was never shown on screen.- Phase B (library extraction): Android
:hostKotlin/JVM library holds the engine, app is a thin shell depending on it (settings.gradle.kts+app/build.gradle.kts); iOSFluxHostSwiftPM package holds the engine, app is a thin shell importing it. Engine sources moved verbatim (package renamedev.flux.app→dev.flux.host); tests relocated withgit mv, no work lost. - FR-017 (iOS reconnect): real
URLSessionWebSocketTasktransport (FluxWebSocketTransport) feeding decoded frames into the runtime, aFluxTransportprotocol +HostConnectionStateobservable, and a “Reconnecting…” banner with a 1-second retry loop. On reconnect the dev server pushes a freshInitframe (no client→server “request Init” opcode invented — Appendix D has none). Verification: Android:host:test+:app:testDebugUnitTestBUILD SUCCESSFUL; iOSxcodebuild test -scheme FluxApp5 passed / 1 skipped (env- gated wire-fixture);FluxHostpackage 32/33 (the 1 fail is the pre-existing experimentalrunViaDispatchTableVM test divergence, out of scope). On- device Poco smoke is user-triggered (no device access from the agent).
- Phase B (library extraction): Android
-
ADR renumbering + spec artifacts — DONE (
380a55cADRADR-00XX-prefix normalization viagit mv;61ea6dfADR-0027 signal-node dependency tracking;e2b7eb2reconcile-trace-format / wire-signal-deps / reconcile-counters spec artifacts). All cross-references updated. -
i18n — French locale — DONE (
252d3dd). Addedfrlocale + locale-aware root redirect. -
Dev server hot-reload + device-reachability fixes (FLUX-019 / flux-cli) — DONE (atomic commits
6d9488d…a8c86d0, tree83cab05..HEAD). All committed as one-commit-per-file viagit commit --only.flux-devserverServerConfig::newnow canonicalizesrootto an absolute path (falling back tocwd.join(root)). A relativerootmadecollect_flux_sourceskey sources by relative paths while the FSEvents/kqueue watcher reports absolute paths, so a save’sset_sourceupdated a differentFileIdthan the initial compile → the recompile saw stale source and emitted noDelta— silently breaking hot reload (FLUX-019 regression).ServerConfiggainedwith_ws_host/with_ws_port/with_http_portbuilders;flux-cli devgained--ws-host(default127.0.0.1;0.0.0.0exposes the patch channel on the LAN for physical devices/simulators),--ws-port, and--http-port(defaulting toDEFAULT_WS_PORT/DEFAULT_HTTP_PORT).- Removed a per-broadcast
tracing::debug!inserver.rs(hot-path log).watch.rserror/disconnect branches now emitWATCH_ERROR/WATCH_DISCONNECTED. - New devserver tests:
tests/gen_frames.rsandtests/probe_delta_shape.rs(delta-shape / frame fixtures for the Android repro — both markedTEMPin-file) andtests/handler_body_hot_reload.rsreformatted. - Removed the leftover debug write that dumped every live
Deltato/tmp/flux_real_delta.bin(watch.rs::compile_and_broadcast); the trace is gone (flag cleared).
-
flux-types — ADT constructor set (FLUX-012 follow-up) — DONE (
5747e08+f89c6c9).TypedASTgainedconstructors: HashSet<String>(every algebraic data-type value constructor in scope). The handler bytecode compiler uses it to decide whether aName(args)call lowers to anALLOC_RECORD(value record) or aCALL_CAP(capability/method) directly from the parse tree, without re-walking the type environment. -
Swift adapters (
adapters/ui-swift) — name-based props — DONE (18fc9a594fbf9fd3dbe4cf89c6c90bc1e0e).Propsresolves props by the FNV-1a name index (mirrorsflux_ir::lower::prop_index_for_name) viagetString(named:)/getInt(named:)/getFloat(named:)/getBool(named:)/getColor(named:)/getRecord(named:)etc.Button/Column/Row/Textswitched from positional indices to named lookup ("text","gap","alignment","color","enabled","max_lines"), so adapters no longer depend on prop position. NewContainerAdaptermaps a userComponentroot to a plainUIViewhost — the registry fallback for component nodes that have no primitive adapter (keeps every node flowing throughregistry.make+setChildren, Appendix F). -
Android runtime — observable-prop recomposition — DONE (
6f040660152aaf54384f9c2ed6c0aba60e165c78dd65fb3e2a3e76f4134e78c12ff8f80fdb7fc).FluxRoot/ShadowTreeRendererreplaced the manualgenerationrecomposition counter with per-node observablepropsState(ShadowNode.observeProps()): Compose re-runs a leaf when the executor re-materialises its props (SwiftUI-style).FluxRootbumpsframeVersionon every applied frame so a root-replaced hot reload (unstable node ids across edits) remounts the new tree instead of leaving the stale composable on screen (FLUX-019 blank-screen).ShadowTreeroot-replace path reformatted + emits aFrametrace;SignalGraphvisibility corrected topublic override;CapabilityRegistry/HelloFrame/FluxBytecodeVmTestreformatted (byte-array literal line-wrapping). -
examples / fixtures / docs —
examples/counter/main.fluxswitched to{count}interpolation syntax (was${count}); addedcrates/flux-cli/main.flux/fixture (main.flux+flux.toml+.fluxignore); addeddocs/flux-architecture.html(architecture diagram).notify_fsevent_test.rswas committed then removed (4958ac4→ removal commit) — it was a root-level fsevent scratch probe, not project source.
Promoted follow-up issues (deferred PRD work → tracked FLUX-0XX)
Every “Deferred (documented follow-up)” / “Blocker” / “remain follow-up” /
“PARTIAL” bullet in this changelog was promoted into a self-contained
FLUX-0XX issue under docs/issues/ so there is no dangling follow-up.
The full mapping (deferred line → issue id → source pointer) lives in
docs/issues/00-FOLLOWUP-INDEX.md. The LSP work (PRD-O’s deferred server) is
promoted into its own crate (crates/flux-lsp) built on async-lsp
(^0.2.4) + lsp-types (^0.97), with the crate scaffold + workspace wiring +
manifest request already applied (FLUX-024). Summary by cluster:
- LSP / editor (PRD-O) — FLUX-024 (real async-lsp server, own crate),
FLUX-025 (
flux lsptype-checking viaflux-types), FLUX-026 (VS Code extension), FLUX-027 (go-to-def / hover / completion over compiler symbols), FLUX-028 (native on-device error overlay, PRD-KFluxError/Span), FLUX-029 (incrementaldidChange+ debounced re-analysis). - Docs / ecosystem (PRD-R) — FLUX-030 (docs site + en/es i18n-drift
checker), FLUX-031 (getting-started / cookbook), FLUX-032 (RN / Flutter
migration guides), FLUX-033 (troubleshooting keyed to
FluxError), FLUX-034 (headless.fluxtest framework reusingflux-parity), FLUX-035 (release crash reporting), FLUX-036 (state patterns + app i18n + showcase apps). - Stdlib (PRD-N) — FLUX-037 (
Stack/Grid/Spacer/SafeArea), FLUX-038 (Modal/Sheet/Dialog), FLUX-039 (Imagelocal+remote caching), FLUX-040 (form primitives), FLUX-041 (gestures), FLUX-042 (signal-graph animation), FLUX-043 (design-token theming codegen), FLUX-044 (a11y props). - Capabilities (PRD-Q) — FLUX-045 (six concrete capabilities), FLUX-046 (native-module escape hatch), FLUX-047 (HTTP/JSON + persistence), FLUX-048 (WebView escape hatch), FLUX-049 (permission gate + CALL_CAP threat model), FLUX-050 (production update-integrity, ADR-0050).
- Language maturity (PRD-S) — FLUX-051 (list comprehension),
FLUX-052 (slot/children composition), FLUX-053 (nullable/optional chaining),
FLUX-054 (structural vs nominal prop typing), FLUX-055 (in-language
Result). - Performance (PRD-T) — FLUX-056 (large-list scroll benchmark), FLUX-057 (RN/Flutter published comparison).
- DevTools (PRD-P) — FLUX-058 (signal-graph edge rendering),
FLUX-059 (timeline / flamegraph from
MetricRecord), FLUX-060 (network inspector + log viewer), FLUX-061 (multi-device connect), FLUX-062 (on-device verification evidence). - Correctness / architecture blockers — FLUX-063 (FLUX-011 PARTIAL:
6/10 B.3 lowering gap at
flux-ir), FLUX-064 (Phase-2 async wire host halves unlanded), FLUX-065 (iOS declarative-tier convergence, ADR-0048 Phase 0/1), FLUX-066 (on-device render-perf harness), FLUX-067 (mutation testing + toolchain matrix), FLUX-068 (flux buildtoolchain invoke + distribution), FLUX-069 (1.0 beta evidence gates).
Status: 46 issues created (FLUX-024 … FLUX-069), all committed. The
flux-lsp crate (FLUX-024) is scaffolded, wired into the workspace
members + [workspace.dependencies], and its async-lsp/lsp-types
dependency request in MANIFEST_REQUESTS.md has been applied. No production
code outside the flux-lsp scaffold was changed by this promotion.
2026-08-29 — Pipeline & runtime performance pass (external review follow-up)
Code changes committed under FLUX-049. Benchmark figures in the external review were not reproduced; measured on this tree (release): parse 500 lines ~308 µs, type-check ~810 µs, diff(50,identical) ~15 µs, serialize 50-node patch ~4 µs, VM 50-instr/10k signals ~439 µs — all within AGENTS.md §3.10 budgets.
Server / Rust (flux-devserver, flux-ir-serde) — [verified]
- OPT-B (serialization buffer reuse).
Frameexposesencode_into(&mut Vec<u8>)onInitFrame/DeltaFrame; the dev-serverPipelinekeeps oneVec<u8>scratch buffer reused across everyInit/Deltaon the hot path. No behavior change;to_bytespreserved.- Verification:
cargo nextest143/143 green;cargo clippy -Dclean; serialize bench no regression (~3.99 µs for 50-node patch).
- Verification:
- OPT-A (incremental string deltas): REVERTED — correctness hazard. Shipping only
newly-interned strings on a
Deltais unsafe becauseStringTable::internassigns ids densely in first-insertion order per compile (flux-syntax/src/strings.rs), not content-derived. After an edit, id 0 can mean a different literal; a host that merges partial deltas would bind stale id→text and render wrong text. The existing “full string table every Delta” is correct. Added a regression guarddelta_ships_full_string_table_for_positional_ids.
Runtime decode-caching (both hosts) — the review’s best idea, real win
Handler bytecode is decoded once at registration and reused on every dispatch instead of re-decoding on every tap.
-
iOS (Swift) —
[verified](FluxExecutor.swift,FluxBytecodeVM.swift):handlerClosuresalready cacheddecoded: [Instruction]?at registration, butrunHandlerAsyncignored it and re-decoded. Added arunResumable(program: originalBytecode:)overload and routed the async dispatch hot path through the cache (fallback to raw-bytecode path when cache absent). Cache invalidated per frame via last-wins re-registration, so handler-body edits still take effect.- Verification:
xcodebuild test -scheme FluxAppon the booted iPhone 17 Pro simulator → TEST SUCCEEDED, 19 executed, 0 failures (incl.RenderMountTests,CapabilityRoundTripTests).
- Verification:
-
Android (Kotlin/JVM) —
[verified](FluxExecutor.kt,FluxBytecodeVM.kt):Closurenow carriesinstructions: List<Instruction>(decoded once viadecodeClosureat registration; malformed bytecode falls back to empty so dispatch still surfaces decode faults). Addedrun(program:)/runResumable(program:)overloads;dispatch/dispatchAsyncroute through the cache when present.- Verified on-device: built
:runtimes:android:app:assembleDebug, installed on the physical Poco (adb15a3cc41de5b) viaadb reverse tcp:7331 tcp:7331to theflux devserver servingexamples/router(port 7331, the app’s hardcoded URL), launchedFluxHostActivity. User confirmed Home/Settings router navigation works (taps exercise the cached-decode path). logcat showed a clean frame render (vri.reportDrawFinished) with no VM/wire faults; server log showed theplatform=androidhandshake. Also fixed a pre-existing build break inshadow/ShadowNodeExt.kt(BUTTON_ON_CLICK→BUTTON_ON_PRESS, the constant actually defined inPropsIndex) that blocked the APK build.
- Verified on-device: built
WebSocket compression (OPT-C) — NOT achievable with current dependency
- Code change
[verified](session.rs,debug_bridge.rs): server now upgrades host connections withaccept_async_with_config(stream, Some(WebSocketConfig:: default()))instead of bareaccept_async.WebSocketConfigis always present, so this compiles today with no behavior change and activates permessage-deflate automatically the moment atokio-tungsteniterelease that supports it is used. - Capability gap (root cause, NOT a process/network limit):
tokio-tungstenitehas nocompressionfeature in any published version.cargo(which has network here) resolves the crate only up to 0.30.0, and 0.30’s feature list contains nocompression;docs.rs/tungstenitestates “There is no support for permessage-deflate at the moment.” Bumping to^0.31was attempted and rejected by the resolver (“no matching package namedtokio-tungstenitefound”), confirming 0.31 does not exist. The earlier^0.31suggestion was a misremembering and is wrong. - Options (not pursued): (1) swap the WS library to one with RFC 7692 support
(e.g.
yawc); (2) application-level gzip of frame payloads with a wire flag (needs host changes on both platforms, unverifiable here); (3) accept uncompressed wire — Flux’s binary patch frames are already small (Init 50-node frame < 20 KB). Decision: defer. Code remains forward-compatible.
Capabilities — WebView / NativeModule escape hatches + permission gate + fail-closed handshake (FLUX-048 / FLUX-046 / FLUX-049 / FLUX-050) — DONE [verified]
- New capabilities (caps 12 & 13).
WebView(cap 12:load/evaluate/sendMessage) andNativeModule(cap 13:invoke) declared instdlib/capabilities.fluxand registered inCAPABILITY_IDL(crates/flux-types/src/capabilities.rs) with deterministic FNV-1a ids so the server and both hosts agree (no hand-assigned ids).WebView→PermissionKind::None(sandbox-contained, no OS grant);NativeModule→PermissionKind::NativeModule(an explicit allow-list grant, because a wrapped SDK runs arbitrary native code). - Both hosts register the impls.
WebView.loadwrites the requested URL into signal 82 andNativeModule.invokerecords the SDK call into signal 83 (CapabilityRegistry.ktAndroid,Registry.swiftiOS), so the dev loop resolves them like any other cap. BothHelloFrameGENERATED tables advertise the new ids. - Permission gate wired into native
CALL_CAP(FLUX-049). APermissionCheckeris threaded through the whole VM dispatch path (run/runResumable/resume/execTail/execTailWith) on both hosts. ACALL_CAPto a capability whoserequired_permission(capId, methodId)is ungranted — or to an unknown cap id — throws a typed error (CAPABILITY_DENIED/capabilityDenied), surfaced as a red banner, never a crash into native code. Therequired_permissiontable is mirrored 1:1 on all three sites (Rust / AndroidPermission.kt/ iOSPermission.swift). Production injects an OS-backed checker; the dev default isAllowAllPermissionChecker. - Fail-closed protocol-version handshake (FLUX-050). Both
FrameDeserializers now reject a frame whose version byte ≠PROTOCOL_VERSIONwith a typedWireErrorbefore any tree decoding — an old host + new server (or vice-versa) can no longer be fed incompatible frames and mis-parsed into a corrupt/blank tree. This closes the update- integrity gap called out as REMAINING in the FLUX-068 entry above. - Native
WebHost(WebView) adapters.WebViewAdapter(Kotlin) +WebHostView(Swift, sandboxedWKWebView) map aWebHostnode to a web view, readingsrcby the FNV-1a prop index (never a hardcoded positional index); they no-op on empty/non-http(s)srcrather than navigating to garbage.PropsIndex.propIndexForNamemadepublicso adapters derive indices by name. - Threat-model docs. ADR-0056 (fail-closed version handshake / update integrity) and
ADR-0057 (capability permission threat model, with a fuzz/dispatch coverage note), plus
docs/NATIVE_MODULE_ESCAPE_HATCH.md(how to wrap any SDK as a capability: deterministic id, host binding, gated by intent). - Verification.
- Rust:
cargo nextest -p flux-types— capability tests green (the two pre-existingResult-diagnostic failures belong to the incomplete ADR-0055Resultwiring inchecker.rs/prelude.rs/typecheck.rs, untouched here). - Android (JVM):
./gradlew :runtimes:android:host:test— newRuntimeFixesTest(denied/unknown/grantedCALL_CAP+ WebView/NativeModule round-trips) andFrameDeserializerTest(version mismatch) green; only the 2 pre-existingIsaConformanceTestfailures remain (confirmed on clean tree, unrelated). - iOS (sim, iPhone 17 Pro):
xcodebuild -scheme FluxApp→ TEST SUCCEEDED; newCapabilityRoundTripTests(denied/unknown/granted) +RuntimeGapTests(version mismatch) green;xcodebuild -scheme FluxUIKit→ 39/39 (incl. 3WebHostViewtests).
- Rust:
