Dielee / volvo2mqtt

Home Assistant addon for connecting AAOS Volvos
MIT License
125 stars 25 forks source link

/volvoAAOS2mqtt/mqtt.py:56: SyntaxWarning: invalid escape sequence '\d' #196

Closed micvdh closed 1 month ago

micvdh commented 1 month ago

Describe the bug Since version 1.9.0 or 1.9.1 (unsure which version), the new "create_otp_input()" contains a syntax error for new pattern argument. At load time, log contain the following error message:

s6-rc: info: service legacy-cont-init: starting s6-rc: info: service legacy-cont-init successfully started s6-rc: info: service legacy-services: starting s6-rc: info: service legacy-services successfully started /volvoAAOS2mqtt/mqtt.py:56: SyntaxWarning: invalid escape sequence '\d' "pattern": "\d{6}", May 27 20:33:21 volvo2mqtt [106] - INFO: Starting volvo2mqtt version v1.9.1 May 27 20:33:21 volvo2mqtt [106] - INFO: Starting login with OTP

It seems this also prevents to enter the OTP code after email with OTP code has been received from Volvo.

Version info:
Core 2024.5.5 Supervisor 2024.05.1 Operating System 12.3 Frontend 20240501.1 volvo2mqtt 1.9.1

Logs:
Enable the debug option and upload your logfile here.

May 27 20:36:48 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 7/24 May 27 20:36:53 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 8/24 May 27 20:36:58 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 9/24 May 27 20:37:03 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 10/24 May 27 20:37:08 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 11/24 May 27 20:37:13 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 12/24 May 27 20:37:18 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 13/24 May 27 20:37:23 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 14/24 May 27 20:37:28 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 15/24 May 27 20:37:33 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 16/24 May 27 20:37:38 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 17/24 May 27 20:37:43 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 18/24 May 27 20:37:48 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 19/24 May 27 20:37:53 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 20/24 May 27 20:37:58 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 21/24 May 27 20:38:03 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 22/24 May 27 20:38:08 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 23/24 Traceback (most recent call last): File "/volvoAAOS2mqtt/main.py", line 15, in authorize() File "/volvoAAOS2mqtt/volvo.py", line 73, in authorize response = send_otp(auth_session, response) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/volvoAAOS2mqtt/volvo.py", line 157, in send_otp raise Exception ("No OTP found, exting...") Exception: No OTP found, exting... s6-rc: info: service legacy-services: stopping s6-rc: info: service legacy-services successfully stopped s6-rc: info: service legacy-cont-init: stopping s6-rc: info: service legacy-cont-init successfully stopped s6-rc: info: service fix-attrs: stopping s6-rc: info: service fix-attrs successfully stopped s6-rc: info: service s6rc-oneshot-runner: stopping s6-rc: info: service s6rc-oneshot-runner successfully stopped s6-rc: info: service s6rc-oneshot-runner: starting s6-rc: info: service s6rc-oneshot-runner successfully started s6-rc: info: service fix-attrs: starting s6-rc: info: service fix-attrs successfully started s6-rc: info: service legacy-cont-init: starting s6-rc: info: service legacy-cont-init successfully started s6-rc: info: service legacy-services: starting s6-rc: info: service legacy-services successfully started /volvoAAOS2mqtt/mqtt.py:56: SyntaxWarning: invalid escape sequence '\d' "pattern": "\d{6}", May 27 20:38:19 volvo2mqtt [106] - INFO: Starting volvo2mqtt version v1.9.1 May 27 20:38:19 volvo2mqtt [106] - INFO: Starting login with OTP May 27 20:38:19 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 0/24 May 27 20:38:24 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 1/24 May 27 20:38:29 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 2/24 May 27 20:38:34 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 3/24 May 27 20:38:39 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 4/24 May 27 20:38:44 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 5/24 May 27 20:38:49 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 6/24 May 27 20:38:54 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 7/24 May 27 20:38:59 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 8/24 May 27 20:39:04 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 9/24 May 27 20:39:09 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 10/24 May 27 20:39:14 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 11/24 May 27 20:39:19 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 12/24 May 27 20:39:24 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 13/24 May 27 20:39:29 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 14/24 May 27 20:39:34 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 15/24 May 27 20:39:39 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 16/24 May 27 20:39:44 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 17/24 May 27 20:39:49 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 18/24 May 27 20:39:54 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 19/24 May 27 20:39:59 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 20/24 May 27 20:40:04 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 21/24 May 27 20:40:09 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 22/24 May 27 20:40:14 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 23/24 Traceback (most recent call last): File "/volvoAAOS2mqtt/main.py", line 15, in authorize() File "/volvoAAOS2mqtt/volvo.py", line 73, in authorize response = send_otp(auth_session, response) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/volvoAAOS2mqtt/volvo.py", line 157, in send_otp raise Exception ("No OTP found, exting...") Exception: No OTP found, exting... s6-rc: info: service legacy-services: stopping s6-rc: info: service legacy-services successfully stopped s6-rc: info: service legacy-cont-init: stopping s6-rc: info: service legacy-cont-init successfully stopped s6-rc: info: service fix-attrs: stopping s6-rc: info: service fix-attrs successfully stopped s6-rc: info: service s6rc-oneshot-runner: stopping s6-rc: info: service s6rc-oneshot-runner successfully stopped s6-rc: info: service s6rc-oneshot-runner: starting s6-rc: info: service s6rc-oneshot-runner successfully started s6-rc: info: service fix-attrs: starting s6-rc: info: service fix-attrs successfully started s6-rc: info: service legacy-cont-init: starting s6-rc: info: service legacy-cont-init successfully started s6-rc: info: service legacy-services: starting s6-rc: info: service legacy-services successfully started /volvoAAOS2mqtt/mqtt.py:56: SyntaxWarning: invalid escape sequence '\d' "pattern": "\d{6}", May 27 20:40:24 volvo2mqtt [106] - INFO: Starting volvo2mqtt version v1.9.1 May 27 20:40:24 volvo2mqtt [106] - INFO: Starting login with OTP May 27 20:40:25 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 0/24 May 27 20:40:30 volvo2mqtt [106] - INFO: Waiting for otp code... Please check your mailbox and post your otp code to the following mqtt topic "volvoAAOS2mqtt/otp_code". Retry 1/24

Dielee commented 1 month ago

This is only a warning.. should not be a problem.

Dielee commented 1 month ago

Fixed with v1.9.2