Skip to content

Count root-reserved space for the OpenCode coverage image apt fetch - #2653

Open
seonghobae wants to merge 1 commit into
mainfrom
fix/opencode-coverage-apt-disk-20261015
Open

seonghobae wants to merge 1 commit into
mainfrom
fix/opencode-coverage-apt-disk-20261015

Conversation

@seonghobae

@seonghobae seonghobae commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • The coverage tool image apt fetch failed on run 38531446132 with E: You don't have enough free space in /var/cache/apt/archives/. while resolving 339 MB of archives. apt uses f_bavail when APT::Sandbox::User is set and f_bfree when that setting is empty.
  • The trusted Dockerfile now clears the sandbox user for this root install, does not keep downloaded packages, and removes the apt archive cache in the same layer. Package set, base image, keys, endpoints, and models are unchanged.

Test

  • PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 python3 -m pytest tests/test_opencode_coverage_apt_disk.py tests/test_opencode_rust_coverage_toolchain_contract.py tests/test_pr_review_autofix_nvidia_nim_contract.py tests/test_opencode_agent_contract.py -q --noconftest : 102 passed, 1 skipped, then the apt-disk test passed after the indentation assertion fix (3 passed for the focused rerun).

Verification gap

  • repository_dispatch reads this workflow from the default branch only. This PR does not by itself rerun job 115744141064's public receive path.

Summary by CodeRabbit

  • 개선 사항
    • 코드 검토용 이미지 설치 과정에서 불필요한 다운로드 파일과 APT 캐시를 정리해 디스크 공간 사용을 줄였습니다.

apt rejects the 339 MB archive fetch when Sandbox::User is set because that check uses f_bavail. An empty sandbox user makes the same root build count f_bfree, and the layer still drops the archive cache after install.
@coderabbitai

coderabbitai Bot commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 97023ce6-116d-4d7f-a187-cf0e2a858434
📥 Commits

Reviewing files that changed from the base of the PR and between 6a03ae9 and 7b558ac.

📒 Files selected for processing: 3
  • .github/workflows/opencode-review-dispatch.yml
  • tests/test_opencode_coverage_apt_disk.py
  • tests/test_pr_review_autofix_nvidia_nim_contract.py

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

📝 Walkthrough

coverage 도구 이미지의 APT 설치 설정과 정리 명령을 변경했습니다. 새 테스트가 Dockerfile의 설정, 정리 명령, 패키지 목록을 확인합니다. 관련 워크플로 blob SHA도 갱신했습니다.

Changes: coverage 도구 이미지 APT 설정

Layer / File(s) Summary
APT 설치 설정 및 캐시 정리
.github/workflows/opencode-review-dispatch.yml, tests/test_opencode_coverage_apt_disk.py, tests/test_pr_review_autofix_nvidia_nim_contract.py
설치 전에 APT 설정을 기록해 패키지 다운로드 파일 보관을 끄고 sandbox 사용자를 빈 값으로 설정합니다. 설치 후 APT 목록, 패키지 아카이브 캐시, 임시 설정 파일을 제거합니다. 새 테스트가 설정 순서와 정리 명령 및 패키지 이름을 확인하며, 워크플로 blob SHA가 갱신되었습니다.

Priority: ➖ Normal

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Merge Risk: ⚪ Minimal · up to 7b558

No actionable merge-blocking issue remains; the APT test retains its intended coverage.

Pre-merge checks: Passed 5
Passed Passed checks: 5 passed
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed 제목은 OpenCode coverage 이미지의 APT fetch에서 root 예약 공간을 계산하도록 수정하는 PR의 주요 변경 사항을 정확하게 요약합니다.
Docstring Coverage Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 2 files. (1 skipped: 1 …
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches: 💡 1
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
🛠️ Fix failing CI checks: 💡
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@opencode-agent opencode-agent Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

OpenCode reviewed the current-head product diff. Coverage is a separate gate.

Changed files

  • .github/workflows/opencode-review-dispatch.yml — GitHub Actions review job
  • tests/test_opencode_coverage_apt_disk.py — regression suite
  • tests/test_pr_review_autofix_nvidia_nim_contract.py — regression suite

Changed behavior

flowchart LR
  PR["PR changed files"] --> Evidence["OpenCode bounded evidence"]
  Evidence --> S1["Workflow: opencode-review-dispatch.yml"]
  S1 --> I1["GitHub Actions review job"]
  I1 --> R1["Review risk: Workflow: opencode-review-dispatch.yml"]
  R1 --> V1["actionlint plus required checks"]
  Evidence --> S2["Test: test_opencode_coverage_apt_disk.py (2 files)"]
  S2 --> I2["regression suite"]
  I2 --> R2["Review risk: Test: test_opencode_coverage_apt_disk.py (2 files)"]
  R2 --> V2["targeted test run"]
Loading

Findings

No source-backed product finding is synthesized from the coverage gate. A coverage miss belongs in the status comment.

  • Head SHA: 7b558acaeffae89ed95d200abe49da2c5fc21460
  • Workflow run: 38677566463
  • Workflow attempt: 1
  • Coverage gate: failure

Review outcome

Coverage is a gate, not the review. This body reviews the changed product files.

Changed-File Evidence Map

flowchart LR
  PR["PR changed files"] --> Evidence["OpenCode bounded evidence"]
  Evidence --> S1["Workflow: opencode-review-dispatch.yml"]
  S1 --> I1["GitHub Actions review job"]
  I1 --> R1["Review risk: Workflow: opencode-review-dispatch.yml"]
  R1 --> V1["actionlint plus required checks"]
  Evidence --> S2["Test: test_opencode_coverage_apt_disk.py (2 files)"]
  S2 --> I2["regression suite"]
  I2 --> R2["Review risk: Test: test_opencode_coverage_apt_disk.py (2 files)"]
  R2 --> V2["targeted test run"]
Loading

@opencode-agent

opencode-agent Bot commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

OpenCode Review Overview

Coverage evidence did not pass, so approval is blocked. The formal pull-request review is the source-backed diff review, not this status comment.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant