Optimize safe output checkout with shallow clone and targeted branch fetching#7176
Optimize safe output checkout with shallow clone and targeted branch fetching#7176
Conversation
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Changed fetch-depth from 0 to 1 for create-pull-request and push-to-pull-request-branch safe outputs. JavaScript now explicitly fetches required branches using git commands. Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
|
🎉 Yo ho ho! Changeset Generator found the treasure and completed successfully! ⚓💰 |
|
🤖 DIAGNOSTIC COMPLETE: Smoke Copilot No Firewall STATUS: ALL_UNITS_OPERATIONAL. MISSION_SUCCESS. |
|
✨ The prophecy is fulfilled... Smoke Codex has completed its mystical journey. The stars align. 🌟 |
|
📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤 |
|
🎉 Yo ho ho! Smoke Copilot Safe Inputs found the treasure and completed successfully! ⚓💰 |
|
🎉 Yo ho ho! Changeset Generator found the treasure and completed successfully! ⚓💰 |
|
✅ Firewall validation complete... Smoke Codex Firewall confirmed network sandboxing is operational. 🛡️ |
|
🎬 THE END — Smoke Claude MISSION: ACCOMPLISHED! The hero saves the day! ✨ |
Smoke Test Results - Copilot EngineLast 2 merged PRs:
Test Results:
Overall Status: PASS cc: @pelikhan
|
Smoke Test Results✅ File Writing: Created Status: PARTIAL PASS (2/3 tests passed)
|
Smoke Test Results: Copilot Engine (No Firewall)Last 2 Merged PRs:
Test Results:
Status: Running final test
|
|
Firewall smoke test (Codex + AWF)
|
Smoke Test Results - Claude EngineLast 2 Merged PRs:
Test Results: Status: PASS (5/6 core tests passed)
|
|
Recent merged PRs: [security-fix] Fix clear-text logging of sensitive information in secrets validation; [docs] Update documentation for shorthand label trigger syntax
|
Safe output jobs for
create-pull-requestandpush-to-pull-request-branchperformed full repository checkouts (fetch-depth: 0), which is expensive for large repositories. This changes them to shallow clones with explicit branch fetching.Changes
Go compiler changes:
buildCreatePullRequestPreStepsConsolidated()andbuildPushToPullRequestBranchPreStepsConsolidated()to usefetch-depth: 1instead offetch-depth: 0JavaScript runtime changes:
create_pull_request.cjs: Replacedgit fetch originwithgit fetch origin ${baseBranch}:${baseBranch}to fetch only the base branchpush_to_pull_request_branch.cjs: Replacedgit fetch originwithgit fetch origin ${branchName}:refs/remotes/origin/${branchName}to fetch only the target branchExample
Before:
After:
This reduces clone time and network transfer significantly for repositories with extensive history.
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
https://api.github.com/user/usr/bin/gh gh api user --jq .login oad-artifact.git php8.3 /usr/bin/git l 4 /usr/bin/git git for-�� b/workflows %(refname) /usr/bin/git l a255aa63a3cc5ba3rev-parse /usr/bin/git git(http block)/usr/bin/gh gh api user --jq .login it/ref/tags/v5 git(http block)/usr/bin/gh gh api user --jq .login ithub/workflows origin e/git-remote-https xterm-color(http block)If you need me to access, download, or install something from one of these locations, you can either:
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.