GNU bug report logs - #46294
python-arrow timezone test failure

Previous Next

Package: guix;

Reported by: Guillaume Le Vaillant <glv <at> posteo.net>

Date: Thu, 4 Feb 2021 12:49:01 UTC

Severity: normal

Done: Efraim Flashner <efraim <at> flashner.co.il>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 46294 in the body.
You can then email your comments to 46294 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#46294; Package guix. (Thu, 04 Feb 2021 12:49:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Guillaume Le Vaillant <glv <at> posteo.net>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Thu, 04 Feb 2021 12:49:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Guillaume Le Vaillant <glv <at> posteo.net>
To: bug-guix <at> gnu.org
Subject: python-arrow timezone test failure
Date: Thu, 04 Feb 2021 13:47:59 +0100
[Message part 1 (text/plain, inline)]
Hi,

The python-arrow package currently fails to build because the
"test_parse_tz_name_zzz" test is failing.
This is with Guix at eae865c134ebb8b7432572288e8721794d6a9b87.
I'm not very familiar with Python, so does someone know how to fix this?


Here's the relevant part of the build log:

--8<---------------cut here---------------start------------->8---
_________ TestDateTimeParserParse.test_parse_tz_name_zzz[America/Nuuk] _________

self = <tests.test_parser.TestDateTimeParserParse object at 0x7ffff3e0d220>
full_tz_name = 'America/Nuuk'

    @pytest.mark.parametrize("full_tz_name", make_full_tz_list())
    def test_parse_tz_name_zzz(self, full_tz_name):
    
        self.expected = datetime(2013, 1, 1, tzinfo=tz.gettz(full_tz_name))
>       assert (
            self.parser.parse("2013-01-01 {}".format(full_tz_name), "YYYY-MM-DD ZZZ")
            == self.expected
        )

tests/test_parser.py:347: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
arrow/parser.py:244: in parse
    self._parse_token(token, value, parts)
arrow/parser.py:397: in _parse_token
    parts["tzinfo"] = TzinfoParser.parse(value)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

cls = <class 'arrow.parser.TzinfoParser'>, tzinfo_string = 'America/Nuuk'

    @classmethod
    def parse(cls, tzinfo_string):
    
        tzinfo = None
    
        if tzinfo_string == "local":
            tzinfo = tz.tzlocal()
    
        elif tzinfo_string in ["utc", "UTC", "Z"]:
            tzinfo = tz.tzutc()
    
        else:
    
            iso_match = cls._TZINFO_RE.match(tzinfo_string)
    
            if iso_match:
                sign, hours, minutes = iso_match.groups()
                if minutes is None:
                    minutes = 0
                seconds = int(hours) * 3600 + int(minutes) * 60
    
                if sign == "-":
                    seconds *= -1
    
                tzinfo = tz.tzoffset(None, seconds)
    
            else:
                tzinfo = tz.gettz(tzinfo_string)
    
        if tzinfo is None:
>           raise ParserError(
                'Could not parse timezone expression "{}"'.format(tzinfo_string)
            )
E           arrow.parser.ParserError: Could not parse timezone expression "America/Nuuk"

arrow/parser.py:592: ParserError
--8<---------------cut here---------------end--------------->8---
[signature.asc (application/pgp-signature, inline)]

Reply sent to Efraim Flashner <efraim <at> flashner.co.il>:
You have taken responsibility. (Mon, 08 Feb 2021 08:04:02 GMT) Full text and rfc822 format available.

Notification sent to Guillaume Le Vaillant <glv <at> posteo.net>:
bug acknowledged by developer. (Mon, 08 Feb 2021 08:04:02 GMT) Full text and rfc822 format available.

Message #10 received at 46294-done <at> debbugs.gnu.org (full text, mbox):

From: Efraim Flashner <efraim <at> flashner.co.il>
To: Guillaume Le Vaillant <glv <at> posteo.net>
Cc: 46294-done <at> debbugs.gnu.org
Subject: Re: bug#46294: python-arrow timezone test failure
Date: Mon, 8 Feb 2021 10:02:49 +0200
[Message part 1 (text/plain, inline)]
On Thu, Feb 04, 2021 at 01:47:59PM +0100, Guillaume Le Vaillant wrote:
> Hi,
> 
> The python-arrow package currently fails to build because the
> "test_parse_tz_name_zzz" test is failing.
> This is with Guix at eae865c134ebb8b7432572288e8721794d6a9b87.
> I'm not very familiar with Python, so does someone know how to fix this?

I tracked this down a bit, python-dateutil still has America/Nuuk as
America/Godthab, so any test looking for America/Nuuk is going to fail.
Unfortunately with the number of dependants there's not an easy way to
fix it on master so I think we'll need to skip that test for now.

I've gone ahead and skipped the broken test and added a message to
re-enable it after an update to python-dateutil.

-- 
Efraim Flashner   <efraim <at> flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[signature.asc (application/pgp-signature, inline)]

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 08 Mar 2021 12:24:10 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 43 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.