Skip to content

[backport] get_parent method for issue_read (upstream main) #15

Closed as not planned

Description

@gastrodon

Summary

Adds a get_parent method to the issue_read consolidated tool — the upward counterpart to the existing get_sub_issues. Uses the GraphQL Issue.parent field and returns {"parent": null} when the issue is not a sub-issue. Kept always-on (not feature-gated) to mirror get_sub_issues.

Changes: pkg/github/issues.go +53/-3 lines; pkg/github/issues_test.go +122 lines.

Upstream reference

Fork conflict

Design note. The fork's issue_graph tool traverses sub-issues downward (BFS). get_parent is the upward complement. Both are useful for autonomous agents navigating issue hierarchies. get_parent is in issues.go (not the fork's custom files) and is purely additive — no conflict.

Context

An agent using issue_graph to traverse sub-issues downward had no efficient way to navigate upward to find an issue's parent epic. get_parent closes this gap, completing the vertical traversal API.

Activity

  1. gastrodon commented on Jun 27, 2026

    @gastrodon
    Author

    No-op. The fork already has get_parent in pkg/github/issues.go (line 620+). The method uses the GraphQL Issue.parent field and returns {"parent": null} for top-level issues. Tests are present in issues_test.go.

  2. added
    no-opFork already has equivalent functionality
    on Jun 27, 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

    backportBackport from upstreamfeatureNew featureno-opFork already has equivalent functionality

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions