← Back to issue list

Changed base from 20->22, crash report

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#2000890
Type
issue
State
open
Author
~williamcharltonengineering
Labels
Created
Updated
Closed

Current evaluation

User reported crash when changing base from core20 to core22 in snapcraft 7.2.10. KeyError: 'core22' in legacy build provider code. Issue is 1339 days old with no activity.

Suggested action: close stale

Reason: The issue is 1339 days old and reports a KeyError for 'core22' in legacy snapcraft code that only recognized 'core18' and 'core20'. Core22 support was added to snapcraft years ago, so this bug has been fixed. The issue is no longer relevant to current versions.

Impact: 10 Quick Win: 8.0 Staleness: 95 Complexity: 20 Confidence: 85 Support Request: 0

Issue body

Hardware Overview: Model Name: MacBook Pro Model Identifier: MacBookPro16,1 Processor Name: 8-Core Intel Core i9 Processor Speed: 2.3 GHz Number of Processors: 1 Total Number of Cores: 8 L2 Cache (per Core): 256 KB L3 Cache: 16 MB $ uname -a Darwin MacBook-Pro.local 21.6.0 Darwin Kernel Version 21.6.0: Sat Jun 18 17:07:25 PDT 2022; root:xnu-8020.140.41~1/RELEASE_X86_64 x86_64 $ snapcraft --version snapcraft 7.2.10 $ snapcraft clean | tee snapcraft.log Cleaned build provider [will@W-MB-P|22:49:32|~/.../diode.io/cli](master) $ snapcraft build --debug 2>&1 | tee snapcraft.log Launching instance... Starting Snapcraft 7.2.9 Logging execution to '/tmp/snapcraft.log' Initializing parts lifecycle Executing parts lifecycle... Executing parts lifecycle: pull go Executed: pull go Executing parts lifecycle: pull openssl Executed: pull openssl Executing parts lifecycle: pull diode Executed: pull diode Executing parts lifecycle: pull snapcraft/core Executed: pull snapcraft/core Executing parts lifecycle: overlay go Executed: overlay go Executing parts lifecycle: overlay openssl Executed: overlay openssl Executing parts lifecycle: overlay diode Executed: overlay diode Executing parts lifecycle: overlay snapcraft/core Executed: overlay snapcraft/core Executing parts lifecycle: build go Executed: build go Executing parts lifecycle: skip pull go (already ran) Executed: skip pull go (already ran) Executing parts lifecycle: skip overlay go (already ran) Executed: skip overlay go (already ran) Executing parts lifecycle: skip build go (already ran) Executed: skip build go (already ran) Executing parts lifecycle: stage go (required to build 'openssl') Executed: stage go (required to build 'openssl') Executing parts lifecycle: build openssl Executed: build openssl Executing parts lifecycle: skip pull openssl (already ran) Executed: skip pull openssl (already ran) Executing parts lifecycle: skip overlay openssl (already ran) Executed: skip overlay openssl (already ran) Executing parts lifecycle: skip build openssl (already ran) Executed: skip build openssl (already ran) Executing parts lifecycle: stage openssl (required to build 'diode') Executed: stage openssl (required to build 'diode') Executing parts lifecycle: build diode Executed: build diode Executing parts lifecycle: build snapcraft/core Executed: build snapcraft/core Executed parts lifecycle [will@W-MB-P|23:01:26|~/.../diode.io/cli](master) $ snapcraft try --debug Issues while validating snapcraft.yaml: The 'architectures[0]' property does not match the required schema: additional properties are not allowed ('build-for' was unexpected) or orderedDict([('build-on', ['amd64']), ('build-for', ['amd64'])]) is not of type 'string' [will@W-MB-P|23:01:39|~/.../diode.io/cli](master) $ snapcraft try --debug Launching a VM. Project base changed from 'core20' to 'core22', cleaning first. Name: snapcraft-diode-cli State: Stopped IPv4: -- Release: -- Image hash: c743f0f2a4bb (Ubuntu Snapcraft builder for Core 20) Load: -- Disk usage: -- Memory usage: -- Mounts: /Users/will/sandbox/diode.io/cli => /root/project UID map: 501:0 GID map: 20:0 /Users/will/sandbox/diode.io/cli/prime => /root/prime UID map: 501:0 GID map: 20:0 Launched: snapcraft-diode-cli Sorry, an error occurred in Snapcraft: 'core22' Traceback (most recent call last): File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/craft_cli/dispatcher.py", line 435, in pre_parse_args self._command_class = self.commands[command] ~~~~~~~~~~~~~^^^^^^^^^ KeyError: 'try' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft/cli.py", line 228, in run _run_dispatcher(dispatcher) File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft/cli.py", line 193, in _run_dispatcher global_args = dispatcher.pre_parse_args(sys.argv[1:]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/craft_cli/dispatcher.py", line 438, in pre_parse_args raise ArgumentParsingError(help_text) # pylint: disable=raise-missing-from ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ craft_cli.errors.ArgumentParsingError: Usage: snapcraft [options] command [args]... Try 'snapcraft -h' for help. Error: no such command 'try' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_multipass/_multipass.py", line 121, in _start self._get_instance_info() File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_multipass/_multipass.py", line 237, in _get_instance_info instance_info_raw = self._multipass_cmd.info( ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_multipass/_multipass_command.py", line 413, in info raise errors.ProviderInfoError( snapcraft_legacy.internal.build_providers.errors.ProviderInfoError: An error occurred when using 'multipass' to query the status of the instance: returned exit code 2: info failed: The following errors occurred: instance "snapcraft-diode-cli" does not exist . The above exception was the direct cause of the following exception: Traceback (most recent call last): File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_base_provider.py", line 238, in launch_instance self._start() File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_multipass/_multipass.py", line 126, in _start raise errors.ProviderInstanceNotFoundError( snapcraft_legacy.internal.build_providers.errors.ProviderInstanceNotFoundError: Cannot find an instance named 'snapcraft-diode-cli'. During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/cli/legacy.py", line 27, in legacy_run run() File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/click/core.py", line 1130, in __call__ return self.main(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/click/core.py", line 1055, in main rv = self.invoke(ctx) ^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/click/core.py", line 1657, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/click/core.py", line 1404, in invoke return ctx.invoke(self.callback, **ctx.params) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/click/core.py", line 760, in invoke return __callback(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/cli/lifecycle.py", line 382, in try_command project = _execute(steps.PRIME, [], setup_prime_try=True, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/cli/lifecycle.py", line 144, in _execute with build_provider_class( File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_base_provider.py", line 87, in __enter__ self.create() File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_multipass/_multipass.py", line 161, in create self.launch_instance() File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_base_provider.py", line 249, in launch_instance self._setup_environment() File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_base_provider.py", line 438, in _setup_environment release=self._get_code_name_from_build_base(), ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/Cellar/snapcraft/7.2.10/libexec/lib/python3.11/site-packages/snapcraft_legacy/internal/build_providers/_base_provider.py", line 369, in _get_code_name_from_build_base return {"core18": "bionic", "core20": "focal"}[build_base] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^ KeyError: 'core22' We would appreciate it åif you created a bug report at https://launchpad.net/snapcraft/+filebug with the above text included. You can find the traceback in file '/var/folders/7l/5gmy0rzn75x27xl37gygn2kw0000gn/T/tmprerlwyw0/trace.txt'.

Evaluation history

Date Model Scores Action Summary
qwen3.6-35b-a3b-mtp-q6
Impact: 10
Quick Win: 8.0
Staleness: 95
Complexity: 20
Confidence: 85
Support Request: 0
close stale User reported crash when changing base from core20 to core22 in snapcraft 7.2.10. KeyError: 'core22' in legacy build provider code. Issue is 1339 days old with no activity.
qwen/qwen3.6-35b-a3b
Staleness: 98
Complexity: 20
Confidence: 90
Support Request: 10
close stale Crash in Snapcraft v7.2.10 when changing base to core22 due to missing codename mapping. Issue is over 3 years old with no activity.
qwen/qwen3.6-35b-a3b
Staleness: 95
Complexity: 15
Confidence: 90
Support Request: 10
close stale Crash in snapcraft 7.2.10 when changing base to core22 due to missing key in legacy build provider mapping. Issue is over 3 years old and core22 is now standard.
qwen3.6-35b-a3b-mtp-q6
Staleness: 95
Complexity: 15
Confidence: 85
Support Request: 5
close stale Snapcraft 7.2.10 crashes with a KeyError when changing the project base from core20 to core22. The legacy build provider code lacks support for core22, causing a fatal crash. No maintainer interaction or labels.
qwen3.6-35b-a3b-mtp-q6
Staleness: 95
Complexity: 15
Confidence: 90
Support Request: 10
close stale Crash when changing snapcraft base from core20 to core22 due to missing core22 mapping in legacy build provider code. Unaddressed for over 3 years.

Update history

No update history recorded yet.

Related issues

No related issues found above the similarity threshold.