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

Not compatible with latest NumPy due to use of numpy.int #41

Open
petebachant opened this issue Feb 25, 2023 · 5 comments
Open

Not compatible with latest NumPy due to use of numpy.int #41

petebachant opened this issue Feb 25, 2023 · 5 comments

Comments

@petebachant
Copy link
Contributor

Output of pip install pyjhtdb with NumPy 1.24.2:

Collecting pyjhtdb
  Using cached pyJHTDB-20200909.0.tar.gz (386 kB)
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error
  
  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [18 lines of output]
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "/private/var/folders/s_/hs4wzl4j51d8tj7v6_cz5s3m0000gn/T/pip-install-hzls0x9p/pyjhtdb_28744e7f6d4545caa7e7ce8cb563e52d/setup.py", line 48, in <module>
          import pyJHTDB
        File "/private/var/folders/s_/hs4wzl4j51d8tj7v6_cz5s3m0000gn/T/pip-install-hzls0x9p/pyjhtdb_28744e7f6d4545caa7e7ce8cb563e52d/pyJHTDB/__init__.py", line 103, in <module>
          from .libJHTDB import *
        File "/private/var/folders/s_/hs4wzl4j51d8tj7v6_cz5s3m0000gn/T/pip-install-hzls0x9p/pyjhtdb_28744e7f6d4545caa7e7ce8cb563e52d/pyJHTDB/libJHTDB.py", line 38, in <module>
          class libJHTDB(object):
        File "/private/var/folders/s_/hs4wzl4j51d8tj7v6_cz5s3m0000gn/T/pip-install-hzls0x9p/pyjhtdb_28744e7f6d4545caa7e7ce8cb563e52d/pyJHTDB/libJHTDB.py", line 159, in libJHTDB
          start=np.array([0, 0, 0], dtype=np.int),
                                          ^^^^^^
        File "/Users/pete/mambaforge/envs/bl-turb-mod/lib/python3.11/site-packages/numpy/__init__.py", line 305, in __getattr__
          raise AttributeError(__former_attrs__[attr])
      AttributeError: module 'numpy' has no attribute 'int'.
      `np.int` was a deprecated alias for the builtin `int`. To avoid this error in existing code, use `int` by itself. Doing this will not modify any behavior and is safe. When replacing `np.int`, you may wish to use e.g. `np.int64` or `np.int32` to specify the precision. If you wish to review your current use, check the release note link for additional information.
      The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
          https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'inf'?
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
@aburlot
Copy link

aburlot commented Mar 20, 2023

Same problem here. I don't know if anyone is still maintaining this. The isotropic_spectra_3D example is not up-to-date. I have an error on a deprecated function when working on SciServer.

@randalburns
Copy link

Thanks. The JHTDB team will fix this asap. We've transitioning the maintainers. I will take a look and get status ASAP

@aburlot
Copy link

aburlot commented Mar 21, 2023

Great news! Many thanks.

@dgcnz
Copy link

dgcnz commented May 5, 2024

Any updates?

@profPlum
Copy link

@randalburns Hi I just encountered this error also. Although I saw a commit where you guys addressed this it seems the pip package is very old and still has this bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants