summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalf Gommers <ralf.gommers@gmail.com>2022-02-16 14:57:02 +0100
committerRalf Gommers <ralf.gommers@gmail.com>2022-02-16 14:57:02 +0100
commitec8e9e78e9a47242f8fc739e615564aa65883fdd (patch)
treeec03da9c113a7708bcd5b4764d8d1b55e19db2ba
parentd87714cdcca1a72a5c6949677ff563d1dae6c386 (diff)
downloadnumpy-ec8e9e78e9a47242f8fc739e615564aa65883fdd.tar.gz
MAINT: fix failure due to importing warnings in `distutils/__init__.py`
-rw-r--r--doc/source/reference/distutils_status_migration.rst9
-rw-r--r--numpy/distutils/__init__.py1
2 files changed, 4 insertions, 6 deletions
diff --git a/doc/source/reference/distutils_status_migration.rst b/doc/source/reference/distutils_status_migration.rst
index 3bcf02d60..9ef5f7232 100644
--- a/doc/source/reference/distutils_status_migration.rst
+++ b/doc/source/reference/distutils_status_migration.rst
@@ -18,9 +18,8 @@ Migration advice
----------------
It is **not necessary** to migrate immediately - the release date for Python 3.12
-is October 2023, so you have a good amount of time left. It may be beneficial
-to wait with migrating until there are examples from other projects to follow
-(see below).
+is October 2023. It may be beneficial to wait with migrating until there are
+examples from other projects to follow (see below).
There are several build systems which are good options to migrate to. Assuming
you have compiled code in your package (if not, we recommend using Flit_) and
@@ -33,9 +32,7 @@ recommend:
If you have modest needs (only simple Cython/C extensions, and perhaps nested
``setup.py`` files) and have been happy with ``numpy.distutils`` so far, you
can also consider switching to ``setuptools``. Note that most functionality of
-``numpy.disutils`` is unlikely to be ported to ``setuptools``. The likely
-exception is nested ``setup.py`` files, but this is not yet done (help with
-this is very welcome!).
+``numpy.disutils`` is unlikely to be ported to ``setuptools``.
Moving to Meson
diff --git a/numpy/distutils/__init__.py b/numpy/distutils/__init__.py
index e8255aa1e..3be3372ff 100644
--- a/numpy/distutils/__init__.py
+++ b/numpy/distutils/__init__.py
@@ -36,6 +36,7 @@ warnings.warn("\n\n"
" For more details, see: TODO! \n\n",
DeprecationWarning, stacklevel=2
)
+del warnings
# If numpy is installed, add distutils.test()
try: