anomalyco/sst · error
not implemented
Error message
not implemented
What it means
`Runtime.Run` for the `worker` runtime is intentionally unimplemented — Cloudflare Workers cannot be executed locally through this code path, so calling it always returns "not implemented". It is a hard stub, not a transient failure.
Source
Thrown at pkg/runtime/worker/worker.go:325
if err != nil {
continue
}
if absPath == file {
return true
}
}
return false
}
// ShouldRunEagerly returns true for Cloudflare Workers - workers restart immediately after rebuild.
// Workers use esbuild's metafile for precise per-function dependency tracking.
func (r *Runtime) ShouldRunEagerly() bool {
return true
}
func (r *Runtime) Run(ctx context.Context, input *runtime.RunInput) (runtime.Worker, error) {
return nil, fmt.Errorf("not implemented")
}
var NODE_BUILTINS = map[string]bool{
"assert": true,
"async_hooks": true,
"buffer": true,
"child_process": true,
"cluster": true,
"console": true,
"constants": true,
"crypto": true,
"dgram": true,
"diagnostics_channel": true,
"dns": true,
"domain": true,
"events": true,
"fs": true,
"http": true,View on GitHub (pinned to a0bd20f762)
Solutions
- Use the default full `sst dev` mode, which builds workers eagerly via esbuild metafiles instead of calling Run
- Run/deploy workers to a real Cloudflare environment instead of local process execution
- Wrap worker components behind a feature that doesn't require local execution during dev
Defensive patterns
Strategy: fallback
Validate before calling
// detect worker components and avoid local-run dev modes
const isWorker = componentType === "sst.aws.Worker";
if (isWorker && devMode === "basic") {
console.warn("worker runtime does not support local Run; use full sst dev");
} Try / catch
try {
await startDev({ mode: "basic" });
} catch (e) {
if (/not implemented/.test(String(e))) {
await startDev({ mode: "full" }); // workers require eager build path
} else throw e;
} Prevention
- Use default (full) `sst dev` when the app contains worker components
- Do not invoke Runtime.Run programmatically for the worker runtime
- Deploy workers to Cloudflare for execution instead of relying on local process execution
When it happens
Trigger: Any code path invoking `Run` on the worker runtime — e.g. attempting `sst dev` with a worker component in a mode that requires local process execution instead of the eager-build/metafile path.
Common situations: Trying to run `sst dev --mode=basic` (or a legacy dev flow) against `sst.aws.Worker` components; tooling that programmatically calls Run on all runtimes.
Related errors
- Invalid worker definition for the "${name}" Worker
- failed to load cloudflare unenv config: %w %s
- failed to decode cloudflare unenv config: %w %s
- SSR server bundle not found in the build output at: "${pat
- You cannot provide both "job" and "worker" in the "${name}"
AI-assisted analysis of anomalyco/sst@a0bd20f762 (2026-08-30).
Data as JSON: /api/errors/4ca3eb5102ad0cc5.
Report an issue: GitHub.