Skip to content

Non-recursive skill file listing reports subfolders with nodeType "ITEM" #1912

Description

@andrii-novikov

Name and Version

ai-dial-core development (Docker image epam/ai-dial-core:development), observed 2026-09-04.

What steps will reproduce the bug?

  1. Create a skill that contains subdirectories — e.g. upload a ZIP through the UI with this layout:

    SKILL.md
    LICENSE.txt
    agents/analyzer.md
    assets/eval_review.html
    references/schemas.md
    scripts/utils.py
    
  2. List its files non-recursively:

    GET /v2/metadata/skills/{bucket}/{path}/files/
    
  3. Inspect nodeType on the entries that correspond to directories.

What is the expected behavior?

Directory entries are reported with "nodeType": "FOLDER", so that a client can tell files from directories by the field that exists for exactly that purpose.

This is what /v1/metadata/files/{bucket}/{path} does — its folder entries come back as FOLDER.

What do you see instead?

Every entry is "nodeType": "ITEM", directories included. Only the trailing / on url distinguishes them:

{
  "name": "files",
  "parentPath": "skill-creator",
  "bucket": "{bucket}",
  "url": "skills/{bucket}/skill-creator/files/",
  "nodeType": "FOLDER",
  "resourceType": "SKILL",
  "items": [
    {
      "name": "SKILL.md",
      "url": "skills/{bucket}/skill-creator/files/SKILL.md",
      "nodeType": "ITEM",
      "resourceType": "SKILL",
      "updatedAt": 1788530552986
    },
    {
      "name": "agents",
      "url": "skills/{bucket}/skill-creator/files/agents/",
      "nodeType": "ITEM",
      "resourceType": "SKILL"
    },
    {
      "name": "scripts",
      "url": "skills/{bucket}/skill-creator/files/scripts/",
      "nodeType": "ITEM",
      "resourceType": "SKILL"
    }
  ]
}

agents and scripts are directories. Both are reported as ITEM, and neither carries updatedAt (unlike the file entries beside them).

A client that trusts nodeType — the documented way to tell the two apart — will treat a directory as a file.

Additional information

  • recursive=true is unaffected. That listing is flattened: it returns leaf files at every depth with the structure in parentPath, and contains no directory entries at all, so there is nothing to mislabel.
  • Empty directories are omitted from both modes.
  • The python client currently works around this by deriving node_type from the trailing / of url for skill file listings, so that its users do not have to know about the discrepancy. We would like to drop that workaround once this is fixed. See feat: add read-side resource for DIAL Core /v2/skills ai-dial-client-python#138.
  • API reference for the endpoint: https://dialx.ai/dial_api

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

  • Status
    Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions