← Back to issue list

fix(deb): refresh apt cache before marking packages

View original Github issue

Metadata

Project
craft-parts
Number
#1468
Type
pull request
State
merged
Author
gcomneno
Labels
Created
Updated
Closed

Current evaluation

Merged a fix refreshing the apt cache before package marking to prevent BuildPackageNotFound errors from stale caches. Approved by three reviewers and merged after CI flakiness was confirmed as environment-related.

Suggested action:

No scores available.

Issue body

Refresh the apt package list before marking packages for installation when installation is required. Previously, marking could fail with BuildPackageNotFound if the apt cache was stale, because apt-get update was triggered too late. Adds unit tests to verify refresh ordering and the refresh_package_cache flag. Related: canonical/craft-parts#292, canonical/rockcraft#1005.

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.6-35b-a3b Merged a fix refreshing the apt cache before package marking to prevent BuildPackageNotFound errors from stale caches. Approved by three reviewers and merged after CI flakiness was confirmed as environment-related.
qwen/qwen3.6-35b-a3b
Staleness: 10
Complexity: 15
Confidence: 90
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors. Includes unit tests. Approved by two reviewers with zero unresolved comments. CI is pending due to unrelated environment timeouts.
qwen/qwen3.6-35b-a3b
Staleness: 5
Complexity: 15
Confidence: 85
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors. Adds unit tests. Approved by two reviewers, CI pending due to environment timeouts, contributor ready for rerun.
qwen/qwen3.6-35b-a3b
Staleness: 15
Complexity: 20
Confidence: 85
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors. Includes unit tests. Approved by two reviewers, with CI failures attributed to environment and network issues. Awaiting maintainer rerun or merge.
qwen/qwen3.6-35b-a3b
Staleness: 15
Complexity: 20
Confidence: 90
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors. Adds unit tests. Approved by two reviewers with zero unresolved comments. CI failures are environmental. Ready for maintainer review.
qwen/qwen3.6-35b-a3b
Staleness: 10
Complexity: 15
Confidence: 90
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors. Includes unit tests. Approved by two reviewers, but currently awaiting conflict resolution and CI environment fixes.
qwen/qwen3.6-35b-a3b
Staleness: 10
Complexity: 20
Confidence: 90
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors. PR has two approvals, all CI checks pass, and the author recently pinged maintainers indicating readiness to merge.
qwen/qwen3.6-35b-a3b
Staleness: 40
Complexity: 15
Confidence: 90
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors. Includes unit tests, has one approval, zero unresolved comments, and CI checks are passing or pending. Ready for maintainer review and merge.
qwen3.6-35b-a3b-mtp-q6
Staleness: 15
Complexity: 15
Confidence: 85
needs review Refreshes apt cache before marking packages to prevent BuildPackageNotFound errors. Includes unit tests. Currently awaiting maintainer review and CI completion, with author recently pinging for status.
qwen/qwen3.6-35b-a3b
Staleness: 45
Complexity: 20
Confidence: 85
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors. Adds unit tests. Author addressed linting and clarified CI failures are environmental. Currently awaiting maintainer review and CI refresh.
qwen3.6-35b-a3b-mtp-q6
Staleness: 15
Complexity: 15
Confidence: 90
needs review Fixes apt cache refresh ordering to prevent BuildPackageNotFound errors during package marking. Includes unit tests. Currently awaiting maintainer feedback after author ping; CI failures stem from environment policies, not code changes.
qwen3.6-35b-a3b-mtp-q6
Staleness: 75
Complexity: 20
Confidence: 65
needs review Refreshes apt cache before marking packages to prevent BuildPackageNotFound errors from stale data. Adds unit tests. Currently blocked by CI runner policy and network timeouts rather than code issues. Waiting for CI environment resolution.

Update history

Date Change
updated
updated
updated
updated
updated
updated
updated
updated

Related issues

Issue Project State Summary Similarity
#1553 fix(deb): avoid re-downloading cached stage-packages craft-parts open Patches apt-cache to treat cached .debs matching expected metadata as cache hits, avoiding repeated stage-packages re-downloads (workaround for python-apt _file_is_same bug). Awaiting review; CI mostly green with a few unrelated failures.
75%
#3099 repo: always refresh cache when build packages are required snapcraft merged Merged to ensure the package cache refreshes whenever a requested build package is not already installed. Approved by one reviewer, modifying eight files with 199 additions and 120 deletions.
72%
#3086 repo: restore marked-install strategy for apt-cache snapcraft merged Merged after approval and CI. Restores the marked-install strategy for apt-cache by refactoring AptCache for safe cache handling. Fixes a primed-stage-packages parsing bug and improves stage package dependency management.
70%