summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xsetup.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/setup.py b/setup.py
index 8b8863255..3f4ccfb14 100755
--- a/setup.py
+++ b/setup.py
@@ -388,3 +388,8 @@ def setup_package():
if __name__ == '__main__':
setup_package()
+ # This may avoid problems where numpy is installed via ``*_requires`` by
+ # setuptools, the global namespace isn't reset properly, and then numpy is
+ # imported later (which will then fail to load numpy extension modules).
+ # See gh-7956 for details
+ del builtins.__NUMPY_SETUP__