Repository navigation
Conversation
Point octoscript-core and octoscript-capabilities at the ported makepad `work` VM (branch vm-port/integration, a4347332b) instead of the vendored copy under vendor/makepad. The vendor tree stays in place; the path is a local checkout for the G3 gate run. Host shape: the ported ScriptVm takes `host: &mut dyn ScriptHost`, so Runtime now owns a `ScriptVmHost<H, S>` and the capability bindings downcast through `as_any()` / `as_any_mut()`. Tool output strings: the ported heap refuses the unrestricted `ScriptVm::new_string_with` whenever an allocation budget or retained cap is armed (it cannot preflight a raw `&mut String`). The three tool-output sites in `install_tool_module` now build through the accounted `heap.new_bounded_string_with`, the same path octoscript-core's string natives already use. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JgSir4cQyaakzPju4h6smw
…ighted heap caps The ported makepad-script (upstream #1139) starts a new statement at a `(` on a new line, so the compatibility preflight now accepts `use mod.std.a\n(42)` just as canonical lowering does. And its heap preflights every charge, so a refused over-limit string never lands on the heap: the runtime is not left above its cap, and the next evaluation runs instead of being refused until GC. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JgSir4cQyaakzPju4h6smw
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.
Switches
octoscript-coreandoctoscript-capabilitiesfrom the vendoredvendor/makepadVM tomakepad-scriptfrom OctoSense-org/makepad at thevm-port/integrationrevision (fork PR #1), which carries every vendor patch. Based on PR #20 (the renamed side branch), so this PR shows only its own commit.Changes:
Runtimeholds aScriptVmHost<H, S>and buildsScriptVm { host, bx }(the fork's host shape); seven capability downcasts go throughas_any_mut(); the three tool-output sites usenew_bounded_string_with, since the ported VM refuses the rawnew_string_withunder a heap cap.vendor/makepadis left in place for this PR and can be deleted once the fork revision is final.Verification on this tree:
cargo test --workspace --no-fail-fast= 986 passed, 4 failed, no VM regressions. The 4:canonical_newline_boundaries_are_lowered_for_vm_compatibility(upstream #1139 makes a newline-(start a statement; expectation must flip),heap_limit_bounds_total_string_storage_after_individual_strings_pass(the ported heap preflights and never allocates the over-limit string, so the next eval is not refused until GC; confirm whether refuse-until-GC was a required contract), and the twoprofile.rscatalog-drift tests that fail on the branch regardless of VM.🤖 Generated with Claude Code
https://claude.ai/code/session_01JgSir4cQyaakzPju4h6smw