diff options
Diffstat (limited to 'gnu/packages/check.scm')
-rw-r--r-- | gnu/packages/check.scm | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index c73d886567..9768e5f8a4 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -2778,18 +2778,29 @@ create data based on random numbers and yet remain repeatable.") (define-public python-freezegun (package (name "python-freezegun") - (version "0.3.14") + (version "1.2.2") (source (origin (method url-fetch) (uri (pypi-uri "freezegun" version)) (sha256 - (base32 "0al75mk829j1izxi760b7yjnknjihyfhp2mvi5qiyrxb9cpxwqk2")))) + (base32 "0ijlq32qvpm5zprfzbyzawpl9qjsknlxhryr1i0q84wl0sxd28nd")) + (modules '((guix build utils))) + (snippet + ;; Add an explicit case for static methods as they are callable + ;; in Python 3.10, breaking this conditional. + ;; XXX Taken from upstream pull request: + ;; https://github.com/spulec/freezegun/pull/397 + '(substitute* "freezegun/api.py" + (("if not callable\\(attr_value\\) or \ +inspect\\.isclass\\(attr_value\\):") + "if (not callable(attr_value) or inspect.isclass(attr_value)\ +or isinstance(attr_value, staticmethod)):"))))) (build-system python-build-system) (native-inputs - (list python-mock python-pytest)) + (list python-pytest)) (propagated-inputs - (list python-six python-dateutil)) + (list python-dateutil)) (arguments `(#:phases (modify-phases %standard-phases |