Summary
linctl issue get ISSUE-ID only queries and renders the issue's forward relations connection. It omits inverseRelations, so incoming relationships are absent from the rich output and JSON.
For example, for an edge A --blocks--> B, linctl issue get B does not show that B is blocked by A. This is especially confusing now that linctl issue relation list B correctly renders the same edge.
Current code
pkg/api/queries.go selects only relations in GetIssue.
cmd/issue.go renders only issue.Relations.Nodes.
- The renderer has a
case "blocked", but blocked is not an IssueRelationType; incoming blocks rows need to be represented/rendered as Blocked by based on their inverse direction.
Proposed fix
- Query
inverseRelations with both issue endpoints and state.
- Preserve which direction each row came from (or merge through a shared relation helper).
- Render the counterpart and a direction-aware label for both connections:
Blocks / Blocked by, Duplicate of / Has duplicate, and unchanged symmetric labels.
- Add command tests covering the same edge viewed from both endpoints, including
issue get -j.
Related: #59 fixed this behavior in issue relation list.
Summary
linctl issue get ISSUE-IDonly queries and renders the issue's forwardrelationsconnection. It omitsinverseRelations, so incoming relationships are absent from the rich output and JSON.For example, for an edge
A --blocks--> B,linctl issue get Bdoes not show that B is blocked by A. This is especially confusing now thatlinctl issue relation list Bcorrectly renders the same edge.Current code
pkg/api/queries.goselects onlyrelationsinGetIssue.cmd/issue.gorenders onlyissue.Relations.Nodes.case "blocked", butblockedis not anIssueRelationType; incomingblocksrows need to be represented/rendered asBlocked bybased on their inverse direction.Proposed fix
inverseRelationswith both issue endpoints and state.Blocks/Blocked by,Duplicate of/Has duplicate, and unchanged symmetric labels.issue get -j.Related: #59 fixed this behavior in
issue relation list.