Skip to content

pm context summary.blocked and pm list-blocked ignore dependency-blocked items (inconsistent with pm next) #578

Closed

Description

@unbraind

Summary

pm next (post GH-489) correctly treats items with open blocked_by dependency edges as blocked: they are excluded from the recommendation and listed in the blocked companion with open_blocker_count/blockers. But the two other surfaces agents use to assess blockage still count only status: "blocked" items and report 0 for dependency-blocked work:

  • pm context (ctx) → summary.blocked: 0 at every depth (brief through full)
  • pm list-blocked → count: 0

Since ctx is advertised as "a token-efficient project context snapshot for next-work decisions", an orchestrator reading blocked: 0 will conclude everything is dispatchable, while pm next (edge-aware) disagrees. Two commands, two silent definitions of "blocked".

Repro (pm-cli 2026.7.17)

pm init --pm-path /tmp/ws/.agents/pm
pm create task "alpha" --pm-path /tmp/ws/.agents/pm            # -> pm-xxxx (blocker)
pm create bug  "beta"  --pm-path /tmp/ws/.agents/pm            # -> pm-yyyy
pm update pm-yyyy --blocked-by pm-xxxx --pm-path /tmp/ws/.agents/pm

pm next --pm-path /tmp/ws/.agents/pm
#   recommended: alpha; blocked companion: beta (open_blocker_count: 1)  ✅

pm ctx --pm-path /tmp/ws/.agents/pm | grep blocked
#   blocked: 0                                                            ❌
pm ctx --depth full --pm-path /tmp/ws/.agents/pm | grep "blocked:"
#   blocked: 0                                                            ❌
pm list-blocked --pm-path /tmp/ws/.agents/pm
#   count: 0                                                              ❌

Expected

Either (a) ctx summary and list-blocked adopt the same edge-aware semantics as pm next (count items whose open blockers > 0, regardless of status), or (b) they report both dimensions explicitly, e.g. blocked_status: 0 + blocked_by_dependencies: 1, so the number can never silently disagree with pm next.

Option (a) or (b) both fix the real problem: an agent should never have to know that "blocked" means status here and edges there.

Context

Activity

  1. coderabbitai commented on Jul 17, 2026

    @coderabbitai
    🔗 Related PRs

    #37 - Improve agent token UX and blocked dependency handling [closed]
    #390 - Fix pm next closeout-row projection [merged]
    #502 - Atomic agent work selection, dependency integrity, and recovery primitives [merged]
    #545 - SDK contract integrity: workspace paths, dependency truth, validation, and MCP parity [merged]
    #559 - SDK durable relationship history and bounded context adapters [merged]


    📝 Issue Planner

    Check the box below or use the @coderabbitai plan command to generate an implementation plan and prompts that you can use with your favorite coding assistant.

    • Create Plan

    🧪 Issue enrichment is currently in open beta.

    You can configure auto-planning by selecting labels in the issue_enrichment configuration.

    To disable automatic issue enrichment, add the following to your .coderabbit.yaml:

    issue_enrichment:
      auto_enrich:
        enabled: false

    💬 Have feedback or questions? Drop into our discord!

  2. unbraind commented on Jul 17, 2026

    @unbraind
    OwnerAuthor

    pm tracker item: pm-uxkf

  3. added a commit that references this issue on Jul 17, 2026
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