summaryrefslogtreecommitdiff
path: root/numpy/core/overrides.py
diff options
context:
space:
mode:
authorAntony Lee <anntzer.lee@gmail.com>2018-10-18 12:15:27 +0200
committerAntony Lee <anntzer.lee@gmail.com>2018-10-18 12:15:27 +0200
commit8589e8d035bdd9a8f67ab2f30ea5cb63d9acf0ba (patch)
tree44eaf31d4bbed8d0457767078b5b1926cf8ab806 /numpy/core/overrides.py
parentebcbd4f4d8c761ac758e7ae9da4bc0d202f80fff (diff)
downloadnumpy-8589e8d035bdd9a8f67ab2f30ea5cb63d9acf0ba.tar.gz
Delay import of distutils.msvccompiler to avoid warning on non-Windows.
*Importing* distutils.msvccompiler works on non-Windows systems, but triggers a pointless "warning" (using distutils' own logging system; "Can't read registry etc.") Delay the import so that other uses of distutils.misc_util are not affected. When running distutils commands, the verbosity is set by default to 1 (`self.verbose = 1` in distutils/dist.py) so the warning does get displayed. To trigger the warning, subclass e.g. build_ext, override its finalize_options method, import numpy.distutils.misc_util from there, and then pass the new build_ext as cmdclass to setuptools.setup(). Partially reverts 15f52f5.
Diffstat (limited to 'numpy/core/overrides.py')
0 files changed, 0 insertions, 0 deletions