-
-
Notifications
You must be signed in to change notification settings - Fork 150
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migration path should be clear for the leeway/window #195
Comments
@Spomky Is there any update on this issue as while using the library i am facing the same issue where i get the following error: "The leeway must be lower than the TOTP period" with v11. it works fine with v10. |
@Spomky your inputs are very valuable for us for above query! We are upgrading the v10 to v11 but mentioned issue we are getting. If you can help us with regard then it will be good to take the further action at our end. |
If you used window=1 in v10, you might like the behavior of leeway=(period-1) in v11. If you used bigger windows, you’ll have to loop through time offsets in you own code. I.e. just multiple calls with leeway=0, for […, time()-30, time(), time()+30, …] |
Thanks for quick response we will check and investigate this at our end if anything will require will come back again |
Hi, I will update the migration path page. A note on #195 (comment) where the exception "Leeway must be less than TOTP period" is thrown. This is one of the reasons why the behavior changed between versions.
To me with previous versions, the |
It's not a literal break because of an api/syntax change, but it's a more subtle, hard to detect behavior change that everybody should think about when upgrading.
Projects cannot be compatible with both v10 and v11 at once without feature detection or having a leaking abstraction.
Originally posted by @talkinnl in #152 (comment)
The text was updated successfully, but these errors were encountered: