Repository navigation
fix(source-read): recover GitHub PR diffs within the existing request budget - #6196
Draft
loopx-agent wants to merge 1 commit into
Draft
loopx-agent wants to merge 1 commit into
loopx-agent wants to merge 1 commit into
Conversation
…ailure Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Goal And Delivered Outcome
A query-free GitHub PR
.diffcan time out at every checked address even while its canonical public diff endpoint is reachable. The anonymous reader previously returned an error until the caller supplied that second URL. After transport failure it now derives the same PR's canonical URL and tries it through the existing checked HTTPS path, within the original deadline and six-hop limit.Ordinary HTTPS reads and redirects retain their current path. TLS/certificate, HTTP-policy and mixed/private-DNS rejections do not activate recovery.
requested_urlandobserved_urlpreserve source provenance.Related to #6181; base:
main. This is a reproduced transport defect, without a separate roadmap claim.Author Declaration
public_source_reader.fetchScope And Continuation
Python remains the existing specialized IO provider; no parallel capability, state store, configuration or frontend control is added. Native Chat already owns opt-in tool discovery, and this patch stays inside that provider. The future-facing pass found no useful separate helper: the recovery transition reuses the current redirect/request owner.
The reader slice is independently reversible. Formal installed-host adoption, original Lark-topic acceptance and response-time qualification remain with the existing delivery owner; this PR does not claim those outcomes. No runtime self-merge or installation is requested here.
Validation
python -m pytest tests/test_public_source_reader.py tests/test_chat_agent.py tests/test_chat_codex_context.py -q: 287 passed. Includes TLS/HTTP rejection, source restriction, cleanup, deadline and hop boundaries.loopx checkand diff checks.loopx checkreports two credential-pattern matches in unchanged synthetic rejection fixtures attests/capabilities/test_issue_fix_explore_private_evidence.py:170,187; that file is byte-identical to the base. Changed-scope scan passes.python -m pytest -q; final aggregate will be added before declaring validation complete.The earlier two-source native candidate turn took 56.388 seconds and repeated reads after output truncation. The additional single-source fault-injected native candidate took 19.862 seconds end to end (0.929 seconds in the reader); it completed one untruncated tool call without asking the user for a fallback URL. Neither run qualifies formal latency/SLA or installed Bot acceptance. Private observations remain local; no transcripts, raw tool results or credentials are attached. No frontend/Lark UI changed or packaged frontend acceptance is claimed.
Frontend / Visual Evidence
Type of Change / LoopX Area
Boundary Checklist