charmcraft 1.4.0: impossible to login to charmhub
Metadata
Current evaluation
Closed as intended behavior: the headless remote host had no local keyring, so Charmcraft could not persist credentials; exporting credentials was the supported workaround.
Resolution: closed not a bug
Reason: The maintainer determined that the remote system had no usable keyring and closed the report on 2022-02-25, stating this was intended behavior. Users must export credentials through the environment or configure a headless keyring.
Evaluated by: mr-cal-bot
No scores available.
Issue body
```bash
$ charmcraft login
Opening an authorization web page in your browser.
If it does not open, please open this URL:
https://api.jujucharms.com/identity/login?did=870565472d077a4ab0c6a67e28ea4f205ffa441ccc3e037ffaa42d0dacf07fa7
Logged in as 'omnivector-solutions'.
$ charmcraft whoami
You are not logged in to Charmhub.
$ snap list | grep charmcraft
charmcraft 1.4.0 761 latest/stable canonical* classic
```
Am I missing something here?
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed not a bug | Closed as intended behavior: the headless remote host had no local keyring, so Charmcraft could not persist credentials; exporting credentials was the supported workaround. | |
| stealth/space-bunny-alpha | — | closed not a bug | Closed as intended behavior: the headless host lacked a usable keyring, so Charmcraft could not persist login; exported credentials via CHARMCRAFT_AUTH are required. | |
| stealth/space-bunny-alpha | — | closed not a bug | Closed as intended behavior: the headless Ubuntu host had no usable keyring, so credentials could not persist; exporting CHARMCRAFT_AUTH was the supported workaround. | |
| stealth/space-bunny-alpha | — | closed not a bug | Closed as intended behavior: the headless host lacked a usable keyring, so Charmcraft could not persist login; exported CHARMCRAFT_AUTH credentials were the workaround. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed as expected behavior. Charmcraft falls back to a non-persistent memory ring on headless systems lacking a keyring, preventing credential persistence. Maintainers advised exporting credentials via environment variables instead of implementing a code fix. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed as intended behavior. Charmcraft requires a system keyring to persist credentials, which headless servers lack. Developers clarified this is not a bug and advised exporting credentials via environment variables. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed as expected behavior. Charmcraft could not persist credentials without a system keyring on the headless server. Maintainers clarified that exporting tokens via environment variables is the required workaround. No code fix needed. |
Update history
No update history recorded yet.
Related work
-
Related To:
canonical/charmcraft#631
(confidence 95%)
Related credential-persistence failure; its discussion supplied the --export workaround cited in this issue.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #844 Cannot use charmcraft login | charmcraft | closed | Login failed over SSH ('Prompt dismissed'). Maintainer closed it pointing to Charmhub discourse instructions for authenticating in remote environments; no code change. | |
| #719 [1.5.0] Charmcraft login not finding keyring | charmcraft | closed | Closed as a headless keyring/session configuration issue; running Charmcraft in dbus-run-session with gnome-keyring unlocked made login succeed. No code fix was recorded. | |
| #759 charmcraft login produces an error | charmcraft | closed | Closed as superseded by #833, which improved the double-login error and recommended `charmcraft logout`; the follow-up was resolved by merged PR #916. | |
| #901 Charmcraft login on remote device has unhelpful error message | charmcraft | closed | Superseded by canonical/craft-store#58 and fixed there through PR #390 (d87f1bd), which converts keyring initialization failures into KeyringUnlockError. | |
| #725 craft-store error when using `charmcraft login` command | charmcraft | closed | Confusing craft-store "Credentials found" error on `charmcraft login` (double login). Closed by facundobatista as tracked in the more specific #833, whose improved error landed via PR #916. | |
| #631 v1.4.0 - failing to login and use anything related to credentials | charmcraft | closed | No code fix was identified; Charmcraft 1.4.0 could not access the desktop keyring from its snap environment. Installing gnome-keyring restored login on Kubuntu, while exported credentials offered another workaround. | |
| #668 `charmcraft status` should work without needing to log in | charmcraft | closed | Closed by facundobatista (2022-02-16) as out of Charmcraft's hands: `status` is backed by Charmhub APIs, which require authentication. No code change made; login remains mandatory. | |
| #2336 Can't login in headless multipass VM with 24.04 | charmcraft | open | Open Charmcraft login failure on headless Ubuntu 24.04 Multipass VMs: Python selects keyring.backends.null.Keyring, so credentials cannot be retrieved; only a backend override is known. | |
| #192 charmcraft login could list charms and statuses | charmcraft | closed | Enhancement request to have `charmcraft login` also list account charms/statuses was declined and closed; maintainer facundobatista argued login is rarely needed due to auto-login and should stay lightweight. | |
| #320 charmcraft release doesn't pay attention to resources | charmcraft | closed | Closed 2021-11-17 without a charmcraft fix: maintainers agreed resource validation belongs in Charmhub, tracking it as Launchpad snapstore-server bug #1951271. |