Coder Social home page Coder Social logo

Comments (8)

lefnire avatar lefnire commented on July 18, 2024

The machine-learning bit is pretty simple at present, and will get more complex the more this project takes off . So don't lose faith just yet.

A user's "cron" is run on the client, so it should run on your own computer's timezone. On page-load, in the browser, Habit tests a flag "is it tomorrow yet?" and if so, runs cron. If cron happens not sometime after midnight of your timezone, it's a bug I need to fix.

You say Habit thinks it's tomorrow on your computer? What happens, exactly, is cron being run prematurely?

from habitica.

empish avatar empish commented on July 18, 2024

I have two daily tasks that weren't supposed to be active until today. They were both greyed out yesterday morning, but then yellow yesterday evening.

I don't know if it would cause cron to run prematurely, but I do use multiple firefox profiles (http://lifehacker.com/231646/geek-to-live--manage-multiple-firefox-profiles).

RE: "On page-load, in the browser, Habit tests a flag "is it tomorrow yet?" and if so, runs cron." How does this deal with travel through different timezones?

from habitica.

lefnire avatar lefnire commented on July 18, 2024

It should just work, AFAIK. I'll have to play with it / do some research,
but new Date() in JavaScript TMK just picks up system's configured
timezone, and system clocks typically update when they have internet
connection in new timezone. Again, I'll play around / research that bit and
get back to you on it.

On Wed, Jan 2, 2013 at 12:08 PM, empish [email protected] wrote:

I have two daily tasks that weren't supposed to be active until today.
They were both greyed out yesterday morning, but then yellow yesterday
evening.

I don't know if it would cause cron to run prematurely, but I do use
multiple firefox profiles (
http://lifehacker.com/231646/geek-to-live--manage-multiple-firefox-profiles
).

RE: "On page-load, in the browser, Habit tests a flag "is it tomorrow
yet?" and if so, runs cron." How does this deal with travel through
different timezones?


Reply to this email directly or view it on GitHubhttps://github.com//issues/30#issuecomment-11815473.

from habitica.

empish avatar empish commented on July 18, 2024

The more this bounces around in the back of my brain, the morehaving a way to edit the date/time stamps seems to make sense. The automated method should work most of the time, but when there are computer or network issues or when someone doesn't have access to a networked computer, an edit option would solve the problem.

from habitica.

mfcovington avatar mfcovington commented on July 18, 2024

I'm on the west coast and when I checked at 10:40PM, it was already 'tomorrow' (sort of).

  • All my dailies had reset (and were green if I had checked them, so they were definitely registering as having completed since it was my first day)
  • However, I ++'d a hobby and looked at the progress chart... it only had the real today's date, not tomorrow's.

Edit: Happy to report that when it really became 'tomorrow' (as of 12:10 AM), nothing reset. I was concerned that back-to-back resets of dailies would nearly kill me. Also, after ++'ing a hobby, the progress chart shows, rightly so, that it is now 'tomorrow'. So, this might be a clue... Is the time on the progress chart generated differently than the time that dictates when dailies are reset?

from habitica.

mfcovington avatar mfcovington commented on July 18, 2024

So, I've been using habitrpg for a few days now and it seems to reset the day twice a day for me. I'm on the West coast and the dailies get reset ~ 10PM local time and then they get reset again when I login in the morning. Is this possible or do you think it is just an issue with the server? As a result, I've had to add a habit that I just click a bunch to get me to the next level so I'm not dead.

from habitica.

lefnire avatar lefnire commented on July 18, 2024

We should be good on this now, cron has been offloaded to the client. It'll take a full cron cycle to kick in for people - you have logged in one day, and the next day the cron issue should be fixed from then on out. If anyone experiences this timezone issue occurring more than once from here on out, hit me up. (@mfcovington - I think you should calibrated now)

from habitica.

mfcovington avatar mfcovington commented on July 18, 2024

@lefnire Sounds great. I'll keep you posted.

from habitica.

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.