← Back to issue list

charmcract pack stuck at `Pausing control of the terminal`

View original Github issue

Metadata

Project
charmcraft
Number
#2369
Type
issue
State
open
Author
yhaliaw
Labels
—
Created
Updated
Closed
—

Current evaluation

First `charmcraft pack` hung ~30 min at 'Pausing control of the terminal' during LXD build; reporter saw it once and never answered maintainer's follow-up.

Suggested action: close stale

Reason: Maintainer @lengau asked on 2025-07-11 whether the hang recurred and if `charmcraft clean` resolved it; the reporter stated it happened only once and never responded, leaving no reproducer or actionable details. The 'Pausing control of the terminal' message is the last log before subprocess output takes over, so the actual hang point is unknown.

Evaluated by: mr-cal-bot

Impact: 25 Quick Win: 2 Complexity: 70 Confidence: 65 Actionability: 20

Issue body

### Bug Description With a new charm created with `charmcraft init` will minimum code added, and not added dependencies, the first `charmcraft pack` took 30+ mins. From the logs, most of the execution was fine until `Emitter: Pausing control of the terminal`, which was stuck for almost 30 mins. ### To Reproduce I have only encountered this issue once. 1. `charmcraft init` to create a new charm 2. `charmcraft pack` ### Environment Ubuntu 22.04 charmcraft 3.5.2 lxd 5.21.3 LTS ### charmcraft.yaml ```yaml # This file configures Charmcraft. # See https://canonical-charmcraft.readthedocs-hosted.com/en/stable/reference/files/charmcraft-yaml-file/ type: charm name: upgrade-on-error title: Charm Template summary: A very short one-line summary of the charm. description: | A single sentence that says what the charm is, concisely and memorably. A paragraph of one to three short sentences, that describe what the charm does. A third paragraph that explains what need the charm meets. Finally, a paragraph that describes whom the charm is useful for. # Documentation: # https://canonical-charmcraft.readthedocs-hosted.com/en/stable/howto/build-guides/select-platforms/ base: ubuntu@22.04 platforms: amd64: arm64: parts: charm: plugin: charm source: . # (Optional) Configuration options for the charm # This config section defines charm config options, and populates the Configure # tab on Charmhub. # More information on this section at: # https://canonical-charmcraft.readthedocs-hosted.com/en/stable/reference/files/charmcraft-yaml-file/#config # General configuration documentation: # https://canonical-juju.readthedocs-hosted.com/en/latest/user/reference/configuration/#application-configuration config: options: # An example config option to customise the log level of the workload log-level: description: | Configures the log level of gunicorn. Acceptable values are: "info", "debug", "warning", "error" and "critical" default: "info" type: string ``` ### Relevant log output ```shell ... 2025-07-10 09:26:05.292 Executing on host: lxc --project charmcraft config device show local:charmcraft-upgrade-on-error-amd64-4101253 2025-07-10 09:26:05.374 Executing on host: lxc --project charmcraft config device add local:charmcraft-upgrade-on-error-amd64-4101253 disk-/root/project disk source=/home/yhaliaw/work/tmp/upgrade-on-error path=/root/project 2025-07-10 09:26:05.483 Instance launched and working directory mounted 2025-07-10 09:26:05.483 Pushing bashrc to instance 2025-07-10 09:26:05.484 Executing on host: lxc --project charmcraft file push /tmp/tmps154e6dk local:charmcraft-upgrade-on-error-amd64-4101253/root/.bashrc --mode=644 2025-07-10 09:26:05.569 Executing in container: lxc --project charmcraft exec local:charmcraft-upgrade-on-error-amd64-4101253 -- env CRAFT_MANAGED_MODE=1 CHARMCRAFT_MANAGED_MODE=1 DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true DEBIAN_PRIORITY=critical chown root:root /root/.bashrc 2025-07-10 09:26:05.696 Executing in container: lxc --project charmcraft exec local:charmcraft-upgrade-on-error-amd64-4101253 -- env CRAFT_MANAGED_MODE=1 CHARMCRAFT_MANAGED_MODE=1 DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true DEBIAN_PRIORITY=critical rm -rf /root/snap/charmcraft/common/cache 2025-07-10 09:26:05.827 Executing in container: lxc --project charmcraft exec local:charmcraft-upgrade-on-error-amd64-4101253 -- env CRAFT_MANAGED_MODE=1 CHARMCRAFT_MANAGED_MODE=1 DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true DEBIAN_PRIORITY=critical mkdir -p /root/.cache 2025-07-10 09:26:05.937 Executing in container: lxc --project charmcraft exec local:charmcraft-upgrade-on-error-amd64-4101253 -- env CRAFT_MANAGED_MODE=1 CHARMCRAFT_MANAGED_MODE=1 DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true DEBIAN_PRIORITY=critical ln -s /root/.cache /root/snap/charmcraft/common/cache 2025-07-10 09:26:06.046 Executing ['charmcraft', 'pack'] in instance location /root/project with {'env': {'CRAFT_PLATFORM': 'amd64', 'CRAFT_VERBOSITY_LEVEL': 'BRIEF'}}. 2025-07-10 09:26:06.046 Emitter: Pausing control of the terminal ```

Evaluation history

Date Model Scores Action Summary
~deepseek/deepseek-pro-latest
Impact: 25
Quick Win: 2
Complexity: 70
Confidence: 65
Actionability: 20
close stale First `charmcraft pack` hung ~30 min at 'Pausing control of the terminal' during LXD build; reporter saw it once and never answered maintainer's follow-up.
qwen/qwen3.6-35b-a3b
Impact: 30
Quick Win: 2
Complexity: 60
Confidence: 70
Actionability: 20
close stale charmcraft pack hangs at 'Pausing control of the terminal' during LXD container build. Only encountered once by reporter; no follow-up after maintainer asked for reproduction details.
qwen/qwen3.8-27b
Impact: 45
Quick Win: 16
Staleness: 80
Complexity: 65
Confidence: 65
Support Request: 15
close stale charmcraft pack hangs ~30 min at 'Pausing control of the terminal' during LXD container build; reporter says it happened once; maintainer asked for reproducibility details, no response for 381 days.
qwen/qwen3.6-35b-a3b
Staleness: 90
Complexity: 35
Confidence: 85
Support Request: 20
close stale Reported 30-minute hang during charmcraft pack at terminal control. Maintainer requested reproducibility details and workaround results, but received no response for over a year. Issue is inactive and awaiting author input.
qwen3.6-35b-a3b-mtp-q6
Staleness: 85
Complexity: 25
Confidence: 80
Support Request: 40
close stale charmcraft pack hangs for 30+ minutes at Pausing control of the terminal during initial build. Unreproducible, author unresponsive to maintainer follow-up, inactive for over a year.
qwen3.6-35b-a3b-mtp-q6
Staleness: 92
Complexity: 65
Confidence: 85
Support Request: 20
close stale charmcraft pack hangs for ~30 minutes at Pausing control of the terminal during initial build. Unanswered for over 10 months after maintainer requested reproduction details.

Update history

No update history recorded yet.

Related work

  • Related To: charmcraft#497 (confidence 40%)

    Earlier 'Pack is not Working' issue was resolved as an environment/LXD configuration problem, not the same hang.

Related issues

Issue Project State Summary Similarity
#660 `charmcraft pack` fails with error writing to lxd unix socket charmcraft closed A transient LXD socket timeout stopped packing; `charmcraft clean` restored operation, the error did not recur, and the reporter closed the report without a code fix.
74%
#823 more transparency for container build in first charmcraft pack charmcraft closed Firewall-blocked LXD setup hung `charmcraft pack` indefinitely on instance network setup. No charmcraft change needed; maintainer tracked the missing timeout in craft-providers and closed the issue.
72%
#815 charmcraft pack fails - connection timed out could not connect charmcraft closed User-reported charmcraft pack failure was a local host/network problem (archive.ubuntu.com/security.ubuntu.com unreachable during apt cache update in the LXD build container). Author rebooted their machine and packing worked again, then self-closed the issue.
70%