Skip to content

Commit

Permalink
Ignore deprecation warnings triggered by pythran 0.12.1
Browse files Browse the repository at this point in the history
These happen with python 3.11, setuptools 67.6.1, numpy 1.24.2.
When pythran 0.12.1 is installed, I get 24 doctest failures due to
deprecation warnings; they are all gone with this commit.
  • Loading branch information
tornaria committed Apr 4, 2023
1 parent 5dd80aa commit 839a6e9
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/sage/all__sagemath_repl.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,17 @@
warnings.filterwarnings('ignore', category=DeprecationWarning,
module='(.*[.]_vendor[.])?packaging')

# Ignore numpy warnings triggered by pythran
# Ignore a few warnings triggered by pythran 0.12.1
warnings.filterwarnings('ignore', category=DeprecationWarning,
module='pythran')
message='\n\n `numpy.distutils` is deprecated since NumPy 1.23.0',
module='pythran.dist')
warnings.filterwarnings('ignore', category=DeprecationWarning,
message='pkg_resources is deprecated as an API|'
'Deprecated call to `pkg_resources.declare_namespace(.*)`',
module='pkg_resources')
warnings.filterwarnings('ignore', category=DeprecationWarning,
message='msvccompiler is deprecated and slated to be removed',
module='distutils.msvccompiler')

warnings.filterwarnings('ignore', category=DeprecationWarning,
message='The distutils(.sysconfig module| package) is deprecated',
Expand Down

0 comments on commit 839a6e9

Please sign in to comment.