Skip to content

fix(cli): propagate GraphQL failures in find_prs_for_issue instead of returning empty list#1501

Closed
jaso0n0818 wants to merge 1 commit into
entrius:testfrom
jaso0n0818:fix/find-prs-graphql-failure-sentinel
Closed

fix(cli): propagate GraphQL failures in find_prs_for_issue instead of returning empty list#1501
jaso0n0818 wants to merge 1 commit into
entrius:testfrom
jaso0n0818:fix/find-prs-graphql-failure-sentinel

Conversation

@jaso0n0818

Copy link
Copy Markdown

Summary

Fixes #1492: when _search_issue_referencing_prs_graphql returns None (rate limit, network error, GraphQL errors, or missing issue payload), find_prs_for_issue now raises RuntimeError instead of collapsing None to [].

This surfaces the failure to callers (e.g. fetch_open_issue_pull_requests re-raises as click.ClickException) rather than silently reporting zero submissions.

Related Issues

Fixes #1492

Type of Change

  • Bug fix

Testing

  • uv run ruff check gittensor/utils/github_api_tools.py
  • uv run pytest tests/test_classes.py tests/cli/ -q --ignore=tests/cli/test_cli_helpers.py --ignore=tests/cli/test_cli_json_error_output.py (pre-existing failures in those files)

… returning empty list

Fixes entrius#1492: when _search_issue_referencing_prs_graphql returns None (rate limit,
network error, GraphQL errors, or missing issue payload), find_prs_for_issue now
raises RuntimeError instead of collapsing None to []. This surfaces the failure
to callers rather than silently reporting zero submissions.
@xiao-xiao-mao xiao-xiao-mao Bot added the bug Something isn't working label Jun 19, 2026
@anderdc

anderdc commented Jun 21, 2026

Copy link
Copy Markdown
Collaborator

Duplicate of #1493 which is better scoped/implemented. Closing.

@anderdc anderdc closed this Jun 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] find_prs_for_issue treats GraphQL lookup failures as zero submissions

2 participants