argenos / nldates-obsidian

Work with dates in natural language in Obsidian
MIT License
477 stars 43 forks source link

"Next tuesday" or "Next monday" shows me this tuesday/monday #111

Closed DeutscheGabanna closed 1 month ago

DeutscheGabanna commented 1 year ago

When I type in "next tuesday", instead of outputting [[2022-08-23]], the program outputs [[2022-08-16]] - this Tuesday. It happens with every day of the week.

DeutscheGabanna commented 1 year ago

My system date (on Windows 7) is properly set up.

callumbirks commented 1 year ago

This happened to me after changing "Week starts on" to Monday. Changing it back to "Locale default (sunday)" fixed this issue. Not a very nice fix though.

Bobw147 commented 1 year ago

This is a natural language problem that I come across very frequently when talking to people. The exact meaning of 'next Thursday' is ambiguous - some use it to mean 'the next Thursday in the calendar', which could be later this week, while others use it to mean 'Thursday next week'. The only realistic solution to this problem in respect of this excellent plug-in would be to make the meaning of 'next' a configurable setting in the plug-in so that it conforms to the usage of the plug-in user.

S-Wil commented 1 year ago

This is also happening to me. I did have "Week starts on" set to Monday and can confirm this fixes the problem. I wanted to highlight that this is a bug in my mind. If I have locale set to Monday, then on a Friday "Next Wednesday" will return the date for the Wednesday 2 days in the past. This is in no way "Next Wednesday" - this would be "Last Wednesday". Once I change the "Week starts on" it immediately works as it should and returns the date for the Wednesday 5 days in the future.

OK I have to update this post. It does not fix the problem in all circumstances. Today (3 Oct) when I type @fri the result is Fri 30-Sep-22 although that is in the past, and when I type @next fri the result is Fri 14-Oct-22 which is two weeks in the future. Something is clearly broken here.

Krizzzn commented 1 year ago

I also changed the week starts to Monday. Here are a few samples i see on my computer:

Last tuesday: 2022-11-15
This tuesday: 2022-11-22
Next tuesday: 2022-11-29
today: 2022-12-01
yesterday: 2022-11-30
3 days ago: 2022-11-28

This tuesday outputs a date in last week. The date of Next tuesday was two days ago.

It might also be related to a german calendar setting on my computer.

cathywu commented 1 year ago

I am experiencing this same issue.

NeoTeo commented 1 year ago

Same here

garbosz commented 3 months ago

honestly the more i use the "Next" modifier the more i notice it pulls from the past. for example on 4/13 im asking for @ Next Wednesday expecting 4/17, but the resulting link keeps giving me 4/10. id expect that if i say next then it would always be the future.

argenos commented 1 month ago

Closing this to keep discussion in a single place (#137)