You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to deserialize something that should contain a UUID, but contains some other string that doesn't happen to be 32 or 36 characters long, one gets this error message from serde:
invalid length: expected one of [36, 32], found <something>
This is very unhelpful.
Expected behavior
I would expect the error to state that UUID parsing failed. The fact that it failed at a length check would be nice to have as a detail, but is far less important.
Other
I think a good fix for this would be to change the serde code to wrap the UUID parsing error in format!("UUID parsing failed: {}", e) or something like that. If you want, I'll open a PR.
The text was updated successfully, but these errors were encountered:
Describe the bug
When trying to deserialize something that should contain a UUID, but contains some other string that doesn't happen to be 32 or 36 characters long, one gets this error message from serde:
invalid length: expected one of [36, 32], found <something>
This is very unhelpful.
Expected behavior
I would expect the error to state that UUID parsing failed. The fact that it failed at a length check would be nice to have as a detail, but is far less important.
Other
I think a good fix for this would be to change the serde code to wrap the UUID parsing error in
format!("UUID parsing failed: {}", e)
or something like that. If you want, I'll open a PR.The text was updated successfully, but these errors were encountered: