Repository navigation
Conversation
skhaz
approved these changes
Sep 30, 2026
Integration patch for runtime #887 and #893. Preserve conversion failures until the actual callable is known, reject before its body, retain untyped conversion semantics, and exercise source/bytecode, cached calls and initializer preemption. Pin the reproducible go-lua #58/#60 integration revision, with no local replacement. Neither main nor existing argument-contract dependency PR is merged.
Exercise missing/optional/variadic arguments on fresh and cached calls, method switches, preempted initialization, and unchanged process/untyped conversion. Keep native API error causes and clean messages through the existing Lua-to-API boundary. Strengthen the late-admission routing assertion to use the canonical PID key.
skhaz
approved these changes
Oct 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Automatically validate explicitly annotated parameters when the functions subsystem invokes a Lua handler. No entry field or application configuration is required, and static diagnostics can remain disabled.
Calling this handler with an integer
idproduces a non-retryable INVALID error. Missing required arguments fail, optional parameters accept nil, and untyped parameters stay unchecked. Typed varargs validate each extra value; ordinary extra arguments retain Lua semantics.Implementation
Scope and limits
Lua function handlers only. Ordinary Lua calls, process startup, workflows, WASM handlers, and return values are unchanged. Module initialization may run before validation; the rejected handler body does not.
Validation follows existing
Type:issemantics, not JSON schema: no coercion; records allow extra fields; arrays/string-keyed maps check their respective table portions. Callable/opaque platform types check runtime kinds rather than callback signatures/userdata identity. Generic function parameters are not dynamically instantiated from argument values. Old bytecode without declaration metadata must be rebuilt.Typed source requires declaration analysis on a cold compile even when diagnostics are off. There is no new per-call analysis, second resolver, or unbounded contract cache.
Verification
GOWORK=offagainst the pushed/pinned dependency. All CI checks now pass on the pinned dependency.Depends on wippyai/go-lua#58. Neither PR authorizes a release or merge.
Review stack and dependency
This PR is stacked on runtime #893 (CPU-bound actor preemption). Land #893 first; this PR adds handler argument validation and the compatibility corrections on top.
v1.6.4-0.20261005132556-8e0ac4f7baf7; no local replacement or workspace dependency.Landing order: go-lua #60 then #58; runtime #893 then #887. Nothing has been merged or released by this update.