When defining a Annotated Query Field it should behave in the same way as pydantic does (set validation_alias the same as alias if not set otherwise). This issue was reported in pydantic (#12369) ...
I ran into what seems to be a bug in starlette's get function in TestClient. I get an unexpected behavior when running the test beneath. from fastapi import FastAPI from pydantic import constr from ...