Sage 9.5.beta8: ipython help triggers pythran deprecation warnings

59 views
Skip to first unread message

Eric Gourgoulhon

unread,
Dec 13, 2021, 4:56:03 PM12/13/21
to sage-devel
Hi,

In the just released Sage 9.5.beta8, invoking help on a function with the question mark yields a bunch of pythran deprecation warnings before the help shows off:

sage: sin?
/home/eric/sage/9.5.develop/local/lib/python3.8/site-packages/pythran/tables.py:4520: DeprecationWarning: `np.bool` is a deprecated alias for the builtin `bool`. To silence this warning, use `bool` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.bool_` here.
Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
  if not hasattr(numpy, method):
/home/eric/sage/9.5.develop/local/lib/python3.8/site-packages/pythran/tables.py:4520: DeprecationWarning: `np.complex` is a deprecated alias for the builtin `complex`. To silence this warning, use `complex` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.complex128` here.
Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
  if not hasattr(numpy, method):
/home/eric/sage/9.5.develop/local/lib/python3.8/site-packages/pythran/tables.py:4520: DeprecationWarning: `np.float` is a deprecated alias for the builtin `float`. To silence this warning, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
  if not hasattr(numpy, method):
/home/eric/sage/9.5.develop/local/lib/python3.8/site-packages/pythran/tables.py:4553: DeprecationWarning: `np.bool` is a deprecated alias for the builtin `bool`. To silence this warning, use `bool` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.bool_` here.
Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
  obj = getattr(themodule, elem)
/home/eric/sage/9.5.develop/local/lib/python3.8/site-packages/pythran/tables.py:4553: DeprecationWarning: `np.complex` is a deprecated alias for the builtin `complex`. To silence this warning, use `complex` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.complex128` here.
Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
  obj = getattr(themodule, elem)
/home/eric/sage/9.5.develop/local/lib/python3.8/site-packages/pythran/tables.py:4553: DeprecationWarning: `np.float` is a deprecated alias for the builtin `float`. To silence this warning, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
  obj = getattr(themodule, elem)

It seems that pythran has just been added in this release.

Eric.

Eric Gourgoulhon

unread,
Dec 13, 2021, 4:58:20 PM12/13/21
to sage-devel
More precisely, these are deprecation warnings from numpy functions invoked by pythran.
Reply all
Reply to author
Forward
0 new messages