This commit is contained in:
Aria Desires 2025-12-16 13:05:49 -05:00
parent 2e2a668b30
commit 62abd204d1
2 changed files with 2 additions and 2 deletions

View File

@ -38,7 +38,7 @@ class Product(BaseModel):
name: str = Field(..., kw_only=False, min_length=1) name: str = Field(..., kw_only=False, min_length=1)
internal_price_cent: int = Field(..., gt=0, alias="price_cent") internal_price_cent: int = Field(..., gt=0, alias="price_cent")
reveal_type(Product.__init__) # revealed: (self: Product, name: str = Any, *, price_cent: int = Any) -> None reveal_type(Product.__init__) # revealed: (self: Product, name: str = ..., *, price_cent: int = ...) -> None
product = Product("Laptop", price_cent=999_00) product = Product("Laptop", price_cent=999_00)

View File

@ -19,7 +19,7 @@ class User:
id: int id: int
role: str = strawberry.field(default="user") role: str = strawberry.field(default="user")
reveal_type(User.__init__) # revealed: (self: User, *, id: int, role: str = Any) -> None reveal_type(User.__init__) # revealed: (self: User, *, id: int, role: str = ...) -> None
user = User(id=1) user = User(id=1)
reveal_type(user.id) # revealed: int reveal_type(user.id) # revealed: int