← Back to issue list

flask-framework charm builds failing due to dependency

View original Github issue

Metadata

Project
charmcraft
Number
#1743
Type
issue
State
closed
Author
lengau
Labels
—
Created
Updated
Closed

Current evaluation

Flask-framework builds were fixed by merged PR #1751 (40beeef3), which gave the extension a default Rust version and resolved the indirect rustc dependency failure.

Resolution: closed resolved

Reason: Merged PR #1751, commit 40beeef3, supplied the flask-framework extension with a default Rust version. PR #1744 (3b05ba5a) had also switched Flask builds to the rustup snap for a newer rustc.

Evaluated by: mr-cal-bot

No scores available.

Issue body

### Bug Description Building a flask-framework charm is now failing due to indirect rust-based dependency issues requiring a newer version of rust. ### To Reproduce 1. `charmcraft init --profile=flask-framework` 2. `charmcraft pack` ### Environment Ubuntu 24.04 with charmcraft edge ### charmcraft.yaml ```shell # This file configures Charmcraft. # See https://juju.is/docs/sdk/charmcraft-config for guidance. name: ff-charm type: charm bases: - build-on: - name: ubuntu channel: "22.04" run-on: - name: ubuntu channel: "22.04" # (Required) summary: A very short one-line summary of the Flask application. # (Required) description: | A comprehensive overview of your Flask application. extensions: - flask-framework ``` ### Relevant log output ```shell :: :: Created wheel for attrs: filename=attrs-23.2.0-py3-none-any.whl size=60851 sha256=2ae03c2409587c42894bd2e9189ad977b1af7cb0cc6341914ffe30e1f73b84a5 :: :: Stored in directory: /root/.cache/pip/wheels/61/05/28/80f4ae2dc3db1710750af2cbc3f4efb6c0435097d9ca802dd1 :: :: Building wheel for jsonschema-specifications (pyproject.toml): started :: :: Building wheel for jsonschema-specifications (pyproject.toml): finished with status 'done' :: :: Created wheel for jsonschema-specifications: filename=jsonschema_specifications-2023.12.1-py3-none-any.whl size=18485 sha256=ee14a8da9c86f6dae36385e01caae0fb68b9f801a057f8d0689c796055c00239 :: :: Stored in directory: /root/.cache/pip/wheels/d2/89/51/54adbb04eea5d40f71a30acc182abb3e5e5d0e3d131a28d0e5 :: :: Building wheel for referencing (pyproject.toml): started :: :: Building wheel for referencing (pyproject.toml): finished with status 'done' :: :: Created wheel for referencing: filename=referencing-0.35.1-py3-none-any.whl size=26684 sha256=87509bc1eb8b7fa5747a2f7ccfc3248f77e56e820a158c6bbf4554e6a0779f13 :: :: Stored in directory: /root/.cache/pip/wheels/9c/cd/9d/c3a4add17384843de796a6704a2f798deed0391574d822558d :: :: Building wheel for rpds-py (pyproject.toml): started :: :: Building wheel for rpds-py (pyproject.toml): finished with status 'error' :: :: error: subprocess-exited-with-error :: :: :: :: × Building wheel for rpds-py (pyproject.toml) did not run successfully. :: :: │ exit code: 1 :: :: ╰─> [13 lines of output] :: :: Running `maturin pep517 build-wheel -i /root/parts/charm/build/staging-venv/bin/python3 --compatibility off` :: :: 📦 Including license file "/tmp/pip-install-obsmhqgl/rpds-py_02cef2b8c3c64826ab00342aaea7fe0c/LICENSE" :: :: 🔗 Found pyo3 bindings :: :: 🐍 Found CPython 3.10 at /root/parts/charm/build/staging-venv/bin/python3 :: :: 📡 Using build options features from pyproject.toml :: :: error: package `triomphe v0.1.13` cannot be built because it requires rustc 1.76 or newer, while the currently active rustc version is 1.75.0 :: :: Either upgrade to rustc 1.76 or newer, or use :: :: cargo update triomphe@0.1.13 --precise ver :: :: where `ver` is the latest version of `triomphe` supporting rustc 1.75.0 :: :: 💥 maturin failed :: :: Caused by: Failed to build a native library through cargo :: :: Caused by: Cargo build finished with "exit status: 101": `env -u CARGO PYO3_ENVIRONMENT_SIGNATURE="cpython-3.10-64bit" PYO3_PYTHON="/root/parts/charm/build/staging-venv/bin/python3" PYTHON_SYS_EXECUTABLE="/root/parts/charm/build/staging-venv/bin/python3" "cargo" "rustc" "--features" "pyo3/extension-module" "--message-format" "json-render-diagnostics" "--manifest-path" "/tmp/pip-install-obsmhqgl/rpds-py_02cef2b8c3c64826ab00342aaea7fe0c/Cargo.toml" "--release" "--lib"` :: :: Error: command ['maturin', 'pep517', 'build-wheel', '-i', '/root/parts/charm/build/staging-venv/bin/python3', '--compatibility', 'off'] returned non-zero exit status 1 :: :: [end of output] :: :: :: :: note: This error originates from a subprocess, and is likely not a problem with pip. :: :: ERROR: Failed building wheel for rpds-py :: :: Successfully built paas-app-charmer pydantic pydantic-core jsonschema ops websocket-client cosl annotated-types attrs jsonschema-specifications referencing :: :: Failed to build rpds-py :: :: ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (rpds-py) ```

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Flask-framework builds were fixed by merged PR #1751 (40beeef3), which gave the extension a default Rust version and resolved the indirect rustc dependency failure.
stealth/space-bunny-alpha — closed resolved Fixed flask-framework charm builds by assigning a default Rust version in merged PR #1751 (commit 40beeef3).
stealth/space-bunny-alpha — closed resolved Resolved by merged PR #1751 (40beeef3), which gives the flask-framework extension a default Rust version.
qwen3.6-35b-a3b-mtp-q6 — — Closed. The flask-framework charm build failure caused by rpds-py requiring Rust 1.76+ was not directly patched. Likely resolved by base environment updates or abandoned.
qwen/qwen3.6-35b-a3b — — Closed without a tracked fix. The rpds-py Rust version conflict was likely resolved by environment updates or abandoned due to inactivity.
qwen/qwen3.6-35b-a3b — — Closed without resolution or comments, likely abandoned. The failure occurred because rpds-py required Rust 1.76+ while the build environment provided 1.75.0. Updated base images or toolchains likely resolved the dependency conflict.
qwen3.6-35b-a3b-mtp-q6 — — Closed without a documented fix. Flask-framework charm builds failed during packaging because rpds-py required Rust 1.76+, while the environment only provided Rust 1.75.0.

Update history

No update history recorded yet.

Related work

  • Likely Fixed By: canonical/charmcraft#1751 (confidence 100%)

    Merged commit 40beeef3 added a default Rust version for flask-framework builds.

  • Related To: canonical/charmcraft#1744 (confidence 95%)

    Merged commit 3b05ba5a changed Flask builds to use the rustup snap and a newer rustc.

Related issues

Issue Project State Summary Similarity
#1747 Failed to run the build script for part 'charm' charmcraft closed Flask-framework packing was fixed by merged PR #1751 (commit 40beeef3), which added a default Rust version. The fix shipped in Charmcraft 3.1.0.
78%
#1751 fix: ensure flask-framework extension gets a default rust version charmcraft merged Merged PR #1751 in commit 40beeef3, adding a default Rust version to the flask-framework extension.
75%
#1744 fix(flask): use rustup snap charmcraft merged Merged as 3b05ba5a: Flask-framework charms now add the rustup snap for a newer rustc on Jammy, fixing #1743. PR #1749 addressed a separate test failure.
73%
#1718 Flask extension. Allow charm-libs to be extended by the user charmcraft merged PR #1718 merged as commit 4ff7cee3, fixing the Flask extension so a user-defined charm-libs list in charmcraft.yaml is merged with the extension's _CHARM_LIBS instead of raising AttributeError.
70%