Skip to content

Agent UX: pm list --sort <field> omits the sort key from the brief projection #1481

Closed

Description

@unbraind

Observed (pm 2026.10.15)

$ pm list --status open --limit 2 --sort priority --format json | jq -c '.items[0]|keys'
["id","status","title","type"]

The result is ordered by priority, but the brief projection (id,status,type,title) leaves the sort key out. The ordering is visible but the value behind it isn't. An agent that asked for priority order and reads .priority gets null for every row. Then it either re-runs with --fields id,priority,... or misreports priorities. That happened in this session: a backlog survey printed pnull for every item.

The same applies to --sort updated_at / created_at / deadline.

Proposal

When --sort <field> is given and --fields is not, add the sort field to the brief projection. In TOON that is one extra column. Record it in projection.fields so the omission receipt stays accurate. An explicit --fields stays authoritative.

Activity

  1. unbraind commented on Oct 16, 2026

    @unbraind
    OwnerAuthor

    Tracked by pm-gh1481.

    Recorded the requested implicit sort-field projection and explicit-field precedence.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions