Skip to content

🛠️ fix: harden GitHub transport diagnostics#52

Merged
SigureMo merged 4 commits into
ShigureLab:mainfrom
ShigureNyako:codex/gh-llm-retry-doctor
May 23, 2026
Merged

🛠️ fix: harden GitHub transport diagnostics#52
SigureMo merged 4 commits into
ShigureLab:mainfrom
ShigureNyako:codex/gh-llm-retry-doctor

Conversation

@ShigureNyako
Copy link
Copy Markdown
Member

Summary

  • Treat noisy gh auth status failures as doctor warnings when REST and GraphQL probes both succeed.
  • Broaden retryable GitHub transport error detection and increase read retry attempts from 4 to 6.
  • Keep GraphQL mutations at 4 attempts and steer transport diagnostics toward direct API probes.

Validation

  • uv run ruff check .
  • uv run ty check --error-on-warning src/gh_llm tests
  • uv run pytest -q
  • prettier --check README.md
  • gh-llm pr view 79119 --repo PaddlePaddle/Paddle --auto-collapse-author PaddlePaddle-bot --auto-collapse-author Paddle-CI-Bot

Co-authored-by: Codex <noreply@openai.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR hardens gh-llm’s GitHub transport diagnostics and retry behavior, aiming to reduce false negatives in doctor output and provide more actionable follow-up steps when GraphQL/transport errors occur.

Changes:

  • Adjust doctor to downgrade noisy gh auth status failures to a warning when both REST and GraphQL probes succeed.
  • Increase retry attempts for GitHub transport failures (notably GraphQL-backed reads) and broaden retryable error detection (e.g., stream/TLS/proxy/5xx indicators).
  • Update layered diagnostics messaging and suggested follow-up commands to prefer direct API probes over gh auth status.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
tests/test_cli.py Adds/updates tests covering doctor warning behavior, expanded retry cases (e.g., stream errors), and new retry counts/messages.
src/gh_llm/github_api.py Increases retry/backoff limits, adds mutation-specific retry cap, and expands retryable error detection (including stdout+stderr inspection).
src/gh_llm/diagnostics.py Updates GraphQL transport diagnosis text and shifts suggested next steps toward direct REST/GraphQL probes; broadens transport pattern detection.
src/gh_llm/commands/doctor.py Refactors probe execution and reconciles auth-status failures into warnings when API probes succeed.
README.md Documents the new doctor warning behavior and updated “Try next” probe guidance.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/gh_llm/commands/doctor.py
Comment thread src/gh_llm/github_api.py
Comment thread src/gh_llm/diagnostics.py Outdated
Co-authored-by: Codex <noreply@openai.com>
Comment thread src/gh_llm/diagnostics.py Outdated
Comment thread src/gh_llm/github_api.py Outdated
Co-authored-by: Codex <noreply@openai.com>
Comment thread src/gh_llm/transport_errors.py Outdated
Co-authored-by: Codex <noreply@openai.com>
@SigureMo SigureMo marked this pull request as ready for review May 23, 2026 17:09
@SigureMo SigureMo merged commit 6a8855a into ShigureLab:main May 23, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants