gnu: python-tzlocal: Update to 1.5.1.

* gnu/packages/time.scm (python-tzlocal): Update to 1.5.1.
[arguments]: Add custom phase to fix symlink issue in pypi release.
[native-inputs]: Add python-mock.
[license]: Update to expat.
This commit is contained in:
Efraim Flashner 2019-01-04 15:59:30 +02:00
parent f20cfa0665
commit d1e75921b2
No known key found for this signature in database
GPG Key ID: 41AAE7DCCA3D8351
1 changed files with 16 additions and 4 deletions

View File

@ -2,7 +2,7 @@
;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org> ;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org>
;;; Copyright © 2013, 2017 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2013, 2017 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr>
;;; Copyright © 2015, 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2015, 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2015, 2017 Leo Famulari <leo@famulari.name>
;;; Copyright © 2015, 2017 Cyril Roelandt <tipecaml@gmail.com> ;;; Copyright © 2015, 2017 Cyril Roelandt <tipecaml@gmail.com>
;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com> ;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com>
@ -198,17 +198,29 @@ datetime module, available in Python 2.3+.")
(define-public python-tzlocal (define-public python-tzlocal
(package (package
(name "python-tzlocal") (name "python-tzlocal")
(version "1.2.2") (version "1.5.1")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
(uri (pypi-uri "tzlocal" version)) (uri (pypi-uri "tzlocal" version))
(sha256 (sha256
(base32 (base32
"0paj7vlsb0np8b5sp4bv64wxv7qk2piyp7xg29pkhdjwsbls9fnb")))) "0kiciwiqx0bv0fbc913idxibc4ygg4cb7f8rcpd9ij2shi4bigjf"))))
(build-system python-build-system) (build-system python-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(add-before 'check 'fix-symlink-test
;; see: https://github.com/regebro/tzlocal/issues/53
(lambda _
(delete-file "tzlocal/test_data/symlink_localtime/etc/localtime")
(symlink "../usr/share/zoneinfo/Africa/Harare"
"tzlocal/test_data/symlink_localtime/etc/localtime")
#t)))))
(propagated-inputs (propagated-inputs
`(("python-pytz" ,python-pytz))) `(("python-pytz" ,python-pytz)))
(native-inputs
`(("python-mock" ,python-mock)))
(home-page "https://github.com/regebro/tzlocal") (home-page "https://github.com/regebro/tzlocal")
(synopsis "Local timezone information for Python") (synopsis "Local timezone information for Python")
(description (description
@ -216,7 +228,7 @@ datetime module, available in Python 2.3+.")
This module attempts to fix a glaring hole in pytz, that there is no way to This module attempts to fix a glaring hole in pytz, that there is no way to
get the local timezone information, unless you know the zoneinfo name, and get the local timezone information, unless you know the zoneinfo name, and
under several distributions that's hard or impossible to figure out.") under several distributions that's hard or impossible to figure out.")
(license cc0))) (license expat)))
(define-public python-isodate (define-public python-isodate
(package (package