[Python-apps-team] Bug#908497: khal FTBFS with python-dateutil 2.7.3-1

Adrian Bunk bunk at debian.org
Mon Sep 10 14:20:13 BST 2018


Source: khal
Version: 1:0.9.8-1
Severity: serious
Tags: ftbfs
Control: block 907718 by -1

https://tests.reproducible-builds.org/debian/rb-pkg/unstable/amd64/khal.html

...
=================================== FAILURES ===================================
________________________ test_event_rrule_recurrence_id ________________________

    def test_event_rrule_recurrence_id():
        dbi = backend.SQLiteDb([calname], ':memory:', locale=LOCALE_BERLIN)
        assert dbi.list(calname) == list()
        events = dbi.get_localized(BERLIN.localize(datetime(2014, 6, 30, 0, 0)),
                                   BERLIN.localize(datetime(2014, 8, 26, 0, 0)))
        assert list(events) == list()
>       dbi.update(_get_text('event_rrule_recuid'), href='12345.ics', etag='abcd', calendar=calname)

tests/backend_test.py:33: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
khal/khalendar/backend.py:262: in update
    self._update_impl(vevent, href, calendar)
khal/khalendar/backend.py:355: in _update_impl
    dtstartend = utils.expand(vevent, href)
khal/khalendar/utils.py:89: in expand
    dtstart=dtstart
/usr/lib/python3/dist-packages/dateutil/rrule.py:1667: in __call__
    return self._parse_rfc(s, **kwargs)
/usr/lib/python3/dist-packages/dateutil/rrule.py:1550: in _parse_rfc
    tzinfos=tzinfos)
/usr/lib/python3/dist-packages/dateutil/rrule.py:1509: in _parse_rfc_rrule
    return rrule(dtstart=dtstart, cache=cache, **rrkwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <dateutil.rrule.rrule object at 0x7f0458449c88>, freq = 2
dtstart = datetime.datetime(2014, 6, 30, 7, 0), interval = 1, wkst = None
count = None, until = datetime.datetime(2014, 8, 6, 6, 0, tzinfo=tzutc())
bysetpos = None, bymonth = None, bymonthday = None, byyearday = None
byeaster = None, byweekno = None, byweekday = None, byhour = None
byminute = None, bysecond = None, cache = False

    def __init__(self, freq, dtstart=None,
                 interval=1, wkst=None, count=None, until=None, bysetpos=None,
                 bymonth=None, bymonthday=None, byyearday=None, byeaster=None,
                 byweekno=None, byweekday=None,
                 byhour=None, byminute=None, bysecond=None,
                 cache=False):
        super(rrule, self).__init__(cache)
        global easter
        if not dtstart:
            if until and until.tzinfo:
                dtstart = datetime.datetime.now(tz=until.tzinfo).replace(microsecond=0)
            else:
                dtstart = datetime.datetime.now().replace(microsecond=0)
        elif not isinstance(dtstart, datetime.datetime):
            dtstart = datetime.datetime.fromordinal(dtstart.toordinal())
        else:
            dtstart = dtstart.replace(microsecond=0)
        self._dtstart = dtstart
        self._tzinfo = dtstart.tzinfo
        self._freq = freq
        self._interval = interval
        self._count = count
    
        # Cache the original byxxx rules, if they are provided, as the _byxxx
        # attributes do not necessarily map to the inputs, and this can be
        # a problem in generating the strings. Only store things if they've
        # been supplied (the string retrieval will just use .get())
        self._original_rule = {}
    
        if until and not isinstance(until, datetime.datetime):
            until = datetime.datetime.fromordinal(until.toordinal())
        self._until = until
    
        if self._dtstart and self._until:
            if (self._dtstart.tzinfo is not None) != (self._until.tzinfo is not None):
                # According to RFC5545 Section 3.3.10:
                # https://tools.ietf.org/html/rfc5545#section-3.3.10
                #
                # > If the "DTSTART" property is specified as a date with UTC
                # > time or a date with local time and time zone reference,
                # > then the UNTIL rule part MUST be specified as a date with
                # > UTC time.
                raise ValueError(
>                   'RRULE UNTIL values must be specified in UTC when DTSTART '
                    'is timezone-aware'
                )
E               ValueError: RRULE UNTIL values must be specified in UTC when DTSTART is timezone-aware

/usr/lib/python3/dist-packages/dateutil/rrule.py:464: ValueError
...


See #907718 for background.



More information about the Python-apps-team mailing list