-
Notifications
You must be signed in to change notification settings - Fork 148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix 1633 unexpected key error with primary key in schema and 1635 unexpected missing label error when ignoring header case #1641
Fix 1633 unexpected key error with primary key in schema and 1635 unexpected missing label error when ignoring header case #1641
Conversation
Hi @roll, This PR is ready for your review. Some things somewhat related to this PR, detailed below bother me a little bit. However, the bugs that are fixed by this PR are blocking for our migration from v4 to v5 on Validata. Would you mind reviewing it as is, and may I transform these concerns into issues and propose associated pull requests? Please don't hesitate if something is bothering you, if I am wrong in any of my points or missed the obvious. Thanks. Details :
|
Hi @pierrecamilleri, Thanks a lot! Can you please resolve the conflicts as the dev/release process update just been merged #1652 |
Done EDIT: Oops tests no longer pass, I spoke too fast. I look into it |
All set ! |
@pierrecamilleri we shoudn't be using Could we instead call It is not part of your PR but would be nice to fix it. |
@pierrecamilleri wait, I will fix this in a new PR instead and then we can merge the fix into this two PRs. |
@pierrecamilleri I just merged #1674 . Could you please rebase and then merge when test are passing? |
… schema_sync option
…'schema_sync=True' options
…part in '__open_row_stream()' 'TableResource' method
…ary key label to the schema fields
…rearrange_schema_fields_given_labels'
…schema_fields_given_labels' method
Co-authored-by: Pierre Camilleri <[email protected]>
…ey_field_name_not_in_label' method
ec8b36b
to
d464802
Compare
header_case = False
#1635This PR fixes unexpected
missing-label
error in validation report which occurs when validating tabular data in this specific case (#1635): The data contains a named column corresponding to a required field in the schema used for validation, written without respecting case-sensitivity.For example:
It adds some test cases:
schema_sync=True
anddialect=Dialect(header_case=False)
options, returns a valid report.schema_sync=True
anddialect=Dialect(header_case=False)
options, returns an invalid report withmissing-label
error related to field "AA".This PR also fixes unexpected KeyError raised when a primary key used in shema is missing in the tabular data to validate(#1633).
For example:
It adds some test cases:
Finally, I suggest some refactoring in this PR:
schema_sync
option indetect_schema()
Detector
methodTableResource
methods to createcells
related to primary key schema.