This repository was archived by the owner on Sep 11, 2025. It is now read-only.
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR enforces the use of the WASI reactor module mode by switching the start function from _start to _initialize and updating the required TinyGo version.
- Bump the minimum TinyGo version from 0.33.0 to 0.35.0 across the build system and CLI globals.
- Remove the TinyGo version check in the build process and unconditionally use reactor mode flags.
- Update module configuration and plugin setup to dynamically select the proper WASI startup function based on module exports.
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| sdk/go/tools/modus-go-build/compiler/compiler.go | Updates version constant and removes conditional TinyGo version check to enforce reactor mode. |
| sdk/assemblyscript/src/plugin.asconfig.json | Changes the exported start function from _start to _initialize. |
| runtime/wasmhost/wasmhost.go | Adapts getModuleConfig usage to include the plugin information and update start functions. |
| runtime/plugins/plugins.go | Introduces a StartFunction field and conditionally selects the appropriate start function. |
| cli/src/custom/globals.ts | Updates the minimum TinyGo version in CLI globals. |
| CHANGELOG.md | Adds an entry for the new WASI reactor mode enforcement feature. |
Comments suppressed due to low confidence (1)
sdk/go/tools/modus-go-build/compiler/compiler.go:27
- The TinyGo version check is removed; consider removing the getCompilerVersion helper and its associated error handling to simplify the build process.
tinygoVersion, err := getCompilerVersion(config)
|
Running Code Quality on PRs by uploading data to Trunk will soon be removed. You can still run checks on your PRs using trunk-action - see the migration guide for more information. |
ryanfoxtyler
approved these changes
May 27, 2025
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
All Modus apps are technically implemented as WASI "reactor" modules - which should use
_initializeas their internal wasm start function._startshould be used only for WASI "command" modules.This PR updates Modus to enforce this part of the WASI spec. As a side effect, the minimum version of TinyGo for the Modus Go SDK is now increased to
v0.35.0.