summaryrefslogtreecommitdiff
path: root/numpy/lib/function_base.py
diff options
context:
space:
mode:
authorEric Wieser <wieser.eric@gmail.com>2020-04-15 14:50:31 +0100
committerEric Wieser <wieser.eric@gmail.com>2020-04-15 14:50:31 +0100
commit3ec9d675a40fb8a7dc8f361870e3710b940553de (patch)
tree42d33f40849798a36d86bb09730c8301eede6d24 /numpy/lib/function_base.py
parent9ccb42d02f7b3fb2b47854bbd4ab418676e6be42 (diff)
downloadnumpy-3ec9d675a40fb8a7dc8f361870e3710b940553de.tar.gz
BUG: Avoid duplication in stack trace of `linspace(a, b, num=1.5)`
Before this commit, the stack trace was: ``` Traceback (most recent call last): File "C:\Users\wiese\Repos\numeric-python\numpy\build\testenv\Lib\site-packages\numpy\core\function_base.py", line 114, in linspace num = operator.index(num) TypeError: 'float' object cannot be interpreted as an integer During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<ipython-input-13-802b8c6e85f6>", line 1, in <module> np.linspace(1, 2, 1.5) File "<__array_function__ internals>", line 5, in linspace File "C:\Users\wiese\Repos\numeric-python\numpy\build\testenv\Lib\site-packages\numpy\core\function_base.py", line 116, in linspace raise TypeError( TypeError: object of type <class 'float'> cannot be safely interpreted as an integer. ``` Now it is ``` Traceback (most recent call last): File "C:\Users\wiese\Repos\numeric-python\numpy\build\testenv\Lib\site-packages\numpy\core\function_base.py", line 114, in linspace num = operator.index(num) TypeError: 'float' object cannot be interpreted as an integer ``` This noisy traceback was introduced in f4dfe833e3e037bb69113f7250fad3699f918cfc.
Diffstat (limited to 'numpy/lib/function_base.py')
0 files changed, 0 insertions, 0 deletions