Linus2punkt0 / bluesky-crossposter

An app for crossposting your posts from bluesky to twitter and mastodon
108 stars 23 forks source link

atproto.exceptions.ModelError: 1 validation error for Response emailConfirmed #29

Closed benborges closed 1 year ago

benborges commented 1 year ago

This is new, perhaps bluesky has changed something ? with this error the crossposter stopped working

logs from inside the docker container :

Traceback (most recent call last): File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/models/utils.py", line 87, in _get_or_create return model(**model_data) ^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pydantic/main.py", line 165, in __init__ __pydantic_self__.__pydantic_validator__.validate_python(data, self_instance=__pydantic_self__) pydantic_core._pydantic_core.ValidationError: 1 validation error for Response emailConfirmed Extra inputs are not permitted [type=extra_forbidden, input_value=False, input_type=bool] For further information visit https://errors.pydantic.dev/2.3/v/extra_forbidden The above exception was the direct cause of the following exception: Traceback (most recent call last): File "//crosspost.py", line 15, in <module> bsky.login(bsky_handle, bsky_password) File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/client/client.py", line 74, in login session = self._get_and_set_session(login, password) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/client/client.py", line 37, in _get_and_set_session session = self.com.atproto.server.create_session( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/namespaces/sync_ns.py", line 1757, in create_session return get_response_model(response, models.ComAtprotoServerCreateSession.Response) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/models/utils.py", line 98, in get_response_model return get_or_create(response.content, model) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/models/utils.py", line 64, in get_or_create raise e File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/models/utils.py", line 57, in get_or_create model_instance = _get_or_create(model_data, model, strict=strict) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/models/utils.py", line 89, in _get_or_create raise ModelError(str(e)) from e atproto.exceptions.ModelError: 1 validation error for Response emailConfirmed Extra inputs are not permitted [type=extra_forbidden, input_value=False, input_type=bool] For further information visit https://errors.pydantic.dev/2.3/v/extra_forbidden Traceback (most recent call last): File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/models/utils.py", line 87, in _get_or_create return model(**model_data) ^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pydantic/main.py", line 165, in __init__ __pydantic_self__.__pydantic_validator__.validate_python(data, self_instance=__pydantic_self__) pydantic_core._pydantic_core.ValidationError: 1 validation error for Response emailConfirmed Extra inputs are not permitted [type=extra_forbidden, input_value=False, input_type=bool] For further information visit https://errors.pydantic.dev/2.3/v/extra_forbidden Traceback (most recent call last): File "/usr/local/lib/python3.11/site-packages/atproto/xrpc_client/models/utils.py", line 87, in _get_or_create return model(**model_data) ^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pydantic/main.py", line 165, in __init__ __pydantic_self__.__pydantic_validator__.validate_python(data, self_instance=__pydantic_self__) pydantic_core._pydantic_core.ValidationError: 1 validation error for Response emailConfirmed Extra inputs are not permitted [type=extra_forbidden, input_value=False, input_type=bool] For further information visit https://errors.pydantic.dev/2.3/v/extra_forbidden The above exception was the direct cause of the following exception: Traceback (most recent call last): File "//crosspost.py", line 15, in <module> bsky.login(bsky_handle, bsky_password)

Linus2punkt0 commented 1 year ago

Yes, they made a change that needed to be adapted to by the atproto python library. I've updated requirements.txt to specify the latest version of atproto with the fix.

benborges commented 1 year ago

ok great, thank you very much , will update here!