Skip to content

Can not use opencode --port #22293

@CamaleH

Description

@CamaleH

Description

opencode --port just quit and return a {}. But opencode is fine.

System:

$ uname -a
Linux FA 6.12.73+deb13-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.12.73-1 (2026-02-17) x86_64 GNU/Linux

opencode --port logs (hide some privacy):

opencode --port --print-logs
INFO  2026-04-13T12:56:12 +302ms service=default version=1.4.3 args=["--port","--print-logs"] opencode
INFO  2026-04-13T12:56:12 +1ms service=default directory=/path/to/workspace creating instance
INFO  2026-04-13T12:56:12 +4ms service=project directory=/path/to/workspace fromDirectory
INFO  2026-04-13T12:56:12 +19ms service=db path=$HOME/.local/share/opencode/opencode.db opening database
INFO  2026-04-13T12:56:12 +36ms service=db count=10 mode=bundled applying migrations
INFO  2026-04-13T12:56:12 +15ms service=config path=$HOME/.config/opencode/config.json loading
INFO  2026-04-13T12:56:12 +0ms service=config path=$HOME/.config/opencode/opencode.json loading
INFO  2026-04-13T12:56:12 +1ms service=config path=$HOME/.config/opencode/opencode.jsonc loading
{}

opencode logs, startup and then /exit (hide some privacy):

opencode --print-logs
INFO  2026-04-13T13:02:52 +302ms service=default version=1.4.3 args=["--print-logs"] opencode
INFO  2026-04-13T13:02:52 +1ms service=default directory=/path/to/workspace creating instance
INFO  2026-04-13T13:02:52 +4ms service=project directory=/path/to/workspace fromDirectory
INFO  2026-04-13T13:02:52 +28ms service=db path=$HOME/.local/share/opencode/opencode.db opening database
INFO  2026-04-13T13:02:52 +29ms service=db count=10 mode=bundled applying migrations
INFO  2026-04-13T13:02:52 +18ms service=config path=$HOME/.config/opencode/config.json loading
INFO  2026-04-13T13:02:52 +0ms service=config path=$HOME/.config/opencode/opencode.json loading
INFO  2026-04-13T13:02:52 +1ms service=config path=$HOME/.config/opencode/opencode.jsonc loading

It's seem that two logs are same.

Can anyone tell me how to debug it?

Plugins

None

OpenCode version

1.4.3

Steps to reproduce

  1. Use machine same with me. I don't know whether this can be reproduced.
  2. opencode --port

Screenshot and/or share link

No response

Operating System

Linux FA 6.12.73+deb13-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.12.73-1 (2026-02-17) x86_64

Terminal

No response

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingcoreAnything pertaining to core functionality of the application (opencode server stuff)

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions