mycroft_routine_skill icon indicating copy to clipboard operation
mycroft_routine_skill copied to clipboard

Feature request: support 24-hour time to accommodate European defaults

Open KathyReid opened this issue 5 years ago • 2 comments

This feedback came through a person who was doing a lot of translation on the Mycroft Translate platform in the Dutch language

Is it possible to support utterances in 24-hr time, such as "nineteen hundred hours" for 7pm - as this style of phrase is very common in European languages.

KathyReid avatar Dec 27 '18 15:12 KathyReid

Hey @KathyReid,

Thanks for sending this in. I think this would be as simple as adding or hour >= 12 to this line. I'll keep this in mind and see if I can knock it out when I've got a spare moment (hopefully sometime next week).

-Chris

ChristopherRogers1991 avatar Dec 29 '18 02:12 ChristopherRogers1991

Try out the extract_datetime() method. I think it might solve this for you. It handles things like "Thursday at oh-5-hundred", etc.

https://github.com/MycroftAI/mycroft-core/blob/dev/test/unittests/util/test_parse.py#L343

penrods avatar Jan 15 '19 00:01 penrods