mirror of
https://github.com/Sea-Haven-Industries/open-swe.git
synced 2026-10-07 16:19:09 +00:00
* fix: fall back to core GitHub App scope when optional grants missing Proxy-token minting requested workflows:write and actions:read in the permission set used for every sandbox. GitHub 422s a token request that asks for a permission the installation hasn't granted, so any install without workflows:write failed to mint a token and every run died in before-agent setup with "GitHub App installation token is unavailable". _resolve_proxy_token now walks a permission ladder (full -> +workflows -> core) and returns the first scope that mints, recording the granted scope so hourly proxy refreshes stay consistent. A missing optional grant now degrades to the install-time core scope instead of failing the run; workflow-file HITL pushes still require workflows:write and fail at push time when it is absent. * refactor: flatten proxy-token ladder loop with continue --------- Co-authored-by: open-swe[bot] <open-swe@users.noreply.github.com> (cherry picked from commit f53caff1aa24a7b29d851b267aa3bdfe62c1e935) Sea Haven fork deviation: upstream #1701 folds workflows:write into the standing BASE/RUNTIME scope. This fork deliberately keeps workflows:write OUT of the standing permission ladder (RUNTIME = core + actions:read; LADDER = (RUNTIME, CORE)) so the sandbox proxy token cannot push .github/workflows/* during normal operation. workflows:write is minted only transiently by WorkflowPushGuardMiddleware for an approved HITL push and dropped on restore, preserving token scope as a backstop for the workflow- push approval control. Security-reviewed (agentic fan-out + GPT-4.1 cross review); the standing-scope-carries-workflows:write bypass was blocked. |
||
|---|---|---|
| .. | ||
| agents_md.py | ||
| analyzer_skills.py | ||
| api_standards_skill.py | ||
| auth.py | ||
| authorship.py | ||
| comments.py | ||
| dashboard_handoff.py | ||
| dashboard_links.py | ||
| deferred_model.py | ||
| gateway.py | ||
| github_app.py | ||
| github_checks.py | ||
| github_ci.py | ||
| github_comments.py | ||
| github_feedback.py | ||
| github_http.py | ||
| github_org_membership.py | ||
| github_proxy.py | ||
| github_token.py | ||
| http.py | ||
| langsmith.py | ||
| linear.py | ||
| linear_team_repo_map.py | ||
| model.py | ||
| multimodal.py | ||
| repo.py | ||
| repo_prep.py | ||
| reviewer_outcomes.py | ||
| sandbox.py | ||
| sandbox_paths.py | ||
| sandbox_state.py | ||
| slack.py | ||
| slack_feedback.py | ||
| thread_ids.py | ||
| thread_ops.py | ||
| tracing.py | ||
| url_safety.py | ||