aiida-common-workflows icon indicating copy to clipboard operation
aiida-common-workflows copied to clipboard

Unable to install with Python 3.10 due to pymatgen

Open dev-zero opened this issue 3 years ago • 1 comments

trying to install with Python 3.10 gives:

      pymatgen/optimization/neighbors.c: In function ‘__Pyx_TraceSetupAndCall’:
      pymatgen/optimization/neighbors.c:26523:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘use_tracing’; did you mean ‘tracing’?
      26523 |     tstate->use_tracing = 0;
            |             ^~~~~~~~~~~
            |             tracing
      pymatgen/optimization/neighbors.c:26531:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘use_tracing’; did you mean ‘tracing’?
      26531 |     tstate->use_tracing = (tstate->c_profilefunc ||
            |             ^~~~~~~~~~~
            |             tracing
      pymatgen/optimization/neighbors.c:26536:24: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘use_tracing’; did you mean ‘tracing’?
      26536 |         return tstate->use_tracing && retval;
            |                        ^~~~~~~~~~~
            |                        tracing
      error: command '/usr/bin/gcc' failed with exit code 1
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure

× Encountered error while trying to install package.
╰─> pymatgen

note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.

Quick googling shows that Python 3.10 has a change triggering that. Due to the block for newer versions of pymatgen installation is broken with Python 3.10.

dev-zero avatar Apr 11 '22 06:04 dev-zero

I had mentioned this to them early this year https://github.com/materialsproject/pymatgen/issues/2332 They closed it but I never checked if they actually fixed it. They may have done in a new release that you are not getting due to an upper bound

sphuber avatar Apr 11 '22 07:04 sphuber

Fixed in #327

sphuber avatar Feb 26 '24 12:02 sphuber