Skip to content

numpy error numpy.dtype size changed, may indicate binary incompatibility due to conflict with pandas #553

Description

@nesnoj

Description of the issue

After installing from source I get
ValueError: numpy.dtype size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject

pip reveals that pandas 2.1.0 and numpy 2.1.0 have been installed.

According to the changelog, pandas <2.2.2 was not fully compatible with numpy >=2.0 which can lead to the error above. After installing pandas==2.2.2 the error is gone.

Interestingly, pandas 2.2.2 (and numpy 2.1.0) is used when installing from pypi. However, the dev requirements installed above are not the reason for the different versions as I also tried without these.

In a later installation attempt, pandas 2.2.2 has been used end everything is fine. I guess, the pandas version 2.1.0 from my cache had been used before (which meets our requirement >=2.1).

Steps to Reproduce

  1. Install from source as described here (branch: production)
  2. Start python, type e.g. from open_mastr.soap_api.download import MaStRAPI

Ideas of solution

To avoid incompatible versions, I propose to set min. pandas version to 2.2.2.
This is in accordance to our min. python version (v3.9) given in the toml.

Workflow checklist

Metadata

Metadata

Assignees

Labels

🐛 bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions