Refactor artifact cleanup: extract rootless permission repair into artifact-permissions.ts#5605
Conversation
artifact-permissions.ts
|
@copilot The branch only has the empty "Initial plan" commit — none of the changes described in the PR body were actually committed/pushed (0 changed files). Please re-apply and push the refactor you described: add |
|
✅ Copilot review passed with no inline comments. @copilot Add the |
|
✅ Build Test Suite completed successfully! |
|
✅ Smoke Gemini completed. All facets verified. 💎 Attempting to list PRs |
|
✅ Smoke Copilot BYOK completed. Copilot BYOK mode operational. 🔓 |
|
🔌 Smoke Services — All services reachable! ✅ |
|
🔑 Smoke Copilot PAT PAT auth validated. All systems operational. ✅ |
|
📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤 |
|
✅ Contribution Check completed successfully! Contribution guidelines review complete for PR #5605: the PR includes focused tests, keeps new source/test files in the expected src/ layout, has a clear description, and does not appear to require documentation updates for this refactor. |
|
✅ Smoke Copilot BYOK AOAI (api-key) completed. Copilot AOAI BYOK (api-key) mode operational. 🔓 |
|
Chroot tests passed! Smoke Chroot - All security and functionality tests succeeded. |
|
🚀 Security Guard has started processing this pull request |
|
✅ Smoke Claude passed |
|
✅ Smoke Copilot BYOK AOAI (Entra) completed. Copilot AOAI BYOK (Entra) mode operational. 🔓 Smoke test comment posted and label added for PR #5605 |
|
📡 Smoke OTel Tracing completed. All tracing scenarios validated. ✅ |
|
✨ The prophecy is fulfilled... Smoke Codex has completed its mystical journey. The stars align. 🌟 |
✅ Coverage Check PassedOverall Coverage
📁 Per-file Coverage Changes (2 files)
✨ New Files (1 files)
Coverage comparison generated by |
🔥 Smoke Test Results — PAT Auth
Overall: PASS Auth mode: PAT (COPILOT_GITHUB_TOKEN)
|
🔍 Smoke Test Results
Overall: FAIL — pre-step outputs were not expanded (template variables literal in agent context) PR: Refactor artifact cleanup: extract rootless permission repair into
|
Smoke Test: Claude Engine Validation
Overall result: PASS
|
|
✅ Smoke Test: Copilot BYOK (Direct) Mode — PASS
Running in direct BYOK mode (COPILOT_PROVIDER_API_KEY) with credentials held by sidecar.
|
Gemini Smoke Test Results
Overall status: FAIL Warning Firewall blocked 1 domainThe following domain was blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "localhost"See Network Configuration for more information.
|
|
Smoke test
Warning Firewall blocked 1 domainThe following domain was blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "registry.npmjs.org"See Network Configuration for more information.
|
Smoke Test: API Proxy OpenTelemetry Tracing
All scenarios pass. OTEL tracing integration is working correctly.
|
|
Refactor artifact cleanup: extract rootless permission repair into
Running in direct BYOK mode (COPILOT_PROVIDER_API_KEY + COPILOT_PROVIDER_BASE_URL) via api-proxy → Azure OpenAI (Foundry, o4-mini-aw) PASS
|
🏗️ Build Test Suite Results
Overall: 8/8 ecosystems passed — ✅ PASS
|
Chroot Version Comparison Results
Overall: ❌ FAILED — Python and Node.js versions differ between host and chroot environments.
|
|
Running in direct BYOK mode (AWF_AUTH_TYPE=github-oidc + AWF_AUTH_AZURE_* + COPILOT_PROVIDER_BASE_URL) via api-proxy → Azure OpenAI (Foundry, o4-mini-aw) authenticated via Microsoft Entra Overall: PASS
|
Smoke Test: Services Connectivity
Overall: FAIL
|
src/artifact-preservation.tswas carrying three concerns (artifact copy/preservation, rootless permission repair, and cleanup), withpreserveCleanupArtifactsand embedded Docker-based chown logic making the file oversized and harder to review. This PR isolates the rootless permission-fixer path into a focused module without changing cleanup call flow.Scope split: permission repair extracted
src/artifact-permissions.tswith:resolvePermFixerImageRef(...)fixArtifactPermissionsForRootless(...)artifact-preservation.tsnarrowed to artifact I/O + orchestrationpreserveIptablesAudit,preserveCleanupArtifacts, andremoveWorkDirectoriesin place.preserveCleanupArtifacts(...)now delegates permission repair to the extracted module.Focused test coverage for the extracted unit
src/artifact-permissions.test.tsto cover: