Smartapi INVALID TOTP
-
Re: Errors in login
Traceback (most recent call last):
File "c:\Users\dhanr\WebDevloper\HTML.html\ligin_smartapi_code.py", line 187, in <module>
raise e
File "c:\Users\dhanr\WebDevloper\HTML.html\ligin_smartapi_code.py", line 184, in <module>
totp = pyotp.TOTP(token).now()
^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\dhanr\AppData\Roaming\Python\Python312\site-packages\pyotp\totp.py", line 34, in now
return self.generate_otp(self.timecode(datetime.datetime.now()))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\dhanr\AppData\Roaming\Python\Python312\site-packages\pyotp\otp.py", line 31, in generate_otp
self.byte_secret(),
^^^^^^^^^^^^^^^^^^
File "C:\Users\dhanr\AppData\Roaming\Python\Python312\site-packages\pyotp\otp.py", line 49, in byte_secret
return base64.b32decode(self.secret, casefold=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\Python312\Lib\base64.py", line 254, in b32decode
return _b32decode(_b32alphabet, s, casefold, map01)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\Python312\Lib\base64.py", line 210, in _b32decode
raise binascii.Error('Incorrect padding')
binascii.Error: Incorrect padding