easybuilders / easybuild-easyconfigs

A collection of easyconfig files that describe which software to build using which build options with EasyBuild.
https://easybuild.io
GNU General Public License v2.0
356 stars 685 forks source link

Failed to Build polars-0.15.6-foss-2022a #19697

Open garadar opened 5 months ago

garadar commented 5 months ago

Related to https://github.com/easybuilders/easybuild-easyconfigs/pull/16989

I am trying to build polars from the mentionned Pull-request but I got thie error message:

EB output

== FAILED: Installation ended unsuccessfully (build directory: /dev/shm/ebbuild/polars/0.15.6/foss-2022a): build failed (first 300 chars): cmd " /opt/ebsofts/Python/3.10.4-GCCcore-11.3.0/bin/python -m pip install --prefix=/opt/ebsofts/polars/0.15.6-foss-2022a  --no-deps  --ignore-installed  --no-index  --no-build-isolation  ." exited with exit code 1 and output:
Processing /dev/shm/ebbuild/polars/0.15.6/foss-2022a/deltalake/deltalake-0 (took 6 mins 45 secs)
== Results of the build can be found in the log file(s) /opt/cluster/easybuild/logs/easybuild-polars-0.15.6-20240123.173326.dAATt.log
ERROR: Build of /opt/ebsofts/EasyBuild/4.9.0/easybuild/easyconfigs/p/polars/polars-0.15.6-foss-2022a.eb failed (err: 'build failed (first 300 chars): cmd " /opt/ebsofts/Python/3.10.4-GCCcore-11.3.0/bin/python -m pip install --prefix=/opt/ebsofts/polars/0.15.6-foss-2022a  --no-deps  --ignore-installed  --no-index  --no-build-isolation  ." exited with exit code 1 and output:\nProcessing /dev/shm/ebbuild/polars/0.15.6/foss-2022a/deltalake/deltalake-0')

LogFile

== 2024-01-23 17:45:08,902 pythonpackage.py:229 INFO Determining pip version...
== 2024-01-23 17:45:08,903 run.py:247 INFO running cmd: /opt/ebsofts/Python/3.10.4-GCCcore-11.3.0/bin/python -m pip --version 
== 2024-01-23 17:45:09,245 pythonpackage.py:237 INFO Found pip version: 22.0.4
== 2024-01-23 17:45:09,246 pythonpackage.py:602 INFO Found pip version 22.0.4, OK
== 2024-01-23 17:45:09,247 run.py:247 INFO running cmd:  /opt/ebsofts/Python/3.10.4-GCCcore-11.3.0/bin/python -m pip install --prefix=/opt/ebsofts/polars/0.15.6-foss-2022a  --no-deps  --ignore-installed  --no-in
dex  --no-build-isolation  . 
== 2024-01-23 17:45:16,009 build_log.py:171 ERROR EasyBuild crashed with an error (at easybuild/base/exceptions.py:126 in __init__): cmd " /opt/ebsofts/Python/3.10.4-GCCcore-11.3.0/bin/python -m pip install --prefix=/opt/ebsofts/polars/0.15.6-foss-2022a  --no-deps  --ignore-installed  --no-index  --no-build-isolation  ." exited with exit code 1 and output:
Processing /dev/shm/ebbuild/polars/0.15.6/foss-2022a/deltalake/deltalake-0.6.4
  Preparing metadata (pyproject.toml): started
  Preparing metadata (pyproject.toml): finished with status 'done'
Building wheels for collected packages: deltalake
  Building wheel for deltalake (pyproject.toml): started
  Building wheel for deltalake (pyproject.toml): finished with status 'error'
  error: subprocess-exited-with-error

   Building wheel for deltalake (pyproject.toml) did not run successfully.
   exit code: 1
  > [12 lines of output]
      Running `maturin pep517 build-wheel -i /opt/ebsofts/Python/3.10.4-GCCcore-11.3.0/bin/python --compatibility off`
      error: package `home v0.5.9` cannot be built because it requires rustc 1.70.0 or newer, while the currently active rustc version is 1.65.0-dev
      Either upgrade to rustc 1.70.0 or newer, or use
      cargo update -p home@0.5.9 --precise ver
      where `ver` is the latest version of `home` supporting rustc 1.65.0-dev
       maturin failed
        Caused by: Failed to build a native library through cargo
        Caused by: Cargo build finished with "exit status: 101": `"cargo" "rustc" "--release" "--manifest-path" "/dev/shm/ebbuild/polars/0.15.6/foss-2022a/deltalake/deltalake-0.6.4/Cargo.toml" "--message-format" "json" "--lib"`
       Building a mixed python/rust project
       Found pyo3 bindings with abi3 support for Python  3.7
       Not using a specific python interpreter
      Error: command ['maturin', 'pep517', 'build-wheel', '-i', '/opt/ebsofts/Python/3.10.4-GCCcore-11.3.0/bin/python', '--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 deltalake
Failed to build deltalake

Someone has a magic trick ?

Micket commented 5 months ago

Someone has a magic trick ?

No, the proper fix would be to switch to the CargoPythonBundle easyblock, and include the entire crate list (several hundreds items for polars...).

The problem here is that by default cargo looks online for latest compatible releases of crates, downloads them and builds them, so Rust builds aren't reproducible over time unless you cache the downloads. This happens to basically all our stuff that uses Rust (and isn't using the Cargo* easyblocks).

It would be really really really annoying to retroactively find out what crates were used back when this build last worked, so I doubt anyone will volunteer to fix this. I did this once for one as a test, and it was a painful experience. We should just remove this easyconfig I.M.H.O.

garadar commented 5 months ago

Thank you for your quick answers! Indeed if the building is not reproducible, I agree with you to delete this recipe.