Repository navigation
Closed
Description
core/tests/test_regression.py::TestRegression::test_object_array_from_list
/venv/lib/python3.7/site-packages/numpy/core/tests/test_regression.py:507: FutureWarning: Promotion of numbers and bools to strings is deprecated. In the future, code such as `np.concatenate((['string'], [0]))` will raise an error, while `np.asarray(['string', 0])` will return an array with `dtype=object`. To avoid the warning while retaining a string result use `dtype='U'` (or 'S'). To get an array of Python objects use `dtype=object`. (Warning added in NumPy 1.21)
assert_(np.array([1, 'A', None]).shape == (3,))
core/tests/test_regression.py::TestRegression::test_string_truncation
/venv/lib/python3.7/site-packages/numpy/core/tests/test_regression.py:2058: FutureWarning: Promotion of numbers and bools to strings is deprecated. In the future, code such as `np.concatenate((['string'], [0]))` will raise an error, while `np.asarray(['string', 0])` will return an array with `dtype=object`. To avoid the warning while retaining a string result use `dtype='U'` (or 'S'). To get an array of Python objects use `dtype=object`. (Warning added in NumPy 1.21)
b = np.array([val, tostr('xx')])
core/tests/test_regression.py::TestRegression::test_string_truncation
/venv/lib/python3.7/site-packages/numpy/core/tests/test_regression.py:2060: FutureWarning: Promotion of numbers and bools to strings is deprecated. In the future, code such as `np.concatenate((['string'], [0]))` will raise an error, while `np.asarray(['string', 0])` will return an array with `dtype=object`. To avoid the warning while retaining a string result use `dtype='U'` (or 'S'). To get an array of Python objects use `dtype=object`. (Warning added in NumPy 1.21)
b = np.array([tostr('xx'), val])
core/tests/test_regression.py::TestRegression::test_string_truncation
/venv/lib/python3.7/site-packages/numpy/core/tests/test_regression.py:2064: FutureWarning: Promotion of numbers and bools to strings is deprecated. In the future, code such as `np.concatenate((['string'], [0]))` will raise an error, while `np.asarray(['string', 0])` will return an array with `dtype=object`. To avoid the warning while retaining a string result use `dtype='U'` (or 'S'). To get an array of Python objects use `dtype=object`. (Warning added in NumPy 1.21)
b = np.array([val, tostr('xxxxxxxxxx')])
core/tests/test_regression.py::TestRegression::test_string_truncation
/venv/lib/python3.7/site-packages/numpy/core/tests/test_regression.py:2066: FutureWarning: Promotion of numbers and bools to strings is deprecated. In the future, code such as `np.concatenate((['string'], [0]))` will raise an error, while `np.asarray(['string', 0])` will return an array with `dtype=object`. To avoid the warning while retaining a string result use `dtype='U'` (or 'S'). To get an array of Python objects use `dtype=object`. (Warning added in NumPy 1.21)
b = np.array([tostr('xxxxxxxxxx'), val])
ma/tests/test_mrecords.py::TestMRecordsImport::test_fromarrays
/venv/lib/python3.7/site-packages/numpy/ma/core.py:2826: FutureWarning: Promotion of numbers and bools to strings is deprecated. In the future, code such as `np.concatenate((['string'], [0]))` will raise an error, while `np.asarray(['string', 0])` will return an array with `dtype=object`. To avoid the warning while retaining a string result use `dtype='U'` (or 'S'). To get an array of Python objects use `dtype=object`. (Warning added in NumPy 1.21)
order=order, subok=True, ndmin=ndmin)
Metadata
Metadata
Assignees
Labels
No labels
Activity
DEP: Ensure the string promotion FutureWarning is raised