Skip to content
This repository was archived by the owner on Sep 8, 2025. It is now read-only.

Commit b21d6e3

Browse files
authored
fix: set total false to user attributes typed dict
1 parent c506308 commit b21d6e3

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

gotrue/_sync/client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -305,8 +305,8 @@ def update(self, *, attributes: Union[UserAttributesDict, UserAttributes]) -> Us
305305
306306
Parameters
307307
----------
308-
attributes : UserAttributes
309-
The attributes to update.
308+
attributes : UserAttributesDict | UserAttributes
309+
Attributes to update, could be: email, password, email_change_token, data
310310
311311
Returns
312312
-------

gotrue/types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ class LinkType(str, Enum):
158158
invite = "invite"
159159

160160

161-
class UserAttributesDict(TypedDict):
161+
class UserAttributesDict(TypedDict, total=False):
162162
"""Dict version of `UserAttributes`"""
163163

164164
email: Optional[str]

tests/_sync/test_client_with_auto_confirm_enabled.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ def test_update_user(client: SyncGoTrueClient):
255255

256256
@pytest.mark.asyncio
257257
@pytest.mark.depends(on=[test_sign_in.__name__])
258-
def test_update_user(client: SyncGoTrueClient):
258+
def test_update_user_dict(client: SyncGoTrueClient):
259259
try:
260260
client.init_recover()
261261
response = client.update(attributes={"data": {"hello": "world"}})

0 commit comments

Comments
 (0)