question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

build fails with mpi4py 3.1

See original GitHub issue

setup.py mandates mpi4py 3.0.3,

SETUP_REQUIRES.append("mpi4py ==3.0.3; python_version>='3.8'")

But the latest release of mpi4py is 3.1.1, so h5py will not build on systems where mpi4py 3.1.1 is installed. Stack trace with mpi4py 3.1.1 installed is

ERROR: Exception:
Traceback (most recent call last):
  File "/usr/share/python-wheels/resolvelib-0.5.4-py2.py3-none-any.whl/resolvelib/resolvers.py", line 171, in _merge_into_criterion
    crit = self.state.criteria[name]
KeyError: 'mpi4py'

Is there a reason for the strict 3.0.3 version? As far as I can see mpi4py 3.1 should be fine. Patching to

SETUP_REQUIRES.append("mpi4py >=3.0.3; python_version>='3.8'")

works, h5py builds and tests pass.

  • Operating System: Debian GNU/Linux (debian unstable)
  • Python version 3.9.7
  • Where Python was acquired: debian repository (apt-get install python3)
  • h5py version 3.3.0
  • HDF5 version 1.10.7

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
drew-parsonscommented, Sep 27, 2021

Looks good, makes it clear. Thanks @takluyver

0reactions
takluyvercommented, Sep 27, 2021

I’ve had a go at documenting this better in #1970.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Installation — MPI for Python 3.1.4 documentation
You need to have the following software properly installed in order to build MPI for Python: A working MPI implementation, preferably supporting MPI-3...
Read more >
[BUG] 60.1.0: Installing mpi4py fails with latest setuptools #2969
This code worked flawlessly for 15 years, but it broke after the removal of get_versions() . While I could make a new release...
Read more >
Issues with compiling mpi4py and Python 3.10 for IntelMPI
I am trying to build mpi4py with python 3.10 and IntelMPI 2021.02. It is failing as follows (mpi4py is not yet installed in...
Read more >
Build failure when building thirdparty mpi4py (#18567) · Issues
It seems that the problem is caused by the wrong version of cpython (or python? maybe). And I found the mpi4py was updated...
Read more >
Error when installing mpi4py with pip on macOS - Bitbucket
8 using pip and virtualenv on my Macbook. When I run pip install ---no-cache-dir mpi4p , I get an error of error: Cannot...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found