Python Error: module 'numpy' has no attribute 'float'

Hi All,

I'm trying to get data from a database using GX Developer Python API. Whatever I do, I keep getting the following error

NumPy downgrading to 1.20 doesn't help. Any ideas about what could be wrong?

Tagged:

Answers

  • any luck with this? I'm running successfully with an older environment where the gxpy.gdb works fine  (incidentally this env has numpy 1.24.2, pandas 2.0.0, Geosoft 2022.2.0 - although when I recreate a new env with these same packages I get same error as you!). For now I can only run in my original env but not in any new env I create.

  • Yep. I've commented out all references to np.float and np.int (two in the gx_dtype function and two in the gx_dummy function) in the utility.py file (.\site-packages\geosoft\gxpy\utility.py). That was the only solution that worked for me.

  • ok great. that seems to have worked :)