You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(review): a failed base-file read counts as an absent file, and an empty pull request diff raises is no diff #1907
Two reads of pull request data in the review path fail without a clear error.
The helpers _write_base_revision_files, _write_base_revision_lockfiles and _evaluate_session_complexity_deltas read a base file that failed to load as an absent file. A review then runs with a missing baseline and does not say so.
get_pr_diff raises GitHubUnreadError with the text is no diff: NoneType when a pull request has an empty diff body.
Evidence
Refactor refactor(github): pull request, repository and ssh key calls move from pygithub onto the github session #891 (part A) moved the pull request reads onto the GitHub session. The helpers in item 1 still treat a failed base read as absent. The stage handlers around them swallow every error: _run_static_scanners has except Exception, and _run_review_evidence catches (OSError, RuntimeError, ValueError), where GitHubOperationError is a RuntimeError. If only the helpers raised, one failed read would skip the whole static stage with a debug log. That is worse than a missing baseline. So the helpers and the stage handlers must change together.
commands/pr.py (_fetch_pr_files and _changed_file) duplicates GitHubClient.get_pull_files.
Remedy
Decide the behaviour first: a failed base read gives the review an explicit coverage gap with a reason, and a diff with no changes gives an empty result and not an error. Change the helpers and the stage handlers in one pull request, with tests on the github_api fake. Replace the copy in commands/pr.py with GitHubClient.get_pull_files. Do not add a broad except to hide the error.
Intake placed this item to the backlog: at intake only a critical fix goes into a release; a release start pulls Ready items in, P0 features first.
Type: type/bug. The candidate describes fixes for specific error conditions in the review path and pull request handling, which are bug fixes.
Priority: P2-Medium. The issue affects core functionality of pull request reviews and handling, but does not block critical workflows or introduce security concerns.
Value: Medium. Fixes improve reliability of review processes and error handling for edge cases like empty diffs and failed base reads.
Effort: Medium. Requires changes to multiple helpers, stage handlers, and tests across the codebase, involving coordination between several components.
Activity
dan-petty commentedon Oct 22, 2026
Intake placed this item to the backlog: at intake only a critical fix goes into a release; a release start pulls Ready items in, P0 features first.
The candidate describes fixes for specific error conditions in the review path and pull request handling, which are bug fixes.The issue affects core functionality of pull request reviews and handling, but does not block critical workflows or introduce security concerns.Fixes improve reliability of review processes and error handling for edge cases like empty diffs and failed base reads.Requires changes to multiple helpers, stage handlers, and tests across the codebase, involving coordination between several components.fix(review): the review pipeline reports the eight failures it now sw…
fix(review): record coverage gaps on base read failures and accept em…