These changes fix issue #222. The validate_file checks for each row were returning early if no file was found regardless of how the allow_missing flag was set. The existing allow_missing check was after the early return.
The logic behind checking for a valid file has been updated to ensure the state of allow_missing is checked before returning early.
I have tested this locally and it works as intended now, my only concern is the messaging set to stderr in the validate_file function might be a bit confusing for anyone using the code with this flag set as it says Error: at the start.
I am happy to update the message to be a bit more dynamic and change to a Warning: when allow_missing is used but was on the fence if the extra logic needed for that was really worth it in this case.
These changes fix issue #222. The
validate_file
checks for each row were returning early if no file was found regardless of how theallow_missing
flag was set. The existingallow_missing
check was after the early return.The logic behind checking for a valid file has been updated to ensure the state of
allow_missing
is checked before returning early.I have tested this locally and it works as intended now, my only concern is the messaging set to stderr in the
validate_file
function might be a bit confusing for anyone using the code with this flag set as it saysError:
at the start.I am happy to update the message to be a bit more dynamic and change to a
Warning:
whenallow_missing
is used but was on the fence if the extra logic needed for that was really worth it in this case.