duckduckgo / zeroclickinfo-goodies

DuckDuckGo Instant Answers based on Perl & JavaScript
https://duckduckhack.com/
Other
979 stars 1.76k forks source link

Calendar/DatesRole doesn't respect relative dates correctly #773

Closed mintsoft closed 9 years ago

mintsoft commented 9 years ago

Just noticed this:

image

cc @mwmiller

moollaza commented 9 years ago

@mintsoft great find! We should try and fix this soon, that's a pretty bad bug...

mnp commented 9 years ago

I'll take a look at this.

daniellockyer commented 9 years ago

Am I right in saying that this was never actually a feature? I've looked through CalendarToday.pm but see no mention of tomorrow etc.

mintsoft commented 9 years ago

Hi @NeoSilky / @mnp

The handling of dates is all processed in a Moo Role and so lives here: https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/lib/DDG/GoodieRole/Dates.pm The tests are here: https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/t/00-roles.t

Essentially it's a class that defines all date parsing and marshalling behaviour for Goodies, fix it there and it fixes it everywhere, add functionality there and everything gets the benefit. I've not actually investigated this yet so the issue might be either with the Calendar usage of the role, or within the role itself.

Role 'docs': https://duck.co/duckduckhack/goodie_helpers#date-parsing

Hope that helps! Any issues just ping me and I'll try to help out

mnp commented 9 years ago

Unrelated question, but where should issues against the codio environment (box) get reported?

On Sat, Nov 29, 2014 at 5:07 AM, Rob Emery notifications@github.com wrote:

Hi @NeoSilky https://github.com/NeoSilky / @mnp https://github.com/mnp

The handling of dates is all processed in a Moo Role and so lives here:

https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/lib/DDG/GoodieRole/Dates.pm The tests are here:

https://github.com/duckduckgo/zeroclickinfo-goodies/blob/master/t/00-roles.t

Essentially it's a class that defines all date parsing and marshalling behaviour for Goodies, fix it there and it fixes it everywhere, add functionality there and everything gets the benefit. I've not actually investigated this yet so the issue might be either with the Calendar usage of the role, or within the role itself.

Role 'docs': https://duck.co/duckduckhack/goodie_helpers#date-parsing

Hope that helps! Any issues just ping me and I'll try to help out

— Reply to this email directly or view it on GitHub https://github.com/duckduckgo/zeroclickinfo-goodies/issues/773#issuecomment-64947159 .

Mitchell Perilstein mitchell.perilstein@gmail.com (484) 876-1444

mintsoft commented 9 years ago

@mnp idk actually probably against the duckduckgo repository: https://github.com/duckduckgo/duckduckgo is this right? @moollaza

moollaza commented 9 years ago

@mnp hmm I suppose it depends on the issue. I think the DuckPAN repo might make the most sense because that's really what Codio is for -- giving you a dev environment with DuckPAN pre-installed. If the issue is related to DDG I'll be sure to take a look. If it's related to Codio they have pretty good support. Click Help->Support/Contact Us from the Codio toolbar and you'll be able to message them with your concerns.

Feel free to email me, moollaza@duckduckgo.com about your problems if you prefer :)

mintsoft commented 9 years ago

@moollaza fixed by @mnp in https://github.com/duckduckgo/zeroclickinfo-goodies/pull/793