You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Getting the same.
Seems to work just fine in node for me as well.
I think it has to be some change that was made to the functions being called in _generate_signature, but no idea what exactly. Have you managed to solve this?
--> Edit 1:
Just found the solution in one of the forks, change time parameter sent to _generate_signature to time.time().
Do I understand it? nope. But it works
--> Edit 2:
Now that I understand it, I added import calendar and changed it to:
signature = self._generate_signature(
path_with_params , verb, channel,int(calendar.timegm(req_time.timetuple()))
)
Seems more correct to be using the same variable as the one I'm using in x-tourcms-date header since the two should always match.
Essentially Date (or x-tourcms-date) must match the date used to sign the request. From my limited Python knowledge this should be good. That said, do check #3 for an alternative, x-tourcms-date can be expressed as a unix timestamp.
Thank you for your work! But need little help with it.
'urllib.error.HTTPError: HTTP Error 401: Not Authorized'
same key and id test good in node and js.
Looks something wrong with this 10 years old library...... maybe something wrong with python 3.10?
The text was updated successfully, but these errors were encountered: