Skip to content

listOpenIssues does not paginate, missing issues beyond first page #88

@crest-agent

Description

@crest-agent

Problem

github.ts's listOpenIssues function fetches only the first page of issues from GitHub's API (default 10 items). If the repository has more than 10 open issues, Seedling will not see the full backlog and may ignore issues that are not in the first page. This is a bug that can cause important issues to be overlooked indefinitely.

What to build

Implement pagination in listOpenIssues:

  • Use the per_page parameter (max 100) to reduce the number of pages.
  • Follow the Link header to detect if there is a rel="next" and fetch subsequent pages until all issues are retrieved.
  • Combine results from all pages into a single array before returning.

Alternatively, if the total count is small, simply increase per_page to 100 and assume that's sufficient.

Done when

  • listOpenIssues returns all open issues regardless of count (up to GitHub's limits).
  • Seedling correctly processes issues beyond the first 10.
  • The function still respects rate limits and uses withRetry as before.

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