← Back to issue list

test(spread): make LXD refresh in prepare more reliable

View original Github issue

Metadata

Project
craft-application
Number
#1133
Type
pull request
State
open
Author
lengau
Labels
Created
Updated
Closed

Current evaluation

Retry only the known LXD auto-refresh transient error in spread prepare to avoid hard failures. Has 1 unresolved review comment, 49 days of inactivity, and failing CI checks.

Suggested action: needs review

Reason: PR has 1 unresolved review comment and addresses a real problem (LXD refresh race in spread tests). However, it's been inactive for 49 days and there's a related issue #1170 proposing a different approach (24-hour hold) to the same problem. A maintainer should follow up on the unresolved comment and decide whether to pursue this retry approach or #1170's wait-out approach.

Impact: 50 Quick Win: 37.5 Staleness: 70 Complexity: 25 Confidence: 65

Issue body

## Summary - make spread project prepare robust when LXD snap refresh collides with snap auto-refresh - retry only the known transient error: `snap "lxd" has "auto-refresh" change in progress` - keep other failures as hard failures ## Context - addresses spread project prepare failures seen in https://github.com/canonical/craft-application/actions/runs/29414578447/job/87350369623?pr=1128

Evaluation history

Date Model Scores Action Summary
qwen3.6-35b-a3b-mtp-q6
Impact: 50
Quick Win: 37.5
Staleness: 70
Complexity: 25
Confidence: 65
needs review Retry only the known LXD auto-refresh transient error in spread prepare to avoid hard failures. Has 1 unresolved review comment, 49 days of inactivity, and failing CI checks.
qwen/qwen3.6-35b-a3b
Staleness: 10
Complexity: 15
Confidence: 85
needs review Fixes spread project prepare failures during LXD snap refresh collisions by retrying only the known transient auto-refresh error. Currently pending review with minor lint and title policy failures.
qwen3.6-35b-a3b-mtp-q6
Staleness: 5
Complexity: 15
Confidence: 90
needs review Makes spread project prepare robust against LXD snap refresh collisions by retrying only the known transient auto-refresh error. Currently unreviewed and awaiting maintainer feedback.

Update history

Date Change
updated

Related work

  • Related To: craft-application#1170 (confidence 80%)

    Addresses the same LXD refresh race problem with a different approach (retry transient error vs. 24-hour hold). Both are open with unresolved review comments.

Related issues

Issue Project State Summary Similarity
#2983 tests: add LXD spread test snapcraft merged Merged after reviewer approval and passing CI checks. Added LXD spread test to verify LXD builds and installs. Modified two files with 29 added lines.
77%
#1170 test(spread): wait out in-progress auto-refresh in prepare craft-application open Fixes spread prepare step race condition with snapd auto-refresh by holding refreshes and waiting for in-progress operations. Approved, CI passing.
76%
#302 test(spread): switch to testing in destructive mode imagecraft merged Switched spread tests to destructive mode and merged. This addresses an upcoming losetup requirement that temporarily breaks the LXD backend. Approved by two reviewers with passing CI checks.
76%
#694 tests(spread): use LXD from `5.21/candidate` rockcraft merged Updated spread tests to use LXD from 5.21/candidate, resolving main branch breakage from overlay filesystem mounting regressions. Establishes a stable testing baseline against LTS regressions. Merged after approval and passing CI.
74%
#4236 lxd-type-base spread test is flaky due to lxd timeouts snapcraft closed Resolved flaky spread test failures caused by LXD container stop timeouts. Closed via pull request #4239.
74%
#2631 spread tests: enable LXD build provider tests snapcraft merged Merged into master. Enabled LXD build provider tests by relocating setup to the early prepare phase to reduce overhead and consolidating declarations from task.yaml to spread.yaml. Approved, passed CI, and increased coverage by 0.01%.
74%
#5856 fix(spread): pack with lxd for core20 base tests snapcraft merged Merged after two approvals. Updates spread tests to pack with LXD for core20 base tests. CI passed with one non-blocking schema diff failure. Related core20 and snapd test failures were resolved in separate PRs.
72%
#269 tests: add initial spread testing fetch-service merged Merged following approval by three reviewers. Adds initial spread testing infrastructure across 13 files, resolving issue #226. Validation confirms all 10 test tasks passed successfully on Ubuntu 20.04 and 22.04 LXD environments.
72%
#3120 spread: only run in LXD with the google/multipass provider for repo snapcraft merged Merged changes restricting spread tests to LXD with the google/multipass provider for the repo. Switched autopkgtest to destructive mode to bypass dirmngr failures until the environment is verified. Approved and passed CI.
71%
#202 tests: bump lxd to 5.11 in spread tests rockcraft merged Merged update bumping LXD in spread tests to 5.11, resolving installation failures from the unlisted 5.9 snap channel. Approved by two reviewers and passed CI.
70%