Keys mismatch: make error message more informative
MEMBER
Good idea ! I think this can be improved in `Features.reorder_fields_as()` indeed at

https://github.com/huggingface/datasets/blob/7feeb5648a63b6135a8259dedc3b1e19185ee4c7/src/datasets/features/features.py#L1739-L1740

Is it something you would be interested in contributing ?
2022-08-31T13:49:06Z
https://github.com/huggingface/datasets/issues/4917#issuecomment-1232964792
https://api.github.com/repos/huggingface/datasets/issues/4917
IC_kwDODunzps5JfYy4
https://api.github.com/repos/huggingface/datasets/issues/comments/1232964792/reactions
2022-08-31T13:49:06Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1232964792
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
NONE
Is this open to work on? I'd love to take on this as my first issue.
2022-08-31T23:46:16Z
https://github.com/huggingface/datasets/issues/4917#issuecomment-1233561006
https://api.github.com/repos/huggingface/datasets/issues/4917
IC_kwDODunzps5JhqWu
https://api.github.com/repos/huggingface/datasets/issues/comments/1233561006/reactions
2022-08-31T23:46:16Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1233561006
https://avatars.githubusercontent.com/u/59410571?v=4
https://api.github.com/users/daspartho/events{/privacy}
https://api.github.com/users/daspartho/followers
https://api.github.com/users/daspartho/following{/other_user}
https://api.github.com/users/daspartho/gists{/gist_id}
https://github.com/daspartho
daspartho
MDQ6VXNlcjU5NDEwNTcx
https://api.github.com/users/daspartho/orgs
https://api.github.com/users/daspartho/received_events
https://api.github.com/users/daspartho/repos
https://api.github.com/users/daspartho/starred{/owner}{/repo}
https://api.github.com/users/daspartho/subscriptions
User
https://api.github.com/users/daspartho
public
CONTRIBUTOR
Hi @daspartho I’ve opened a PR #4919 
I don’t think there’s much left to do
2022-09-01T07:37:38Z
https://github.com/huggingface/datasets/issues/4917#issuecomment-1233872090
https://api.github.com/repos/huggingface/datasets/issues/4917
IC_kwDODunzps5Ji2Ta
https://api.github.com/repos/huggingface/datasets/issues/comments/1233872090/reactions
2022-09-01T07:37:38Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1233872090
https://avatars.githubusercontent.com/u/25532159?v=4
https://api.github.com/users/PaulLerner/events{/privacy}
https://api.github.com/users/PaulLerner/followers
https://api.github.com/users/PaulLerner/following{/other_user}
https://api.github.com/users/PaulLerner/gists{/gist_id}
https://github.com/PaulLerner
PaulLerner
MDQ6VXNlcjI1NTMyMTU5
https://api.github.com/users/PaulLerner/orgs
https://api.github.com/users/PaulLerner/received_events
https://api.github.com/users/PaulLerner/repos
https://api.github.com/users/PaulLerner/starred{/owner}{/repo}
https://api.github.com/users/PaulLerner/subscriptions
User
https://api.github.com/users/PaulLerner
public
NONE
ok : )
2022-09-01T11:34:50Z
https://github.com/huggingface/datasets/issues/4917#issuecomment-1234155277
https://api.github.com/repos/huggingface/datasets/issues/4917
IC_kwDODunzps5Jj7cN
https://api.github.com/repos/huggingface/datasets/issues/comments/1234155277/reactions
2022-09-01T11:34:50Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1234155277
https://avatars.githubusercontent.com/u/59410571?v=4
https://api.github.com/users/daspartho/events{/privacy}
https://api.github.com/users/daspartho/followers
https://api.github.com/users/daspartho/following{/other_user}
https://api.github.com/users/daspartho/gists{/gist_id}
https://github.com/daspartho
daspartho
MDQ6VXNlcjU5NDEwNTcx
https://api.github.com/users/daspartho/orgs
https://api.github.com/users/daspartho/received_events
https://api.github.com/users/daspartho/repos
https://api.github.com/users/daspartho/starred{/owner}{/repo}
https://api.github.com/users/daspartho/subscriptions
User
https://api.github.com/users/daspartho
public
**Is your feature request related to a problem? Please describe.**
When loading a dataset from disk with a defect in its `dataset_info.json` describing its features (I don’t know when/why/how this happens but it deserves its own issue), you will get an error message like:
`ValueError: Keys mismatch: between {'bar': Value(dtype='int64', id=None)} and {'foo': Value(dtype='int64', id=None)}`

Which is fine when you have only a few features like in the example but it gets very hard to read when you have a lot of features in your dataset.

**Describe the solution you'd like**
The error message should give the difference between the features (what keys are in A but missing in B and vice-versa). It should also tell which keys are inferred from `dataset.arrow` and which come from `dataset_info.json`.

Willing to help :)
