Crash when giving non-canonical date to due:

Bug #993931 reported by psychoslave on 2012-05-03
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Getting Things GNOME!
Low
Izidor Matušov

Bug Description

When typing due:dd with 0<dd<32 gtg would add the task taking (due:31 means due next 31, so if today is 3 feb. the task is due 31 march).

------------------------------

I wanted to add a task for the end of the month, so I tried to type "due:31". The application crashed :

Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/GTG/gtk/browser/browser.py", line 899, in on_quickadd_activate
    task.set_complex_title(text,tags=tags)
  File "/usr/lib/python2.7/site-packages/GTG/core/task.py", line 181, in set_complex_title
    due_date = get_canonical_date(args)
  File "/usr/lib/python2.7/site-packages/GTG/tools/dates.py", line 207, in get_canonical_date
    assert(len(arg) == 8)
AssertionError

% gtg --version
gtg (Getting Things Gnome!) 0.2.9
% uname -a
Linux tarasque 3.3.3-1-ARCH #1 SMP PREEMPT Mon Apr 23 09:41:07 CEST 2012 x86_64 Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz GenuineIntel GNU/Linux

By the way, it would be nice to add such a support, when typing due:dd with 0<dd<32 gtg would add the task taking (due:31 means due next 31, so if today is 3 feb. the task is due 31 march).

Alternatively, a keyword like endofmonth (eom), would means due for the last day of the current month.

Related branches

Izidor Matušov (izidor) on 2012-05-03
Changed in gtg:
status: New → Confirmed
importance: Undecided → Low
Izidor Matušov (izidor) wrote :

Dates class was refactored in the current trunk and your problem is not there anymore. I've coded support for due:dd in the linked branch. (After others review it, it will be available through our daily PPA)

Changed in gtg:
assignee: nobody → Izidor Matušov (izidor)
status: Confirmed → In Progress
description: updated
Changed in gtg:
milestone: none → 0.3
Izidor Matušov (izidor) on 2012-05-05
Changed in gtg:
status: In Progress → Fix Committed
Changed in gtg:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers