This merge request adds two new tests to the BGS rules:
check_loca_within_great_britain
check_locx_is_not_duplicate_of_other_column
These rules are described in #21.
I've used a different way to implement these checks, where I define a checking function and use df.apply() to run it on each row. It only works where validation happens within a single row, but has the benefit that you get the Row ID out in the error message. We can't use line numbers in the BGS checks because the dataframes don't record them.
It also forces conversion of the coordinate columns into numeric types, even if they are marked with type X. This fixes a bug where real files were failing with "Can't convert string to float" errors.
To test:
Confirm all tests run
Run the API and process test/files/real/wells relief bh.ags, which previously suffered from the bug
This merge request adds two new tests to the BGS rules:
These rules are described in #21.
I've used a different way to implement these checks, where I define a checking function and use
df.apply()
to run it on each row. It only works where validation happens within a single row, but has the benefit that you get the Row ID out in the error message. We can't use line numbers in the BGS checks because the dataframes don't record them.It also forces conversion of the coordinate columns into numeric types, even if they are marked with type
X
. This fixes a bug where real files were failing with "Can't convert string to float" errors.To test:
test/files/real/wells relief bh.ags
, which previously suffered from the bug