summaryrefslogtreecommitdiff
path: root/numpy/ma/mrecords.py
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2016-09-02 10:06:54 -0500
committerGitHub <noreply@github.com>2016-09-02 10:06:54 -0500
commit3dbbfd8db5c21c603620bebc98e03bc84334f11c (patch)
treee29eb26cfbf72ee9b03aa15dd02671bf17e70301 /numpy/ma/mrecords.py
parent9164f23c19c049e28d4d4825a53bbb01aedabcfc (diff)
parent68ea0c792db6bac435752e45d8681f7f1283453d (diff)
downloadnumpy-3dbbfd8db5c21c603620bebc98e03bc84334f11c.tar.gz
Merge pull request #7148 from seberg/stacklevel+tests
ENH,TST: Bump stacklevel and add tests for warnings
Diffstat (limited to 'numpy/ma/mrecords.py')
-rw-r--r--numpy/ma/mrecords.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/ma/mrecords.py b/numpy/ma/mrecords.py
index 6c9a4ea73..6b7acf469 100644
--- a/numpy/ma/mrecords.py
+++ b/numpy/ma/mrecords.py
@@ -743,7 +743,7 @@ def fromtextfile(fname, delimitor=None, commentchar='#', missingchar='',
if len(vartypes) != nfields:
msg = "Attempting to %i dtypes for %i fields!"
msg += " Reverting to default."
- warnings.warn(msg % (len(vartypes), nfields))
+ warnings.warn(msg % (len(vartypes), nfields), stacklevel=2)
vartypes = _guessvartypes(_variables[0])
# Construct the descriptor.