Bug#892145: undertime enhancement: different start/end times for each timezone
On Tue, 2018-03-06 at 09:22 -0500, Antoine Beaupré wrote: > How does that sound? That sounds like you would get someone filing a bug about it :) It might be best to avoid implementing this until argparse can do it, or until we figure out how to do it with argparse. -- bye, pabs https://wiki.debian.org/PaulWise signature.asc Description: This is a digitally signed message part
Bug#892145: undertime enhancement: different start/end times for each timezone
On 2018-03-06 09:37:31, Paul Wise wrote: > Package: undertime > Version: 1.2.0 > Severity: wishlist > > It would be nice to be able to specify different start/end times for > the highlights for each timezone, since different meeting participants > might have different requirements on times. > > One meeting participant might work during the day but be available in > the early evening while another participant might be on night shift but > be available during their breakfast period. > > I was thinking this might be a good way to do it but then I was > thinking about having multiple availability periods for each timezone, > but that might be conflating multiple feature requests into one :) > > $ undertime --no-default-zone -s 8 -e 9 Australia/Perth -s 9 -e 10 > Europe/Paris -s 10 -e 11 America/Vancouver > usage: undertime [-h] [--start HOUR] [--end HOUR] [--date WHEN] [--colors] > [--default-zone] [--print-zones] > [timezones [timezones ...]] > undertime: error: unrecognized arguments: Europe/Paris America/Vancouver Kind of weird that argparse can't deal with out of order arguments like this... But yeah, if 'start' and 'end' would be nargs=+, we could collect those and map them to the right timezone. You would need to specify the start/end for all timezones otherwise things could break down quickly: once parsed, argparse doesn't have a concept of which option came before which argument. The above commandline would end up something like: start = [8, 9, 10] end = [9, 10, 11] zones = ['Australia/Perth', 'Europe/Paris', 'America/Vancouver'] So if you skip (say) Paris, you would end up with: start = [8, 10] end = [9, 11] zones = ['Australia/Perth', 'Europe/Paris', 'America/Vancouver'] The user would expect 10-11 to be mapped to Vancouver, but it would actually be mapped to Paris. Or Paris and Vancouver. I don't know how to parse this. :) I would probably just error out if there are more than one start/end times and that the count is different than the number of timezones. How does that sound? A. -- May your trails be crooked, winding, lonesome, dangerous, leading to the most amazing view. May your mountains rise into and above the clouds. - Edward Abbey
Bug#892145: undertime enhancement: different start/end times for each timezone
Package: undertime Version: 1.2.0 Severity: wishlist It would be nice to be able to specify different start/end times for the highlights for each timezone, since different meeting participants might have different requirements on times. One meeting participant might work during the day but be available in the early evening while another participant might be on night shift but be available during their breakfast period. I was thinking this might be a good way to do it but then I was thinking about having multiple availability periods for each timezone, but that might be conflating multiple feature requests into one :) $ undertime --no-default-zone -s 8 -e 9 Australia/Perth -s 9 -e 10 Europe/Paris -s 10 -e 11 America/Vancouver usage: undertime [-h] [--start HOUR] [--end HOUR] [--date WHEN] [--colors] [--default-zone] [--print-zones] [timezones [timezones ...]] undertime: error: unrecognized arguments: Europe/Paris America/Vancouver -- System Information: Debian Release: buster/sid APT prefers testing-debug APT policy: (900, 'testing-debug'), (900, 'testing'), (800, 'unstable-debug'), (800, 'unstable'), (790, 'buildd-unstable'), (700, 'experimental-debug'), (700, 'experimental'), (690, 'buildd-experimental') Architecture: amd64 (x86_64) Kernel: Linux 4.14.0-3-amd64 (SMP w/4 CPU cores) Locale: LANG=en_AU.utf8, LC_CTYPE=en_AU.utf8 (charmap=UTF-8), LANGUAGE=en_AU.utf8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) Versions of packages undertime depends on: ii python3 3.6.4-1 ii python3-parsedatetime 2.4-2 ii python3-termcolor 1.1.0-1 ii python3-terminaltables 3.1.0-2 ii python3-tz 2018.3-2 undertime recommends no packages. undertime suggests no packages. -- no debconf information -- bye, pabs https://wiki.debian.org/PaulWise signature.asc Description: This is a digitally signed message part