Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

wit-bindgen-go crashes with error-context type

Open
#411 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
45/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
go, wasm
Domain
tooling

Research direction

Start by running the documented go run ./cmd/wit-bindgen-go generate poc.wit reproduction and inspect how the generator handles the wit.ErrorContext primitive. Done means the same WIT input generates Go bindings successfully without the reported panic.

Written by the indexing model from the issue text.

Description

Generating Go bindings for any WIT that mentions error-context crashes with BUG: unknown wit.Primitive *wit.ErrorContext

Steps-To-Reproduce

go run ./cmd/wit-bindgen-go \
  generate \
  poc.wit

poc.wit (validated by wasm-tools component wit)

package demo:demo;

world demo {
  export foo: func() -> error-context;
}

Expected

writes generated Go bindings successfully.

Actual

crashes with panic: BUG: unknown wit.Primitive *wit.ErrorContext.

Environment

ubuntu 22.04, x86-64, Go 1.24.3

Dominant language
Go
Stars
148
Forks
20
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from bytecodealliance/go-modules

All issues in bytecodealliance/go-modules

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.