SAIC-iSmart-API / saic-python-mqtt-gateway

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Client not authenticated, please call login first

bj00rn opened this issue · comments

Getting this login exception when I try to set refresh mode since yesterday.

v0.5.10

2024-02-06 14:18:14,099 [  INFO  ] Job "Check for new messages (trigger: interval[0:01:00], next run at: 2024-02-06 14:19:14 CET)" executed successfully - apscheduler.executors.default
saic-mqtt-gateway    | 2024-02-06 14:18:14,939 [  INFO  ] Setting refresh mode to force - vehicle
saic-mqtt-gateway    | 2024-02-06 14:18:14,942 [ DEBUG  ] Refresh mode set to force - vehicle
saic-mqtt-gateway    | 2024-02-06 14:19:14,091 [ DEBUG  ] Looking for jobs to run - apscheduler.scheduler
saic-mqtt-gateway    | 2024-02-06 14:19:14,093 [ DEBUG  ] Next wakeup is due at 2024-02-06 14:20:14.087348+01:00 (in 59.993806 seconds) - apscheduler.scheduler
saic-mqtt-gateway    | 2024-02-06 14:19:14,094 [  INFO  ] Running job "Check for new messages (trigger: interval[0:01:00], next run at: 2024-02-06 14:20:14 CET)" (scheduled at 2024-02-06 14:19:14.087348+01:00) - apscheduler.executors.default
saic-mqtt-gateway    | 2024-02-06 14:19:14,095 [ DEBUG  ] Checking for new messages - __main__
saic-mqtt-gateway    | 2024-02-06 14:19:14,096 [ ERROR  ] MessageHandler poll loop failed - __main__
saic-mqtt-gateway    | Traceback (most recent call last):
saic-mqtt-gateway    |   File "/usr/src/app/./mqtt_gateway.py", line 530, in __polling
saic-mqtt-gateway    |     unread_count = await self.saicapi.get_unread_messages_count()
saic-mqtt-gateway    |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
saic-mqtt-gateway    |   File "/usr/local/lib/python3.12/site-packages/saic_ismart_client_ng/api/message/__init__.py", line 59, in get_unread_messages_count
saic-mqtt-gateway    |     return await self.execute_api_call(
saic-mqtt-gateway    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
saic-mqtt-gateway    |   File "/usr/local/lib/python3.12/site-packages/saic_ismart_client_ng/api/base.py", line 91, in execute_api_call
saic-mqtt-gateway    |     response = await self.api_client.client.send(req)
saic-mqtt-gateway    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
saic-mqtt-gateway    |   File "/usr/local/lib/python3.12/site-packages/httpx/_client.py", line 1646, in send
saic-mqtt-gateway    |     response = await self._send_handling_auth(
saic-mqtt-gateway    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
saic-mqtt-gateway    |   File "/usr/local/lib/python3.12/site-packages/httpx/_client.py", line 1674, in _send_handling_auth
saic-mqtt-gateway    |     response = await self._send_handling_redirects(
saic-mqtt-gateway    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
saic-mqtt-gateway    |   File "/usr/local/lib/python3.12/site-packages/httpx/_client.py", line 1709, in _send_handling_redirects
saic-mqtt-gateway    |     await hook(request)
saic-mqtt-gateway    |   File "/usr/local/lib/python3.12/site-packages/saic_ismart_client_ng/net/client/api.py", line 47, in __encrypt_request
saic-mqtt-gateway    |     raise SaicApiException("Client not authenticated, please call login first")
saic-mqtt-gateway    | saic_ismart_client_ng.exceptions.SaicApiException: Client not authenticated, please call login first
saic-mqtt-gateway    | 2024-02-06 14:19:14,099 [  INFO  ] Job "Check for new messages (trigger: interval[0:01:00], next run at: 2024-02-06 14:20:14 CET)" executed successfully - apscheduler.executors.default
saic-mqtt-gateway    | 2024-02-06 14:20:14,090 [ DEBUG  ] Looking for jobs to run - apscheduler.scheduler
saic-mqtt-gateway    | 2024-02-06 14:20:14,092 [ DEBUG  ] Next wakeup is due at 2024-02-06 14:21:14.087348+01:00 (in 59.994655 seconds) - apscheduler.scheduler
saic-mqtt-gateway    | 2024-02-06 14:20:14,093 [  INFO  ] Running job "Check for new messages (trigger: interval[0:01:00], next run at: 2024-02-06 14:21:14 CET)" (scheduled at 2024-02-06 14:20:14.087348+01:00) - apscheduler.executors.default
saic-mqtt-gateway    | 2024-02-06 14:20:14,094 [ DEBUG  ] Checking for new messages - __main__
saic-mqtt-gateway    | 2024-02-06 14:20:14,097 [ ERROR  ] MessageHandler poll loop failed - __main__

duplicate of #133