Skip to content

Commit

Permalink
Merge pull request #101 from jspaezp/any_error_message_clarification
Browse files Browse the repository at this point in the history
Improves diagnostic information for 'Any' type
  • Loading branch information
DaanRademaker committed Jan 9, 2024
2 parents c85de71 + e8c4300 commit 6a57ae9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/pydantic_avro/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,9 @@ def get_type(value: dict) -> dict:
value_type = value_type.get("type")
avro_type_dict["type"] = {"type": "map", "values": value_type}
else:
if t is None:
raise ValueError(f"Field '{value}' does not have a defined type.")

raise NotImplementedError(
f"Type '{t}' not support yet, "
f"please report this at https://github.com/godatadriven/pydantic-avro/issues"
Expand Down

0 comments on commit 6a57ae9

Please sign in to comment.