Git Product home page Git Product logo

Comments (3)

pkpio avatar pkpio commented on August 17, 2024

@resolS , the latest commit should fix this issue.

from fitbit-googlefit.

lightmaster avatar lightmaster commented on August 17, 2024

I'm getting this issue, but no error. It runs through my date range until the API Limit is hit and then says it will retry at the next hour plus 1 second (ie: 18:00:01), however when that time comes around, it immediately says that the API Limit has been hit again and it will try at the top of the next hour. If I use Ctrl + C to stop it and retry again 5 minutes later, it proceeds successfully until it hits the API Limit again. (syncing 2 years, so gonna be hitting that limit a lot).

I believe that a difference of just a few seconds between the server the app is running on and Fitbit's server is causing the app to attempt to run a few seconds before the Fitbit's server resets the API Limit.

I propose changing the time that it attempts to run the next batch to 5 minutes after the hour to ensure that Fitbit's server's time is past the top of the hour mark.

from fitbit-googlefit.

pkpio avatar pkpio commented on August 17, 2024

@lightmaster In theory, that shouldn't happen because we are not using the time from the local clock directly. Fitbit tells us after how many seconds we can safely try again and we try after those many seconds. Given the delays in the network transmission, we will be waiting at least until the limit is reset. The only way we may try sooner is if the local clock drifts - counts seconds faster than the Fitbit servers. I don't see any issue with waiting a little bit longer as you suggested but I'm just curious about what's really causing the issue - clock drift is my best guess right now.

from fitbit-googlefit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.