Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flask-framework charm builds failing due to dependency #1743

Closed
lengau opened this issue Jul 19, 2024 · 0 comments · Fixed by #1744
Closed

flask-framework charm builds failing due to dependency #1743

lengau opened this issue Jul 19, 2024 · 0 comments · Fixed by #1744
Labels
Bug Something isn't working

Comments

@lengau
Copy link
Collaborator

lengau commented Jul 19, 2024

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

# 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

::    ::   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 [email protected] --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)
@lengau lengau added the Bug Something isn't working label Jul 19, 2024
lengau added a commit that referenced this issue Jul 19, 2024
lengau added a commit that referenced this issue Jul 19, 2024
lengau added a commit that referenced this issue Jul 19, 2024
lengau added a commit that referenced this issue Jul 19, 2024
lengau added a commit that referenced this issue Jul 19, 2024
lengau added a commit that referenced this issue Jul 22, 2024
A new update to a flask dependency requires a more recent version of
rustc than is available in the jammy repos.
This works around that by using the same rustup snap as the craft-parts
rust plugin

Fixes #1743

Spread test failure is fixed in
#1749
rgildein added a commit to canonical/istio-operators that referenced this issue Jul 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant