← Back to issue list

Correctly capture Craft Providers' LXDError

View original Github issue

Metadata

Project
charmcraft
Number
#1098
Type
issue
State
closed
Author
sergiusens
Labels
Created
Updated
Closed

Current evaluation

Craft Providers' LXDError handling was corrected. The issue is closed and resolved in charmcraft 3.

Suggested action:

No scores available.

Issue body

``` $ charmcraft pack Warning: Base centos 7 daily image may be unstable. charmcraft internal error: LXDError(brief="Failed to launch instance 'charmcraft-centos-2175442-0-0-amd64'.", details="* Command that failed: 'lxc --project charmcraft launch images:centos/7 local:charmcraft-centos-2175442-0-0-amd64 --config security.syscalls.intercept.mknod=true'\n* Command exit code: 1\n* Command output: b'Creating charmcraft-centos-2175442-0-0-amd64\\n\\rRetrieving image: metadata: 100% (935.41MB/s)\\r \\rRetrieving image: rootfs: 1% (1.56MB/s)\\r \\rRetrieving image: rootfs: 2% (2.11MB/s)\\r \\rRetrieving image: rootfs: 3% (2.52MB/s)\\r \\rRetrieving image: rootfs: 4% (2.11MB/s)\\r \\rRetrieving image: rootfs: 5% (1.87MB/s)\\r \\rRetrieving image: rootfs: 6% (1.73MB/s)\\r \\rRetrieving image: rootfs: 7% (1.64MB/s)\\r \\rRetrieving image: rootfs: 8% (1.58MB/s)\\r \\rRetrieving image: rootfs: 9% (1.54MB/s)\\r \\rRetrieving image: rootfs: 10% (1.51MB/s)\\r \\rRetrieving image: rootfs: 10% (1.47MB/s)\\r \\rRetrieving image: rootfs: 11% (1.45MB/s)\\r \\rRetrieving image: rootfs: 12% (1.44MB/s)\\r \\rRetrieving image: rootfs: 13% (1.43MB/s)\\r \\rRetrieving image: rootfs: 14% (1.41MB/s)\\r \\rRetrieving image: rootfs: 15% (1.40MB/s)\\r \\rRetrieving image: rootfs: 16% (1.40MB/s)\\r \\rRetrieving image: rootfs: 17% (1.37MB/s)\\r \\rRetrieving image: rootfs: 18% (1.38MB/s)\\r \\rRetrieving image: rootfs: 19% (1.37MB/s)\\r \\rRetrieving image: rootfs: 20% (1.37MB/s)\\r \\rRetrieving image: rootfs: 20% (1.36MB/s)\\r \\rRetrieving image: rootfs: 21% (1.35MB/s)\\r \\rRetrieving image: rootfs: 22% (1.35MB/s)\\r \\rRetrieving image: rootfs: 23% (1.35MB/s)\\r \\rRetrieving image: rootfs: 24% (1.35MB/s)\\r \\rRetrieving image: rootfs: 25% (1.34MB/s)\\r \\rRetrieving image: rootfs: 26% (1.34MB/s)\\r \\rRetrieving image: rootfs: 27% (1.34MB/s)\\r \\rRetrieving image: rootfs: 28% (1.34MB/s)\\r \\rRetrieving image: rootfs: 29% (1.33MB/s)\\r \\rRetrieving image: rootfs: 30% (1.33MB/s)\\r \\rRetrieving image: rootfs: 31% (1.33MB/s)\\r \\rRetrieving image: rootfs: 32% (1.32MB/s)\\r \\rRetrieving image: rootfs: 33% (1.32MB/s)\\r \\rRetrieving image: rootfs: 34% (1.32MB/s)\\r \\rRetrieving image: rootfs: 35% (1.32MB/s)\\r \\rRetrieving image: rootfs: 36% (1.32MB/s)\\r \\rRetrieving image: rootfs: 37% (1.32MB/s)\\r \\rRetrieving image: rootfs: 38% (1.32MB/s)\\r \\rRetrieving image: rootfs: 39% (1.31MB/s)\\r \\rRetrieving image: rootfs: 40% (1.31MB/s)\\r \\rRetrieving image: rootfs: 41% (1.31MB/s)\\r \\rRetrieving image: rootfs: 42% (1.31MB/s)\\r \\rRetrieving image: rootfs: 43% (1.31MB/s)\\r \\rRetrieving image: rootfs: 44% (1.31MB/s)\\r \\rRetrieving image: rootfs: 45% (1.31MB/s)\\r \\rRetrieving image: rootfs: 46% (1.31MB/s)\\r \\rRetrieving image: rootfs: 47% (1.31MB/s)\\r \\rRetrieving image: rootfs: 48% (1.30MB/s)\\r \\rRetrieving image: rootfs: 49% (1.30MB/s)\\r \\rRetrieving image: rootfs: 50% (1.30MB/s)\\r \\rRetrieving image: rootfs: 51% (1.30MB/s)\\r \\rRetrieving image: rootfs: 52% (1.30MB/s)\\r \\rRetrieving image: rootfs: 53% (1.30MB/s)\\r \\rRetrieving image: rootfs: 54% (1.30MB/s)\\r \\rRetrieving image: rootfs: 55% (1.30MB/s)\\r \\rRetrieving image: rootfs: 56% (1.30MB/s)\\r \\rRetrieving image: rootfs: 57% (1.30MB/s)\\r \\rRetrieving image: rootfs: 58% (1.30MB/s)\\r \\rRetrieving image: rootfs: 59% (1.30MB/s)\\r \\rRetrieving image: rootfs: 60% (1.29MB/s)\\r \\rRetrieving image: rootfs: 61% (1.30MB/s)\\r \\rRetrieving image: rootfs: 62% (1.29MB/s)\\r \\rRetrieving image: rootfs: 63% (1.29MB/s)\\r \\rRetrieving image: rootfs: 64% (1.29MB/s)\\r \\rRetrieving image: rootfs: 65% (1.29MB/s)\\r \\rRetrieving image: rootfs: 66% (1.29MB/s)\\r \\rRetrieving image: rootfs: 67% (1.29MB/s)\\r \\rRetrieving image: rootfs: 68% (1.29MB/s)\\r \\rRetrieving image: rootfs: 69% (1.29MB/s)\\r \\rRetrieving image: rootfs: 70% (1.29MB/s)\\r \\rRetrieving image: rootfs: 71% (1.29MB/s)\\r \\rRetrieving image: rootfs: 72% (1.29MB/s)\\r \\rRetrieving image: rootfs: 73% (1.29MB/s)\\r \\rRetrieving image: rootfs: 74% (1.29MB/s)\\r \\rRetrieving image: rootfs: 75% (1.29MB/s)\\r \\rRetrieving image: rootfs: 76% (1.29MB/s)\\r \\rRetrieving image: rootfs: 77% (1.29MB/s)\\r \\rRetrieving image: rootfs: 78% (1.29MB/s)\\r \\rRetrieving image: rootfs: 79% (1.29MB/s)\\r \\rRetrieving image: rootfs: 80% (1.29MB/s)\\r \\rRetrieving image: rootfs: 81% (1.29MB/s)\\r \\rRetrieving image: rootfs: 82% (1.29MB/s)\\r \\rRetrieving image: rootfs: 83% (1.28MB/s)\\r \\rRetrieving image: rootfs: 84% (1.29MB/s)\\r \\rRetrieving image: rootfs: 85% (1.29MB/s)\\r \\rRetrieving image: rootfs: 86% (1.29MB/s)\\r \\rRetrieving image: rootfs: 87% (1.29MB/s)\\r \\rRetrieving image: rootfs: 88% (1.29MB/s)\\r \\rRetrieving image: rootfs: 89% (1.29MB/s)\\r \\rRetrieving image: rootfs: 90% (1.29MB/s)\\r \\rRetrieving image: rootfs: 91% (1.29MB/s)\\r \\rRetrieving image: rootfs: 92% (1.28MB/s)\\r \\rRetrieving image: rootfs: 93% (1.28MB/s)\\r \\rRetrieving image: rootfs: 94% (1.28MB/s)\\r \\rRetrieving image: rootfs: 95% (1.28MB/s)\\r \\rRetrieving image: rootfs: 96% (1.28MB/s)\\r \\rRetrieving image: rootfs: 97% (1.28MB/s)\\r \\rRetrieving image: rootfs: 98% (1.28MB/s)\\r \\rRetrieving image: rootfs: 99% (1.28MB/s)\\r \\rRetrieving image: rootfs: 100% (1.28MB/s)\\r \\rRetrieving image: Unpack: 100% (3.19GB/s)\\r \\rRetrieving image: Unpack: 100% (3.19GB/s)\\r \\rStarting charmcraft-centos-2175442-0-0-amd64\\n'\n* Command standard error output: b'Error: The image used by this instance requires a CGroupV1 host system\\nTry `lxc info --show-log local:charmcraft-centos-2175442-0-0-amd64` for more info\\n'", resolution=None) Full execution log: '/home/sergiusens/.local/state/charmcraft/log/charmcraft-20230425-121642.509945.log' ```

Evaluation history

Date Model Scores Action Summary
qwen3.6-35b-a3b-mtp-q6 Craft Providers' LXDError handling was corrected. The issue is closed and resolved in charmcraft 3.
qwen/qwen3.6-35b-a3b charmcraft pack failed with an unhandled LXDError when LXC instance launch failed due to CGroup version mismatches. The issue was closed after the error handling was fixed in charmcraft 3.
qwen/qwen3.6-35b-a3b Unhandled LXDError during LXC instance launch caused charmcraft pack to crash. The exception is now properly captured and handled. Resolved in charmcraft version 3.
qwen3.6-35b-a3b-mtp-q6 Correctly capturing Craft Providers' LXDError was fixed in charmcraft 3, resolving LXC instance launch failures during pack commands.
qwen3.6-35b-a3b-mtp-q6 The unhandled LXDError during LXC instance launch was properly captured. The fix was merged and released in charmcraft 3.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#1512 Improve error message for provider not installed. charmcraft open Improve the 'Provider is required but not installed' error message shown by charmcraft pack before lxd init, to clarify what is missing and what answering y does. Maintainers acknowledged in 2024-02 and noted prerequisite craft-providers work was complete, but no fix has landed.
71%
#4262 LXD errors from Craft Providers not properly presented snapcraft closed Closed. Fixed unhandled LXD installation errors that caused raw Python tracebacks. Updated Craft Providers to surface user-friendly error messages instead of stack traces.
70%