Skip to content

Skills with metadata as last frontmatter field are not discovered #951

@kamja-bq

Description

@kamja-bq

Describe the bug

Skills are not discovered when the metadata field (nested YAML) is the last field in SKILL.md frontmatter.

VS Code Copilot Chat does NOT have this issue - it correctly discovers skills regardless of field order. This bug is specific to Copilot CLI.

Affected version

0.0.380 Commit: 39ff7b7

Steps to reproduce the behavior

  1. Create a skill at ~/.copilot/skills/sample-skill/SKILL.md with this content:
name: sample-skill
description: A sample skill for testing.
metadata:
  author: test

Sample Skill

  1. Run copilot in terminal
  2. Observe "No skills found" or skill missing from /skills list
  3. Add any field after metadata (e.g., license: MIT)
  4. Restart copilot - skill is now discovered

Expected behavior

Skills should be discovered regardless of field order in frontmatter, as long as the YAML is valid per the Agent Skills specification (https://agentskills.io/specification).

This is the current behavior in VS Code Copilot Chat, which handles these skills correctly.

Additional context

  • Operating system: Windows 11
  • CPU architecture: x86_64
  • Terminal emulator: Windows Terminal / VS Code integrated terminal
  • Shell: PowerShell

Workaround: Add any simple field (e.g., license: MIT or compatibility: ...) after the metadata block.

Working example:

name: sample-skill
description: A sample skill for testing.
metadata:
  author: test
license: MIT

The Agent Skills specification (https://agentskills.io/specification) shows an example with metadata as the last field, confirming this is valid YAML frontmatter. No field ordering is specified or required.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions