Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

ParseCron should give relative times #95

Closed
yegg opened this Issue May 14, 2012 · 7 comments

Comments

Projects
None yet
6 participants
Owner

yegg commented May 14, 2012

Gaganpreet ‏ @_gagan
@DuckDuckHack Results seem to be fixed to the server's timezone. A difference result, eg: "After 1 hour 5 minutes" will be much better.

Contributor

Habbie commented May 14, 2012

And/or times in the local timezone (I believe this can be figured out from JavaScript, at least when running in the browser and not in the zeroclick API).

Contributor

arunsrin commented May 15, 2012

I feel that the @_gagan's relative time will still have the same drawback, e.g: if DDG's server time is 12PM and a cron job is run every day at 2PM, the relative result of "After 2 hours" will still be incorrect for users in, say, the DDG+4 timezone (they would expect "After 22 hours" instead).

@Habbie's fix is the best case scenario, but I fear this is beyond my skill. There are a couple of other fixes I do have in mind:

a) Show the time in UTC to eliminate confusion. e.g.
Cron will start this event next at 12:42:00 on 2 Feb, 2013 UTC.

b) Show the next 3 events to make it clearer. e.g.
Cron will start this event next at the following times:
06:01:00 on 15 May, 2012.
06:02:00 on 15 May, 2012.
06:03:00 on 15 May, 2012.
Not the best fix, but this at least clearly shows that the cron job is run per minute, irrespective of timezone.

Any suggestions?

Owner

yegg commented May 15, 2012

I like option b) a lot as I often want to know a few times it will start. Also we could change the wording a bit to indicate like Cron will schedule this job at this frequency:

Contributor

Habbie commented May 15, 2012

+1 for option b

Gabriel Weinberg reply@reply.github.com wrote:

I like option b) a lot as I often want to know a few times it will
start. Also we could change the wording a bit to indicate like Cron
will schedule this job at this frequency:


Reply to this email directly or view it on GitHub:
#95 (comment)

Sent from my Android phone with K-9 Mail. Please excuse my brevity.

Contributor

gaganpreet commented May 15, 2012

Didn't occur to me relative time would suffer from the same drawback. Javascript will be the perfect solution, but if that's not possible, showing the time/date and linking to WolframAlpha with the query will show better details.

@arunsrin arunsrin added a commit to arunsrin/zeroclickinfo-goodies that referenced this issue Jun 12, 2012

@arunsrin arunsrin Fix for issue #95 e404f34

@majuscule majuscule added a commit that referenced this issue Jun 12, 2012

@arunsrin @majuscule arunsrin + majuscule Fix for issue #95 a0d1a1f
Member

xfix commented Sep 28, 2012

This was fixed, why it wasn't closed yet?

Owner

moollaza commented Mar 17, 2014

Closing. Looks to have been fixed in a0d1a1f

@moollaza moollaza closed this Mar 17, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment