summaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorVinicius Monego <monego@posteo.net>2021-12-27 23:30:25 +0000
committerNicolas Goaziou <mail@nicolasgoaziou.fr>2022-01-11 18:07:27 +0100
commit5b43b55846ba8234e48d67ef7a0f38ee8086606a (patch)
treeb7c9c768c2ed1c7c7e4c21b1f6eb71562cb37e32 /gnu
parent276038ceb2d2687c66ae4e4c954c5644079e19fd (diff)
gnu: Add python-pylru.
* gnu/packages/python-xyz.scm (python-pylru): New variable. Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/python-xyz.scm29
1 files changed, 29 insertions, 0 deletions
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index a1f33559ed..a0cf06e132 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -11309,6 +11309,35 @@ signature of a file or buffer.")
provides a collection of cache libraries in the same API interface.")
(license license:bsd-3)))
+(define-public python-pylru
+ (package
+ (name "python-pylru")
+ (version "1.2.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "pylru" version))
+ (sha256
+ (base32 "15yj46307sw703vjfkgnr04dqvaicmfcj0hc6yrciildp55r6bs9"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key inputs outputs tests? #:allow-other-keys)
+ (when tests?
+ (add-installed-pythonpath inputs outputs)
+ (invoke "python" "test.py")))))))
+ (home-page "https://github.com/jlhutch/pylru")
+ (synopsis "Least recently used (LRU) cache implementation")
+ (description
+ "Pylru implements a true LRU cache along with several support classes.
+Pylru provides a cache class with a simple dict interface. It also provides
+classes to wrap any object that has a dict interface with a cache. Both
+write-through and write-back semantics are supported. Pylru also provides
+classes to wrap functions in a similar way, including a function decorator.")
+ (license license:gpl2+)))
+
(define-public python-legacy-api-wrap
(package
(name "python-legacy-api-wrap")