When column names in the pandera SchemaModel do not match the column names in the supplied data frame, this should be displayed in the error message as well as included as rows in the errors dataframe. All errors in the supplied dataframe should be reported as errors and no good rows should be returned.
However, as we are using the index column in ex.failure_cases dataframe, and this is nan for column name failures, the merge does not work and the entire dataframe is returned as being valid (unless there are other rows that fail from row level validation),
Expected behaviour should be as described in the first paragraph.
Bug in
data.validate.py
.When column names in the pandera SchemaModel do not match the column names in the supplied data frame, this should be displayed in the error message as well as included as rows in the errors dataframe. All errors in the supplied dataframe should be reported as errors and no good rows should be returned.
However, as we are using the
index
column inex.failure_cases
dataframe, and this isnan
for column name failures, the merge does not work and the entire dataframe is returned as being valid (unless there are other rows that fail from row level validation),Expected behaviour should be as described in the first paragraph.