Plugin fails to load on OpenCode v2.0.27 - incompatible plugin API
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 25/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Ativa
- Stack de tecnologia
- node.js, typescript
- Domínio
- developer-experience
Direção de pesquisa
Start at the plugin's entry module, where the named export PTYPlugin is declared, and compare it with the default-export shape OpenCode 2.x expects (an id plus an effect or setup function). The error text is in the issue, and the linked oh-my-openagent and opencode-pty#67 threads describe the same loader. Done means the plugin loads on OpenCode v2.0.27 without the error. The issue does not choose between adapting the API and adding a shim, so ask the maintainer first.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Bug Description
[email protected] fails to load as a plugin on OpenCode v2.0.27 with the following error:
Plugin must export a default definition with an id and an effect or setup function.
Environment
- OpenCode version: v2.0.27
- opencode-pty version: 0.4.0 (latest on npm)
- Platform: Windows 11
- Node: v22.18.0
Steps to Reproduce
- Install opencode-pty:
opencode plugin add opencode-pty@latest - Start OpenCode v2.0.27
- Plugin fails to load with the error above
Root Cause
OpenCode 2.0 introduced a new Effect-based plugin API that requires plugins to export a default definition with id and effect or setup function keys. opencode-pty currently uses the old export format (named exports like export { PTYPlugin }).
Expected Behavior
opencode-pty should either:
- Adapt to the new Effect-based plugin API, OR
- Provide a compatibility shim for OpenCode 2.x
Additional Context
- Similar issues reported for oh-my-openagent: https://github.com/code-yeongyu/oh-my-openagent/issues/10089
- Related v2 plugin installation bug: https://github.com/shekohex/opencode-pty/issues/67
- Linguagem predominante
- TypeScript
- Estrelas
- 601
- Forks
- 66
- Merge médio
- 1d 20h
- PRs com merge (30d)
- 3
Preparar o ambiente
Este projeto não oferece contêiner de desenvolvimento, Dockerfile nem guia de contribuição, então a configuração fica por sua conta: comece pelo README e veja nosso guia da primeira contribuição para os passos gerais.
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de shekohex/opencode-pty
-
[Bug]: exit notification delivery failures are silently swallowed — agent never wakes, no diagnosticAberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
shekohex/opencode-pty#54 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
shekohex/opencode-pty#48 ·
Mantenedores costumam responder em até 1 dia
-
bug
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 64/100
shekohex/opencode-pty#82 ·
Mantenedores costumam responder em até 1 dia
-
enhancement
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 67/100
shekohex/opencode-pty#81 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 46/100
shekohex/opencode-pty#80 ·
Mantenedores costumam responder em até 1 dia
Todas as issues de shekohex/opencode-pty
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 62/100
umami-software/umami#4637 ·
Mantenedores costumam responder em até 3 dias
-
Hotkeys fire when pressed with the Ctrl key, so browser shortcuts also trigger player actionsTalvez já em andamento @RaphaelFakhri assumiu hoje. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
muxinc/media-chrome#1332 ·
Mantenedores costumam responder em até 5 dias
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
polarsource/polar#15580 ·
Mantenedores costumam responder em até 1 dia
-
accepted bug via-triage
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 69/100
pingdotgg/t3code#20931 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
bug/1-unconfirmed kind/bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
Mantenedores costumam responder em até 1 dia