File tree Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -66,6 +66,13 @@ New Features
66
66
Improvements
67
67
============
68
68
69
+ build shell independence
70
+ ------------------------
71
+ NumPy builds should no longer interact with the host machine
72
+ shell directly. ``exec_command `` has been replaced with
73
+ ``subprocess.check_output `` where appropriate.
74
+
75
+
69
76
`np.polynomial.Polynomial ` classes render in LaTeX in Jupyter notebooks
70
77
-----------------------------------------------------------------------
71
78
Original file line number Diff line number Diff line change 147
147
from distutils .util import get_platform
148
148
149
149
from numpy .distutils .exec_command import (
150
- find_executable , exec_command , get_pythonexe )
150
+ find_executable , filepath_from_subprocess_output ,
151
+ get_pythonexe )
151
152
from numpy .distutils .misc_util import (is_sequence , is_string ,
152
153
get_shared_lib_extension )
153
154
from numpy .distutils .command .config import config as cmd_config
@@ -2243,8 +2244,12 @@ def get_config_exe(self):
2243
2244
2244
2245
def get_config_output (self , config_exe , option ):
2245
2246
cmd = config_exe + ' ' + self .append_config_exe + ' ' + option
2246
- s , o = exec_command (cmd , use_tee = 0 )
2247
- if not s :
2247
+ try :
2248
+ o = subprocess .check_output (cmd )
2249
+ except (OSError , subprocess .CalledProcessError ):
2250
+ pass
2251
+ else :
2252
+ o = filepath_from_subprocess_output (o )
2248
2253
return o
2249
2254
2250
2255
def calc_info (self ):
You can’t perform that action at this time.
0 commit comments