Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Due dates not handled correctly in Russian locale #140

Open
mihan007 opened this issue Nov 17, 2016 · 14 comments
Open

Due dates not handled correctly in Russian locale #140

mihan007 opened this issue Nov 17, 2016 · 14 comments

Comments

@mihan007
Copy link

mihan007 commented Nov 17, 2016

  • just installed your workflow using link from readme
  • it adds issues fine but can't set due date

Example "wl new due today"

Adding task with reminder "wl task remind me today at 6:00pm" work as expected:
https://dl.dropboxusercontent.com/s/at6yb4n426ghyyj/2016-11-17%20at%2011.09.png

Using

  • Alfred 3.2 Build 759, Tuesday 8th November 2016
  • Wunderlist 3.4.5 (41)
  • Russian localization

What should I check/change to make it work as expected with adding task with due date?

@idpaterson
Copy link
Owner

idpaterson commented Nov 17, 2016

It looks like you will need to use Russian language dates since the parsedatetime date processing library that the workflow uses provides a Russian locale. In this example, "due сегодня"

See the locale file for more examples.

In general since Alfred is English only workflow developers focus on English, which has always made it a bit difficult to find ways for the Wunderlist workflow to support other languages. When this issue comes up I always ask whether you would prefer a preference in the workflow to just use English for everything. Let me know if it is very confusing or inconvenient to use English for the workflow keywords like due and reminder but Russian for all the dates.

On a related note, I am working on a contribution to parsedatetime to add a much more comprehensive testing framework so that locales can be better supported. That won't be done for quite awhile still but it paves the way to being able to document this workflow's behavior for various locales and better support all dates formats.

@idpaterson
Copy link
Owner

idpaterson commented Nov 17, 2016

I forgot to add that the due keyword can often be omitted since a date within the task is implicitly taken as the due date. Similarly, a time within the task is implicitly taken as a reminder date. When a task specifies only a time there due date is set to today.

That is why your reminder example worked – the time was treated as a reminder and since no date was found the due date was set to today. When adding a task "test сегодня 9:45pm" your final task in Wunderlist should include only the word "test" since the date and time after removed.

@mihan007
Copy link
Author

Thanks for your response.

  1. I've tried to add task like 'wl new task due сегодня' & 'wl new task due завтра' => doesn't work as expected => no due date at all
    (https://dl.dropboxusercontent.com/s/iudayhck1uk1785/2016-11-19%20at%2015.01.png)
  2. Tried one more time 'wl new task due tomorrow' => doesn't work, no due date (same screenshot)
  3. It's totally ok to use just English at Alfred date/time parsing and not ok to use it for task description (I'd like to make tasks in Russian words and use English for date/time - it's ok)
  4. I've tried 'test сегодня 9:45pm' => https://dl.dropboxusercontent.com/s/xh6fp9jt0jp0sf9/2016-11-19%20at%2015.05.png (incorrect time and parsing, time of reminder is 9:45am, should be 9:45pm)
  5. I've tried 'test завтра 9:45pm' => https://dl.dropboxusercontent.com/s/c50s4vhtkxmld5x/2016-11-19%20at%2015.07.png (incorrect parsing, expected tomorrow 9:45pm, got today 9:45am)

Is it any way to make parsing date/time library use english localization only?

@idpaterson
Copy link
Owner

Since the localization is not working as expected I'll gladly add a preference for that and push out a release. I'll post a download here first for you to evaluate.

In these situations it is helpful for me to see a screenshot of your locale settings. Would you please send a screenshot of the Language & Region preferences screen, as well as the General tab when you click Advanced on the bottom of that preferences screen? They will help me to figure out what's wrong with the Russian locale. Thanks!

@idpaterson idpaterson self-assigned this Nov 19, 2016
@idpaterson
Copy link
Owner

idpaterson commented Nov 19, 2016

I added a setting at wl-pref to "Force US English for dates." I don't think I will publish the preference as-is since it would be nicer to choose from all available locales rather than just US English. Download the beta here, this will automatically update for you when the next version is released.

I would still like to figure out what is wrong with the Russian locale if you can send that locale settings screenshot.

@mihan007
Copy link
Author

@mihan007
Copy link
Author

Are you sure that you've pushed your changes? Because I installed workflow from link that you've posted above and haven't seen any new items at wl-pref. Then I've checked link https://github.com/idpaterson/alfred-wunderlist-workflow/blob/27cadfebcff0ff338824c927ba575fc8f6dd1031/Wunderlist.alfredworkflow and it says that commit is from 26 sep (https://dl.dropboxusercontent.com/s/lv8bat58einzhor/2016-11-19%20at%2020.49.png).

  1. wl-pref top - https://dl.dropboxusercontent.com/s/ym18dwtkotm9c6l/2016-11-19%20at%2020.50.png
  2. wl-pref bottom - https://dl.dropboxusercontent.com/s/mpnpwd9bsvrfa04/2016-11-19%20at%2020.51.png

Am I missing something?

@idpaterson
Copy link
Owner

Sorry about the wrong commit, that was supposed to be this build on develop

@idpaterson
Copy link
Owner

Very interesting, there are a few things going on with parsedatetime and your locale. I'll keep an eye on this while working on the new test framework for v3.0. The current Russian locale tests do not include any keywords and it doesn't appear that they work. I get unicode warnings when testing the locale directly in parsedatetime.

Would you be interested in being contacted within the next few months to help write or double-check Russian language tests for parsedatetime v3.0?

@idpaterson idpaterson changed the title Possible issue with adding task with due date Due dates not handled correctly in Russian locale Nov 19, 2016
@mihan007
Copy link
Author

Build works fine, thanks a lot.

For sure I'm interested in to help you with moving forward with Russian language, just ping me via this issue and we'll check.

Thanks for your help! Really appreciate it.

@idpaterson
Copy link
Owner

That's great to hear, sorry for the mixup earlier. Again, this will automatically update to the next version when it is released so you shouldn't need to come back to GitHub to download future versions.

If you have any feedback on a better solution to the locale setting please respond to this issue when you get a chance.

@holgtronic
Copy link

HI @idpaterson,
having the same issue on a machine running Wunderlist in german and using your workflow. I thought it was working before, this is why I ask?

wl test due today does not work (see screenshot1)

if I change it manually to
wl test due heute it does work (see screenshot2)

If there anything how I can make it working. I thought it worked fine before? (not sure)
Thanks...

MacOS on german local
Alfred 3.2.1
Workflow v0.6.3.

@idpaterson
Copy link
Owner

@HolgerT you can try installing the workflow that I linked to a few comments above which adds a preference to force English dates. I have not had time to get a fully capable preference released yet.

@holgtronic
Copy link

that works perfect. Many thanks :-)

@idpaterson idpaterson removed their assignment Nov 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants