# HG changeset patch # User Paul Boddie # Date 1374528008 -7200 # Node ID 68903dad01b908586b1be64ad6f7b1ee334fd1e1 # Parent fe36f9b2b6a6eb6fa84db61485076faf845fc19d Fixed timespan coverage scale construction where open-ended timespans are involved. diff -r fe36f9b2b6a6 -r 68903dad01b9 EventAggregatorSupport/Filter.py --- a/EventAggregatorSupport/Filter.py Sat Jun 22 02:14:23 2013 +0200 +++ b/EventAggregatorSupport/Filter.py Mon Jul 22 23:20:08 2013 +0200 @@ -256,6 +256,21 @@ a_date, a_limit = a b_date, b_limit = b + + # Handle None as the datetime. + + a_before_everything = a_date is None and a_limit == START + a_after_everything = a_date is None and a_limit == END + b_before_everything = b_date is None and b_limit == START + b_after_everything = b_date is None and b_limit == END + + if a_before_everything and b_before_everything or a_after_everything and b_after_everything: + return 0 + elif a_before_everything or b_after_everything: + return -1 + elif a_after_everything or b_before_everything: + return 1 + result = cmp_dates_as_day_start(a_date, b_date) if result == 0: diff -r fe36f9b2b6a6 -r 68903dad01b9 README.txt --- a/README.txt Sat Jun 22 02:14:23 2013 +0200 +++ b/README.txt Mon Jul 22 23:20:08 2013 +0200 @@ -362,6 +362,8 @@ * Accessibility improvements: introduced table captions for the display of table headings; added link titles; supported the opening of pop-up menus and map labels using links and link targets. + * Fixed timespan coverage scale construction where open-ended timespans are + involved. New in EventAggregator 0.10.1 (Changes since EventAggregator 0.10) ------------------------------------------------------------------