Repository navigation
Remove WebAssembly format plugins and Wasmtime: built-in plugins only - #440
Conversation
Format plugins loaded as WebAssembly components were too big an API to keep: the forge:format WIT contract, the component glue, the Wasmtime sandbox and its limits, and the configuration around them. Forge now supports built-in plugins only, crates under plugins/ that the server links in, like NuGet. Gone: forge-plugin's wasm runtime (Plugin::load, HostLimits, the digest pin), wasmtime and wasmtime-wasi, forge-plugin-api's component feature, export_component! and wit/, the component and limits keys of plugin.toml, the example plugin plugins/helm and its tests, `cargo xtask plugins` and `plugins-check`, the CI `plugins` job (and its place in the release gate), the wasm32-wasip2 target, and builtin/sha256 in GET /admin/formats. A config that still has a [plugins] section fails startup and says what changed. The 64 KiB summary bound applied to WebAssembly plugins only, so it goes too. The host contract stays covered by the native probe plugin, which now also checks that a repository whose format is missing answers 503. The changelog fragments that described WebAssembly-only fixes (228, 229, 234) are dropped. Fixes #437 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JpCggxduZYrAYTnobHTzhY
Brings in main via #435. The Helm plugin's files and the WebAssembly plugin tests stay deleted; main's #283 test there (a proxy of an unreachable upstream answers 503) moves to group_proxy.rs with its NuGet half. Main's new "every format lives in plugins/" text in AGENTS.md, README.md and DEVELOPMENT.md now says plugins are linked into the server. A leftover [plugins] section is now ignored, like any other unknown top-level key, rather than refused at startup. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JpCggxduZYrAYTnobHTzhY
|
aws-sdk-s3 = { version = "1.85", default-features = false, features = [
- "sigv4a",
"http-1x",
"default-https-client",
"rt-tokio",
] }The alternative is to ignore RUSTSEC-2026-0387 in Generated by Claude Code |
Cargo.lock conflicted: main dropped Wasmtime (#440), this branch the SigV4a crates. Took main's lockfile and re-resolved it with cargo update -w, which removes the same 11 crates as before and changes nothing else. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GcmkrXQyFekcS5VQgA7oGi
Fixes #437
Stacked on #435 (it deletes
plugins/helm, which #435 keeps as the WebAssembly tests' subject). It retargets tomainonce #435 merges.Format plugins loaded as WebAssembly components were too big an API to keep stable. Forge now supports only built-in plugins: crates under
plugins/that the server links in, like NuGet. This removes about 9,700 lines.Removed
forge-plugin'swasmmodule (Plugin::load,HostLimits,WasmPlugin, the digest pin,Origin) and thewasmtime/wasmtime-wasidependencies.cargo tree -p forge-serverhas no Wasmtime any more.forge-plugin-api'scomponentfeature,export_component!, the WIT conversion macros,wit/format.witandforge_plugin::testing.plugin.toml: thecomponentkey and the[limits]table, which are now refused as unknown keys.[plugins]section. A config that still has it (orFORGE_PLUGINS__*) starts as before: the section is ignored like any other unknown top-level key. Also removed from.env.exampleandforge.toml.example.builtinandsha256inGET /admin/formats. The web UI no longer names a format "(plugin )".plugins/helm,crates/plugin/tests/component.rsandcrates/server/tests/plugins.rs.probeplugin inplugin_contract.rs, which now also checks that a repository whose format is missing answers 503.plugins.rs(a proxy of an unreachable upstream answers 503) moved togroup_proxy.rs, with its NuGet half.plugins_blockoption is now a genericextra_toml.cargo xtask pluginsandplugins-check.pluginsjob, removed fromREQUIRED_JOBSinrelease.yml,CI_JOB_GROUPinci-changes.shand the required-checks list inDEVELOPMENT.md. Branch protection's required checks needpluginsremoved by hand.wasm32-wasip2target in thetestjob.wasmtimegroup.Apache-2.0 WITH LLVM-exceptionlicense inabout.toml: the crates left under it also offer plain Apache-2.0 or MIT.docs/format-plugins.md(loading WebAssembly plugins, the sandbox, the artifact-keeper comparison),plugins/README.md,README.md,DEVELOPMENT.md,AGENTS.mdanddocs/deployment.mdnow describe built-in plugins only.WebAssembly plugins shipped as a preview in 1.x. As agreed for 2.0, there is no upgrade note.
Kept
FormatPluginand the{mount}/{repo}/…dispatcher.Admin screen
No new admin API, only two fields removed from
GET /admin/formats. The repository form follows.Tests run locally
cargo fmt --all --check;cargo clippy --workspace --all-targets -- -D warnings;cargo clippy -p forge-e2e --features forge-e2e --tests -- -D warnings;cargo xtask changelog --checkcargo test -p forge-plugin -p forge-plugin-api -p forge-format-nuget -p xtask -p forge-oci;cargo test -p forge-server --lib(203, including the ignored[plugins]section)cargo test -p forge-server --test plugin_contract(8),--test group_proxy(2),--test registry(32),--test browse(10),--test admin(44)pnpm run tsc,pnpm run test(399),pnpm run buildforge-e2esuite (compiled with clippy only).🤖 Generated with Claude Code
https://claude.ai/code/session_01JpCggxduZYrAYTnobHTzhY