Skip to content

Invalid input: expected object, received array skills #22040

@decmade

Description

@decmade

Description

When running opencode in a directory containing an opencode.json file with a skills array, the tool errors with: Invalid input: expected object, received array skills
Steps to reproduce:

Plugins

No response

OpenCode version

1.4.0

Steps to reproduce

  1. Open a project directory
  2. Ask Opnecode to create skills
  3. Opencode creates a opencode.json file containing a skills array
  4. Exit Opencode
  5. Run opencode in that directory Expected behavior: Skills should be loaded and available for useActual behavior: Error: Invalid input: expected object, received array skills

Sample minimal opencode.json that triggers the issue:
{
"skills": [
{
"name": "test",
"description": "Test skill",
"command": "echo test"
}
]
}

Screenshot and/or share link

No response

Operating System

No response

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