gomyway1216 / rag

0 stars 2 forks source link

Add min value validation for `weight` and `height` in BMI API #50

Open huyfififi opened 1 month ago

huyfififi commented 1 month ago

It's possible to send negative values to this API endpoint, and it should be prohibited.

https://docs.pydantic.dev/latest/concepts/fields/#numeric-constraints

Please add test cases to confirm that clients get validation errors, and please feel free to reach out to me when you are stuck.