You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This test results in rising the following exception: {TypeError}unsupported operand type(s) for -: 'str' and 'str'
The issue arises because the empty string is converted to nan while reading a csv file containing the dataframe.
Traceback (most recent call last):
File ".../venv/lib/python3.7/site-packages/IPython/core/interactiveshell.py", line 3437, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
File "<ipython-input-1-b86ebfe209ab>", line 1, in <module>
dataframe_regression.check(df)
File ".../venv/lib/python3.7/site-packages/pytest_regressions/dataframe_regression.py", line 260, in check
force_regen=self._force_regen,
File ".../venv/lib/python3.7/site-packages/pytest_regressions/common.py", line 153, in perform_regression_check
check_fn(obtained_filename, filename)
File ".../venv/lib/python3.7/site-packages/pytest_regressions/dataframe_regression.py", line 143, in _check_fn
diffs = np.abs(obtained_column - expected_column)[diff_ids]
File ".../venv/lib/python3.7/site-packages/pandas/core/ops/common.py", line 65, in new_method
return method(self, other)
File ".../venv/lib/python3.7/site-packages/pandas/core/arraylike.py", line 97, in __sub__
return self._arith_method(other, operator.sub)
File ".../venv/lib/python3.7/site-packages/pandas/core/series.py", line 4998, in _arith_method
result = ops.arithmetic_op(lvalues, rvalues, op)
File ".../venv/lib/python3.7/site-packages/pandas/core/ops/array_ops.py", line 189, in arithmetic_op
res_values = _na_arithmetic_op(lvalues, rvalues, op)
File ".../venv/lib/python3.7/site-packages/pandas/core/ops/array_ops.py", line 149, in _na_arithmetic_op
result = _masked_arith_op(left, right, op)
File ".../venv/lib/python3.7/site-packages/pandas/core/ops/array_ops.py", line 91, in _masked_arith_op
result[mask] = op(xrav[mask], yrav[mask])
TypeError: unsupported operand type(s) for -: 'str' and 'str'
The text was updated successfully, but these errors were encountered:
Minimal, reproducible example:
This test results in rising the following exception:
{TypeError}unsupported operand type(s) for -: 'str' and 'str'
The issue arises because the empty string is converted to nan while reading a csv file containing the dataframe.
The text was updated successfully, but these errors were encountered: