Skip to content

spike: TypeScriptToLua output on piccolo (wasm32) — Tier-2 authoring gate #96

Closed

Description

@Mathih13

Spike, offline only. Spec: the packages-devx design, §Runtime scripts (public proposal: #1; the full design doc lives in the private working origin); prior engine spikes: the Lua-scripting research notes §5 (private working origin — piccolo builds on wasm32-unknown-unknown with the getrandom workaround recorded there).

Question: does TypeScriptToLua output actually run on piccolo? TSTL's generated code leans on its lualib runtime support (class machinery, array/string helpers) and assumes a reasonable Lua stdlib; piccolo's stdlib is explicitly incomplete. This is load-bearing for the "author runtime scripts in TS, execute as Lua" decision — run it before any Tier-2 host work.

Scope: scratch crate (session sandbox, same recipe as the 2026-07-02 spikes), piccolo pinned, TSTL targeting Lua 5.4. Transpile a representative script (classes, closures, array methods, string ops, a hook-handler shape) and execute it under piccolo with fuel metering on.

Done when: the representative TSTL-generated script executes correctly under piccolo in the spike harness, OR the exact incompatibilities (missing stdlib fns, lualib assumptions) are enumerated with a shim-size estimate — findings appended to the Lua-scripting research notes (private working origin) either way.


Migrated 2026-08-11 from the private tracker (spacetime-core#508).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2normalagent-safeSmall and low risk: safe to hand to an agent without supervisionenhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions