From 271b2e43bef96f17f3f1e1085394b4bb144c5768 Mon Sep 17 00:00:00 2001 From: Danny Milosavljevic Date: Mon, 2 May 2022 23:33:19 +0200 Subject: gnu: openjdk: Update to 11.0.15. * gnu/packages/java (openjdk): Update to 11.0.15. [arguments]<#:phases>[fix-java-shebangs]: Adapt phase. --- gnu/packages/java.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index a72b08d16c..3d05ef831e 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -1768,7 +1768,7 @@ new Date();")) (define-public openjdk11 (package (name "openjdk") - (version "11.0.13") + (version "11.0.15") (source (origin (method url-fetch) (uri (string-append "https://openjdk-sources.osci.io/openjdk11/openjdk-" @@ -1776,7 +1776,7 @@ new Date();")) (file-name (string-append name "-" version ".tar.bz2")) (sha256 (base32 - "0xavz7msaadprq65p5bhp6sxcyp12p0zlbhb3aaz0cvp21c9pdm9")) + "0di91nnms2iq1svgq72r5y17am17r4vh2lq43k0bkcwpc84d6nd8")) (modules '((guix build utils))) (snippet `(begin @@ -1819,8 +1819,8 @@ new Date();")) (lambda _ ;; This file was "fixed" by patch-source-shebangs, but it requires ;; this exact first line. - (substitute* "make/data/blacklistedcertsconverter/blacklisted.certs.pem" - (("^#!.*") "#! java BlacklistedCertsConverter SHA-256\n")) + (substitute* "make/data/blockedcertsconverter/blocked.certs.pem" + (("^#!.*") "#! java BlockedCertsConverter SHA-256\n")) #t)) (add-after 'unpack 'patch-jni-libs ;; Hardcode dynamically loaded libraries. -- cgit v1.2.3 From 6b974845c7460d1f3dc84a633eafa785b5e72b9d Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Mon, 9 May 2022 15:56:44 +0200 Subject: gnu: rust-instant: Fix dependencies. Fixes a build failure introduced in bec6bf64bcbcf559eb0b91abcb7f3b2488916797. * gnu/packages/crates-io.scm (rust-instant-0.1)[arguments]: Adjust inputs as per "guix import crate rust@0.1.9". --- gnu/packages/crates-io.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0449e4f3fe..54dfda90fa 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -29089,13 +29089,14 @@ data efficiently.") (arguments `(#:tests? #f ; Issue during the wasm test. #:cargo-inputs - (("rust-js-sys" ,rust-js-sys-0.3) + (("rust-cfg-if" ,rust-cfg-if-1) + ("rust-js-sys" ,rust-js-sys-0.3) ("rust-stdweb" ,rust-stdweb-0.4) - ("rust-time" ,rust-time-0.1) + ("rust-time" ,rust-time-0.2) ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2) ("rust-web-sys" ,rust-web-sys-0.3)) #:cargo-development-inputs - (("rust-wasm-bindgen-test" ,rust-wasm-bindgen-test-0.2)))) + (("rust-wasm-bindgen-test" ,rust-wasm-bindgen-test-0.3)))) (home-page "https://github.com/sebcrozet/instant") (synopsis "Partial replacement for std::time::Instant that works on WASM too") -- cgit v1.2.3 From 1ebc27475cc310d6f9dd154b6b6893918f604c09 Mon Sep 17 00:00:00 2001 From: Andrew Tropin Date: Thu, 5 May 2022 10:09:56 +0300 Subject: gnu: emacs-modus-themes: Update to 2.3.3. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [[PGP Signed Part:No public key for 2208D20958C1DEB0 created at 2022-05-05T09:12:05+0200 using RSA]] * gnu/packages/emacs-xyz.scm (emacs-modus-themes): Update to 2.3.3. * gnu/packages/emacs-xyz.scm (emacs-modus-themes)[source]: Change repository. Signed-off-by: Ludovic Courtès --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index cc8c534787..c18505a681 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -27555,7 +27555,7 @@ Emacs that integrate with major modes like Org-mode.") (define-public emacs-modus-themes (package (name "emacs-modus-themes") - (version "2.3.2") + (version "2.3.3") (source (origin (method git-fetch) @@ -27564,7 +27564,7 @@ Emacs that integrate with major modes like Org-mode.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "00c3sa663rnl2rvnjdqzghcyfbdri09xjfigyrgd5xa3y0mnpqiz")))) + (base32 "14nfb94y9vcnpmwj9acwl6h5v0h1c6swqf33ch4zimxxqgx9zrm4")))) (native-inputs (list texinfo)) (build-system emacs-build-system) (arguments -- cgit v1.2.3 From 1a23c0a0c7a865e1d8c7443e714e1214fc2e2842 Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Fri, 22 Apr 2022 13:54:33 +0530 Subject: gnu: mumi: Use guile-json-4 instead of guile-json-3. * gnu/packages/mail.scm (mumi)[inputs]: Replace guile-json-3 with guile-json-4. --- gnu/packages/mail.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 5f8f27238f..cf251c6a88 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -4005,7 +4005,7 @@ It is a replacement for the @command{urlview} program.") (list guile-email-latest guile-fibers guile-gcrypt - guile-json-3 + guile-json-4 guile-kolam guile-redis guile-syntax-highlight -- cgit v1.2.3 From a2130bcf09af41e4f3e017a8b6118007a30fd2f2 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 9 May 2022 21:49:33 +0300 Subject: gnu: git-annex: Update inputs. * gnu/packages/haskell-apps.scm (git-annex)[inputs]: Add ghc-ansi-terminal, ghc-attoparsec, ghc-conduit, ghc-connection, ghc-http-client-tls, ghc-microlens, ghc-network-bsd, ghc-network-uri, ghc-transformers, ghc-unliftio-core, ghc-vector. Remove ghc-esqueleto, ghc-hslogger. --- gnu/packages/haskell-apps.scm | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/gnu/packages/haskell-apps.scm b/gnu/packages/haskell-apps.scm index f7ca3b324f..5579ef58ea 100644 --- a/gnu/packages/haskell-apps.scm +++ b/gnu/packages/haskell-apps.scm @@ -11,7 +11,7 @@ ;;; Copyright © 2015 Paul van der Walt ;;; Copyright © 2019, 2020 Kyle Meyer ;;; Copyright © 2015 John Soo -;;; Copyright © 2019, 2020 Efraim Flashner +;;; Copyright © 2019, 2020, 2022 Efraim Flashner ;;; Copyright © 2019, 2020 Alex Griffin ;;; Copyright © 2020 Alexandru-Sergiu Marton ;;; Copyright © 2020 Brian Leung @@ -404,12 +404,16 @@ to @code{cabal repl}).") (inputs (list curl ghc-aeson + ghc-ansi-terminal ghc-async + ghc-attoparsec ghc-aws ghc-bloomfilter ghc-byteable ghc-case-insensitive ghc-concurrent-output + ghc-conduit + ghc-connection ghc-crypto-api ghc-cryptonite ghc-data-default @@ -417,26 +421,28 @@ to @code{cabal repl}).") ghc-disk-free-space ghc-dlist ghc-edit-distance - ghc-esqueleto ghc-exceptions ghc-feed ghc-filepath-bytestring ghc-free ghc-hinotify - ghc-hslogger ghc-http-client + ghc-http-client-tls ghc-http-client-restricted ghc-http-conduit ghc-http-types ghc-ifelse ghc-magic ghc-memory + ghc-microlens ghc-monad-control ghc-monad-logger ghc-mountpoints ghc-network + ghc-network-bsd ghc-network-info ghc-network-multicast + ghc-network-uri ghc-old-locale ghc-optparse-applicative ghc-persistent @@ -454,10 +460,13 @@ to @code{cabal repl}).") ghc-stm-chans ghc-tagsoup ghc-torrent + ghc-transformers ghc-unix-compat + ghc-unliftio-core ghc-unordered-containers ghc-utf8-string ghc-uuid + ghc-vector git rsync)) (native-inputs -- cgit v1.2.3 From 0ec70c2c79893114ea558a9c4d3cc3610dba8b19 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 9 May 2022 23:10:02 +0300 Subject: gnu: mujs: Update to 1.2.0. * gnu/packages/javascript.scm (mujs): Update to 1.2.0. [source]: Add snippet to remove generated files. --- gnu/packages/javascript.scm | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm index 68d338de8d..70c1b11dd1 100644 --- a/gnu/packages/javascript.scm +++ b/gnu/packages/javascript.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2017 Arun Isaac ;;; Copyright © 2017, 2019, 2020, 2022 Ricardo Wurmus ;;; Copyright © 2017, 2018, 2020, 2021 Tobias Geerinckx-Rice -;;; Copyright © 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2017, 2018, 2019, 2020, 2022 Efraim Flashner ;;; Copyright © 2018 Nicolas Goaziou ;;; Copyright © 2021 Pierre Neidhardt ;;; Copyright © 2021 Maxim Cournoyer @@ -34,6 +34,7 @@ #:use-module (gnu packages readline) #:use-module (gnu packages uglifyjs) #:use-module (gnu packages web) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) @@ -681,7 +682,7 @@ external server.") (define-public mujs (package (name "mujs") - (version "1.1.3") + (version "1.2.0") (source (origin (method git-fetch) @@ -690,7 +691,14 @@ external server.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0qizld89qw24i9v6i2j9cxjyqn425xbiqfp1b7qfrkyxqkn0byws")))) + (base32 "0kqw3xhjk4l2jar14a1f9b3m0xq0h2g3nc9m6hsdv7kf8jhfm83l")) + (snippet + #~(begin + (use-modules (guix build utils)) + (for-each delete-file + (list "astnames.h" + "opnames.h" + "one.c")))))) (build-system gnu-build-system) (arguments `(#:phases -- cgit v1.2.3 From 05d4f2435b32b1d91c4b4589ba7c6571e180e2b6 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 9 May 2022 23:13:27 +0300 Subject: gnu: mujs: Use G-expressions. * gnu/packages/javascript.scm (mujs)[arguments]: Rewrite using G-expressions. --- gnu/packages/javascript.scm | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm index 70c1b11dd1..8ab8c46cd3 100644 --- a/gnu/packages/javascript.scm +++ b/gnu/packages/javascript.scm @@ -701,16 +701,17 @@ external server.") "one.c")))))) (build-system gnu-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (delete 'configure) ; no configure script - (replace 'install - (lambda* (#:key (make-flags '()) #:allow-other-keys) - (apply invoke "make" "install-shared" make-flags)))) + (list + #:phases + #~(modify-phases %standard-phases + (delete 'configure) ; no configure script + (replace 'install + (lambda* (#:key (make-flags '()) #:allow-other-keys) + (apply invoke "make" "install-shared" make-flags)))) #:make-flags - (list ,(string-append "VERSION=" version) - ,(string-append "CC=" (cc-for-target)) - (string-append "prefix=" (assoc-ref %outputs "out"))) + #~(list (string-append "VERSION=" #$version) + (string-append "CC=" #$(cc-for-target)) + (string-append "prefix=" #$output)) #:tests? #f)) ; no tests (inputs (list readline)) -- cgit v1.2.3 From c438809bc460ddb32c895505ebd0ed17031c634d Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 9 May 2022 23:23:19 +0300 Subject: gnu: mupdf: Update to 1.19.1. * gnu/packages/pdf.scm (mupdf): Update to 1.19.1. [source]: Remove trailing #t. --- gnu/packages/pdf.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/pdf.scm b/gnu/packages/pdf.scm index 74c6166cc0..39c428d071 100644 --- a/gnu/packages/pdf.scm +++ b/gnu/packages/pdf.scm @@ -704,14 +704,14 @@ extracting content or merging files.") (define-public mupdf (package (name "mupdf") - (version "1.19.0") + (version "1.19.1") (source (origin (method url-fetch) (uri (string-append "https://mupdf.com/downloads/archive/" "mupdf-" version "-source.tar.xz")) (sha256 - (base32 "1i98xqgnzp168hnnhradl8658qsif06wlbvcglz0mmh8wi1rkwrq")) + (base32 "0gl0wf16m1cafs20h3v1f4ysf7zlbijjyd6s1r1krwvlzriwdsmm")) (modules '((guix build utils))) (snippet '(begin @@ -725,8 +725,7 @@ extracting content or merging files.") (string-append kept "/" file))) keep) (delete-file-recursively from) - (rename-file kept from)) - #t)))) + (rename-file kept from)))))) (build-system gnu-build-system) (inputs `(("curl" ,curl) -- cgit v1.2.3 From 489dba600be96b3e28187d8afa1ddc07de0d3238 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 9 May 2022 23:24:15 +0300 Subject: gnu: mupdf: Remove input labels. * gnu/packages/pdf.scm (mupdf)[inputs]: Remove input labels. --- gnu/packages/pdf.scm | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/gnu/packages/pdf.scm b/gnu/packages/pdf.scm index 39c428d071..7bf3654a6f 100644 --- a/gnu/packages/pdf.scm +++ b/gnu/packages/pdf.scm @@ -728,19 +728,19 @@ extracting content or merging files.") (rename-file kept from)))))) (build-system gnu-build-system) (inputs - `(("curl" ,curl) - ("freeglut" ,freeglut) - ("freetype" ,freetype) - ("gumbo-parser" ,gumbo-parser) - ("harfbuzz" ,harfbuzz) - ("jbig2dec" ,jbig2dec) - ("libjpeg" ,libjpeg-turbo) - ("libx11" ,libx11) - ("libxext" ,libxext) - ("mujs" ,mujs) - ("openjpeg" ,openjpeg) - ("openssl" ,openssl) - ("zlib" ,zlib))) + (list curl + freeglut + freetype + gumbo-parser + harfbuzz + jbig2dec + libjpeg-turbo + libx11 + libxext + mujs + openjpeg + openssl + zlib)) (native-inputs (list pkg-config)) (arguments -- cgit v1.2.3 From f7da6b0be5b7c06d9a648085c550a7dd38f7913d Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 9 May 2022 23:27:47 +0300 Subject: gnu: mupdf: Use G-expressions. * gnu/packages/pdf.scm (mupdf)[source, arguments]: Rewrite using G-expressions. --- gnu/packages/pdf.scm | 55 +++++++++++++++++++++++++++------------------------- 1 file changed, 29 insertions(+), 26 deletions(-) diff --git a/gnu/packages/pdf.scm b/gnu/packages/pdf.scm index 7bf3654a6f..5963401975 100644 --- a/gnu/packages/pdf.scm +++ b/gnu/packages/pdf.scm @@ -714,18 +714,19 @@ extracting content or merging files.") (base32 "0gl0wf16m1cafs20h3v1f4ysf7zlbijjyd6s1r1krwvlzriwdsmm")) (modules '((guix build utils))) (snippet - '(begin - ;; Remove bundled software. - (let* ((keep (list "extract" - "lcms2")) ; different from our lcms2 package - (from "thirdparty") - (kept (string-append from "~temp"))) - (mkdir-p kept) - (for-each (lambda (file) (rename-file (string-append from "/" file) - (string-append kept "/" file))) - keep) - (delete-file-recursively from) - (rename-file kept from)))))) + #~(begin + ;; Remove bundled software. + (let* ((keep (list "extract" + "lcms2")) ; different from our lcms2 package + (from "thirdparty") + (kept (string-append from "~temp"))) + (mkdir-p kept) + (for-each (lambda (file) + (rename-file (string-append from "/" file) + (string-append kept "/" file))) + keep) + (delete-file-recursively from) + (rename-file kept from)))))) (build-system gnu-build-system) (inputs (list curl @@ -742,21 +743,23 @@ extracting content or merging files.") openssl zlib)) (native-inputs - (list pkg-config)) + (list pkg-config)) (arguments - `(#:tests? #f ; no check target - #:make-flags (list "verbose=yes" - (string-append "CC=" ,(cc-for-target)) - "XCFLAGS=-fpic" - "USE_SYSTEM_LIBS=yes" - "USE_SYSTEM_MUJS=yes" - "shared=yes" - ;; Even with the linkage patch we must fix RUNPATH. - (string-append "LDFLAGS=-Wl,-rpath=" - (assoc-ref %outputs "out") "/lib") - (string-append "prefix=" (assoc-ref %outputs "out"))) - #:phases (modify-phases %standard-phases - (delete 'configure)))) ; no configure script + (list + #:tests? #f ; no check target + #:make-flags + #~(list "verbose=yes" + (string-append "CC=" #$(cc-for-target)) + "XCFLAGS=-fpic" + "USE_SYSTEM_LIBS=yes" + "USE_SYSTEM_MUJS=yes" + "shared=yes" + ;; Even with the linkage patch we must fix RUNPATH. + (string-append "LDFLAGS=-Wl,-rpath=" #$output "/lib") + (string-append "prefix=" #$output)) + #:phases + #~(modify-phases %standard-phases + (delete 'configure)))) ; no configure script (home-page "https://mupdf.com") (synopsis "Lightweight PDF viewer and toolkit") (description -- cgit v1.2.3 From 37e44d48baf976f6bfcd885b2e10da4ab7be4af9 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 9 May 2022 23:41:50 +0300 Subject: gnu: parallel: Update to 20220422. * gnu/packages/parallel.scm (parallel): Update to 20220422. --- gnu/packages/parallel.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/parallel.scm b/gnu/packages/parallel.scm index 70f9e6dc4a..96e8cb5df4 100644 --- a/gnu/packages/parallel.scm +++ b/gnu/packages/parallel.scm @@ -62,14 +62,14 @@ (define-public parallel (package (name "parallel") - (version "20220322") + (version "20220422") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/parallel/parallel-" version ".tar.bz2")) (sha256 - (base32 "1n76lhw2sw21kj9hbd3pij9kwq460kpjl15p4qhssagmm7vcr4yz")))) + (base32 "19rwnxqbwbfhrrifyq5chsg6qgz9n8xf96l838agq0hkzwzvgr4n")))) (build-system gnu-build-system) (arguments `(#:phases -- cgit v1.2.3 From d775a24344d4a910f6a19072c595bdafcf104b6f Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 10 May 2022 11:13:45 +0300 Subject: gnu: openjdk12: Fix build. * gnu/packages/java.scm (openjdk12)[arguments]: Override inherited 'fix-java-shebangs phase. --- gnu/packages/java.scm | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index 3d05ef831e..97eae386de 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2017, 2019, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2018, 2019 Gábor Boskovits ;;; Copyright © 2018 Chris Marusich -;;; Copyright © 2018, 2019, 2020, 2021 Efraim Flashner +;;; Copyright © 2018, 2019, 2020, 2021, 2022 Efraim Flashner ;;; Copyright © 2019, 2020, 2021 Björn Höfling ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen ;;; Copyright © 2020 Raghav Gururajan @@ -2054,6 +2054,16 @@ new Date();")) `(begin (for-each delete-file (find-files "." ".*.(bin|exe|jar)$")) #t)))) + (arguments + (substitute-keyword-arguments (package-arguments openjdk11) + ((#:phases phases) + `(modify-phases ,phases + (replace 'fix-java-shebangs + (lambda _ + ;; This file was "fixed" by patch-source-shebangs, but it requires + ;; this exact first line. + (substitute* "make/data/blacklistedcertsconverter/blacklisted.certs.pem" + (("^#!.*") "#! java BlacklistedCertsConverter SHA-256\n")))))))) (inputs `(("alsa-lib" ,alsa-lib) ("cups" ,cups) -- cgit v1.2.3 From c37d14fbea86e6cfd5a883da05632ce544ba01d3 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Wed, 27 Apr 2022 13:46:07 -0500 Subject: gnu: Add ruby-sucker-punch * gnu/packages/ruby.scm (ruby-sucker-punch): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 5cc58d0052..1e21ad1e57 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12250,3 +12250,35 @@ functions for complex numbers. The functions in this module accept integers, floating-point numbers or complex numbers as arguments.") (home-page "https://github.com/ruby/cmath") (license license:bsd-2))) + +(define-public ruby-sucker-punch + (package + (name "ruby-sucker-punch") + (version "3.0.1") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "sucker_punch" version)) + (sha256 + (base32 "0yams24wndpj7dzdysvm4z1w6ggg4xvj4snxba66prahhxvik4xl")))) + (build-system ruby-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'extract-gemspec 'less-strict-dependencies + (lambda _ + (substitute* "sucker_punch.gemspec" + (("1.0.0") "1.0"))))))) + (native-inputs + (list + ruby-pry)) + (propagated-inputs + (list + ruby-concurrent)) + (home-page "https://github.com/brandonhilkert/sucker_punch") + (synopsis "Asynchronous processing library for Ruby") + (description "Sucker Punch is a single-process Ruby asynchronous processing +library. It is perfect for asynchronous processes like emailing, data crunching +or social platform manipulation; and generally recommended for jobs that are +fast and non-mission critical like logs, emails, etc.") + (license license:expat))) -- cgit v1.2.3 From 3ee6cb8d54845ca94c6370e3275a30f97a1db137 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 06:20:54 -0400 Subject: gnu: Add ruby-countdownlatch. * gnu/packages/ruby.scm (ruby-countdownlatch): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 1e21ad1e57..29f8456c7c 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12282,3 +12282,21 @@ library. It is perfect for asynchronous processes like emailing, data crunching or social platform manipulation; and generally recommended for jobs that are fast and non-mission critical like logs, emails, etc.") (license license:expat))) + +(define-public ruby-countdownlatch + (package + (name "ruby-countdownlatch") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "countdownlatch" version)) + (sha256 + (base32 "1v6pbay6z07fp7yvnba1hmyacbicvmjndd8rn2h1b5rmpcb5s0j3")))) + (build-system ruby-build-system) + (home-page "https://github.com/benlangfeld/countdownlatch") + (synopsis "Thread synchronization aid Ruby") + (description "CountDownLatch is a synchronization aid that allows one or +more threads to wait until a set of operations being performed in other threads +completes.") + (license license:expat))) -- cgit v1.2.3 From 22b9ac3f76a3d6970decbff29a999e118c4281b0 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 06:39:55 -0400 Subject: gnu: Add ruby-value-semantics. * gnu/packages/ruby.scm (ruby-value-semantics): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 29f8456c7c..817f9f614b 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12300,3 +12300,31 @@ fast and non-mission critical like logs, emails, etc.") more threads to wait until a set of operations being performed in other threads completes.") (license license:expat))) + +(define-public ruby-value-semantics + (package + (name "ruby-value-semantics") + (version "3.6.1") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "value_semantics" version)) + (sha256 + (base32 "1vdwai8wf6r1fkvdpyz1vzxm89q7ghjvb3pqpg2kvwibwzd99dnx")))) + (build-system ruby-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "rspec"))))))) + (native-inputs + (list + ruby-rspec)) + (home-page "https://github.com/tomdalling/value_semantics") + (synopsis "Ruby gem for making value classes") + (description "ValueSemantics generates modules that provide conventional +value semantics for a given set of attributes. The behaviour is similar to an +immutable Struct class, plus extensible, lightweight validation and coercion.") + (license license:expat))) -- cgit v1.2.3 From 0573e5962607f83b5d185ccedb6a37519e615fe5 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 10 May 2022 14:01:44 +0300 Subject: gnu: ncdu: Update to 1.17. * gnu/packages/ncdu.scm (ncdu): Update to 1.17. --- gnu/packages/ncdu.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/ncdu.scm b/gnu/packages/ncdu.scm index 45cae30e01..9f238c06e7 100644 --- a/gnu/packages/ncdu.scm +++ b/gnu/packages/ncdu.scm @@ -33,14 +33,14 @@ (define-public ncdu (package (name "ncdu") - (version "1.16") + (version "1.17") (source (origin (method url-fetch) (uri (string-append "https://dev.yorhel.nl/download/ncdu-" version ".tar.gz")) (sha256 (base32 - "1m0gk09jaz114piidiw8fkg0id5l6nhz1cg5nlaf1yl3l595g49b")))) + "1wfvdajln0iy7364nxkg4bpgdv8l3b6a9bnkhy67icqsxnl4a1w1")))) (build-system gnu-build-system) (inputs (list ncurses)) (synopsis "Ncurses-based disk usage analyzer") -- cgit v1.2.3 From 0ed219bb335b34f4ae3c1e28c923a0cfe9bd67ba Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 07:18:54 -0400 Subject: gnu: Add ruby-promise. * gnu/packages/ruby.scm (ruby-promise): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 817f9f614b..23526c2243 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12328,3 +12328,37 @@ completes.") value semantics for a given set of attributes. The behaviour is similar to an immutable Struct class, plus extensible, lightweight validation and coercion.") (license license:expat))) + +(define-public ruby-promise + (package + (name "ruby-promise") + (version "0.7.4") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "promise.rb" version)) + (sha256 + (base32 "0a819sikcqvhi8hck1y10d1nv2qkjvmmm553626fmrh51h2i089d")))) + (build-system ruby-build-system) + (arguments + `(#:test-target "spec" + #:phases + (modify-phases %standard-phases + (add-after 'extract-gemspec 'less-strict-dependencies + (lambda _ + (substitute* "Rakefile" + (("if Gem.ruby_version.*") "if false\n")) + (substitute* "spec/spec_helper.rb" + ((".*devtools/spec_helper.*") "\n"))))))) + (native-inputs + (list + ruby-rspec + ruby-rspec-its + ruby-awesome-print + ruby-fuubar)) + (home-page "https://github.com/lgierth/promise.rb") + (synopsis "Asynchronous operation library for Ruby") + (description "Promise is a Ruby implementation of the Promises/A+ +specification. It provides 100% mutation coverage, tested on MRI 1.9, 2.0, 2.1, +2.2, Rubinius, and JRuby.") + (license license:unlicense))) -- cgit v1.2.3 From 1cb87949d96ee919008fded192532a87c06b60be Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 07:33:32 -0400 Subject: gnu: Add ruby-multicodecs. * gnu/packages/ruby.scm (ruby-multicodecs): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 23526c2243..ebd2e088cc 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12362,3 +12362,21 @@ immutable Struct class, plus extensible, lightweight validation and coercion.") specification. It provides 100% mutation coverage, tested on MRI 1.9, 2.0, 2.1, 2.2, Rubinius, and JRuby.") (license license:unlicense))) + +(define-public ruby-multicodecs + (package + (name "ruby-multicodecs") + (version "0.2.1") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "multicodecs" version)) + (sha256 + (base32 "0drq267di57l9zqw6zvqqimilz42rbc8z7392dwkk8wslq30s7v8")))) + (build-system ruby-build-system) + (home-page "https://github.com/SleeplessByte/ruby-multicodec") + (synopsis "Ruby implementation of multiformats/multicodec") + (description "Multicodecs is the ruby implementation of +multiformats/multicodec, a canonical table of of codecs used by various +multiformats.") + (license license:expat))) -- cgit v1.2.3 From ad2f8ee1b233adfca8f97350598b7751480654c9 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 07:46:35 -0400 Subject: gnu: Add ruby-multihashes. * gnu/packages/ruby.scm (ruby-multihashes): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index ebd2e088cc..9b3a61041a 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12380,3 +12380,24 @@ specification. It provides 100% mutation coverage, tested on MRI 1.9, 2.0, 2.1, multiformats/multicodec, a canonical table of of codecs used by various multiformats.") (license license:expat))) + +(define-public ruby-multihashes + (package + (name "ruby-multihashes") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "multihashes" version)) + (sha256 + (base32 "17wiyy3fiv8rpgdv9ca01yncsmaaf8yg15bg18wc7m9frss1vgqg")))) + (build-system ruby-build-system) + (propagated-inputs + (list + ruby-multicodecs)) + (home-page "https://github.com/multiformats/ruby-multihash") + (synopsis "Multihash implementation for Ruby") + (description "Multihashes provides a simple, low-level multihash +implementation for Ruby. A multihash is a digest with an embedded hash function +code") + (license license:expat))) -- cgit v1.2.3 From dde2e36394a07a863339950e18f384f4f2ce69fd Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 08:05:22 -0400 Subject: gnu: Add ruby-lazy-object. * gnu/packages/ruby.scm (ruby-lazy-object): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 9b3a61041a..ff05f63662 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12401,3 +12401,22 @@ multiformats.") implementation for Ruby. A multihash is a digest with an embedded hash function code") (license license:expat))) + +(define-public ruby-lazy-object + (package + (name "ruby-lazy-object") + (version "0.0.3") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "lazy_object" version)) + (sha256 + (base32 "08px15lahc28ik9smvw1hgamf792gd6gq0s4k94yq1h7jq25wjn8")))) + (build-system ruby-build-system) + (arguments + `(#:test-target "spec")) + (home-page "https://github.com/HornsAndHooves/lazy_object") + (synopsis "Object wrapper that forwards all calls to the reference object") + (description "LazyObject is an object wrapper that forwards all calls to the +reference object. This object is not created until the first method dispatch.") + (license license:expat))) -- cgit v1.2.3 From 2d8daae3bdc98cfe739a26808b59579ee122ea39 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 10 May 2022 15:32:42 +0300 Subject: gnu: Add rust-thread-id-4. * gnu/packages/crates-io.scm (rust-thread-id-4): New variable. (rust-thread-id-3): Inherit from rust-thread-id-4. --- gnu/packages/crates-io.scm | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 54dfda90fa..c59ddca1c9 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -62368,23 +62368,22 @@ handle Unicode characters correctly.") @code{thiserror} crate.") (license (list license:expat license:asl2.0)))) -(define-public rust-thread-id-3 +(define-public rust-thread-id-4 (package (name "rust-thread-id") - (version "3.3.0") + (version "4.0.0") (source (origin (method url-fetch) (uri (crate-uri "thread-id" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "1h90v19fjz3x9b25ywh68z5yf2zsmm6h5zb4rl302ckbsp4z9yy7")))) + (base32 "0zvikdngp0950hi0jgiipr8l36rskk1wk7pc8cd43xr3g5if1psz")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-libc" ,rust-libc-0.2) - ("rust-redox-syscall" ,rust-redox-syscall-0.1) + ("rust-redox-syscall" ,rust-redox-syscall-0.2) ("rust-winapi" ,rust-winapi-0.3)))) (home-page "https://github.com/ruuda/thread-id") (synopsis "Get a unique ID for the current thread in Rust") @@ -62394,6 +62393,25 @@ different for every thread.") (license (list license:asl2.0 license:expat)))) +(define-public rust-thread-id-3 + (package + (inherit rust-thread-id-4) + (name "rust-thread-id") + (version "3.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "thread-id" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1h90v19fjz3x9b25ywh68z5yf2zsmm6h5zb4rl302ckbsp4z9yy7")))) + (arguments + `(#:cargo-inputs + (("rust-libc" ,rust-libc-0.2) + ("rust-redox-syscall" ,rust-redox-syscall-0.1) + ("rust-winapi" ,rust-winapi-0.3)))))) + (define-public rust-thread-id-2 (package (inherit rust-thread-id-3) -- cgit v1.2.3 From 25c66d69b274214ce1d1b9482bef087c39571b62 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 10 May 2022 15:22:58 +0300 Subject: gnu: rust-parking-lot-core-0.8: Fix dependencies. This is a follow-up to d16298196c23cf4d05c4010af399270a2dbbd831. * gnu/packages/crates-io.scm (rust-parking-lot-core-0.8)[arguments]: In cargo-inputs replace rust-cfg-if-0.1 with 1, rust-redox-syscall-0.1 with 0.2, rust-thread-id-3 with 4. Remove rust-cloudabi-0.1. --- gnu/packages/crates-io.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c59ddca1c9..67bb1fb993 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -40651,14 +40651,13 @@ synchronization primitives.") (arguments `(#:cargo-inputs (("rust-backtrace" ,rust-backtrace-0.3) - ("rust-cfg-if" ,rust-cfg-if-0.1) - ("rust-cloudabi" ,rust-cloudabi-0.1) + ("rust-cfg-if" ,rust-cfg-if-1) ("rust-instant" ,rust-instant-0.1) ("rust-libc" ,rust-libc-0.2) ("rust-petgraph" ,rust-petgraph-0.5) - ("rust-redox-syscall" ,rust-redox-syscall-0.1) + ("rust-redox-syscall" ,rust-redox-syscall-0.2) ("rust-smallvec" ,rust-smallvec-1) - ("rust-thread-id" ,rust-thread-id-3) + ("rust-thread-id" ,rust-thread-id-4) ("rust-winapi" ,rust-winapi-0.3)))) (home-page "https://github.com/Amanieu/parking_lot") (synopsis "API for creating custom synchronization primitives") -- cgit v1.2.3 From 000a620d17965cf7b6fd22c2387c5db477f5e8db Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 10 May 2022 15:25:58 +0300 Subject: gnu: rust-parking-lot-0.11: Fix dependencies. This is a follow-up to f02f8db3810b5c304bce98df9be4c809e13861de. * gnu/packages/crates-io.scm (rust-parking-lot-0.11)[arguments]: In cargo-development-inputs replace rust-rand-0.7 with 0.8. --- gnu/packages/crates-io.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 67bb1fb993..12ba102da5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -40523,7 +40523,7 @@ unparking.") ("rust-parking-lot-core" ,rust-parking-lot-core-0.8)) #:cargo-development-inputs (("rust-bincode" ,rust-bincode-1) - ("rust-rand" ,rust-rand-0.7)))) + ("rust-rand" ,rust-rand-0.8)))) (home-page "https://github.com/Amanieu/parking_lot") (synopsis "Efficient implementations of the standard synchronization primitives") -- cgit v1.2.3 From 956ca540dc8d2e2fc10f0202cd78ecba5edd21f0 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 08:57:15 -0400 Subject: gnu: Add ruby-citrus. * gnu/packages/ruby.scm (ruby-citrus): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index ff05f63662..ffc7ad3bec 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12420,3 +12420,25 @@ code") (description "LazyObject is an object wrapper that forwards all calls to the reference object. This object is not created until the first method dispatch.") (license license:expat))) + +(define-public ruby-citrus + (package + (name "ruby-citrus") + (version "3.0.2") + (source + (origin + (method git-fetch) + ;; Download from GitHub because the rubygems version does not contain + ;; files needed for tests. + (uri (git-reference + (url "https://github.com/mjackson/citrus") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "197wrgqrddgm1xs3yvjvd8vkvil4h4mdrcp16jmd4b57rxrrr769")))) + (build-system ruby-build-system) + (home-page "http://mjackson.github.io/citrus/") + (synopsis "Parsing Expressions for Ruby") + (description "Citrus is a parsing library for Ruby that combines the +expressiveness of the language with the parsing expressions.") + (license license:expat))) -- cgit v1.2.3 From 7455ed8e520b6a3853b1495a4ae19553bf1e8813 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 09:12:41 -0400 Subject: gnu: Add ruby-cbor. * gnu/packages/ruby.scm (ruby-cbor): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index ffc7ad3bec..75f31a3101 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12442,3 +12442,28 @@ reference object. This object is not created until the first method dispatch.") (description "Citrus is a parsing library for Ruby that combines the expressiveness of the language with the parsing expressions.") (license license:expat))) + +(define-public ruby-cbor + (package + (name "ruby-cbor") + (version "0.5.9.6") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "cbor" version)) + (sha256 + (base32 "0511idr8xps9625nh3kxr68sdy6l3xy2kcz7r57g47fxb1v18jj3")))) + (build-system ruby-build-system) + (arguments + `(#:test-target "spec")) + (native-inputs + (list + ruby-rspec + ruby-rake-compiler + ruby-yard)) + (home-page "http://cbor.io/") + (synopsis "Concise Binary Object Representation") + (description "CBOR is a library for the +@acronym{CBOR, Concise Binary Object Representation} format, based on +Sadayuki Furuhashi's MessagePack library.") + (license license:asl2.0))) -- cgit v1.2.3 From 9b21f4b6692f846b97cdb91b1b7564716ad83b25 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 09:26:56 -0400 Subject: gnu: Add ruby-gem-release. * gnu/packages/ruby.scm (ruby-gem-release): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 75f31a3101..0a90398e30 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12467,3 +12467,24 @@ expressiveness of the language with the parsing expressions.") @acronym{CBOR, Concise Binary Object Representation} format, based on Sadayuki Furuhashi's MessagePack library.") (license license:asl2.0))) + +(define-public ruby-gem-release + (package + (name "ruby-gem-release") + (version "2.2.2") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "gem-release" version)) + (sha256 + (base32 "108rrfaiayi14zrqbb6z0cbwcxh8n15am5ry2a86v7c8c3niysq9")))) + (build-system ruby-build-system) + (arguments + ;; No rakefile + `(#:tests? #f)) + (home-page "https://github.com/svenfuchs/gem-release") + (synopsis "Ruby gem plugin for release management") + (description "GemRelease is a gem plugin that aims at making gem development +easier by automating repetitive work based on conventions, configuration, and +templates.") + (license license:expat))) -- cgit v1.2.3 From 0f705472126f7b935e0783bcd8fec831b7a0593b Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 09:55:06 -0400 Subject: gnu: Add ruby-base32. * gnu/packages/ruby.scm (ruby-base32): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 0a90398e30..15f875f976 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12488,3 +12488,23 @@ Sadayuki Furuhashi's MessagePack library.") easier by automating repetitive work based on conventions, configuration, and templates.") (license license:expat))) + +(define-public ruby-base32 + (package + (name "ruby-base32") + (version "0.3.4") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "base32" version)) + (sha256 + (base32 "1fjs0l3c5g9qxwp43kcnhc45slx29yjb6m6jxbb2x1krgjmi166b")))) + (build-system ruby-build-system) + (native-inputs + (list + ruby-gem-release)) + (home-page "https://github.com/stesla/base32") + (synopsis "Ruby extension for base32 encoding and decoding") + (description "Base32 is a library which provides base32 decoding and +encoding.") + (license license:expat))) -- cgit v1.2.3 From 9d349c01d82196bd56da0e4981b6949836a50cd4 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 1 May 2022 02:00:01 +0200 Subject: gnu: memcached: Update to 1.6.15. * gnu/packages/databases.scm (memcached): Update to 1.6.15. --- gnu/packages/databases.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 90fbd14844..438cb3b22f 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -23,7 +23,7 @@ ;;; Copyright © 2017 Jelle Licht ;;; Copyright © 2017 Adriano Peluso ;;; Copyright © 2017, 2021 Arun Isaac -;;; Copyright © 2017–2021 Tobias Geerinckx-Rice +;;; Copyright © 2017–2022 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2018 Alex Vong ;;; Copyright © 2017, 2018 Ben Woodcroft ;;; Copyright © 2017 Rutger Helling @@ -515,14 +515,14 @@ mapping from string keys to string values.") (define-public memcached (package (name "memcached") - (version "1.6.13") + (version "1.6.15") (source (origin (method url-fetch) (uri (string-append "https://memcached.org/files/memcached-" version ".tar.gz")) (sha256 - (base32 "1m5mhw9ybb8qcyi6hb5kwpqanqmlnz27r54ccabc4y7nhpfvl6mx")))) + (base32 "05fmds73hr71bha9gszjfp02lgyacqfyyhkgl6xysy4kchyvwyld")))) (build-system gnu-build-system) (inputs (list libevent cyrus-sasl)) -- cgit v1.2.3 From 38028fdf9520ee9544afcb89ae2ab840dbc261b8 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:03 +0200 Subject: gnu: recutils: Update to 1.9. * gnu/packages/databases.scm (recutils): Update to 1.9. --- gnu/packages/databases.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 438cb3b22f..5e08c8bcdb 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -1559,14 +1559,14 @@ organized in a hash table or B+ tree.") (define-public recutils (package (name "recutils") - (version "1.8") + (version "1.9") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/recutils/recutils-" version ".tar.gz")) (sha256 (base32 - "14xiln4immfsw8isnvwvq0h23f6z0wilpgsc4qzabnrzb5lsx3nz")))) + "03kf91f20brn2ffljfjzirxh5xj99m1mvvspcx2lph9000mmj0b3")))) (build-system gnu-build-system) (arguments '(#:configure-flags -- cgit v1.2.3 From 1115428bbb8f838eb4c06e39a129d85fa28eed25 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: recutils: Omit static libraries. * gnu/packages/databases.scm (recutils)[arguments]: Add "--disable-static" to #:configure-flags. --- gnu/packages/databases.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 5e08c8bcdb..b7cbfa6536 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -1570,7 +1570,8 @@ organized in a hash table or B+ tree.") (build-system gnu-build-system) (arguments '(#:configure-flags - (list (string-append "--with-bash-headers=" + (list "--disable-static" + (string-append "--with-bash-headers=" (assoc-ref %build-inputs "bash:include") "/include/bash")))) -- cgit v1.2.3 From 605b1f776446df7b681394af88dacf0ef3c837b4 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:02 +0200 Subject: gnu: dovecot: Update to 2.3.19. * gnu/packages/mail.scm (dovecot): Update to 2.3.19. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index cf251c6a88..13bb083fc4 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -1890,7 +1890,7 @@ facilities for checking incoming mail.") (package (name "dovecot") ;; Also update dovecot-pigeonhole when updating to a new minor version. - (version "2.3.18") + (version "2.3.19") (source (origin (method url-fetch) @@ -1898,7 +1898,7 @@ facilities for checking incoming mail.") (version-major+minor version) "/" "dovecot-" version ".tar.gz")) (sha256 - (base32 "0cvcbp6f5i8sg2sz8d3j654xrf4a74h7rszfpm2kq2bciik3zrq6")))) + (base32 "0ys3zq9b1rgj1cz6a0i9l421y6h2j3b5zak2ia5j9dj1sj9zcwq1")))) (build-system gnu-build-system) (native-inputs (list pkg-config)) -- cgit v1.2.3 From b6b504d64ff8392a6eb4eb40562b8018410d50b2 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: dovecot-pigeonhole: Update to 0.5.19. * gnu/packages/mail.scm (dovecot-pigeonhole): Update to 0.5.19. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 13bb083fc4..c4ccc53e84 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -1958,7 +1958,7 @@ It supports mbox/Maildir and its own dbox/mdbox formats.") (let ((dovecot-version (version-major+minor (package-version dovecot)))) (package (name "dovecot-pigeonhole") - (version "0.5.18") + (version "0.5.19") (source (origin (method url-fetch) @@ -1966,7 +1966,7 @@ It supports mbox/Maildir and its own dbox/mdbox formats.") "https://pigeonhole.dovecot.org/releases/" dovecot-version "/" "dovecot-" dovecot-version "-pigeonhole-" version ".tar.gz")) (sha256 - (base32 "198865a9fv9a8gj8lsp4jjylalm6qzjyqhsk22jwpppjsvw2in56")) + (base32 "033kkhby9k9yrmgvlfmyzp8fccsw5bhq1dyvxj94sg3grkpj7f8h")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From a2a97b10ca316ce6f604b8f81b74121d1e8c484b Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: font-adobe-source-sans-pro: Update to 3.046R. * gnu/packages/fonts.scm (font-adobe-source-sans-pro): Update to 3.046R. --- gnu/packages/fonts.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index 1973f243d4..97c3b5ec0c 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2016, 2020 Marius Bakke ;;; Copyright © 2016 Toni Reina -;;; Copyright © 2017–2021 Tobias Geerinckx-Rice +;;; Copyright © 2017–2022 Tobias Geerinckx-Rice ;;; Copyright © 2017 José Miguel Sánchez García ;;; Copyright © 2017 Alex Griffin ;;; Copyright © 2017 Clément Lassieur @@ -1003,7 +1003,7 @@ designed to work well in user interface environments.") (define-public font-adobe-source-sans-pro (package (name "font-adobe-source-sans-pro") - (version "3.028R") + (version "3.046R") (source (origin (method git-fetch) @@ -1012,7 +1012,7 @@ designed to work well in user interface environments.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0lgjqi4d5p1q1z00ad807v5qy4z54gmp7jpdaypc0rxk8czv6zq7")))) + (base32 "01dnhyfffnlyjzyh40x2z728qpc4i0jvrcxdcjfm17zrwhmw84lw")))) (build-system font-build-system) (home-page "https://github.com/adobe-fonts/source-sans-pro") (synopsis -- cgit v1.2.3 From d798e5b6c1522336438134b1034bb66323ebb3f2 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:00 +0200 Subject: gnu: parted: Update to 3.5. * gnu/packages/disk.scm (parted): Update to 3.5. --- gnu/packages/disk.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/disk.scm b/gnu/packages/disk.scm index d03c915f9d..d05737b6c3 100644 --- a/gnu/packages/disk.scm +++ b/gnu/packages/disk.scm @@ -236,14 +236,14 @@ tmpfs/ramfs filesystems.") (define-public parted (package (name "parted") - (version "3.4") + (version "3.5") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/parted/parted-" version ".tar.xz")) (sha256 (base32 - "0hjkv84x1bs2qqyx1fnzjqyyqrhv7kpdbq9bgydmi99d8wi80ag1")))) + "18h51i3x5cbqhlj5rm23m9sfw63gaaby5czln5w6qpqj3ifdsf29")))) (build-system gnu-build-system) (arguments `(#:phases -- cgit v1.2.3 From 9a867c26b0138dcdb5bf79bad4b8a342498db78a Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:03 +0200 Subject: gnu: parted: Use G-expressions & new input style. * gnu/packages/disk.scm (parted) [arguments]: Rewrite as G-expressions. [native-inputs]: Remove input labels. --- gnu/packages/disk.scm | 29 ++++++++++++++--------------- 1 file changed, 14 insertions(+), 15 deletions(-) diff --git a/gnu/packages/disk.scm b/gnu/packages/disk.scm index d05737b6c3..2a583c64c1 100644 --- a/gnu/packages/disk.scm +++ b/gnu/packages/disk.scm @@ -246,26 +246,25 @@ tmpfs/ramfs filesystems.") "18h51i3x5cbqhlj5rm23m9sfw63gaaby5czln5w6qpqj3ifdsf29")))) (build-system gnu-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-locales-and-python - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "tests/t0251-gpt-unicode.sh" - (("C.UTF-8") "en_US.utf8")) ;not in Glibc locales - (substitute* "tests/msdos-overlap" - (("/usr/bin/python") (which "python"))) - #t))))) + (list #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-locales-and-python + (lambda _ + (substitute* "tests/t0251-gpt-unicode.sh" + (("C.UTF-8") "en_US.utf8")) ;not in Glibc locales + (substitute* "tests/msdos-overlap" + (("/usr/bin/python") (which "python")))))))) (inputs (list lvm2 readline `(,util-linux "lib"))) (native-inputs - `(("gettext" ,gettext-minimal) + (list gettext-minimal - ;; For the tests. - ("e2fsprogs" ,e2fsprogs) - ("perl" ,perl) - ("python-wrapper" ,python-wrapper) - ("util-linux" ,util-linux))) + ;; For the tests. + e2fsprogs + perl + python-wrapper + util-linux)) (home-page "https://www.gnu.org/software/parted/") (synopsis "Disk partition editor") (description -- cgit v1.2.3 From dda07b2cbc9875b4a7ce290a867935313b2e88fd Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 10:37:02 -0400 Subject: gnu: Add ruby-dhall. * gnu/packages/ruby.scm (ruby-dhall): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 15f875f976..76dd78709f 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12508,3 +12508,33 @@ templates.") (description "Base32 is a library which provides base32 decoding and encoding.") (license license:expat))) + +(define-public ruby-dhall + (package + (name "ruby-dhall") + (version "0.5.2") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "dhall" version)) + (sha256 + (base32 "09wcq8xc1ynld04r2f332bx8cn7rjc4afaq8hm1dr2fc35jlpn6m")))) + (build-system ruby-build-system) + (arguments + ;; No test in gem archive + `(#:tests? #f)) + (propagated-inputs + (list + ruby-base32 + ruby-cbor + ruby-citrus + ruby-lazy-object + ruby-multihashes + ruby-promise + ruby-value-semantics)) + (home-page "https://git.sr.ht/~singpolyma/dhall-ruby") + (synopsis "Ruby implementation of the Dhall configuration language") + (description "Dhall.rb is a Ruby implementation of the Dhall configuration +language. Dhall is a memory safe and non-Turing-complete configuration +language.") + (license license:gpl3+))) -- cgit v1.2.3 From 9d795fb8fd3feffe584462cdfe3869acee64d226 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 11:04:13 -0400 Subject: gnu: Add ruby-money. * gnu/packages/ruby.scm (ruby-money): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 76dd78709f..cda56bf6d6 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12538,3 +12538,41 @@ encoding.") language. Dhall is a memory safe and non-Turing-complete configuration language.") (license license:gpl3+))) + +(define-public ruby-money + (package + (name "ruby-money") + (version "6.16.0") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "money" version)) + (sha256 + (base32 "0jkmsj5ymadik7bvl670bqwmvhsdyv7hjr8gq9z293hq35gnyiyg")))) + (build-system ruby-build-system) + (arguments + ;; No rakefile. + `(#:tests? #f)) + (propagated-inputs + (list + ruby-i18n)) + (home-page "https://rubymoney.github.io/money/") + (synopsis "Currency conversion library for Ruby") + (description "RubyMoney provides a library for dealing with money and +currency conversion. Its features are: +@itemize +@item +Provides a Money class which encapsulates all information about a certain +amount of money, such as its value and its currency. +@item +Provides a Money::Currency class which encapsulates all information about a +monetary unit. +@item +Represents monetary values as integers, in cents; so avoids floating point +rounding errors. +@item +Represents currency as Money::Currency instances providing a high level of +flexibility. +@item Provides APIs for exchanging money from one currency to another. +@end itemize") + (license license:expat))) -- cgit v1.2.3 From 427afa650170133c4888878f55d245d8047c58e2 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Wed, 11 May 2022 00:20:18 +0200 Subject: gnu: rust-parking-lot-core@0.8: Fix compilation. Fixes a build failure introduced in d16298196c23cf4d05c4010af399270a2dbbd831. This is a followup to 25c66d69b274214ce1d1b9482bef087c39571b62. * gnu/packages/crates-io.scm (rust-parking-lot-core-0.8): Add 'relax-dependencies' phase. --- gnu/packages/crates-io.scm | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 12ba102da5..cf8fc9a2ca 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -40658,7 +40658,15 @@ synchronization primitives.") ("rust-redox-syscall" ,rust-redox-syscall-0.2) ("rust-smallvec" ,rust-smallvec-1) ("rust-thread-id" ,rust-thread-id-4) - ("rust-winapi" ,rust-winapi-0.3)))) + ("rust-winapi" ,rust-winapi-0.3)) + #:phases (modify-phases %standard-phases + (add-after 'unpack 'relax-dependencies + (lambda _ + ;; XXX: The file demands 0.3.60; we have 0.3.56, but + ;; that works well, really. + (substitute* "Cargo.toml" + (("0\\.3\\.60") + ,(package-version rust-backtrace-0.3)))))))) (home-page "https://github.com/Amanieu/parking_lot") (synopsis "API for creating custom synchronization primitives") (description "This package provides an advanced API for creating custom -- cgit v1.2.3 From dba78c32a7ad26b1210e4471b9cb4be4d2ea74e3 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Wed, 11 May 2022 00:22:15 +0200 Subject: gnu: python-cryptography: Bump 'rust-redox-syscall' dependency. Fixes a build failure. * gnu/packages/python-crypto.scm (python-cryptography): Replace 'rust-redox-syscall-0.1' with 'rust-redox-syscall-0.2'. --- gnu/packages/python-crypto.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/python-crypto.scm b/gnu/packages/python-crypto.scm index 2e16392c9d..08b86335c0 100644 --- a/gnu/packages/python-crypto.scm +++ b/gnu/packages/python-crypto.scm @@ -650,7 +650,7 @@ message digests and key derivation functions.") rust-pyo3-macros-0.15 rust-pyo3-macros-backend-0.15 rust-quote-1 - rust-redox-syscall-0.1 + rust-redox-syscall-0.2 rust-scopeguard-1 rust-smallvec-1 rust-stable-deref-trait-1 -- cgit v1.2.3 From b9365c163d53d28072ad27cc353d224b9df7814e Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 11:56:07 -0400 Subject: gnu: Add ruby-monetize. * gnu/packages/ruby.scm (ruby-monetize): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index cda56bf6d6..78579c01f4 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12576,3 +12576,28 @@ flexibility. @item Provides APIs for exchanging money from one currency to another. @end itemize") (license license:expat))) + +(define-public ruby-monetize + (package + (name "ruby-monetize") + (version "1.11.0") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "monetize" version)) + (sha256 + (base32 "0cna2myxdbwfq0gn6k2hgrh368dq7wld3jklm96443ysykd0difn")))) + (build-system ruby-build-system) + (arguments + `(#:test-target "spec")) + (native-inputs + (list + ruby-rspec)) + (propagated-inputs + (list + ruby-money)) + (home-page "https://github.com/RubyMoney/monetize") + (synopsis "Convert various objects into Money objects") + (description "Monetize provides a library for converting various objects +into Money objects.") + (license license:expat))) -- cgit v1.2.3 From 57baf246e88b1eb78a1f106cb658cd1d47b5b24b Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 10 May 2022 22:13:52 -0400 Subject: gnu: Add ruby-money-open-exchange-rates. * gnu/packages/ruby.scm (ruby-money-open-exchange-rates): New variable. Signed-off-by: Raghav Gururajan --- gnu/packages/ruby.scm | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 78579c01f4..54dcae9089 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -12601,3 +12601,37 @@ flexibility. (description "Monetize provides a library for converting various objects into Money objects.") (license license:expat))) + +(define-public ruby-money-open-exchange-rates + (package + (name "ruby-money-open-exchange-rates") + (version "1.4.0") + (source + (origin + (method git-fetch) + ;; Download from GitHub because the rubygems version does not contain + ;; Rakefile. + (uri (git-reference + (url "https://github.com/spk/money-open-exchange-rates") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "11xwqli8snr19k48yh8h77sal5vxd4snzq9gxg08v61f0574m3gw")))) + (build-system ruby-build-system) + (native-inputs + (list + ruby-minitest + ruby-mocha + ruby-monetize + ruby-rake + ruby-rubocop + ruby-timecop + ruby-webmock)) + (propagated-inputs + (list + ruby-money)) + (home-page "https://spk.github.io/money-open-exchange-rates/") + (synopsis "Money open exchange rates for Ruby") + (description "This package provides a gem that calculates the exchange rate +using published rates from open-exchange-rates. Compatible with the money gem.") + (license license:expat))) -- cgit v1.2.3 From aaa981f7c57c1a09a32137b9a4e059ab8e91a1c9 Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Sat, 7 May 2022 15:00:16 +0530 Subject: gnu: cwltool: Do not propagate inputs. * gnu/packages/bioinformatics.scm (cwltool)[propagated-inputs]: Move to ... [inputs]: ... here. --- gnu/packages/bioinformatics.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index ca6c1eba19..28b3be2308 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -3009,7 +3009,7 @@ and record oriented data modeling and the Semantic Web.") ;; Pytest doesn't know what to do with "-n auto" (substitute* "tox.ini" (("-n auto") ""))))))) - (propagated-inputs + (inputs (list python-argcomplete python-bagit python-coloredlogs -- cgit v1.2.3 From ef1d3d44d0f53917772cdb42f4dc380baec4eb7c Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 11 May 2022 09:41:56 +0300 Subject: gnu: rust-parking-lot-core-0.8: Move code changes to snippet. This allows the changes to propagate through the cargo-build-system. * gnu/packages/crates-io.scm (rust-parking-lot-core-0.8)[source]: Add snippet to relax version dependencies. [arguments]: Remove 'relax-dependencies phase. --- gnu/packages/crates-io.scm | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index cf8fc9a2ca..2b67033775 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -40646,7 +40646,14 @@ synchronization primitives.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 - "08n7w09q6b2prvazbzgwrc9ml7aaf8yg3132ifsayrkwy1nwwzs6")))) + "08n7w09q6b2prvazbzgwrc9ml7aaf8yg3132ifsayrkwy1nwwzs6")) + (modules '((guix build utils))) + (snippet + '(begin + ;; XXX: The file demands 0.3.60; we have 0.3.56, but + ;; that works well, really. + (substitute* "Cargo.toml" + (("0\\.3\\.60") "0.3.56")))))) (build-system cargo-build-system) (arguments `(#:cargo-inputs @@ -40658,15 +40665,7 @@ synchronization primitives.") ("rust-redox-syscall" ,rust-redox-syscall-0.2) ("rust-smallvec" ,rust-smallvec-1) ("rust-thread-id" ,rust-thread-id-4) - ("rust-winapi" ,rust-winapi-0.3)) - #:phases (modify-phases %standard-phases - (add-after 'unpack 'relax-dependencies - (lambda _ - ;; XXX: The file demands 0.3.60; we have 0.3.56, but - ;; that works well, really. - (substitute* "Cargo.toml" - (("0\\.3\\.60") - ,(package-version rust-backtrace-0.3)))))))) + ("rust-winapi" ,rust-winapi-0.3)))) (home-page "https://github.com/Amanieu/parking_lot") (synopsis "API for creating custom synchronization primitives") (description "This package provides an advanced API for creating custom -- cgit v1.2.3 From f0ce201f499b075e1e0248d91c97c30469e84407 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 11 May 2022 10:03:36 +0300 Subject: gnu: rust-proc-macro-error-1: Move code changes to snippet. * gnu/packages/crates-io.scm (rust-proc-macro-error-1)[arguments]: Move code relaxing version requirements from custom phase ... [source]: ... to a snippet. --- gnu/packages/crates-io.scm | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2b67033775..84f09f2da7 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -44645,11 +44645,17 @@ renamed in @file{Cargo.toml}.") (uri (crate-uri "proc-macro-error" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "1373bhxaf0pagd8zkyd03kkx6bchzf6g0dkwrwzsnal9z47lj9fs")))) + (base32 "1373bhxaf0pagd8zkyd03kkx6bchzf6g0dkwrwzsnal9z47lj9fs")) + (modules '((guix build utils))) + (snippet + '(begin + ;; Ignore the "DO NOT BUMP" warning. + (substitute* "Cargo.toml" + (("=1.0.107") "^1.0.107") + (("=0.5.2") "^0.5.2")))))) (build-system cargo-build-system) (arguments - ;; Tests fail with "extern crate test_crate; <-- can't find crate" error. - `(#:tests? #f + `(#:tests? #f ; 'test_crate' folder not included in release. #:cargo-inputs (("rust-proc-macro-error-attr" ,rust-proc-macro-error-attr-1) ("rust-proc-macro2" ,rust-proc-macro2-1) @@ -44659,14 +44665,7 @@ renamed in @file{Cargo.toml}.") #:cargo-development-inputs (("rust-serde-derive" ,rust-serde-derive-1) ("rust-toml" ,rust-toml-0.5) - ("rust-trybuild" ,rust-trybuild-1)) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-version-requirements - (lambda _ - (substitute* "Cargo.toml" - (("1.0.107") ,(package-version rust-serde-derive-1)) - (("0.5.2") ,(package-version rust-toml-0.5)))))))) + ("rust-trybuild" ,rust-trybuild-1)))) (home-page "https://gitlab.com/CreepySkeleton/proc-macro-error") (synopsis "Drop-in replacement to panics in proc-macros") (description -- cgit v1.2.3 From 210bc02c508f206a743f2d3dc0541fa9cd9d6b69 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 11 May 2022 10:45:46 +0300 Subject: gnu: rust-pyo3-0.15: Adjust version dependency relaxing code. * gnu/packages/crates-io.scm (rust-pyo3-0.15)[source]: Adjust snippet to require at least the desired version, not an exact version. --- gnu/packages/crates-io.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 84f09f2da7..9b593c526e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -45753,7 +45753,7 @@ ecosystem.") ;; version of RUST-CRITERION-0.3. '(substitute* "Cargo.toml" (("\"=0\\.3\\.4\"") - "\"=0.3.5\""))))) + "\"^0.3.4\""))))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From 408d78d3ef322bfc274e5d97babf7bcf9baa4966 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 11 May 2022 10:53:51 +0300 Subject: gnu: rust-average-0.13: Move code changes to snippet. * gnu/packages/crates-io.scm (rust-average-0.13)[arguments]: Move code relaxing version requirements ... [source]: ... to a snippet. (rust-nalgebra-0.26, rust-nalgebra-macros-0.1, rust-rand-distr-0.4, rust-statrs-0.14)[arguments]: Adjust accordingly. --- gnu/packages/crates-io.scm | 32 +++++++++++++------------------- 1 file changed, 13 insertions(+), 19 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9b593c526e..c3718bea72 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5248,20 +5248,18 @@ they're not available.") (uri (crate-uri "average" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "1c97m8yagvq8r6qgd3harm5vnkdbld4mxg9byyxh6igjsf8wfgl4")))) + (base32 "1c97m8yagvq8r6qgd3harm5vnkdbld4mxg9byyxh6igjsf8wfgl4")) + (modules '((guix build utils))) + (snippet + '(begin + (substitute* "Cargo.toml" + ;; The resolver feature is not supported by our versions of Cargo. + (("resolver = \"2\".*") "") + ;; Relax version requirement for byteorder + (("=1.3") "^1.3")))))) (build-system cargo-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'configure 'patch-Cargo.toml - (lambda _ - (substitute* '("guix-vendor/rust-average-0.13.1.tar.gz/Cargo.toml" - "Cargo.toml") - ;; The resolver feature is not supported by this version of Cargo. - (("resolver = \"2\".*") "") - ;; Relax! - (("1.3") ,(package-version rust-byteorder-1)))))) - #:cargo-inputs + `(#:cargo-inputs (("rust-easy-cast" ,rust-easy-cast-0.4) ("rust-float-ord" ,rust-float-ord-0.3) ("rust-num-traits" ,rust-num-traits-0.2) @@ -35753,8 +35751,7 @@ quick compile time, and minimal dependencies.") (add-after 'configure 'patch-Cargo.toml (lambda _ (substitute* '("Cargo.toml" - "guix-vendor/rust-nalgebra-0.26.2.tar.gz/Cargo.toml" - "guix-vendor/rust-average-0.13.1.tar.gz/Cargo.toml") + "guix-vendor/rust-nalgebra-0.26.2.tar.gz/Cargo.toml") ;; The resolver feature is not supported by this version of Cargo. (("resolver = \"2\".*") ""))))) #:cargo-inputs @@ -35930,8 +35927,7 @@ statically-sized or dynamically-sized matrices.") (lambda _ (substitute* '("Cargo.toml" "guix-vendor/rust-nalgebra-macros-0.1.0.tar.gz/Cargo.toml" - "guix-vendor/rust-nalgebra-0.26.2.tar.gz/Cargo.toml" - "guix-vendor/rust-average-0.13.1.tar.gz/Cargo.toml") + "guix-vendor/rust-nalgebra-0.26.2.tar.gz/Cargo.toml") ;; The resolver feature is not supported by this version of Cargo. (("resolver = \"2\".*") ""))))) #:cargo-inputs @@ -46959,8 +46955,7 @@ tools for implementation.") (modify-phases %standard-phases (add-after 'configure 'patch-Cargo.toml (lambda _ - (substitute* '("Cargo.toml" - "guix-vendor/rust-average-0.13.1.tar.gz/Cargo.toml") + (substitute* "Cargo.toml" ;; The resolver feature is not supported by this version of Cargo. (("resolver = \"2\".*") ""))))) #:cargo-inputs @@ -58246,7 +58241,6 @@ map.") (add-after 'configure 'patch-Cargo.toml (lambda _ (substitute* '("Cargo.toml" - "guix-vendor/rust-average-0.13.1.tar.gz/Cargo.toml" "guix-vendor/rust-nalgebra-0.26.2.tar.gz/Cargo.toml") ;; The resolver feature is not supported by this version of Cargo. (("resolver = \"2\".*") ""))))) -- cgit v1.2.3 From 9dd784bacee8f3d3aed6e25520a4fd049be0597d Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 11 May 2022 11:13:28 +0300 Subject: gnu: rust-nalgebra-0.26: Move code changes to snippet. * gnu/packages/crates-io.scm (rust-nalgebra-0.26)[arguments]: Move code relaxing version requirements ... [source]: ... to a snippet. (rust-nalgebra-macros-0.1, rust-statrs-0.14)[arguments]: Adjust accordingly. --- gnu/packages/crates-io.scm | 27 ++++++++------------------- 1 file changed, 8 insertions(+), 19 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c3718bea72..bfd8e42b7d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -35742,18 +35742,16 @@ quick compile time, and minimal dependencies.") (uri (crate-uri "nalgebra" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "01hxksmgg17c4k2rzjx1h8kkjbw9rm81dsancg459zh2zrcisva7")))) + (base32 "01hxksmgg17c4k2rzjx1h8kkjbw9rm81dsancg459zh2zrcisva7")) + (modules '((guix build utils))) + (snippet + '(begin + (substitute* "Cargo.toml" + ;; The resolver feature is not supported by our versions of Cargo. + (("resolver = \"2\".*") "")))))) (build-system cargo-build-system) (arguments `(#:skip-build? #t - #:phases - (modify-phases %standard-phases - (add-after 'configure 'patch-Cargo.toml - (lambda _ - (substitute* '("Cargo.toml" - "guix-vendor/rust-nalgebra-0.26.2.tar.gz/Cargo.toml") - ;; The resolver feature is not supported by this version of Cargo. - (("resolver = \"2\".*") ""))))) #:cargo-inputs (("rust-abomonation" ,rust-abomonation-0.7) ("rust-alga" ,rust-alga-0.9) @@ -35926,8 +35924,7 @@ statically-sized or dynamically-sized matrices.") (add-after 'configure 'patch-Cargo.toml (lambda _ (substitute* '("Cargo.toml" - "guix-vendor/rust-nalgebra-macros-0.1.0.tar.gz/Cargo.toml" - "guix-vendor/rust-nalgebra-0.26.2.tar.gz/Cargo.toml") + "guix-vendor/rust-nalgebra-macros-0.1.0.tar.gz/Cargo.toml") ;; The resolver feature is not supported by this version of Cargo. (("resolver = \"2\".*") ""))))) #:cargo-inputs @@ -58236,14 +58233,6 @@ map.") (build-system cargo-build-system) (arguments `(#:skip-build? #t - #:phases - (modify-phases %standard-phases - (add-after 'configure 'patch-Cargo.toml - (lambda _ - (substitute* '("Cargo.toml" - "guix-vendor/rust-nalgebra-0.26.2.tar.gz/Cargo.toml") - ;; The resolver feature is not supported by this version of Cargo. - (("resolver = \"2\".*") ""))))) #:cargo-inputs (("rust-approx" ,rust-approx-0.4) ("rust-lazy-static" ,rust-lazy-static-1) -- cgit v1.2.3 From d47b7bbfc818e16ab9899756f3a27f89834d4021 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 11 May 2022 11:26:37 +0300 Subject: gnu: rust-nalgebra-macros-0.1: Move code changes to snippet. * gnu/packages/crates-io.scm (rust-nalgebra-macros-0.1)[arguments]: Move code relaxing version requirements ... [source]: ... to a snippet. --- gnu/packages/crates-io.scm | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index bfd8e42b7d..c595e920aa 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -35915,18 +35915,16 @@ statically-sized or dynamically-sized matrices.") (uri (crate-uri "nalgebra-macros" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "063jvvvlwmzzxfr4wyiil2cn1yqj3arvghwsr2nk4ilv2jwc1z01")))) + (base32 "063jvvvlwmzzxfr4wyiil2cn1yqj3arvghwsr2nk4ilv2jwc1z01")) + (modules '((guix build utils))) + (snippet + '(begin + (substitute* "Cargo.toml" + ;; The resolver feature is not supported by our versions of Cargo. + (("resolver = \"2\".*") "")))))) (build-system cargo-build-system) (arguments `(#:skip-build? #t - #:phases - (modify-phases %standard-phases - (add-after 'configure 'patch-Cargo.toml - (lambda _ - (substitute* '("Cargo.toml" - "guix-vendor/rust-nalgebra-macros-0.1.0.tar.gz/Cargo.toml") - ;; The resolver feature is not supported by this version of Cargo. - (("resolver = \"2\".*") ""))))) #:cargo-inputs (("rust-proc-macro2" ,rust-proc-macro2-1) ("rust-quote" ,rust-quote-1) -- cgit v1.2.3 From 427dbce3a86d2d9d2229e858af24083f912f9fe9 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 11 May 2022 11:29:37 +0300 Subject: gnu: rust-rand-distr-0.4: Move code changes to snippet. * gnu/packages/crates-io.scm (rust-rand-distr-0.4)[arguments]: Move code relaxing version requirements ... [source]: ... to a snippet. --- gnu/packages/crates-io.scm | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c595e920aa..7c55c7593e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -46943,17 +46943,16 @@ tools for implementation.") (uri (crate-uri "rand_distr" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "0brd2946xfapm2bmhmczfbwck041x7khsfhqxw1f24kxis7m8kcn")))) + (base32 "0brd2946xfapm2bmhmczfbwck041x7khsfhqxw1f24kxis7m8kcn")) + (modules '((guix build utils))) + (snippet + '(begin + (substitute* "Cargo.toml" + ;; The resolver feature is not supported by our versions of Cargo. + (("resolver = \"2\".*") "")))))) (build-system cargo-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'configure 'patch-Cargo.toml - (lambda _ - (substitute* "Cargo.toml" - ;; The resolver feature is not supported by this version of Cargo. - (("resolver = \"2\".*") ""))))) - #:cargo-inputs + `(#:cargo-inputs (("rust-average" ,rust-average-0.13) ("rust-num-traits" ,rust-num-traits-0.2) ("rust-rand" ,rust-rand-0.8) -- cgit v1.2.3 From dc0009853550fc5e7ad647d7dc4b962d343d62df Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Wed, 11 May 2022 12:27:08 +0200 Subject: gnu: mergerfs: Update to 2.33.5. * gnu/packages/file-systems.scm (mergerfs): Update to 2.33.5. --- gnu/packages/file-systems.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/file-systems.scm b/gnu/packages/file-systems.scm index e6ec51fe40..6b446971f6 100644 --- a/gnu/packages/file-systems.scm +++ b/gnu/packages/file-systems.scm @@ -1369,7 +1369,7 @@ On Guix System, you will need to invoke the included shell scripts as (define-public mergerfs (package (name "mergerfs") - (version "2.32.6") + (version "2.33.5") (source (origin (method url-fetch) @@ -1377,7 +1377,7 @@ On Guix System, you will need to invoke the included shell scripts as "releases/download/" version "/" "mergerfs-" version ".tar.gz")) (sha256 - (base32 "08gwi094ll0b7nf2i44fyjxiyvr45rp766npbdyw0yzyigas8a2f")))) + (base32 "0m0fg191ax855yb20vqpvn6v2gc3i5xdizx09pgpymj1ybxc7yyw")))) (build-system gnu-build-system) (arguments `(#:make-flags -- cgit v1.2.3 From 601d95206decdc85186dd0cfba4bd3b70658c7e4 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:02 +0200 Subject: gnu: libscrypt: Update to 1.22. * gnu/packages/crypto.scm (libscrypt): Update to 1.22. --- gnu/packages/crypto.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm index c5b19b0c2a..0cef58259e 100644 --- a/gnu/packages/crypto.scm +++ b/gnu/packages/crypto.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2015, 2017, 2018, 2019, 2022 Ricardo Wurmus ;;; Copyright © 2016, 2017, 2018, 2019, 2021 Leo Famulari ;;; Copyright © 2016 Lukas Gradl -;;; Copyright © 2016–2021 Tobias Geerinckx-Rice +;;; Copyright © 2016–2022 Tobias Geerinckx-Rice ;;; Copyright © 2016, 2017 Nikita ;;; Copyright © 2016, 2017, 2019, 2020 Eric Bavier ;;; Copyright © 2017 Pierre Langlois @@ -580,7 +580,7 @@ attacks than alternative functions such as @code{PBKDF2} or @code{bcrypt}.") (define-public libscrypt (package (name "libscrypt") - (version "1.21") + (version "1.22") (source (origin (method git-fetch) @@ -589,8 +589,7 @@ attacks than alternative functions such as @code{PBKDF2} or @code{bcrypt}.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 - "1d76ys6cp7fi4ng1w3mz2l0p9dbr7ljbk33dcywyimzjz8bahdng")))) + (base32 "10dinz1zx8zfm81ra16s20izpm7f7j414n4i3fkdf40vbl5slra1")))) (build-system gnu-build-system) (outputs (list "out" "static")) (arguments -- cgit v1.2.3 From 6f4ceb544952ceb1c34fcd754547003b7dd0c16f Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: libscrypt: Use G-expressions. * gnu/packages/crypto.scm (libscrypt)[arguments]: Rewrite as G-expressions. --- gnu/packages/crypto.scm | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm index 0cef58259e..f938d3c115 100644 --- a/gnu/packages/crypto.scm +++ b/gnu/packages/crypto.scm @@ -593,17 +593,16 @@ attacks than alternative functions such as @code{PBKDF2} or @code{bcrypt}.") (build-system gnu-build-system) (outputs (list "out" "static")) (arguments - `(#:make-flags (list (string-append "PREFIX=" %output) - ,(string-append "CC=" (cc-for-target))) - #:phases - (modify-phases %standard-phases - (delete 'configure) ; no configure script - (add-after 'install 'install:static - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (lib (string-append out "/lib"))) - (install-file "libscrypt.a" lib) - #t)))))) + (list #:make-flags + #~(list (string-append "PREFIX=" #$output) + (string-append "CC=" #$(cc-for-target))) + #:phases + #~(modify-phases %standard-phases + (delete 'configure) ; no configure script + (add-after 'install 'install:static + (lambda _ + (install-file "libscrypt.a" + (string-append #$output:static "/lib"))))))) (home-page "https://lolware.net/libscrypt.html") (synopsis "Password hashing library") (description "@code{libscrypt} implements @code{scrypt} key derivation -- cgit v1.2.3 From 8de6d6ffb24ac2f07b3f3594816df570e579ddba Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:02 +0200 Subject: gnu: htop: Update to 3.2.0. * gnu/packages/admin.scm (htop): Update to 3.2.0. --- gnu/packages/admin.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index 813aa59093..7e6a040493 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -671,7 +671,7 @@ console.") (define-public htop (package (name "htop") - (version "3.1.2") + (version "3.2.0") (source (origin (method git-fetch) @@ -679,7 +679,7 @@ console.") (url "https://github.com/htop-dev/htop") (commit version))) (sha256 - (base32 "024qhrlmqgwmn6bwb5yiff9bhhdabryiphzx8y654k8r8vqi59j4")) + (base32 "16l1r2ixzs640ybqp2x8bfyvk98kiywy7k3sjmp5j5npdzn5ryd7")) (file-name (git-file-name name version)))) (build-system gnu-build-system) (inputs -- cgit v1.2.3 From 85d56c1780bd68929498ed9b4e9cc7938e94a6e5 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: inxi-minimal: Update to 3.3.15-1. * gnu/packages/admin.scm (inxi-minimal): Update to 3.3.15-1. --- gnu/packages/admin.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index 7e6a040493..a32d28a92e 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -4128,7 +4128,7 @@ Python loading in HPC environments.") (let ((real-name "inxi")) (package (name "inxi-minimal") - (version "3.3.11-1") + (version "3.3.15-1") (source (origin (method git-fetch) @@ -4137,7 +4137,7 @@ Python loading in HPC environments.") (commit version))) (file-name (git-file-name real-name version)) (sha256 - (base32 "1nk3q2xg0myykq1myasxhvhhr0vk8qv3m7pb3icw81r3ydasnls0")))) + (base32 "02zy94bd6ayfl9y7ka6gk32q254k49cbq3a6wgi31r2fcvybyrf7")))) (build-system trivial-build-system) (inputs `(("bash" ,bash-minimal) -- cgit v1.2.3 From 09e885d848f7c86e62881c749843582ccfb6c9a3 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: netcat-openbsd: Update to 1.218-5. * gnu/packages/admin.scm (netcat-openbsd): Update to 1.218-5. --- gnu/packages/admin.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index a32d28a92e..ff2ff2fc2d 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -1068,7 +1068,7 @@ would need and has several interesting built-in capabilities.") (define-public netcat-openbsd (package (name "netcat-openbsd") - (version "1.218-2") + (version "1.218-5") (source (origin (method git-fetch) (uri (git-reference @@ -1077,7 +1077,7 @@ would need and has several interesting built-in capabilities.") (file-name (git-file-name name version)) (sha256 (base32 - "1rj4nx0jdism1idc4fghahqbafhv72cpk7zlyq9czgvbps10d1kh")))) + "0hpbmz9m2q22a6qgbn9590z2x96xgffim8g0m1v47mariz3pqhlc")))) (build-system gnu-build-system) (arguments `(#:tests? #f ; no test suite -- cgit v1.2.3 From 4051231d208ddd681a741893768efd912ffb0496 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:03 +0200 Subject: gnu: nq: Update to 0.5. * gnu/packages/admin.scm (nq): Update to 0.5. --- gnu/packages/admin.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index ff2ff2fc2d..52f832bdf0 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -4868,7 +4868,7 @@ the XMODEM/YMODEM/ZMODEM file transfer protocols.") (define-public nq (package (name "nq") - (version "0.4") + (version "0.5") (source (origin (method git-fetch) @@ -4877,7 +4877,7 @@ the XMODEM/YMODEM/ZMODEM file transfer protocols.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0sdamjzvmf6cxhjmd1rjvn7zm6k10fp5n6vabyxd3yl30cgrxw2i")))) + (base32 "0szbndvwl6ghwjzb165s09977s0r1yq8h0ziknm0h6xndkcjspl3")))) (build-system gnu-build-system) (native-inputs (list perl)) -- cgit v1.2.3 From d24ad3949127a938cad306f0524c120afe5e2e4f Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:02 +0200 Subject: gnu: nq: Use G-expressions. * gnu/packages/admin.scm (nq)[arguments]: Rewrite as G-expressions. --- gnu/packages/admin.scm | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index 52f832bdf0..cd7053f819 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -4882,11 +4882,12 @@ the XMODEM/YMODEM/ZMODEM file transfer protocols.") (native-inputs (list perl)) (arguments - `(#:make-flags (list (string-append "CC=" ,(cc-for-target)) - (string-append "PREFIX=" (assoc-ref %outputs "out"))) - #:phases - (modify-phases %standard-phases - (delete 'configure)))) + (list #:make-flags + #~(list (string-append "CC=" #$(cc-for-target)) + (string-append "PREFIX=" #$output)) + #:phases + #~(modify-phases %standard-phases + (delete 'configure)))) (synopsis "Unix command line queue utility") (description "@code{nq} can create very lightweight job queue systems which require no -- cgit v1.2.3 From e764b89a52171fd5ff6d22fdb562ceb60ec6a50a Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Thu, 31 Mar 2022 16:34:47 +0000 Subject: gnu: libgit2: Update to 1.4.3. * gnu/packages/version-control.scm (libgit2): Update to 1.4.3. [source]: Adjust snippet to comment out the "10 years ago" test, which was changed in 1.4.3 but is still problematic. [arguments]: Add "-DUSE_SSH=ON". Remove 'fix-hardcoded-paths' phase. Adjust 'check' phase for new executable name. (libgit2-1.3): New variable. (libgit2-1.1): Inherit from 'libgit2-1.3'; inherit from its origin too. * gnu/packages/crates-io.scm (rust-git2-0.13)[inputs]: Use LIBGIT2-1.3. * gnu/packages/python-xyz.scm (python-pygit2)[propagated-inputs]: Likewise. Co-authored-by: Maxime Devos --- gnu/packages/crates-io.scm | 2 +- gnu/packages/python-xyz.scm | 2 +- gnu/packages/version-control.scm | 66 ++++++++++++++++++++++++---------------- 3 files changed, 41 insertions(+), 29 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7c55c7593e..136e5fe727 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -25048,7 +25048,7 @@ dirty state into your program.") `(("pkg-config" ,pkg-config) ("git" ,git-minimal))) ;for a single test (inputs - (list libgit2 libssh2 openssl zlib)) + (list libgit2-1.3 libssh2 openssl zlib)) (home-page "https://github.com/rust-lang/git2-rs") (synopsis "Rust bindings to libgit2") (description diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 659538d193..299804ae3e 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -6137,7 +6137,7 @@ readable format.") (arguments '(#:tests? #f)) ; tests don't run correctly in our environment (propagated-inputs - (list python-cached-property python-cffi libgit2)) + (list python-cached-property python-cffi libgit2-1.3)) (native-inputs (list python-pytest)) (home-page "https://github.com/libgit2/pygit2") diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index 49b53789f9..d528a08e63 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -44,6 +44,7 @@ ;;; Copyright © 2021 jgart ;;; Copyright © 2021 Foo Chuan Wei ;;; Copyright © 2022 Jai Vetrivelan +;;; Copyright © 2022 Maxime Devos ;;; ;;; This file is part of GNU Guix. ;;; @@ -789,7 +790,7 @@ to GitHub contributions calendar.") (define-public libgit2 (package (name "libgit2") - (version "1.3.0") + (version "1.4.3") (source (origin ;; Since v1.1.1, release artifacts are no longer offered (see: ;; https://github.com/libgit2/libgit2/discussions/5932#discussioncomment-1682729). @@ -800,18 +801,18 @@ to GitHub contributions calendar.") (file-name (git-file-name name version)) (sha256 (base32 - "0vgpb2175a5dhqiy1iwywwppahgqhi340i8bsvafjpvkw284vazd")) + "02x1a4zrzpzjd0yxnsi8njh5hgihc1iy1v4r0fnl8m4ckcgp6x2s")) (modules '((guix build utils))) (snippet '(begin (delete-file-recursively "deps") ;; The "refs:revparse::date" test is time-dependent: it - ;; assumes "HEAD@{10 years ago}" doesn't match anything, - ;; which is no longer true. Adjust that test. + ;; assumes "HEAD@{10 years ago}" matches a specific commit. + ;; See . (substitute* "tests/refs/revparse.c" - (("10 years ago") - "100 years ago")))))) + (("test_object.*10 years ago.*" all) + (string-append "// " all "\n"))))))) (build-system cmake-build-system) (outputs '("out" "debug")) (arguments @@ -819,6 +820,7 @@ to GitHub contributions calendar.") (list "-DUSE_NTLMCLIENT=OFF" ;TODO: package this "-DREGEX_BACKEND=pcre2" "-DUSE_HTTP_PARSER=system" + "-DUSE_SSH=ON" ; cmake fails to find libssh if this is missing ,@(if (%current-target-system) `((string-append "-DPKG_CONFIG_EXECUTABLE=" @@ -829,18 +831,11 @@ to GitHub contributions calendar.") '())) #:phases (modify-phases %standard-phases - (add-after 'unpack 'fix-hardcoded-paths - (lambda _ - (substitute* "tests/repo/init.c" - (("#!/bin/sh") (string-append "#!" (which "sh")))) - (substitute* "tests/clar/fs.h" - (("/bin/cp") (which "cp")) - (("/bin/rm") (which "rm"))))) ;; Run checks more verbosely, unless we are cross-compiling. (replace 'check (lambda* (#:key (tests? #t) #:allow-other-keys) (if tests? - (invoke "./libgit2_clar" "-v" "-Q") + (invoke "./libgit2_tests" "-v" "-Q") ;; Tests may be disabled if cross-compiling. (format #t "Test suite not run.~%"))))))) (inputs @@ -859,12 +854,39 @@ write native speed custom Git applications in any language with bindings.") ;; GPLv2 with linking exception (license license:gpl2))) -(define-public libgit2-1.1 +(define-public libgit2-1.3 (package (inherit libgit2) - (name "libgit2") + (version "1.3.0") + (source (origin + (inherit (package-source libgit2)) + (method git-fetch) + (uri (git-reference + (url "https://github.com/libgit2/libgit2") + (commit (string-append "v" version)))) + (file-name (git-file-name "libgit2" version)) + (sha256 + (base32 + "0vgpb2175a5dhqiy1iwywwppahgqhi340i8bsvafjpvkw284vazd")))) + (arguments + (substitute-keyword-arguments (package-arguments libgit2) + ((#:phases _ '%standard-phases) + `(modify-phases %standard-phases + ;; Run checks more verbosely, unless we are cross-compiling. + (replace 'check + (lambda* (#:key (tests? #t) #:allow-other-keys) + (if tests? + (invoke "./libgit2_clar" "-v" "-Q") + ;; Tests may be disabled if cross-compiling. + (format #t "Test suite not run.~%")))))))))) + +(define-public libgit2-1.1 + (package + (inherit libgit2-1.3) (version "1.1.0") (source (origin + (inherit (package-source libgit2-1.3)) + (file-name #f) ;use the default name (method url-fetch) (uri (string-append "https://github.com/libgit2/libgit2/" "releases/download/v" version @@ -872,17 +894,7 @@ write native speed custom Git applications in any language with bindings.") (sha256 (base32 "1fjdglkh04qv3b4alg621pxa689i0wlf8m7nf2755zawjr2zhwxd")) - (patches (search-patches "libgit2-mtime-0.patch")) - (snippet '(begin - (delete-file-recursively "deps") - - ;; The "refs:revparse::date" test is time-dependent: it - ;; assumes "HEAD@{10 years ago}" doesn't match anything, - ;; which is no longer true. Adjust that test. - (substitute* "tests/refs/revparse.c" - (("10 years ago") - "100 years ago")))) - (modules '((guix build utils))))))) + (patches (search-patches "libgit2-mtime-0.patch")))))) (define-public git-crypt (package -- cgit v1.2.3 From d3553810627ebb8019e383acbc6a2daae01dfadf Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Wed, 11 May 2022 23:41:37 +0200 Subject: gnu: python-pygit2: Update to 1.9.1. * gnu/packages/python-xyz.scm (python-pygit2): Update to 1.9.1. [propagated-inputs]: Change LIBGIT2-1.3 to LIBGIT2. --- gnu/packages/python-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 299804ae3e..ab4102273a 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -6126,18 +6126,18 @@ readable format.") (define-public python-pygit2 (package (name "python-pygit2") - (version "1.7.1") + (version "1.9.1") (source (origin (method url-fetch) (uri (pypi-uri "pygit2" version)) (sha256 - (base32 "0p8n25bijirxh31cv99vd1mkdsvpcs6z6441wz1fqva3b2as5ynp")))) + (base32 "1jdr6z1il03nifwgpcdf95w6xzzbfzdkcqq5dcqjaa0rnv1pjr7g")))) (build-system python-build-system) (arguments '(#:tests? #f)) ; tests don't run correctly in our environment (propagated-inputs - (list python-cached-property python-cffi libgit2-1.3)) + (list python-cached-property python-cffi libgit2)) (native-inputs (list python-pytest)) (home-page "https://github.com/libgit2/pygit2") -- cgit v1.2.3 From 388e0390441ca7a8e8a57e71d92e6f963f07af9f Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: isc-dhcp: Update to 4.4.3. * gnu/packages/admin.scm (isc-dhcp): Update to 4.4.3. [source]: Remove upstreamed patch. * gnu/packages/patches/isc-dhcp-gcc-compat.patch: Delete file. * gnu/local.mk (dist_patch_DATA): Remove it. --- gnu/local.mk | 1 - gnu/packages/admin.scm | 5 +- gnu/packages/patches/isc-dhcp-gcc-compat.patch | 72 -------------------------- 3 files changed, 2 insertions(+), 76 deletions(-) delete mode 100644 gnu/packages/patches/isc-dhcp-gcc-compat.patch diff --git a/gnu/local.mk b/gnu/local.mk index 3b7db46b26..ed901a5ba8 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1297,7 +1297,6 @@ dist_patch_DATA = \ %D%/packages/patches/iputils-libcap-compat.patch \ %D%/packages/patches/ipxe-reproducible-geniso.patch \ %D%/packages/patches/irrlicht-use-system-libs.patch \ - %D%/packages/patches/isc-dhcp-gcc-compat.patch \ %D%/packages/patches/isl-0.11.1-aarch64-support.patch \ %D%/packages/patches/json-c-0.13-CVE-2020-12762.patch \ %D%/packages/patches/json-c-0.12-CVE-2020-12762.patch \ diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index cd7053f819..34e4a6e8ca 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -1232,15 +1232,14 @@ connection alive.") bind-release-version))) (package (name "isc-dhcp") - (version "4.4.2-P1") + (version "4.4.3") (source (origin (method url-fetch) (uri (string-append "https://ftp.isc.org/isc/dhcp/" version "/dhcp-" version ".tar.gz")) - (patches (search-patches "isc-dhcp-gcc-compat.patch")) (sha256 (base32 - "06jsr0cg5rsmyibshrpcb9za0qgwvqccashdma7mlm1rflrh8pmh")))) + "062q2g8cj2zv0zv22x6pg21m21bdlscxkg3li0ac0pm0qasccghf")))) (build-system gnu-build-system) (arguments `(#:parallel-build? #f diff --git a/gnu/packages/patches/isc-dhcp-gcc-compat.patch b/gnu/packages/patches/isc-dhcp-gcc-compat.patch deleted file mode 100644 index 82cb572d17..0000000000 --- a/gnu/packages/patches/isc-dhcp-gcc-compat.patch +++ /dev/null @@ -1,72 +0,0 @@ -Add minor fixes for compiling with GCC 10. - -Taken from upstream: -https://gitlab.isc.org/isc-projects/dhcp/-/commit/6c7e61578b1b449272dbb40dd8b98d03dad8a57a - -diff --git a/client/dhclient.c b/client/dhclient.c ---- a/client/dhclient.c -+++ b/client/dhclient.c -@@ -83,8 +83,9 @@ static const char message [] = "Internet Systems Consortium DHCP Client"; - static const char url [] = "For info, please visit https://www.isc.org/software/dhcp/"; - #endif /* UNIT_TEST */ - --u_int16_t local_port = 0; --u_int16_t remote_port = 0; -+extern u_int16_t local_port; -+extern u_int16_t remote_port; -+ - #if defined(DHCPv6) && defined(DHCP4o6) - int dhcp4o6_state = -1; /* -1 = stopped, 0 = polling, 1 = started */ - #endif -diff --git a/common/discover.c b/common/discover.c ---- a/common/discover.c -+++ b/common/discover.c -@@ -45,8 +45,8 @@ struct interface_info *fallback_interface = 0; - - int interfaces_invalidated; - int quiet_interface_discovery; --u_int16_t local_port; --u_int16_t remote_port; -+u_int16_t local_port = 0; -+u_int16_t remote_port = 0; - u_int16_t relay_port = 0; - int dhcpv4_over_dhcpv6 = 0; - int (*dhcp_interface_setup_hook) (struct interface_info *, struct iaddr *); -diff --git a/relay/dhcrelay.c b/relay/dhcrelay.c ---- a/relay/dhcrelay.c -+++ b/relay/dhcrelay.c -@@ -95,8 +95,8 @@ enum { forward_and_append, /* Forward and append our own relay option. */ - forward_untouched, /* Forward without changes. */ - discard } agent_relay_mode = forward_and_replace; - --u_int16_t local_port; --u_int16_t remote_port; -+extern u_int16_t local_port; -+extern u_int16_t remote_port; - - /* Relay agent server list. */ - struct server_list { -diff --git a/server/mdb.c b/server/mdb.c ---- a/server/mdb.c -+++ b/server/mdb.c -@@ -67,7 +67,7 @@ static host_id_info_t *host_id_info = NULL; - - int numclasseswritten; - --omapi_object_type_t *dhcp_type_host; -+extern omapi_object_type_t *dhcp_type_host; - - isc_result_t enter_class(cd, dynamicp, commit) - struct class *cd; -diff --git a/server/mdb6.c b/server/mdb6.c ---- a/server/mdb6.c -+++ b/server/mdb6.c -@@ -1945,7 +1945,7 @@ create_prefix6(struct ipv6_pool *pool, struct iasubopt **pref, - } - new_ds.data = new_ds.buffer->data; - memcpy(new_ds.buffer->data, ds.data, ds.len); -- memcpy(new_ds.buffer->data + ds.len, &tmp, sizeof(tmp)); -+ memcpy(&new_ds.buffer->data[0] + ds.len, &tmp, sizeof(tmp)); - data_string_forget(&ds, MDL); - data_string_copy(&ds, &new_ds, MDL); - data_string_forget(&new_ds, MDL); -- cgit v1.2.3 From 2c67e1cfbf5dc4c528f9ddb5dce843bd8326cdab Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:02 +0200 Subject: gnu: agda: Update to 2.6.2.2. * gnu/packages/agda.scm (agda): Update to 2.6.2.2. --- gnu/packages/agda.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/agda.scm b/gnu/packages/agda.scm index 4dd6366247..706360c94f 100644 --- a/gnu/packages/agda.scm +++ b/gnu/packages/agda.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2018 Alex ter Weele ;;; Copyright © 2018 Ricardo Wurmus ;;; Copyright © 2018 Alex Vong -;;; Copyright © 2018 Tobias Geerinckx-Rice +;;; Copyright © 2018, 2022 Tobias Geerinckx-Rice ;;; Copyright © 2018 John Soo ;;; Copyright © 2019 Ludovic Courtès ;;; @@ -37,7 +37,7 @@ (define-public agda (package (name "agda") - (version "2.6.2.1") + (version "2.6.2.2") (source (origin (method url-fetch) @@ -45,7 +45,7 @@ "https://hackage.haskell.org/package/Agda/Agda-" version ".tar.gz")) (sha256 - (base32 "03dw7jfqr3ffik6avigm525djqh2gn5c3qwnb2h6298zkr9lch9w")))) + (base32 "0yjjbhc593ylrm4mq4j01nkdvh7xqsg5in30wxj4y53vf5hkggp5")))) (build-system haskell-build-system) (inputs (list ghc-aeson -- cgit v1.2.3 From 914d2c2142eb22a0219cf09475ea7207808ded6a Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:00 +0200 Subject: gnu: agda: Use G-expressions. * gnu/packages/agda.scm (agda)[arguments]: Rewrite as G-expressions. --- gnu/packages/agda.scm | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/gnu/packages/agda.scm b/gnu/packages/agda.scm index 706360c94f..87e787b72d 100644 --- a/gnu/packages/agda.scm +++ b/gnu/packages/agda.scm @@ -71,22 +71,22 @@ ghc-uri-encode ghc-zlib)) (arguments - `(#:modules ((guix build haskell-build-system) - (guix build utils) - (srfi srfi-26) - (ice-9 match)) - #:phases - (modify-phases %standard-phases - ;; This allows us to call the 'agda' binary before installing. - (add-after 'unpack 'set-ld-library-path - (lambda _ - (setenv "LD_LIBRARY_PATH" (string-append (getcwd) "/dist/build")))) - (add-after 'compile 'agda-compile - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (agda-compiler (string-append out "/bin/agda"))) - (for-each (cut invoke agda-compiler <>) - (find-files (string-append out "/share") "\\.agda$")))))))) + (list #:modules `((guix build haskell-build-system) + (guix build utils) + (srfi srfi-26) + (ice-9 match)) + #:phases + #~(modify-phases %standard-phases + ;; This allows us to call the 'agda' binary before installing. + (add-after 'unpack 'set-ld-library-path + (lambda _ + (setenv "LD_LIBRARY_PATH" (string-append (getcwd) "/dist/build")))) + (add-after 'compile 'agda-compile + (lambda* (#:key outputs #:allow-other-keys) + (let ((agda-compiler (string-append #$output "/bin/agda"))) + (for-each (cut invoke agda-compiler <>) + (find-files (string-append #$output "/share") + "\\.agda$")))))))) (home-page "https://wiki.portal.chalmers.se/agda/") (synopsis "Dependently typed functional programming language and proof assistant") -- cgit v1.2.3 From 5ed3fca18c16cad20765279ba191b3771cdd1af4 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: iceauth: Update to 1.0.9. * gnu/packages/xorg.scm (iceauth): Update to 1.0.9. --- gnu/packages/xorg.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/xorg.scm b/gnu/packages/xorg.scm index 75a7bbd01c..e3c24c4bb2 100644 --- a/gnu/packages/xorg.scm +++ b/gnu/packages/xorg.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2017, 2018, 2019, 2020, 2021 Marius Bakke ;;; Copyright © 2017, 2018, 2019 Rutger Helling ;;; Copyright © 2017, 2020 Arun Isaac -;;; Copyright © 2018–2021 Tobias Geerinckx-Rice +;;; Copyright © 2018–2022 Tobias Geerinckx-Rice ;;; Copyright © 2018 Kei Kebreau ;;; Copyright © 2018, 2020, 2022 Oleg Pykhalov ;;; Copyright © 2018 Benjamin Slade @@ -954,7 +954,7 @@ rendering commands to the X server.") (define-public iceauth (package (name "iceauth") - (version "1.0.8") + (version "1.0.9") (source (origin (method url-fetch) @@ -963,8 +963,7 @@ rendering commands to the X server.") version ".tar.bz2")) (sha256 - (base32 - "1ik0mdidmyvy48hn8p2hwvf3535rf3m96hhf0mvcqrbj44x23vp6")))) + (base32 "1ik0mdidmyvy48hn8p2hwvf3535rf3m96hhf0mvcqrbj44x23vp6")))) (build-system gnu-build-system) (inputs (list libice)) -- cgit v1.2.3 From 5fdc95561596e21443321119c8497246764333bb Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:00 +0200 Subject: doc: Avoid leading ‘But’. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * doc/guix.texi (Manual Installation): End sentence later. --- doc/guix.texi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 5399584cb0..c168a66072 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -2329,8 +2329,8 @@ Installation}). The installation system provides root shells on TTYs 3 to 6; press @kbd{ctrl-alt-f3}, @kbd{ctrl-alt-f4}, and so on to reach them. It includes -many common tools needed to install the system. But it is also a full-blown -Guix System, which means that you can install additional packages, should you +many common tools needed to install the system, but is also a full-blown +Guix System. This means that you can install additional packages, should you need it, using @command{guix package} (@pxref{Invoking guix package}). @menu -- cgit v1.2.3 From b4c9a3d23b06d9441e96938b45fbf6669685955d Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: recutils: Remove some input labels. * gnu/packages/databases.scm (recutils)[inputs]: Remove input labels. [arguments]: Adjust accordingly. --- gnu/packages/databases.scm | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index b7cbfa6536..91d2e28eb8 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -1568,22 +1568,23 @@ organized in a hash table or B+ tree.") (base32 "03kf91f20brn2ffljfjzirxh5xj99m1mvvspcx2lph9000mmj0b3")))) (build-system gnu-build-system) - - (arguments '(#:configure-flags - (list "--disable-static" - (string-append "--with-bash-headers=" - (assoc-ref %build-inputs "bash:include") - "/include/bash")))) - - (native-inputs `(("bc" ,bc) - ("bash:include" ,bash "include") - ("check" ,check-0.14) - ("pkg-config" ,pkg-config))) - - ;; TODO: Add more optional inputs. - (inputs `(("curl" ,curl) - ("libgcrypt" ,libgcrypt) - ("libuuid" ,util-linux "lib"))) + (arguments + (list #:configure-flags + '(list "--disable-static" + (string-append "--with-bash-headers=" + (search-input-directory %build-inputs + "include/bash"))))) + (native-inputs + ;; XXX Without labels, the default 'configure phase picks the wrong "bash". + `(("bc" ,bc) + ("bash:include" ,bash "include") + ("check" ,check-0.14) + ("pkg-config" ,pkg-config))) + (inputs + ;; TODO: Add more optional inputs. + (list curl + libgcrypt + `(,util-linux "lib"))) (synopsis "Manipulate plain text files as databases") (description "GNU Recutils is a set of tools and libraries for creating and -- cgit v1.2.3 From 20fbd870938e239c038d8524a56729f123f19f80 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:00 +0200 Subject: gnu: recutils: Fix cross-compilation. * gnu/packages/databases.scm (recutils) [arguments]: Point "--with-bash-headers" to the root bash "/include" directory. --- gnu/packages/databases.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 91d2e28eb8..c70173b329 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -1572,8 +1572,9 @@ organized in a hash table or B+ tree.") (list #:configure-flags '(list "--disable-static" (string-append "--with-bash-headers=" - (search-input-directory %build-inputs - "include/bash"))))) + (dirname (search-input-directory + %build-inputs + "include/bash")))))) (native-inputs ;; XXX Without labels, the default 'configure phase picks the wrong "bash". `(("bc" ,bc) -- cgit v1.2.3 From faf715b1dcf9a7d984846f43c2110de2d4b896ff Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:10 +0200 Subject: gnu: lighttpd: Fix bash reference. * gnu/packages/web.scm (lighttpd)[arguments]: Substitute SEARCH-INPUT-FILE for WHICH. [inputs]: Add bash-minimal. f fix lighttpd xcc --- gnu/packages/web.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index bc913664e3..fabe488c2a 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -16,7 +16,7 @@ ;;; Copyright © 2016 Clément Lassieur ;;; Copyright © 2016, 2017 Nikita ;;; Copyright © 2016, 2017, 2018, 2019, 2021 Arun Isaac -;;; Copyright © 2016–2021 Tobias Geerinckx-Rice +;;; Copyright © 2016–2022 Tobias Geerinckx-Rice ;;; Copyright © 2016 Bake Timmons ;;; Copyright © 2017 Thomas Danckaert ;;; Copyright © 2017, 2018, 2020, 2021, 2022 Marius Bakke @@ -849,9 +849,9 @@ stream. Remote control of the module is possible over HTTP.") #:phases (modify-phases %standard-phases (add-after 'unpack 'embed-/bin/sh-reference - (lambda _ + (lambda* (#:key inputs #:allow-other-keys) (substitute* "src/mod_ssi.c" - (("/bin/sh") (which "sh"))) + (("/bin/sh") (search-input-file inputs "/bin/sh"))) #t)) (add-after 'unpack 'fix-tests (lambda _ @@ -862,7 +862,8 @@ stream. Remote control of the module is possible over HTTP.") "{HOSTNAME} = \"127.0.0.1\";")) #t))))) (inputs - `(("cyrus-sasl" ,cyrus-sasl) + `(("bash-minimal" ,bash-minimal) + ("cyrus-sasl" ,cyrus-sasl) ("libev" ,libev) ("libunwind" ,libunwind) ("linux-pam" ,linux-pam) -- cgit v1.2.3 From fd7130e4b514feeb72b7e386df4959023a38b55c Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:02 +0200 Subject: gnu: lighttpd: Update to 1.4.64. * gnu/packages/web.scm (lighttpd): Update to 1.4.64. [arguments]: Add a new 'skip-failing-tests phase. [inputs]: Substitute pcre2 for pcre & pcre:bin. --- gnu/packages/web.scm | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index fabe488c2a..37ae528f08 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -827,7 +827,7 @@ stream. Remote control of the module is possible over HTTP.") (define-public lighttpd (package (name "lighttpd") - (version "1.4.59") + (version "1.4.64") (source (origin (method url-fetch) (uri (string-append "https://download.lighttpd.net/lighttpd/" @@ -835,7 +835,7 @@ stream. Remote control of the module is possible over HTTP.") "lighttpd-" version ".tar.xz")) (sha256 (base32 - "1mc421yrbnq3k6yrc708svp0fgcamrn5a0p2nvnhivysffr3v5gv")))) + "09hf3cp4ivy9a9z9drgi4f6d60137dcqncqw0wpbyvs9lygrsj71")))) (build-system gnu-build-system) (arguments `(#:configure-flags @@ -860,7 +860,17 @@ stream. Remote control of the module is possible over HTTP.") (substitute* "tests/LightyTest.pm" (("\\{HOSTNAME\\} = \\$name;") "{HOSTNAME} = \"127.0.0.1\";")) - #t))))) + #t)) + (add-after 'unpack 'skip-failing-tests + ;; XXX It would be wonderful if you, reader, felt suddenly and + ;; irresistibly compelled to investigate & fix these failures. + (lambda _ + ;; Throws a bunch of ‘connect failed: Connection refused’. + (delete-file "tests/mod-scgi.t") + + ;; test_mod_ssi_read_fd: Assertion `cq->first' failed. + (substitute* "src/t/test_mod.c" + ((".*\\btest_mod_ssi\\b.*") ""))))))) (inputs `(("bash-minimal" ,bash-minimal) ("cyrus-sasl" ,cyrus-sasl) @@ -870,8 +880,7 @@ stream. Remote control of the module is possible over HTTP.") ("mit-krb5" ,mit-krb5) ("openldap" ,openldap) ("openssl" ,openssl) - ("pcre" ,pcre) - ("pcre:bin" ,pcre "bin") + ("pcre2" ,pcre2) ("zlib" ,zlib))) (native-inputs (list perl ; for tests -- cgit v1.2.3 From cd00881d72830ef9293c2693a9eb24d5692b2ab8 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: lighttpd: Update style. * gnu/packages/web.scm (lighttpd)[arguments]: Rewrite as G-expressions. Don't explicitly return #t from phases. [inputs]: Remove input labels. --- gnu/packages/web.scm | 82 +++++++++++++++++++++++++--------------------------- 1 file changed, 40 insertions(+), 42 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 37ae528f08..5e200d13cc 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -838,50 +838,48 @@ stream. Remote control of the module is possible over HTTP.") "09hf3cp4ivy9a9z9drgi4f6d60137dcqncqw0wpbyvs9lygrsj71")))) (build-system gnu-build-system) (arguments - `(#:configure-flags - (list "--with-krb5" - "--with-ldap" - "--with-libev" - "--with-libunwind" - "--with-openssl" - "--with-pam" - "--with-sasl") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'embed-/bin/sh-reference - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "src/mod_ssi.c" - (("/bin/sh") (search-input-file inputs "/bin/sh"))) - #t)) - (add-after 'unpack 'fix-tests - (lambda _ - (setenv "SHELL" (which "sh")) - ;; gethostbyaddr fails - (substitute* "tests/LightyTest.pm" - (("\\{HOSTNAME\\} = \\$name;") - "{HOSTNAME} = \"127.0.0.1\";")) - #t)) - (add-after 'unpack 'skip-failing-tests - ;; XXX It would be wonderful if you, reader, felt suddenly and - ;; irresistibly compelled to investigate & fix these failures. - (lambda _ - ;; Throws a bunch of ‘connect failed: Connection refused’. - (delete-file "tests/mod-scgi.t") + (list #:configure-flags + #~(list "--with-krb5" + "--with-ldap" + "--with-libev" + "--with-libunwind" + "--with-openssl" + "--with-pam" + "--with-sasl") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'embed-/bin/sh-reference + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "src/mod_ssi.c" + (("/bin/sh") (search-input-file inputs "/bin/sh"))))) + (add-after 'unpack 'fix-tests + (lambda _ + (setenv "SHELL" (which "sh")) + ;; gethostbyaddr fails + (substitute* "tests/LightyTest.pm" + (("\\{HOSTNAME\\} = \\$name;") + "{HOSTNAME} = \"127.0.0.1\";")))) + (add-after 'unpack 'skip-failing-tests + ;; XXX It would be wonderful if you, reader, felt suddenly and + ;; irresistibly compelled to investigate & fix these failures. + (lambda _ + ;; Throws a bunch of ‘connect failed: Connection refused’. + (delete-file "tests/mod-scgi.t") - ;; test_mod_ssi_read_fd: Assertion `cq->first' failed. - (substitute* "src/t/test_mod.c" - ((".*\\btest_mod_ssi\\b.*") ""))))))) + ;; test_mod_ssi_read_fd: Assertion `cq->first' failed. + (substitute* "src/t/test_mod.c" + ((".*\\btest_mod_ssi\\b.*") ""))))))) (inputs - `(("bash-minimal" ,bash-minimal) - ("cyrus-sasl" ,cyrus-sasl) - ("libev" ,libev) - ("libunwind" ,libunwind) - ("linux-pam" ,linux-pam) - ("mit-krb5" ,mit-krb5) - ("openldap" ,openldap) - ("openssl" ,openssl) - ("pcre2" ,pcre2) - ("zlib" ,zlib))) + (list bash-minimal + cyrus-sasl + libev + libunwind + linux-pam + mit-krb5 + openldap + openssl + pcre2 + zlib)) (native-inputs (list perl ; for tests pkg-config which)) -- cgit v1.2.3 From de15ca7af8cfb92f716ad8600f9295a2dca581a2 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:04 +0200 Subject: gnu: beep: Update to 1.4.12. * gnu/packages/terminals.scm (beep): Update to 1.4.12. [arguments]: Set $(CC) #:make-flag. Manually substitute the correct value of make check's $(PWD). (!) --- gnu/packages/terminals.scm | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index 58fd569ff2..59949daf21 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2016 David Craven ;;; Copyright © 2016, 2017, 2019, 2020 Ludovic Courtès ;;; Copyright © 2016, 2017 José Miguel Sánchez García -;;; Copyright © 2017–2021 Tobias Geerinckx-Rice +;;; Copyright © 2017–2022 Tobias Geerinckx-Rice ;;; Copyright © 2017 Kei Kebreau ;;; Copyright © 2017, 2018, 2019 Ricardo Wurmus ;;; Copyright © 2017 Petter @@ -559,7 +559,7 @@ to all types of devices that provide serial consoles.") (define-public beep (package (name "beep") - (version "1.4.10") + (version "1.4.12") (source (origin (method git-fetch) @@ -572,11 +572,12 @@ to all types of devices that provide serial consoles.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "05c2gxfqc12rgp88c65q7f5ha9gzh222vdh0qpdq1zmyhqj43pq1")))) + (base32 "0dgrb5yg4ys1fa4hs95iz3m2yhryfzzw0j6g6yf6vhbys4ihcf40")))) (build-system gnu-build-system) (arguments `(#:make-flags - (list (string-append "prefix=" (assoc-ref %outputs "out")) + (list (string-append "CC=" ,(cc-for-target)) + (string-append "prefix=" (assoc-ref %outputs "out")) (string-append "pkgdocdir=$(docdir)/" ,name "-" ,version)) #:phases (modify-phases %standard-phases @@ -585,9 +586,14 @@ to all types of devices that provide serial consoles.") (lambda _ (substitute* "GNUmakefile" (("/bin/bash") - (which "bash"))) + (which "bash")) + ;; XXX In the build environment, $(PWD) is the *parent* directory + ;; /tmp/guix-build-beep-x.y.drv-0! A pure guix shell works fine. + (("\\$\\(PWD\\)" pwd) + (string-append pwd "/source"))) (substitute* (find-files "tests" "\\.expected") ;; The build environment lacks /dev/{console,tty*}. + ;; In fact, even nckx's regular Guix System lacks ttyS1… ((": Permission denied") ": No such file or directory"))))))) (synopsis "Linux command-line utility to control the PC speaker") -- cgit v1.2.3 From e6c3e7d7416daebebe4d3e2d086461d6fb89ce93 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:01 +0200 Subject: gnu: beep: Use G-expressions. * gnu/packages/terminals.scm (beep)[arguments]: Rewrite as G-expressions. --- gnu/packages/terminals.scm | 43 ++++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 21 deletions(-) diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index 59949daf21..2367eccb3b 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -58,6 +58,7 @@ #:use-module (guix build-system python) #:use-module (guix download) #:use-module (guix git-download) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix utils) #:use-module (gnu packages) @@ -575,27 +576,27 @@ to all types of devices that provide serial consoles.") (base32 "0dgrb5yg4ys1fa4hs95iz3m2yhryfzzw0j6g6yf6vhbys4ihcf40")))) (build-system gnu-build-system) (arguments - `(#:make-flags - (list (string-append "CC=" ,(cc-for-target)) - (string-append "prefix=" (assoc-ref %outputs "out")) - (string-append "pkgdocdir=$(docdir)/" ,name "-" ,version)) - #:phases - (modify-phases %standard-phases - (delete 'configure) ; no configure script - (add-before 'check 'patch-tests - (lambda _ - (substitute* "GNUmakefile" - (("/bin/bash") - (which "bash")) - ;; XXX In the build environment, $(PWD) is the *parent* directory - ;; /tmp/guix-build-beep-x.y.drv-0! A pure guix shell works fine. - (("\\$\\(PWD\\)" pwd) - (string-append pwd "/source"))) - (substitute* (find-files "tests" "\\.expected") - ;; The build environment lacks /dev/{console,tty*}. - ;; In fact, even nckx's regular Guix System lacks ttyS1… - ((": Permission denied") - ": No such file or directory"))))))) + (list #:make-flags + #~(list (string-append "CC=" #$(cc-for-target)) + (string-append "prefix=" #$output) + (string-append "pkgdocdir=$(docdir)/" #$name "-" #$version)) + #:phases + #~(modify-phases %standard-phases + (delete 'configure) ; no configure script + (add-before 'check 'patch-tests + (lambda _ + (substitute* "GNUmakefile" + (("/bin/bash") + (which "bash")) + ;; XXX In the build environment, $(PWD) is the *parent* directory + ;; /tmp/guix-build-beep-x.y.drv-0! A pure guix shell works fine. + (("\\$\\(PWD\\)" pwd) + (string-append pwd "/source"))) + (substitute* (find-files "tests" "\\.expected") + ;; The build environment lacks /dev/{console,tty*}. + ;; In fact, even nckx's regular Guix System lacks ttyS1… + ((": Permission denied") + ": No such file or directory"))))))) (synopsis "Linux command-line utility to control the PC speaker") (description "beep allows the user to control the PC speaker with precision, allowing different sounds to indicate different events. While it can be run -- cgit v1.2.3 From f04dceac726873f0fef725eb05f5f7ca0cb204b3 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 8 May 2022 02:00:00 +0200 Subject: gnu: beep: Drop obsolete $(pkgdocdir) make flag. * gnu/packages/terminals.scm (beep)[arguments]: Remove "pkgdocdir=" from #:make-flags. --- gnu/packages/terminals.scm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index 2367eccb3b..c5877affc2 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -578,8 +578,7 @@ to all types of devices that provide serial consoles.") (arguments (list #:make-flags #~(list (string-append "CC=" #$(cc-for-target)) - (string-append "prefix=" #$output) - (string-append "pkgdocdir=$(docdir)/" #$name "-" #$version)) + (string-append "prefix=" #$output)) #:phases #~(modify-phases %standard-phases (delete 'configure) ; no configure script -- cgit v1.2.3 From 96795f6be37381fa5d062d4f8c56626175ac62b7 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Mon, 9 May 2022 21:55:12 -0400 Subject: gnu: linux-libre: Update to 5.17.6. * gnu/packages/linux.scm (linux-libre-5.17-version): Update to 5.17.6. (linux-libre-5.17-pristine-source, deblob-scripts-5.17): Update hashes. --- gnu/packages/linux.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 9bb2314ebd..ffcf7e7e6a 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -361,17 +361,17 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The current "stable" kernels. That is, the most recently released major ;; versions that are still supported upstream. -(define-public linux-libre-5.17-version "5.17.5") +(define-public linux-libre-5.17-version "5.17.6") (define-public linux-libre-5.17-gnu-revision "gnu") (define deblob-scripts-5.17 (linux-libre-deblob-scripts linux-libre-5.17-version linux-libre-5.17-gnu-revision (base32 "08ip5g827f30qzb3j2l19zkbdqv00sij46nbrjg75h5kkasdbfgr") - (base32 "0h9zm17lb5g93yp8rdzbhznrd5jbrl2k096c28wz6ic6gpz0wrvh"))) + (base32 "1zd4ds6ha4a2acqnalp234r2m9rz9p30qmy1aqri78i06aw7flwn"))) (define-public linux-libre-5.17-pristine-source (let ((version linux-libre-5.17-version) - (hash (base32 "11z95wsgmj97pg77yck26l0383gncbla0zwpzv4gjdj4p62x3g4v"))) + (hash (base32 "035i9i0gg3fxi5ighjrya97592sk0i4xagra6a8m8nxyh21z3k34"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.17))) -- cgit v1.2.3 From f8057fdb7ef3ffcf0f9e27c099ad396846e7339a Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Mon, 9 May 2022 21:55:52 -0400 Subject: gnu: linux-libre 5.15: Update to 5.15.38. * gnu/packages/linux.scm (linux-libre-5.15-version): Update to 5.15.38. (linux-libre-5.15-pristine-source, deblob-scripts-5.15): Update hashes. --- gnu/packages/linux.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index ffcf7e7e6a..5d94d3890e 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -379,17 +379,17 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The "longterm" kernels — the older releases with long-term upstream support. ;; Here are the support timelines: ;; -(define-public linux-libre-5.15-version "5.15.37") +(define-public linux-libre-5.15-version "5.15.38") (define-public linux-libre-5.15-gnu-revision "gnu") (define deblob-scripts-5.15 (linux-libre-deblob-scripts linux-libre-5.15-version linux-libre-5.15-gnu-revision (base32 "1n57mz5agvf1d0ggbg080d7hvx8p9y0iqxkq4ypg10a7n96zy7y5") - (base32 "1s2s1sjdhblaz80shq1jgp4kp9vi7j1bsh4vvsk28s5m6xwf6yvl"))) + (base32 "0gs92qbpvirwd02rpwwnja7771z2azbiy9ppy9ynpr14lxmzxnnh"))) (define-public linux-libre-5.15-pristine-source (let ((version linux-libre-5.15-version) - (hash (base32 "09n0l9ly111r6jbpgz1kw2q4n4mmcv5jxfhs5bcsiyjp44d0kgqq"))) + (hash (base32 "0lhhl766mrl2mbbvn7gkajfzja4v1f96xm9qq3z8pf4h1515shby"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.15))) -- cgit v1.2.3 From 2d7264721e75ce25925febba00fdb29a1e38bc83 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Mon, 9 May 2022 21:56:42 -0400 Subject: gnu: linux-libre 5.10: Update to 5.10.114. * gnu/packages/linux.scm (linux-libre-5.10-version): Update to 5.10.114. (linux-libre-5.10-pristine-source, deblob-scripts-5.10): Update hashes. --- gnu/packages/linux.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 5d94d3890e..7b71c7229e 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -394,17 +394,17 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-5.15))) -(define-public linux-libre-5.10-version "5.10.113") +(define-public linux-libre-5.10-version "5.10.114") (define-public linux-libre-5.10-gnu-revision "gnu1") (define deblob-scripts-5.10 (linux-libre-deblob-scripts linux-libre-5.10-version linux-libre-5.10-gnu-revision (base32 "0mw7qn77y9c6wrnw4rjvf75cpm1w6n1aqqhf8cnghcb97p2yxxrf") - (base32 "0wx0y9fbgfbmhdb8v4ki2hq58m0w6gp66wq944sr5x0sv6m4bgf3"))) + (base32 "1xyhz0dyrkg2avz382ly3dzpa5v89x49gfzx80c1drpwsk7jg6gp"))) (define-public linux-libre-5.10-pristine-source (let ((version linux-libre-5.10-version) - (hash (base32 "1z3dd5hrdbn2axsi2n70n41q1dq2dvg7s8aph1p6yiajpc16llc2"))) + (hash (base32 "09h5ngcl8clsvsv11q6ksvgcs01whlwbbrlpj1jz8mg3gjsrzl07"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.10))) -- cgit v1.2.3 From b33ebc22fb2bb578c8150398538884439f36dfde Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Mon, 9 May 2022 21:57:20 -0400 Subject: gnu: linux-libre 5.4: Update to 5.4.192. * gnu/packages/linux.scm (linux-libre-5.4-version): Update to 5.4.192. (linux-libre-5.4-pristine-source, deblob-scripts-5.4): Update hashes. --- gnu/packages/linux.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 7b71c7229e..b3723c513d 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -409,17 +409,17 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-5.10))) -(define-public linux-libre-5.4-version "5.4.191") +(define-public linux-libre-5.4-version "5.4.192") (define-public linux-libre-5.4-gnu-revision "gnu1") (define deblob-scripts-5.4 (linux-libre-deblob-scripts linux-libre-5.4-version linux-libre-5.4-gnu-revision (base32 "1nlgk8ajb5wl3aa96h9a0pb9j5a5wmrbpk63varn557x1d00r7wj") - (base32 "1mp9d0b7mqw7cl65k0a18265cvn4qwcpnvna8r6n5m3y4pz3rik9"))) + (base32 "05i286d98fm2pdf9724x1dsmfcm7gsd7yyyvxqlpisyj1kx14hda"))) (define-public linux-libre-5.4-pristine-source (let ((version linux-libre-5.4-version) - (hash (base32 "0fharjqasvq76pciwci6qamdadpfjh2n8gdyri8fj65drmgsi318"))) + (hash (base32 "14wyvacajnj6fnxqrash7b8inq0lgmglydqa30kb21zva88jwj1j"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.4))) -- cgit v1.2.3 From 2e0d02ebe351024cd97911cb1e5e1a6af1edc7f0 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Thu, 12 May 2022 08:42:09 +0300 Subject: gnu: agda.scm: Add missing import. * gnu/packages/agda.scm: Also use (guix gexp). --- gnu/packages/agda.scm | 1 + 1 file changed, 1 insertion(+) diff --git a/gnu/packages/agda.scm b/gnu/packages/agda.scm index 87e787b72d..038b38195f 100644 --- a/gnu/packages/agda.scm +++ b/gnu/packages/agda.scm @@ -29,6 +29,7 @@ #:use-module (guix build-system gnu) #:use-module (guix build-system haskell) #:use-module (guix build-system trivial) + #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix git-download) #:use-module ((guix licenses) #:prefix license:) -- cgit v1.2.3 From a1a55e5b607bc5ebb3310b5c592f2a2b1161625a Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Thu, 12 May 2022 12:58:04 +0530 Subject: gnu: fastahack: Wrap long line. * gnu/packages/bioinformatics.scm (fastahack): Wrap long line. --- gnu/packages/bioinformatics.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 28b3be2308..33bf0921d1 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -14503,7 +14503,8 @@ neural networks.") (build-system gnu-build-system) (arguments (list #:make-flags #~(list (string-append "CXX=" #$(cxx-for-target))) - #:tests? #f ; Unclear how to run tests: https://github.com/ekg/fastahack/issues/15 + ;; Unclear how to run tests: https://github.com/ekg/fastahack/issues/15 + #:tests? #f #:phases #~(modify-phases %standard-phases (delete 'configure) ; There is no configure phase. -- cgit v1.2.3 From 8980f6c5322a8d24b6c7b52f9aaff5eef7e22a5e Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Thu, 12 May 2022 13:29:57 +0530 Subject: gnu: quark: Use G-expressions. * gnu/packages/web.scm (quark)[arguments]: Rewrite using G-expressions. --- gnu/packages/web.scm | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 5e200d13cc..c56ec186f8 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -15,7 +15,7 @@ ;;; Copyright © 2016 Ben Woodcroft ;;; Copyright © 2016 Clément Lassieur ;;; Copyright © 2016, 2017 Nikita -;;; Copyright © 2016, 2017, 2018, 2019, 2021 Arun Isaac +;;; Copyright © 2016–2022 Arun Isaac ;;; Copyright © 2016–2022 Tobias Geerinckx-Rice ;;; Copyright © 2016 Bake Timmons ;;; Copyright © 2017 Thomas Danckaert @@ -8199,13 +8199,13 @@ Unicode.") "1znvnr30xi5vgd6n3wvgv9pwj992zpzzjk0fmq28ydf1l6kqvkm7")))) (build-system gnu-build-system) (arguments - `(#:tests? #f ; no tests - #:make-flags - (list (string-append "CC=" ,(cc-for-target)) - (string-append "PREFIX=" %output)) - #:phases - (modify-phases %standard-phases - (delete 'configure)))) ; no configure script + (list #:tests? #f ; no tests + #:make-flags + #~(list (string-append "CC=" #$(cc-for-target)) + (string-append "PREFIX=" (assoc-ref %outputs "out"))) + #:phases + #~(modify-phases %standard-phases + (delete 'configure)))) ; no configure script (home-page "https://tools.suckless.org/quark/") (synopsis "Small and simple HTTP GET/HEAD-only web server for static content") -- cgit v1.2.3 From af375c63945819128375226cb987bc90a9a88743 Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Wed, 11 May 2022 23:59:05 -0400 Subject: gnu: racket: Update to 8.5. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/patches/racket-gui-tethered-launcher-backport.patch, gnu/packages/patches/racket-enable-scheme-backport.patch: Delete files. * gnu/local.mk (dist_patch_DATA): Remove them. * gnu/packages/chez.scm (chez-scheme-for-racket): Update to 9.5.7.6. * gnu/packages/racket.scm (%racket-version): Update to 8.5. (%racket-origin)[patches]: Remove obsolete patches. (racket-vm-common-configure-flags): Correct comment. (racket)[inputs]<2d, datalog, deinprogramm, draw, drracket, expeditor, htdp, pict, plot, quickscript, racklog, rackunit, redex, scribble, typed-racket, string-constants, syntax-color, web-server, xrepl>: Update checksums. : Likewise, and remove obsolete backports. Signed-off-by: Ludovic Courtès --- gnu/local.mk | 2 - gnu/packages/chez.scm | 4 +- .../patches/racket-enable-scheme-backport.patch | 465 --------------------- .../racket-gui-tethered-launcher-backport.patch | 26 -- gnu/packages/racket.scm | 82 ++-- 5 files changed, 32 insertions(+), 547 deletions(-) delete mode 100644 gnu/packages/patches/racket-enable-scheme-backport.patch delete mode 100644 gnu/packages/patches/racket-gui-tethered-launcher-backport.patch diff --git a/gnu/local.mk b/gnu/local.mk index ed901a5ba8..d7788796cc 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1757,8 +1757,6 @@ dist_patch_DATA = \ %D%/packages/patches/ripperx-missing-file.patch \ %D%/packages/patches/rpcbind-CVE-2017-8779.patch \ %D%/packages/patches/rtags-separate-rct.patch \ - %D%/packages/patches/racket-enable-scheme-backport.patch \ - %D%/packages/patches/racket-gui-tethered-launcher-backport.patch \ %D%/packages/patches/racket-minimal-sh-via-rktio.patch \ %D%/packages/patches/remake-impure-dirs.patch \ %D%/packages/patches/restic-0.9.6-fix-tests-for-go1.15.patch \ diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm index d47225dbe5..a7f75a731a 100644 --- a/gnu/packages/chez.scm +++ b/gnu/packages/chez.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2017, 2019 Tobias Geerinckx-Rice ;;; Copyright © 2019 Brett Gilio ;;; Copyright © 2020 Brendan Tildesley -;;; Copyright © 2021 Philip McGrath +;;; Copyright © 2021, 2022 Philip McGrath ;;; ;;; This file is part of GNU Guix. ;;; @@ -361,7 +361,7 @@ and 32-bit PowerPC architectures.") (package (inherit chez-scheme) (name "chez-scheme-for-racket") - (version "9.5.7.3") + (version "9.5.7.6") ;; The version should match `(scheme-fork-version-number)`. ;; See racket/src/ChezScheme/s/cmacros.ss c. line 360. ;; It will always be different than the upstream version! diff --git a/gnu/packages/patches/racket-enable-scheme-backport.patch b/gnu/packages/patches/racket-enable-scheme-backport.patch deleted file mode 100644 index 3a5a4a3d82..0000000000 --- a/gnu/packages/patches/racket-enable-scheme-backport.patch +++ /dev/null @@ -1,465 +0,0 @@ -From 8d7687842f099e3e7e60d3a83fed58b2c6a92863 Mon Sep 17 00:00:00 2001 -From: Matthew Flatt -Date: Sun, 6 Feb 2022 10:36:09 -0700 -Subject: [PATCH 1/2] Chez Scheme: adapt bootfile build for supplied `Scheme=` - -(cherry picked from commit fca1e02349664060e10278ca2ce6577a949bebf5) - -(Fixed conflicts by dropping pbchunks and pbarch changes.) ---- - racket/src/ChezScheme/configure | 15 ++++++++++++++- - racket/src/ChezScheme/s/Mf-base | 4 ++-- - racket/src/ChezScheme/s/Mf-cross | 4 +++- - 3 files changed, 19 insertions(+), 4 deletions(-) - -diff --git a/racket/src/ChezScheme/configure b/racket/src/ChezScheme/configure -index 4515ffc105..0098829091 100755 ---- a/racket/src/ChezScheme/configure -+++ b/racket/src/ChezScheme/configure -@@ -45,6 +45,7 @@ threads=yes - nothreads=no - temproot="" - help=no -+forceworkarea=no - gzipmanpages=yes - installowner="" - installgroup="" -@@ -205,6 +206,9 @@ while [ $# != 0 ] ; do - --pb) - pb=yes - ;; -+ --force) -+ forceworkarea=yes -+ ;; - --installprefix=*) - installprefix=`echo $1 | sed -e 's/^--installprefix=//'` - ;; -@@ -439,6 +443,7 @@ if [ "$help" = "yes" ]; then - echo " --toolprefix= prefix tool (compiler, linker, ...) names" - echo " --[no]gzip-man-pages compress manual pages ($gzipmanpages)" - echo " --workarea= build directory ($w)" -+ echo " --force configure even without boot files" - echo " CC= C compiler" - echo " CPPFLAGS= C preprocessor flags" - echo " CFLAGS= C compiler flags" -@@ -721,8 +726,16 @@ case "${flagsmuni}" in - ;; - esac - -+if [ "$w" = "$m" ] ; then -+ configuringin="" -+else -+ configuringin=" in $w" -+fi -+ - if [ -f boot/$m/scheme.boot -o -f "$srcdir"/boot/$m/scheme.boot ] ; then -- echo "Configuring for $m" -+ echo "Configuring for $m$configuringin" -+elif [ "$forceworkarea" = yes ] ; then -+ echo "Configuring for $m$configuringin despite missing boot files" - else - if [ "$m" = "" ] ; then - maybem="" -diff --git a/racket/src/ChezScheme/s/Mf-base b/racket/src/ChezScheme/s/Mf-base -index cc6178c973..1f4a967998 100644 ---- a/racket/src/ChezScheme/s/Mf-base -+++ b/racket/src/ChezScheme/s/Mf-base -@@ -94,7 +94,7 @@ endif - # that Scheme and SCHEMEHEAPDIRS are set by Mf-cross to point to the host Scheme - # implementation - Scheme = ../bin/$m/scheme${ExeSuffix} --export SCHEMEHEAPDIRS=../boot/%m -+export SCHEMEHEAPDIRS=../boot/$m - export CHEZSCHEMELIBDIRS=. - - # Define the libdirs separator character -@@ -691,4 +691,4 @@ reset-one: - - .PHONY: run - run: -- env SCHEMEHEAPDIRS=../boot/$m/ ../bin/$m/scheme $(ARGS) -+ env SCHEMEHEAPDIRS=${SCHEMEHEAPDIRS} ${Scheme} $(ARGS) -diff --git a/racket/src/ChezScheme/s/Mf-cross b/racket/src/ChezScheme/s/Mf-cross -index d796cbb459..397af59a28 100644 ---- a/racket/src/ChezScheme/s/Mf-cross -+++ b/racket/src/ChezScheme/s/Mf-cross -@@ -43,5 +43,7 @@ x$(xm).$(m): - $(MAKE) -f Mf-cross m=$(m) xm=$(xm) i=f o=3 d=0 xpatch - mv xpatch x$(xm).$(m) - -+ifneq ($(SCHEMEHEAPDIRS),:) - # Ensure that cross-compiling "nanopass.so" is rebuilt if the host compiler changed --nanopass.so: ${SCHEME} ${SCHEMEHEAPDIRS}/petite.boot ${SCHEMEHEAPDIRS}/scheme.boot -+nanopass.so: ${Scheme} ${SCHEMEHEAPDIRS}/petite.boot ${SCHEMEHEAPDIRS}/scheme.boot -+endif --- -2.32.0 - - -From 26c8e2c1d9b02ad85acef8bda40d92154cf0b699 Mon Sep 17 00:00:00 2001 -From: Matthew Flatt -Date: Sun, 6 Feb 2022 11:03:30 -0700 -Subject: [PATCH 2/2] configure: make `--enable-scheme` work with an executable - -When the same Chez Scheme version as used by Racket is already -available, then `--enable-scheme=...` can supply an executable. For -cross builds, `--enable-scheme=...` can still supply a build -directory, instead, as before. - -(cherry picked from commit 4f0e76855ce7e86107de495292a553469daf0b3f) ---- - racket/src/ChezScheme/makefiles/Makefile.in | 3 ++ - racket/src/README.txt | 30 +++++++++++--- - racket/src/configure | 8 +++- - racket/src/cs/README.txt | 6 ++- - racket/src/cs/c/Makefile.in | 44 ++++++++++++++++----- - racket/src/cs/c/configure | 24 +++++++++-- - racket/src/cs/c/configure.ac | 21 ++++++++-- - 7 files changed, 112 insertions(+), 24 deletions(-) - -diff --git a/racket/src/ChezScheme/makefiles/Makefile.in b/racket/src/ChezScheme/makefiles/Makefile.in -index c396efc851..3998ef9ccd 100644 ---- a/racket/src/ChezScheme/makefiles/Makefile.in -+++ b/racket/src/ChezScheme/makefiles/Makefile.in -@@ -59,6 +59,9 @@ reset: - %.boot: - (cd $(workarea) && $(MAKE) $*.boot) - -+auto.boot: -+ (cd $(workarea) && $(MAKE) $(defaultm).boot) -+ - # .bootquick to build boot files for - # with o=3 d=0 for the cross compiler, and only after - # building the kernel for the configured machine -diff --git a/racket/src/README.txt b/racket/src/README.txt -index 98647aebce..d77310b4a4 100644 ---- a/racket/src/README.txt -+++ b/racket/src/README.txt -@@ -354,6 +354,10 @@ variant of MinGW without "libdelayimp.a", get the implementation of - ======================================================================== - - Cross-compilation requires at least two flags to `configure`: -+`--host=OS` and either `--enable-racket=RACKET` or (for Racket CS) -+`--enable-scheme-SCHEME`. -+ -+More information: - - * `--host=OS`, where OS is something like `i386-gnu-linux` to - indicate the target platform. -@@ -374,11 +378,27 @@ Cross-compilation requires at least two flags to `configure`: - run `configure` again (with no arguments) in a "local" subdirectory - to create a build for the current platform. - --An additional flag is needed for building Racket CS, unless the flag --`--enable-racket=auto` is used: -- -- * `--enable-scheme=DIR`, where DIR is a path that has a "ChezScheme" -- directory where Chez Scheme is built for the host system. -+ * `--enable-scheme=SCHEME`, where SCHEME is a Chez Scheme executable -+ executable that runs on the build platform; the executable must be -+ the same version as used in Racket built for the target platform. -+ -+ Supplying `--enable-scheme=DIR` is also supported in cross-build -+ mode, where DIR is a path that has a "ChezScheme" directory where -+ Chez Scheme is built for the host system. -+ -+The `--enable-racket=RACKET` and `--enable-scheme=SCHEME` flags are -+allowed for non-cross builds, too: -+ -+ * For Racket CS, supplying either selects a Racket or Chez Scheme -+ implementation used to create boot files to the build platform. -+ Suppling Chez Scheme is a much more direct path, but when Racket is -+ supplied, its version does not have to match the version being -+ built. -+ -+ * For Racket BC, `--enable-racket=RACKET` selects a Racket for -+ prepare C sources to cooperate with garbage collection. Its version -+ needs to be close to the one being built, and potentially exactly -+ the same version. - - Some less commonly needed `configure` flags are for Racket BC: - -diff --git a/racket/src/configure b/racket/src/configure -index c9f3ba4419..1b53ec7ce2 100755 ---- a/racket/src/configure -+++ b/racket/src/configure -@@ -9,6 +9,7 @@ pb_dir="$dir/ChezScheme/boot/pb" - use_cs=maybe - use_bc=maybe - supplied_racket=no -+supplied_scheme=no - enable_boothelp= - - # We don't have to detect conflicts like `--enable-csdefault --enable-bcdefault`, -@@ -34,6 +35,9 @@ for arg in $*; do - --enable-racket=*) - supplied_racket=yes - ;; -+ --enable-scheme=*) -+ supplied_scheme=yes -+ ;; - --help | -h) - echo $0: - echo see --help-bc or --help-cs, since the Racket CS build and the -@@ -70,8 +74,8 @@ elif test "$use_cs" = "maybe" ; then - fi - - if test "$use_cs" = "yes" ; then -- if test $use_bc = no -a $supplied_racket = no -a ! -d "$pb_dir" ; then -- echo $0: must have $pb_dir or --enable-racket=... for --enable-csonly -+ if test $use_bc = no -a $supplied_racket = no -a $supplied_scheme = no -a ! -d "$pb_dir" ; then -+ echo $0: must have $pb_dir, --enable-racket=... or --enable-scheme=... for --enable-csonly - exit 1 - fi - -diff --git a/racket/src/cs/README.txt b/racket/src/cs/README.txt -index 2ece417b78..8e6fc57b74 100644 ---- a/racket/src/cs/README.txt -+++ b/racket/src/cs/README.txt -@@ -39,6 +39,11 @@ build: - installed in the "../ChezScheme/boot/pb" directory as described by - "../ChezScheme/BUILDING". - -+ Supplying `--enable-scheme=...` is also an option if you alerady -+ have the same version of Chez Scheme built on the current platform. -+ Another build will be created, anyway, but more quickly than -+ without Chez Scheme. -+ - * Racket is needed to generate the files in the "schemified" - directory from the sources in sibling directories like "../io". The - Racket version must be practically the same as the current Racket -@@ -48,7 +53,6 @@ build: - Unlike Chez Scheme boot files, the files generated in "schemified" - are human-readable and -editable Scheme code. That provides a way - out of bootstrapping black holes, even without BC. -- - - - ======================================================================== -diff --git a/racket/src/cs/c/Makefile.in b/racket/src/cs/c/Makefile.in -index 54a644a1d9..d73993f0fc 100644 ---- a/racket/src/cs/c/Makefile.in -+++ b/racket/src/cs/c/Makefile.in -@@ -12,7 +12,9 @@ CS_HOST_WORKAREA_PREFIX = @CS_HOST_WORKAREA_PREFIX@ - SCHEME_HOST_WORKAREA = $(CS_HOST_WORKAREA_PREFIX)$(SCHEME_WORKAREA) - SCHEME_BIN = $(SCHEME_HOST_WORKAREA)/$(MACH)/bin/$(MACH)/scheme - SCHEME_INC = $(SCHEME_HOST_WORKAREA)/$(MACH)/boot/$(MACH) --SCHEME = $(SCHEME_BIN) -B $(SCHEME_INC)/petite.boot -B $(SCHEME_INC)/scheme.boot -+SCHEME_built = $(SCHEME_BIN) -B $(SCHEME_INC)/petite.boot -B $(SCHEME_INC)/scheme.boot -+SCHEME_existing = @MAKE_SCHEME_SCHEME@ -+SCHEME = $(SCHEME@USE_SCHEME_MODE@) - - TARGET_MACH = @TARGET_MACH@ - SCHEME_TARGET_INC = $(SCHEME_WORKAREA)/$(TARGET_MACH)/boot/$(TARGET_MACH) -@@ -88,7 +90,7 @@ mainsrcdir = @srcdir@/../.. - @INCLUDEDEP@ @srcdir@/../../version/version.mak - - cs: -- $(MAKE) scheme@T_CROSS_MODE@ -+ $(MAKE) scheme@MAKE_SCHEME_MODE@ - $(MAKE) racket-so - cd rktio; $(MAKE) - $(MAKE) racketcs -@@ -121,9 +123,13 @@ racket-so: - - RACKET_SO_ENV = @CONFIGURE_RACKET_SO_COMPILE@ - -+TARGET_MACH_built = $(TARGET_MACH) -+TARGET_MACH_existing = xc-$(TARGET_MACH) -+XPATCH_FILE = $(SCHEME_WORKAREA)/$(TARGET_MACH@USE_SCHEME_MODE@)/s/xpatch -+ - CS_PROGS = SCHEME="$(SCHEME)" - CS_OPTS = COMPRESS_COMP=@COMPRESS_COMP@ @ENABLE_OR_DISABLE_WPO@ --CS_OPTScross = $(CS_OPTS) CSO=$(MACH) CROSS_COMP="--xpatch $(SCHEME_WORKAREA)/$(TARGET_MACH)/s/xpatch" -+CS_OPTScross = $(CS_OPTS) CSO=$(MACH) CROSS_COMP="--xpatch $(XPATCH_FILE)" - PASS_COMPILE_DEPS = EXTRA_COMPILE_DEPS="$(SCHEME_INC)/petite.boot $(SCHEME_INC)/scheme.boot" - - build-racket-so: -@@ -163,6 +169,15 @@ pb-bootquick: - cd $(SCHEME_WORKAREA) && $(MAKE) reset - $(SHELL) $(srcdir)/ready_boot.sh $(MACH) $(SCHEME_WORKAREA) - -+scheme-via-scheme: -+ $(MAKE) $(SCHEME_WORKAREA)/boot/$(MACH)/scheme.boot -+ $(MAKE) mach-make -+ -+$(SCHEME_WORKAREA)/boot/$(MACH)/scheme.boot: -+ mkdir -p $(SCHEME_WORKAREA) -+ $(MAKE) config-scheme CONFIG_SCHEME_MODE="$(CONFIG_SCHEME_MODE) --force" -+ cd $(SCHEME_WORKAREA) && $(MAKE) $(MACH).boot Scheme="$(SCHEME)" SCHEMEHEAPDIRS=: o=3 d=0 what=all -+ - mach-make: - $(MAKE) config-scheme - cd $(SCHEME_WORKAREA) && $(MAKE) -@@ -182,24 +197,33 @@ config-scheme: - - scheme-cross: - env MAKE_BOOT_FOR_CROSS=yes SCHEME_SRC="$(SCHEME_DIR)" SCHEME_WORKAREA=$(SCHEME_WORKAREA) MACH="$(TARGET_MACH)" $(BOOTSTRAP_RACKET) "$(SCHEME_DIR)"/rktboot/make-boot.rkt -+ $(MAKE) finish-scheme-cross -+ -+finish-scheme-cross: - $(SHELL) $(srcdir)/reset_boot.sh $(TARGET_MACH) $(SCHEME_WORKAREA) - cd $(SCHEME_WORKAREA) && "$(UP_SCHEME_DIR)"/configure @SCHEME_CROSS_CONFIG_ARGS@ $(SCHEME_CONFIG_VARS) - cd $(SCHEME_WORKAREA)/$(TARGET_MACH)/c && $(CHOST_HACK@T_CROSS_MODE@) $(MAKE) o=o cross=t -- $(MAKE) $(SCHEME_WORKAREA)/$(TARGET_MACH)/s/xpatch -+ $(MAKE) $(XPATCH_FILE) -+ -+scheme-cross-via-scheme: -+ $(MAKE) $(SCHEME_WORKAREA)/boot/$(TARGET_MACH)/scheme.boot MACH=$(TARGET_MACH) -+ $(MAKE) finish-scheme-cross - - # Rebuild patch file and cross "petite.boot" and "scheme.boot" when older --# than the build-host "scheme.boot" or when "make-boot.rkt" touchs dummy boot files --XPATCH_DEPS = $(SCHEME_HOST_WORKAREA)/$(MACH)/boot/$(MACH)/scheme.boot \ -- $(SCHEME_WORKAREA)/boot/$(TARGET_MACH)/scheme.boot -+# than the build- use as Racket for build; or "auto" to create -- --enable-scheme= use as host's build directory for cross -+ --enable-scheme= use as host build for cross - --enable-mach= use Chez Scheme machine type - --enable-target= cross-build for Chez Scheme machine type - --enable-portable prefer portable to host-specific -@@ -2867,7 +2870,7 @@ show_explicitly_enabled "${enable_xonx}" "Unix style" - show_explicitly_enabled "${enable_libzo}" 'Compiled ".zo" files moved to lib' - - show_explicitly_set "${enable_racket}" "Racket" --show_explicitly_set "${enable_scheme}" "Chez Scheme build directory" -+show_explicitly_set "${enable_scheme}" "Chez Scheme for build" - show_explicitly_set "${enable_mach}" "machine type" - show_explicitly_set "${enable_target}" "cross-build machine type" - show_explicitly_enabled "${enable_portable}" "portable" -@@ -4745,9 +4748,21 @@ esac - - SCHEME_DIR=${srcdir}/../../ChezScheme - MAKE_BUILD_SCHEME=checkout -+USE_SCHEME_MODE="_built" -+MAKE_SCHEME_MODE="${T_CROSS_MODE}" - - if test "${enable_scheme}" != "" ; then -- CS_HOST_WORKAREA_PREFIX="${enable_scheme}/" -+ if test -d "${enable_scheme}" ; then -+ # Directory exists, so use it as a build directory -+ echo "Using supplied Scheme path as a build directory" -+ CS_HOST_WORKAREA_PREFIX="${enable_scheme}/" -+ else -+ # Directory does not exist, so assume it's an executable -+ echo "Using supplied Scheme path as an executable" -+ MAKE_SCHEME_MODE="${T_CROSS_MODE}-via-scheme" -+ MAKE_SCHEME_SCHEME="${enable_scheme}" -+ USE_SCHEME_MODE="_existing" -+ fi - fi - - if test "${enable_racket}" != "" ; then -@@ -6012,6 +6027,9 @@ SCHEME_CROSS_CONFIG_ARGS="--machine=${TARGET_MACH} --disable-x11 ${cs_auto_flags - - - -+ -+ -+ - - - -diff --git a/racket/src/cs/c/configure.ac b/racket/src/cs/c/configure.ac -index 464ebe1760..aaee88156d 100644 ---- a/racket/src/cs/c/configure.ac -+++ b/racket/src/cs/c/configure.ac -@@ -23,7 +23,7 @@ AC_ARG_ENABLE(compressmore, [ --enable-compressmore compress compiled code ev - AC_ARG_ENABLE(compressboot, [ --enable-compressboot compress boot files]) - m4_include(../ac/path_arg.m4) - AC_ARG_ENABLE(racket, [ --enable-racket= use as Racket for build; or "auto" to create]) --AC_ARG_ENABLE(scheme, [ --enable-scheme= use as host's build directory for cross]) -+AC_ARG_ENABLE(scheme, [ --enable-scheme= use as host build for cross]) - AC_ARG_ENABLE(mach, [ --enable-mach= use Chez Scheme machine type ]) - AC_ARG_ENABLE(target, [ --enable-target= cross-build for Chez Scheme machine type ]) - m4_include(../ac/portable_arg.m4) -@@ -81,7 +81,7 @@ show_explicitly_disabled "${enable_compressboot}" "Compressed boot files" - show_explicitly_enabled "${enable_xonx}" "Unix style" - m4_include(../ac/path_show.m4) - show_explicitly_set "${enable_racket}" "Racket" --show_explicitly_set "${enable_scheme}" "Chez Scheme build directory" -+show_explicitly_set "${enable_scheme}" "Chez Scheme for build" - show_explicitly_set "${enable_mach}" "machine type" - show_explicitly_set "${enable_target}" "cross-build machine type" - m4_include(../ac/portable_show.m4) -@@ -504,9 +504,21 @@ esac - - SCHEME_DIR=${srcdir}/../../ChezScheme - MAKE_BUILD_SCHEME=checkout -+USE_SCHEME_MODE="_built" -+MAKE_SCHEME_MODE="${T_CROSS_MODE}" - - if test "${enable_scheme}" != "" ; then -- CS_HOST_WORKAREA_PREFIX="${enable_scheme}/" -+ if test -d "${enable_scheme}" ; then -+ # Directory exists, so use it as a build directory -+ echo "Using supplied Scheme path as a build directory" -+ CS_HOST_WORKAREA_PREFIX="${enable_scheme}/" -+ else -+ # Directory does not exist, so assume it's an executable -+ echo "Using supplied Scheme path as an executable" -+ MAKE_SCHEME_MODE="${T_CROSS_MODE}-via-scheme" -+ MAKE_SCHEME_SCHEME="${enable_scheme}" -+ USE_SCHEME_MODE="_existing" -+ fi - fi - - if test "${enable_racket}" != "" ; then -@@ -821,6 +833,9 @@ AC_SUBST(DIFF_MACH) - AC_SUBST(CROSS_MODE) - AC_SUBST(T_CROSS_MODE) - AC_SUBST(TT_CROSS_MODE) -+AC_SUBST(MAKE_SCHEME_MODE) -+AC_SUBST(MAKE_SCHEME_SCHEME) -+AC_SUBST(USE_SCHEME_MODE) - AC_SUBST(SETUP_BOOT_MODE) - AC_SUBST(OSX) - AC_SUBST(NOT_OSX) --- -2.32.0 - diff --git a/gnu/packages/patches/racket-gui-tethered-launcher-backport.patch b/gnu/packages/patches/racket-gui-tethered-launcher-backport.patch deleted file mode 100644 index 1e018eaa79..0000000000 --- a/gnu/packages/patches/racket-gui-tethered-launcher-backport.patch +++ /dev/null @@ -1,26 +0,0 @@ -From aa792e707b1fbc5cc33691bfaee5828dc3fbebaa Mon Sep 17 00:00:00 2001 -From: Matthew Flatt -Date: Mon, 31 Jan 2022 15:31:22 -0700 -Subject: [PATCH] fix creation of tethered launchers - -Related to racket/racket#4133 - -(cherry picked from commit 563c68432f127729592f234ef30c31e92618b517) ---- - gui-lib/mred/installer.rkt | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/gui-lib/mred/installer.rkt b/gui-lib/mred/installer.rkt -index b1691472..9ef06c53 100644 ---- a/gui-lib/mred/installer.rkt -+++ b/gui-lib/mred/installer.rkt -@@ -72,4 +72,5 @@ - (list "-A" (path->string (find-system-path 'addon-dir))))) - - (define (config-flags) -- (list "-G" (path->string (find-config-dir)))) -+ (list "-X" (path->string (find-collects-dir)) -+ "-G" (path->string (find-config-dir)))) --- -2.32.0 - diff --git a/gnu/packages/racket.scm b/gnu/packages/racket.scm index 471a11dd48..c6f8ec20ba 100644 --- a/gnu/packages/racket.scm +++ b/gnu/packages/racket.scm @@ -195,7 +195,7 @@ racket-vm-cs racket-vm-bc)) -(define %racket-version "8.4") ; Remember to update chez-scheme-for-racket! +(define %racket-version "8.5") ; Remember to update chez-scheme-for-racket! (define %racket-commit (string-append "v" %racket-version)) (define %racket-origin @@ -205,11 +205,9 @@ (url "https://github.com/racket/racket") (commit %racket-commit))) (sha256 - (base32 "1vpl66gdgc8rnldmn8rmb7ar9l057jqjvgpfn29k57i3c5skr8s6")) + (base32 "0f9zyhdvbh4xsndrqjzl85j5ziz0rmqi676g9s1lw3h3skq2636h")) (file-name (git-file-name "racket" %racket-version)) - (patches (search-patches "racket-minimal-sh-via-rktio.patch" - ;; Remove by Racket 8.5: - "racket-enable-scheme-backport.patch")) + (patches (search-patches "racket-minimal-sh-via-rktio.patch")) (modules '((guix build utils))) (snippet #~(begin @@ -248,8 +246,10 @@ ,(string-append "CPPFLAGS=-DGUIX_RKTIO_PATCH_BIN_SH=" #$(file-append bash-minimal "/bin/sh")) "--disable-strip" - ;; XXX: origtree layout is required by some other packages down the - ;; bootstrap chain. Remove these flags as soon as we can do without them. + ;; Using --enable-origtree lets us distinguish the VM from subsequent + ;; layers and produces a build with the shape expected by tools such as + ;; "distro-build" and "raco-cross". Removing these flags would require + ;; changes, especially to 'configure-layer.rkt' (defined below). "--enable-origtree" ,(string-append "--prefix=" #$output "/opt/racket-vm"))) @@ -589,7 +589,7 @@ DrRacket IDE, are not included.") racket-minimal ;; <-- TODO non-tethered layer (racket-vm-for-system) (simple-racket-origin - "2d" (base32 "1zzcz5qyjv7syi41vb8jkxjp1rqgj61zbsdrg0nlc4qy9qsafzgr") + "2d" (base32 "0fb5v6058ls08xw3zbmqyr2ym0psm119gl9ffgmhm9w8rs9i4dq7") '("2d" "2d-doc" "2d-lib")) (simple-racket-origin "algol60" (base32 "09kj6asypmc24n29w0izc9p0q8hpga2hpkchsypfwn5c8zpvihlx") @@ -622,22 +622,22 @@ DrRacket IDE, are not included.") "data" (base32 "10iabgrk9alaggvksnyb0hdq7f1p30pq6pq2bcakvhzpxwiv1f55") '("data" "data-doc" "data-enumerate-lib" "data-lib")) (simple-racket-origin - "datalog" (base32 "0n5j5gnqh7g31mvgx19ggl18hirzbvq2r189lbngmnrmbc7b73fp") + "datalog" (base32 "0nf6cy4djpyhfvgpa6yn72apbz9s83gp0qg95pzjd0az4v6qwq1s") '(("datalog" "."))) (simple-racket-origin "db" (base32 "1n02ja0yj3mjjhmz0yv04yfhyvrsznbljn8bjviyfxnm4xf9rcc5") '("db" "db-doc" "db-lib")) (simple-racket-origin - "deinprogramm" (base32 "1is6fapgv6rxfjz47nh6qf3kh7y7sjdinakaxqffi46gf1al8prd") + "deinprogramm" (base32 "0g8flr1qg3bcyhdinqhs4w7dyisaqyailbxrjgd2a7zlqmdyicfr") '("deinprogramm" "deinprogramm-signature")) (simple-racket-origin "distributed-places" (base32 "1dajpkj9balqcpv6cdk9hwjz592h1vq8rrx5vncariiac4vbdpa0") '("distributed-places" "distributed-places-doc" "distributed-places-lib")) (simple-racket-origin - "draw" (base32 "1xgjfbh70hqw67z88iqqajg98d04qwbzn6im2wj47rs28jxlm9ly") + "draw" (base32 "1fpk85rs2crd63bxnmwj2pysisd62pxcqaip01si67dv1ri8ff92") '("draw" "draw-doc" "draw-lib")) (simple-racket-origin - "drracket" (base32 "0m3l4an3nq2ycd1h287s1az2v2zprjbzd8if2x7d5r71vaj4i00c") + "drracket" (base32 "0dipnz92c63zxys9z1kl5215rm7arc35g9r8bs8ivp96p75mljnz") '("drracket" "drracket-plugin-lib" "drracket-tool" @@ -657,7 +657,7 @@ DrRacket IDE, are not included.") "errortrace" (base32 "14m7rhaxngj36070iw15am434hm438pfgmwjfsiqhsglz4pcxhip") '("errortrace" "errortrace-doc" "errortrace-lib")) (simple-racket-origin - "expeditor" (base32 "07djzxs6307l51mcsk3yr2g4g47ayxa3878g7sf5xhqdr4hd9vxf") + "expeditor" (base32 "0mjfwb4wzwsg5xj3k6cmik0va432n56rp5h7rxx1c2yy3prh1j7q") '("expeditor" "expeditor-doc" "expeditor-lib")) (simple-racket-origin "frtime" (base32 "0ydz2yn8vvv6z7brwlswcyx0f31a6y6d443i89rysfvd2xkhpfd5") @@ -670,25 +670,14 @@ DrRacket IDE, are not included.") (simple-racket-origin "games" (base32 "0kpn3izlx1ccd0pj0dnvmnrhny51b85xy418a7psj70lz8j8415d") '(("games" "."))) - (racket-packages-origin - "gui" (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/racket/gui") - (commit %racket-commit))) - (sha256 (base32 - "1x33jgrx3r32k7hgwr591z3xqv1m2r5nc4km2fnxv0ak2xa0j3gj")) - (patches - ;; remove in Racket 8.5 - ;; see https://github.com/racket/racket/issues/4133 - (search-patches "racket-gui-tethered-launcher-backport.patch")) - (file-name (git-file-name "racket-gui" %racket-version))) + (simple-racket-origin + "gui" (base32 "0r3ck4gxdhnzr1a1fi0f1i7gwfip7akq10qgcxza66pp57hnl0wx") '("gui" "gui-doc" "gui-lib" "tex-table")) (simple-racket-origin "gui-pkg-manager" (base32 "1ji9448d723nklqvycwdswj0ni28sabrncag14f9mx47did5myb5") '("gui-pkg-manager-lib")) (simple-racket-origin - "htdp" (base32 "0r4ykybcpr10y2db9rlza9pr0xh58nd7ac389mjcxp8g386hgihl") + "htdp" (base32 "19xqixrqbwdxph17w9jga19008j88harb5wgml4hpqj3x0apx9g3") '("htdp" "htdp-doc" "htdp-lib")) (simple-racket-origin "html" (base32 "18n1jnjgzfknc8nv8dppi85nb8q08gqdwkg6hfjk08x0p00anx2x") @@ -756,7 +745,7 @@ DrRacket IDE, are not included.") "pconvert" (base32 "00czi0p399mmyrvxyrs5kniizpkqfxyz2ncxqi2jy79a7wk79pb1") '("pconvert-lib")) (simple-racket-origin - "pict" (base32 "0g1iwdr6qh1xb0crhj96830vjjnbds409xbpqn7j5sh0ksy6vr5x") + "pict" (base32 "0v7a3l77swsbh80mnb9rakdwgw7s66ji0mall7qcqfwyg1b4zmlv") '("pict" "pict-doc" "pict-lib")) (simple-racket-origin "pict-snip" (base32 "081nwiy4a0n4f7xws16hqbhf0j3kz5alizndi3nnyr3chm4kng6x") @@ -771,7 +760,7 @@ DrRacket IDE, are not included.") "planet" (base32 "0r2yqrzrmdjjyr14k6hhlzc5kzrcx3583m1s02mhrcmpfw0s85w9") '("planet" "planet-doc" "planet-lib")) (simple-racket-origin - "plot" (base32 "07kq32si34ybcwz8idxxcrzssg8diyrp1nfgkcj0mmvr45321zm7") + "plot" (base32 "04871pspbm0q3bz5896sa3jw2rp9i6jf0b5aivrxfp56vxxd2ybb") '("plot" "plot-compat" "plot-doc" "plot-gui-lib" "plot-lib")) (simple-racket-origin "preprocessor" (base32 "1p5aid58ifnjy4xl0ysh85cq39k25661v975jrpk182z3k5621mg") @@ -786,7 +775,7 @@ DrRacket IDE, are not included.") (url "https://github.com/Metaxal/quickscript") (commit %racket-commit))) (sha256 (base32 - "100g3yqhbjdq06b6l6d72ywsw29awgy8crqg33wj7h12xq07nzcr")) + "00sf5nw09aacd0l4a4cknnffvcs95p596im3blsdvfz5ck6jdwl8")) (file-name (git-file-name "Metaxal-quickscript" %racket-version))) '(("quickscript" "."))) (simple-racket-origin @@ -807,10 +796,10 @@ DrRacket IDE, are not included.") (git-file-name "jeapostrophe-racket-cheat" %racket-version))) '(("racket-cheat" "."))) (simple-racket-origin - "racklog" (base32 "1rgrvwy3kr9b9w5cghsffiv3ly00yfvvzr5xaaw83g1w7yin0mnb") + "racklog" (base32 "0fbq0fpfb3l6h7h772dvkmlzlk2dnq5f8296xx1qxhhwypibqzr9") '(("racklog" "."))) (simple-racket-origin - "rackunit" (base32 "057z31rja6h3nabh5b2xgwfrzmlm6h1cv1qcgf3xfy4g2q5dqn5p") + "rackunit" (base32 "0vfwcddzrgrdv5awjka7m0jzqhqvfc5wlkih83a670y96496a83n") '("rackunit" "rackunit-doc" "rackunit-gui" @@ -826,7 +815,7 @@ DrRacket IDE, are not included.") "realm" (base32 "0hxcgla08iack54j8v40fj51811chpy66ym2zq76zb52c7kzn0hi") '(("realm" "."))) (simple-racket-origin - "redex" (base32 "0vlgxbnbgrlihk1hh5zd6hsc4566ldi4q76f87z5vai54dxkwy2f") + "redex" (base32 "18rn8ddsqh1s7hdlb2cb9wxln63bz0wysjssaf9v92r712xnnv8i") '("redex" "redex-benchmark" "redex-doc" @@ -841,7 +830,7 @@ DrRacket IDE, are not included.") "scheme-lib" (base32 "0pcf0y8rp4qyjhaz5ww5sr5diq0wpcdfrrnask7zapyklzx1jx8x") '(("scheme-lib" "."))) (simple-racket-origin - "scribble" (base32 "0rgvnsykrxkah6s5fw1vyp9lxsb4z9w6hgwk5j6wbwjp2gsfczbm") + "scribble" (base32 "0fbb7xgz95y90247hfc1a19v7ry8m6blvv4y8irdgzhjvik70zb3") '("scribble" "scribble-doc" "scribble-html-lib" @@ -873,35 +862,24 @@ DrRacket IDE, are not included.") "snip" (base32 "01r9wc5xr3q3n4yyif6j0a37rgdzmpslxn05k13ksik73b3wj6hj") '("snip" "snip-lib")) (simple-racket-origin - "typed-racket" (base32 "1462kj9yswsxbnw71casylzlvhd7cxrml2v9j7rcsnn9hmrqx4vv") + "typed-racket" (base32 "0z6bagp6qiw0i3slhvq035y5hqgq664xw3bdlvdayad0bgbg0mdc") '("source-syntax" "typed-racket" "typed-racket-compatibility" "typed-racket-doc" "typed-racket-lib" "typed-racket-more")) - (racket-packages-origin - "srfi" (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/racket/srfi") - ;; Includes an FSDG fix: return to %racket-commit in 8.5. - ;; See . - (commit "7243029b135741ce08ae30f877e2f49a2a460b22"))) - (sha256 (base32 - "0aqbcdv2dfc2xnk0h6zfi56p7bpwqji8s88qds3d03hhh9k28gvn")) - ;; Use the relevant version for srfi-doc and srfi-lib, - ;; since we're using a newer commit than the v8.4 tag. - (file-name (git-file-name "racket-srfi" "1.1"))) + (simple-racket-origin + "srfi" (base32 "0aqbcdv2dfc2xnk0h6zfi56p7bpwqji8s88qds3d03hhh9k28gvn") '("srfi" "srfi-doc" "srfi-lib" "srfi-lite-lib")) (simple-racket-origin - "string-constants" (base32 "1qizjq4n0hzdgdcjjpr94464gsywpsk2g9mnvwzqr7dcqbrsfvn6") + "string-constants" (base32 "0b1ji31pv6bjb0a2bh9sqp5abvf91gn2rai8r4c4nkar1fzfwfac") '("string-constants" "string-constants-doc" "string-constants-lib")) (simple-racket-origin "swindle" (base32 "164gdsphjzdl2vv7zxz7dfk9jwax8njpmim6sidm8qz8a8589y67") '(("swindle" "."))) (simple-racket-origin - "syntax-color" (base32 "1vf2fc3qvx8a1igi7swsg8gaqhx786sa0vqxd18xhbsidfgb5ywp") + "syntax-color" (base32 "17lb2403ymz6sflw4vs3gsh2y7kgsf0gn8sncsxjhi16rpj3a9vm") '("syntax-color" "syntax-color-doc" "syntax-color-lib")) (simple-racket-origin "trace" (base32 "070ihla5j796hdarn5wxdwn4xj0xnkm50shgh49jy994mribvhia") @@ -910,13 +888,13 @@ DrRacket IDE, are not included.") "unix-socket" (base32 "02dfwas5ynbpyz74w9kwb4wgb37y5wys7svrlmir8k0n9ph9vq0y") '("unix-socket" "unix-socket-doc" "unix-socket-lib")) (simple-racket-origin - "web-server" (base32 "1zgb6jl7zx6258ljs8f3lvryrq5n5zpd71dqzr698m92kw3x2pkn") + "web-server" (base32 "1g4x79ym3mgxv4f3z3z84j12355pf44pjlzlb7f0h6r0i7p0cbjd") '("web-server" "web-server-doc" "web-server-lib")) (simple-racket-origin "wxme" (base32 "1qp5gr9gqsakiq3alw6m4yyv5vw4i3hp4y4nhq8vl2nkjmirvn0b") '("wxme" "wxme-lib")) (simple-racket-origin - "xrepl" (base32 "12zjgsy5zqm3fck3ihg4a70wj56s2cnnjyb4jlfi5nnsfqyrnxg3") + "xrepl" (base32 "19svg0jfs656bld5ikqipz3a5szk5k02zq5fh43209qw527dnfbk") '("xrepl" "xrepl-doc" "xrepl-lib")))) (build-system gnu-build-system) (arguments -- cgit v1.2.3 From 544fbdcc9e092fd03663d649a199060ea278a658 Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Mon, 9 May 2022 02:02:43 -0400 Subject: gnu: racket: Fix out-of-source build. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/racket.scm (racket-vm-cgc)[arguments]: Supply '#:out-of-source? #t'. Wrap 'install-license-files' to work around limitation. Signed-off-by: Ludovic Courtès --- gnu/packages/racket.scm | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/gnu/packages/racket.scm b/gnu/packages/racket.scm index c6f8ec20ba..e593f64c21 100644 --- a/gnu/packages/racket.scm +++ b/gnu/packages/racket.scm @@ -276,8 +276,9 @@ ;; main-distribution-test that aren't part of the main ;; distribution. #:tests? #f - ;; Upstream recommends #:out-of-source?, and it does - ;; help with debugging, but it confuses `install-license-files`. + ;; Upstream recommends #:out-of-source?, and it + ;; helps a lot with debugging. + #:out-of-source? #t #:modules '((ice-9 match) (ice-9 regex) (guix build gnu-build-system) @@ -314,7 +315,18 @@ #f))))))) (add-before 'configure 'chdir (lambda _ - (chdir "racket/src")))))) + (chdir "racket/src"))) + (replace 'install-license-files + ;; The #:out-of-source? mode for install-license-files fails + ;; to find the srcdir: as a workaround, navigate there ourselves. + (let ((install-license-files + (assoc-ref %standard-phases 'install-license-files))) + (lambda args + (with-directory-excursion "../src" + (apply install-license-files + `(,@args + ;; if there are duplicate keywords, last is used + #:out-of-source? #f))))))))) (home-page "https://racket-lang.org") (synopsis "Old Racket implementation used for bootstrapping") (description "This variant of the Racket BC (``before Chez'' or -- cgit v1.2.3 From e9ac2a8f4bb4d275ea68b3611834b82259cfceac Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Mon, 9 May 2022 02:02:44 -0400 Subject: gnu: chez-scheme: Update to 9.5.8. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/chez.scm (chez-scheme): Update to 9.5.8. Signed-off-by: Ludovic Courtès --- gnu/packages/chez.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm index a7f75a731a..34545b1f58 100644 --- a/gnu/packages/chez.scm +++ b/gnu/packages/chez.scm @@ -210,7 +210,7 @@ If native threads are supported, the returned list will include (name "chez-scheme") ;; The version should match `(scheme-version-number)`. ;; See s/cmacros.ss c. line 360. - (version "9.5.6") + (version "9.5.8") (source (origin (method git-fetch) (uri (git-reference @@ -218,7 +218,7 @@ If native threads are supported, the returned list will include (commit (string-append "v" version)))) (sha256 (base32 - "07s433hn1z2slfc026sidrpzxv3a8narcd40qqr1xrpb9012xdky")) + "0xchqq8cm0ka5wgpn18sjs0hh15rc3nb7xrjqbbc9al3asq0d7gc")) (file-name (git-file-name name version)) (snippet #~(begin (use-modules (guix build utils)) -- cgit v1.2.3 From d35920daf0c2efe3b3da055a1468cb2f8d3616d4 Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Mon, 9 May 2022 02:02:45 -0400 Subject: gnu: chez-scheme: Refactor documentation phases. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Patches merged in both upstream Chez Scheme and Racket's variant will soon let us replace the 'install-docs' phase with just 'make install-docs'. Separating the 'link-doc-pdfs' phase (which won't change) leaves us well-prepared for the transition, regardless of whether Chez Scheme 9.5.10 or Racket 8.6 is released first. * gnu/packages/chez.scm (chez-scheme)[arguments]: Split 'install-doc' phase into 'install-docs' (matching the future 'make' target) and 'link-doc-pdfs'. Signed-off-by: Ludovic Courtès --- gnu/packages/chez.scm | 64 +++++++++++++++++++++++++++++---------------------- 1 file changed, 36 insertions(+), 28 deletions(-) diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm index 34545b1f58..49051abd17 100644 --- a/gnu/packages/chez.scm +++ b/gnu/packages/chez.scm @@ -309,35 +309,43 @@ If native threads are supported, the returned list will include (string-append (dirname scheme.boot) "/chez-scheme.boot"))))))) ;; Building the documentation requires stex and a running scheme. - ;; FIXME: this is probably wrong for cross-compilation - (add-after 'install-symlink 'install-doc + (add-after 'install-symlink 'install-docs (lambda* (#:key native-inputs inputs outputs #:allow-other-keys) - (match (assoc-ref outputs "doc") - (#f - (format #t "not installing docs~%")) - (doc-prefix - (let* ((chez+version (strip-store-file-name #$output)) - (scheme (search-input-file outputs "/bin/scheme")) - (stexlib (search-input-directory (or native-inputs - inputs) - "/lib/stex")) - (doc-dir (string-append doc-prefix - "/share/doc/" - chez+version))) - (define* (stex-make #:optional (suffix "")) - (invoke "make" "install" - (string-append "Scheme=" scheme) - (string-append "STEXLIB=" stexlib) - (string-append "installdir=" doc-dir suffix))) - (with-directory-excursion "csug" - (stex-make "/csug")) - (with-directory-excursion "release_notes" - (stex-make "/release_notes")) - (with-directory-excursion doc-dir - (symlink "release_notes/release_notes.pdf" - "release_notes.pdf") - (symlink "csug/csug9_5.pdf" - "csug.pdf")))))))))) + (let* ((doc-prefix (or (assoc-ref outputs "doc") + (assoc-ref outputs "out"))) + (chez+version (strip-store-file-name #$output)) + (scheme (search-input-file outputs "/bin/scheme")) + (stexlib (search-input-directory (or native-inputs + inputs) + "/lib/stex")) + (doc-dir (string-append doc-prefix + "/share/doc/" + chez+version))) + (define* (stex-make #:optional (suffix "")) + (invoke "make" "install" + (string-append "Scheme=" scheme) + (string-append "STEXLIB=" stexlib) + (string-append "installdir=" doc-dir suffix))) + (with-directory-excursion "csug" + (stex-make "/csug")) + (with-directory-excursion "release_notes" + (stex-make "/release_notes"))))) + (add-after 'install-docs 'link-doc-pdfs + ;; otherwise, it's hard to notice them in a forest of HTML files + (lambda* (#:key outputs #:allow-other-keys) + (with-directory-excursion + (string-append (or (assoc-ref outputs "doc") + (assoc-ref outputs "out")) + "/share/doc/" + (strip-store-file-name #$output)) + (symlink "release_notes/release_notes.pdf" + "release_notes.pdf") + (match (find-files "csug" + "csug.*\\.pdf$" ;; embeded version number + #:fail-on-error? #t) + ((pth) + (symlink pth + "csug.pdf"))))))))) ;; Chez Scheme does not have a MIPS backend. ;; FIXME: Debian backports patches to get armhf working. ;; We should too. It is the Chez machine type arm32le -- cgit v1.2.3 From 7ea79beda3aea0beba993285103f50b6d94cb14e Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Mon, 9 May 2022 02:02:46 -0400 Subject: gnu: chez-scheme: Refactor configure phase and fix '--threads'. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Move Chez-specific logic into '#:configure-flags' and a new 'configure-environment-variables' phase, leaving the 'configure' phase as just a variant of the one from 'gnu-build-system' (including support for '#:out-of-source?') that doesn't add implicit Autoconf-style flags. In the process, do the right thing for "--threads", rather than assuming the only nonthreaded platform is broken. * gnu/packages/chez.scm (chez-scheme)[arguments]: Set configure flags in '#:configure-flags' and separate 'configure-environment-variables' from the residual 'configure' phase. More closely follow 'gnu-build-system'. Use 'chez-upstream-features-for-system' for "--threads". (chez-scheme-for-racket)[arguments]<#:configure-flags>: Add "--threads" unconditionally. Signed-off-by: Ludovic Courtès --- gnu/packages/chez.scm | 63 ++++++++++++++++++++++++++++++++++----------------- 1 file changed, 42 insertions(+), 21 deletions(-) diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm index 49051abd17..785b6837c1 100644 --- a/gnu/packages/chez.scm +++ b/gnu/packages/chez.scm @@ -258,8 +258,18 @@ If native threads are supported, the returned list will include (ice-9 ftw) (ice-9 match)) #:test-target "test" - ;; TODO when we fix armhf, it may not support --threads - #:configure-flags #~'("--threads") + #:configure-flags + #~`(,(string-append "--installprefix=" #$output) + #$@(if (and=> (chez-upstream-features-for-system) + (cut memq 'threads <>)) + #~("--threads") + #~()) + "ZLIB=-lz" + "LZ4=-llz4" + "--libkernel" + ;; Guix will do 'compress-man-pages', + ;; and letting Chez try causes an error + "--nogzip-man-pages") #:phases #~(modify-phases %standard-phases (add-after 'unpack 'unpack-nanopass+stex @@ -273,26 +283,35 @@ If native threads are supported, the returned list will include (search-input-directory (or native-inputs inputs) "lib/chez-scheme-bootfiles") "boot"))) - ;; NOTE: the custom Chez 'configure' script doesn't allow + ;; NOTE: The custom Chez 'configure' script doesn't allow ;; unrecognized flags, such as those automatically added - ;; by `gnu-build-system`. + ;; by `gnu-build-system`. This replacement phase uses only + ;; the explicitly provided `#:configure-flags`. (replace 'configure - (lambda* (#:key inputs (configure-flags '()) #:allow-other-keys) - ;; add flags which are always required: - (let ((flags (cons* (string-append "--installprefix=" #$output) - "ZLIB=-lz" - "LZ4=-llz4" - "--libkernel" - ;; Guix will do compress-man-pages, - ;; and letting Chez try causes an error - "--nogzip-man-pages" - configure-flags))) - (format #t "configure flags: ~s~%" flags) - ;; Some makefiles (for tests) don't seem to propagate CC - ;; properly, so we take it out of their hands: - (setenv "CC" #$(cc-for-target)) - (setenv "HOME" "/tmp") - (apply invoke "./configure" flags)))) + (lambda* (#:key inputs (configure-flags '()) out-of-source? + #:allow-other-keys) + (let* ((abs-srcdir (getcwd)) + (srcdir (if out-of-source? + (string-append "../" (basename abs-srcdir)) + "."))) + (format #t "source directory: ~s (relative from build: ~s)~%" + abs-srcdir srcdir) + (if out-of-source? + (begin + (mkdir "../build") + (chdir "../build"))) + (format #t "build directory: ~s~%" (getcwd)) + (format #t "configure flags: ~s~%" configure-flags) + (apply invoke + (string-append srcdir "/configure") + configure-flags)))) + (add-after 'configure 'configure-environment-variables + (lambda args + ;; Some makefiles (for tests) don't seem to propagate CC + ;; properly, so we take it out of their hands: + (setenv "CC" #$(cc-for-target)) + ;; Likewise, some tests have needed HOME to be set: + (setenv "HOME" "/tmp"))) ;; The binary file name is called "scheme" as is the one from ;; MIT/GNU Scheme. We add a symlink to use in case both are ;; installed. @@ -385,7 +404,9 @@ and 32-bit PowerPC architectures.") (arguments (substitute-keyword-arguments (package-arguments chez-scheme) ((#:configure-flags cfg-flags #~'()) - #~(cons "--disable-x11" #$cfg-flags)) + #~(cons* "--disable-x11" + "--threads" ;; ok to potentially duplicate + #$cfg-flags)) ((#:phases those-phases #~%standard-phases) #~(let* ((those-phases #$those-phases) (unpack (assoc-ref those-phases 'unpack))) -- cgit v1.2.3 From 9f88d8b72d8250168f8c5347ed0b01dfc46f7e45 Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Mon, 9 May 2022 02:02:47 -0400 Subject: gnu: stex: Get machine type dynamically. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/chez.scm (stex)[arguments]: Run 'scheme' to determine the machine type. Signed-off-by: Ludovic Courtès --- gnu/packages/chez.scm | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm index 785b6837c1..dd485d37e1 100644 --- a/gnu/packages/chez.scm +++ b/gnu/packages/chez.scm @@ -602,6 +602,10 @@ Chez Scheme."))) ("src" "lib/stex/") ("Mf-stex" "lib/stex/") ("Makefile.template" "lib/stex/")) + #:modules + '((guix build copy-build-system) + (guix build utils) + (ice-9 popen)) #:phases #~(modify-phases %standard-phases (add-before 'install 'patch-sources @@ -633,8 +637,14 @@ Chez Scheme."))) (define makefile (string-append (getcwd) "/Makefile")) (define machine - #$(and=> (nix-system->chez-machine) - chez-machine->threaded)) + (let ((pipe (open-pipe* OPEN_BOTH scheme "-q"))) + ;; try to not be wrong for cross-compilation + ;; (avoid #% reader abbreviation for Guile) + (write '(($primitive $target-machine)) pipe) + (force-output pipe) + (let ((sym (read pipe))) + (close-pipe pipe) + (symbol->string sym)))) (with-directory-excursion (search-input-directory outputs "/lib/stex") (invoke "make" -- cgit v1.2.3 From 9322697636b4800194154c7153db08eedbba16ce Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Mon, 9 May 2022 02:02:48 -0400 Subject: gnu: chez-upstream-features-for-system: Improve implementation. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit is a follow-up to b8fc9169515ef1a6d6037c84e30ad308e5418b6f. While that commit fixed a breaking build, this one begins to address the faulty assumptions that lead to the failure: see also . In this commit, we reimplement 'chez-upstream-features-for-system' using the new '%chez-features-table', which explicitly specifies platform support for both 'chez-scheme' and 'chez-scheme-for-racket', rather than assuming a non-false result from 'nix-system->chez-machine' means that the system is supported. The remaining uses of 'nix-system->chez-machine' still make that incorrect assumption and must be repaired in a future commit. * gnu/packages/chez.scm (%nix-arch-to-chez-alist, %nix-os-to-chez-alist): Replace with ... (target-chez-arch, target-chez-os): ... these new variables. (nix-system->chez-machine): Rewrite using them. (%chez-features-table): New variable. (chez-upstream-features-for-system): Rewrite using it. (chez-scheme)[supported-systems]: Update armhf-linux comment. (chez-scheme-bootstrap-bootfiles)[supported-systems]: Use 'chez-upstream-features-for-system'. (chez-machine->nonthreaded, chez-machine->threaded, chez-machine->nix-system): Remove unused functions. Signed-off-by: Ludovic Courtès --- gnu/packages/chez.scm | 234 +++++++++++++++++++++++++++++--------------------- 1 file changed, 134 insertions(+), 100 deletions(-) diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm index dd485d37e1..41f083e0ac 100644 --- a/gnu/packages/chez.scm +++ b/gnu/packages/chez.scm @@ -49,8 +49,6 @@ #:use-module (srfi srfi-26) #:export (chez-scheme-for-system nix-system->chez-machine - chez-machine->nonthreaded - chez-machine->threaded unpack-nanopass+stex)) ;; Commentary: @@ -82,68 +80,57 @@ including support for native threads." chez-scheme chez-scheme-for-racket)) -(define (chez-machine->nonthreaded machine) - "Given a string MACHINE naming a Chez Scheme machine type, returns a string -naming the nonthreaded machine type for the same architecture and OS as -MACHINE. The returned string may share storage with MACHINE." - ;; Chez Scheme documentation consistently uses "nonthreaded" rather than - ;; e.g. "unthreaded" - (if (eqv? #\t (string-ref machine 0)) - (substring machine 1) - machine)) -(define (chez-machine->threaded machine) - "Like @code{chez-machine->nonthreaded}, but returns the threaded machine -type." - (if (eqv? #\t (string-ref machine 0)) - machine - (string-append "t" machine))) - -;; Based on the implementation from raco-cross-lib/private/cross/platform.rkt -;; in https://github.com/racket/raco-cross. -;; For supported platforms, refer to release_notes/release_notes.stex in the -;; upstream Chez Scheme repository or to racket/src/ChezScheme/README.md -;; in https://github.com/racket/racket. -(define %nix-arch-to-chez-alist - `(("x86_64" . "a6") - ("i386" . "i3") - ("aarch64" . "arm64") - ("armhf" . "arm32") ;; Chez supports ARM v6+ - ("ppc" . "ppc32"))) -(define %nix-os-to-chez-alist - `(("w64-mingw32" . "nt") - ("darwin" . "osx") - ("linux" . "le") - ("freebsd" . "fb") - ("openbsd" . "ob") - ("netbsd" . "nb") - ("solaris" . "s2"))) - -(define (chez-machine->nix-system machine) - "Return the Nix system type corresponding to the Chez Scheme machine type -MACHINE. If MACHINE is not a string representing a known machine type, an -exception is raised. This function does not distinguish between threaded and -nonthreaded variants of MACHINE. +(define* (target-chez-arch #:optional (system + (or (%current-target-system) + (%current-system)))) + "Return a string representing the architecture of SYSTEM as used in Chez +Scheme machine types, or '#f' if none is defined." + (cond + ((target-x86-64? system) + "a6") + ((target-x86-32? system) + "i3") + ((target-aarch64? system) + "arm64") + ((target-arm32? system) + "arm32") + ((target-ppc64le? system) + #f) + ((target-ppc32? system) + "ppc32") + ((target-riscv64? system) + #f) + (else + #f))) -Note that this function only handles Chez Scheme machine types in the -strictest sense, not other kinds of descriptors sometimes used in place of a -Chez Scheme machine type by Racket, such as @code{\"pb\"}, @code{#f}, or -@code{\"racket\"}. (When using such extensions, the Chez Scheme machine type -for the host system is often still relevant.)" - (let ((machine (chez-machine->nonthreaded machine))) - (let find-arch ((alist %nix-arch-to-chez-alist)) - (match alist - (((nix . chez) . alist) - (if (string-prefix? chez machine) - (string-append - nix "-" (let ((machine-os - (substring machine (string-length chez)))) - (let find-os ((alist %nix-os-to-chez-alist)) - (match alist - (((nix . chez) . alist) - (if (equal? chez machine-os) - nix - (find-os alist))))))) - (find-arch alist))))))) +(define* (target-chez-os #:optional (system (or (%current-target-system) + (%current-system)))) + "Return a string representing the operating system kernel of SYSTEM as used +in Chez Scheme machine types, or '#f' if none is defined." + ;; e.g. "le" includes both GNU/Linux and Android + (cond + ((target-linux? system) + "le") + ((target-hurd? system) + #f) + ((target-mingw? system) + "nt") + ;; missing (guix utils) predicates + ;; cf. https://github.com/NixOS/nixpkgs/blob/master/lib/systems/doubles.nix + ((string-suffix? "-darwin" system) + "osx") + ((string-suffix? "-freebsd" system) + "fb") + ((string-suffix? "-openbsd" system) + "ob") + ((string-suffix? "-netbsd" system) + "nb") + ;; Nix says "x86_64-solaris", but accommodate "-solaris2" + ((string-contains system "solaris") + "s2") + ;; unknown + (else + #f))) (define* (nix-system->chez-machine #:optional (system (or (%current-target-system) @@ -153,16 +140,81 @@ identifier SYSTEM, or @code{#f} if the translation of SYSTEM to a Chez Scheme machine type is undefined. It is unspecified whether the resulting string will name a threaded or a -nonthreaded machine type: when the distinction is relevant, use -@code{chez-machine->nonthreaded} or @code{chez-machine->threaded} to adjust -the result." - (let* ((hyphen (string-index system #\-)) - (nix-arch (substring system 0 hyphen)) - (nix-os (substring system (+ 1 hyphen))) - (chez-arch (assoc-ref %nix-arch-to-chez-alist nix-arch)) - (chez-os (assoc-ref %nix-os-to-chez-alist nix-os))) +nonthreaded machine type." + (let* ((chez-arch (target-chez-arch system)) + (chez-os (target-chez-os system))) (and chez-arch chez-os (string-append chez-arch chez-os)))) +(define %chez-features-table + ;; An alist of alists mapping: + ;; os -> arch -> (or/c #f (listof symbol?)) + ;; where: + ;; - `os` is a string for the OS part of a Chez Scheme machine type; and + ;; - `arch` is a string for the architecture part of a Chez machine type. + ;; + ;; The absence of an entry for a given arch--os pair means that neither + ;; upstream Chez Scheme nor the Racket variant can generate native code for + ;; that system. (The Racket variant can still provide support via its + ;; ``portable bytecode'' backends and optional compilation to C.) A value + ;; of `#f` means that upstream Chez Scheme does not support the arch--os + ;; pair at all, but the Racket variant does. A list has the same meaning as + ;; a result from `chez-upstream-features-for-system`. + ;; + ;; The arch--os pairs marked "commented out" have been commented out in the + ;; STeX source for the upstream release notes since the initial release as + ;; free software, but they are reported to work and/or have been described + ;; as supported by upstream maintainers. + ;; + ;; For this overall approach to make sense, we assume that Racket's variant + ;; of Chez Scheme can generate native code for a superset of the platforms + ;; supported upstream, supports threads on all platforms it supports at all + ;; (because they are needed for Racket), and doesn't need bootstrap + ;; bootfiles. Those assumptions have held for several years. + '(;; Linux + ("le" + ("i3" threads bootstrap-bootfiles) + ("a6" threads bootstrap-bootfiles) + ("arm32" bootstrap-bootfiles) + ("arm64" . #f) + ("ppc32" threads)) + ;; FreeBSD + ("fb" + ("i3" threads) ;; commented out + ("a6" threads) ;; commented out + ("arm32" . #f) + ("arm64" . #f) + ("ppc32" . #f)) + ;; OpenBSD + ("ob" + ("i3" threads) ;; commented out + ("a6" threads) ;; commented out + ("arm32" . #f) + ("arm64" . #f) + ("ppc32" . #f)) + ;; NetBSD + ("nb" + ("i3" threads) ;; commented out + ("a6" threads) ;; commented out + ("arm32" . #f) + ("arm64" . #f) + ("ppc32" . #f)) + ;; OpenSolaris / OpenIndiana / Illumos + ("s2" + ("i3" threads) ;; commented out + ("a6" threads)) ;; commented out + ;; Windows + ("nt" + ("i3" threads bootstrap-bootfiles) + ("a6" threads bootstrap-bootfiles) + ;; ^ threads "experiemental", but reportedly fine + ("arm64" . #f)) + ;; Darwin + ("osx" + ("i3" threads bootstrap-bootfiles) + ("a6" threads bootstrap-bootfiles) + ("arm64" . #f) + ("ppc32" . #f)))) + (define* (chez-upstream-features-for-system #:optional (system (or (%current-target-system) @@ -172,20 +224,14 @@ for the Nix system identifier SYSTEM, or @code{#f} if upstream Chez Scheme does not support SYSTEM at all. If native threads are supported, the returned list will include -@code{'threads}. Other feature symbols may be added in the future." - (cond - ((not (nix-system->chez-machine system)) - #f) - ((target-aarch64? system) - #f) - ((target-arm32? system) - (and (target-linux? system) - '())) - ((target-ppc32? system) - (and (target-linux? system) - '(threads))) - (else - '(threads)))) +@code{'threads}. If bootstrap bootfiles for SYSTEM are distributed in the +upstream Chez Scheme repository, the returned list will include +@code{'bootstrap-bootfiles}. Other feature symbols may be added in the +future." + (let ((chez-arch (target-chez-arch system)) + (chez-os (target-chez-os system))) + (and=> (assoc-ref %chez-features-table chez-os) + (cut assoc-ref <> chez-arch)))) ;; ;; Chez Scheme: @@ -365,14 +411,9 @@ If native threads are supported, the returned list will include ((pth) (symlink pth "csug.pdf"))))))))) - ;; Chez Scheme does not have a MIPS backend. - ;; FIXME: Debian backports patches to get armhf working. - ;; We should too. It is the Chez machine type arm32le - ;; (no threaded version upstream yet, though there is in - ;; Racket's fork), more specifically (per the release notes) ARMv6. (supported-systems (delete - "armhf-linux" ;; <-- should work, but reportedly broken + "armhf-linux" ;; XXX reportedly broken, needs checking (filter chez-upstream-features-for-system %supported-systems))) (home-page "https://cisco.github.io/ChezScheme/") @@ -471,16 +512,9 @@ Faster multiplication and division for large exact numbers (list #:install-plan #~`(("boot/" "lib/chez-scheme-bootfiles")))) (supported-systems - ;; Upstream only distributes pre-built bootfiles for - ;; arm32le and t?(i3|a6)(le|nt|osx) (filter (lambda (system) - (let ((machine (and=> (nix-system->chez-machine system) - chez-machine->nonthreaded))) - (or (equal? "arm32le" machine) - (and machine - (member (substring machine 0 2) '("i3" "a6")) - (or-map (cut string-suffix? <> machine) - '("le" "nt" "osx")))))) + (and=> (chez-upstream-features-for-system system) + (cut memq 'bootstrap-bootfiles <>))) %supported-systems)) (synopsis "Chez Scheme bootfiles (binary seed)") (description -- cgit v1.2.3 From 4c0ac41ba4072677ed5876dacb8e17a7671f20d5 Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Mon, 9 May 2022 02:02:49 -0400 Subject: gnu: chez-scheme-for-racket: Fix supported systems. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit fixes the treatment of systems like "powerpc-w64-mingw32", where the combination of architecture and kernel is not supported, even though both are supported in other combinations. The build failure fixed in b8fc9169515ef1a6d6037c84e30ad308e5418b6f highlighted this problem: see also . The correct support status is specified by '%chez-features-table', which was added to improve 'chez-upstream-features-for-system': this commit uses it to fix the repair. Once the issues in are resolved, 'chez-scheme-for-racket' and 'racket-vm-cs' will be able to run even on systems for which native code generation is not supported. It's not clear what behavior would be useful from 'nix-system->chez-machine': since the current implementation is flawed and easy to misuse, we remove it for now, replacing the remaining uses with 'racket-cs-native-supported-system?'. * gnu/packages/chez.scm (nix-system->chez-machine): Remove it. (racket-cs-native-supported-system?): New variable. (chez-scheme-for-racket)[supported-systems]: Use it. * gnu/packages/racket.scm (racket-vm-for-system): Likewise. Signed-off-by: Ludovic Courtès --- gnu/packages/chez.scm | 32 +++++++++++++++++--------------- gnu/packages/racket.scm | 7 +++++-- 2 files changed, 22 insertions(+), 17 deletions(-) diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm index 41f083e0ac..cae17580f8 100644 --- a/gnu/packages/chez.scm +++ b/gnu/packages/chez.scm @@ -48,7 +48,7 @@ #:use-module (srfi srfi-1) #:use-module (srfi srfi-26) #:export (chez-scheme-for-system - nix-system->chez-machine + racket-cs-native-supported-system? unpack-nanopass+stex)) ;; Commentary: @@ -132,19 +132,6 @@ in Chez Scheme machine types, or '#f' if none is defined." (else #f))) -(define* (nix-system->chez-machine #:optional - (system (or (%current-target-system) - (%current-system)))) - "Return the Chez Scheme machine type corresponding to the Nix system -identifier SYSTEM, or @code{#f} if the translation of SYSTEM to a Chez Scheme -machine type is undefined. - -It is unspecified whether the resulting string will name a threaded or a -nonthreaded machine type." - (let* ((chez-arch (target-chez-arch system)) - (chez-os (target-chez-os system))) - (and chez-arch chez-os (string-append chez-arch chez-os)))) - (define %chez-features-table ;; An alist of alists mapping: ;; os -> arch -> (or/c #f (listof symbol?)) @@ -233,6 +220,19 @@ future." (and=> (assoc-ref %chez-features-table chez-os) (cut assoc-ref <> chez-arch)))) +(define* (racket-cs-native-supported-system? #:optional + (system + (or (%current-target-system) + (%current-system)))) + "Can Racket's variant of Chez Scheme generate native code for SYSTEM? +Otherwise, SYSTEM can use only the ``portable bytecode'' backends." + (let ((chez-arch (target-chez-arch system)) + (chez-os (target-chez-os system))) + (and (and=> (assoc-ref %chez-features-table chez-os) + ;; NOT assoc-ref: supported even if cdr is #f + (cut assoc chez-arch <>)) + #t))) + ;; ;; Chez Scheme: ;; @@ -459,7 +459,9 @@ and 32-bit PowerPC architectures.") (add-after 'unpack 'chdir (lambda args (chdir "racket/src/ChezScheme")))))))) - (supported-systems (filter nix-system->chez-machine + ;; TODO: How to build pbarch/pbchunks for other systems? + ;; See https://racket.discourse.group/t/950 + (supported-systems (filter racket-cs-native-supported-system? %supported-systems)) (home-page "https://github.com/racket/ChezScheme") ;; ^ This is downstream of https://github.com/racket/racket, diff --git a/gnu/packages/racket.scm b/gnu/packages/racket.scm index e593f64c21..10617d732c 100644 --- a/gnu/packages/racket.scm +++ b/gnu/packages/racket.scm @@ -190,8 +190,11 @@ (define* (racket-vm-for-system #:optional (system (or (%current-target-system) (%current-system)))) - "Return 'racket-vm-cs' if it supports SYSTEM; 'racket-vm-bc' otherwise." - (if (nix-system->chez-machine system) + "Return 'racket-vm-cs' if we are able to build it for SYSTEM; 'racket-vm-bc' +otherwise." + ;; Once we figure out the issues in https://racket.discourse.group/t/950, + ;; we can use 'racket-vm-cs' everywhere. + (if (racket-cs-native-supported-system? system) racket-vm-cs racket-vm-bc)) -- cgit v1.2.3 From 3547bb6a66c32eb1deac46a98b40e2e051689ed3 Mon Sep 17 00:00:00 2001 From: Philip McGrath Date: Mon, 9 May 2022 02:02:50 -0400 Subject: gnu: chez-scheme-for-system: Adjust for bytecode backend. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change 'chez-scheme-for-system' to return 'chez-scheme-for-racket' in two cases when it previously returned 'chez-scheme': 1. When 'chez-scheme' is not distributed with bootstrap bootfiles, since we can only cross-compile 'chez-scheme' for those systems; and 2. When neither 'chez-scheme' nor 'chez-scheme-for-racket' supports native code generation, since we will be able to use the ``portable bytecode'' backends of 'chez-scheme-for-racket' as soon as the issues in are resolved. * gnu/packages/chez.scm (chez-scheme-for-racket): Change condition. Signed-off-by: Ludovic Courtès --- gnu/packages/chez.scm | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm index cae17580f8..7e6273f26a 100644 --- a/gnu/packages/chez.scm +++ b/gnu/packages/chez.scm @@ -69,14 +69,17 @@ (define* (chez-scheme-for-system #:optional (system (or (%current-target-system) (%current-system)))) - "Return 'chez-scheme' unless only 'chez-scheme-for-racket' supports SYSTEM, -including support for native threads." - (if (or - ;; full support upstream - (and=> (chez-upstream-features-for-system system) - (cut memq 'threads <>)) - ;; no support anywhere - (not (nix-system->chez-machine system))) + "Return 'chez-scheme' if it fully supports SYSTEM, including support for +bootstrapping and native threads. Otherwise, return +'chez-scheme-for-racket'." + (if (and=> (chez-upstream-features-for-system system) + (lambda (features) + (every (cut memq <> features) + '(threads + ;; We can cross-compile for platforms without + ;; bootstrap bootfiles, but we can't self-host + ;; on them short of adding more binary seeds. + bootstrap-bootfiles)))) chez-scheme chez-scheme-for-racket)) -- cgit v1.2.3 From 0b4300d4fd8c972f0cb9d6751fc824b9a065b780 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Thu, 12 May 2022 12:29:11 +0200 Subject: gnu: commencement: Remove redundant import. Reported by Josselin Poiret on #guix. * gnu/packages/commencement.scm: Remove redundant #:use-module (guix gexp). --- gnu/packages/commencement.scm | 1 - 1 file changed, 1 deletion(-) diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm index 1fed8bcd6e..3f8f463b79 100644 --- a/gnu/packages/commencement.scm +++ b/gnu/packages/commencement.scm @@ -58,7 +58,6 @@ #:use-module (guix download) #:use-module (guix build-system gnu) #:use-module (guix build-system trivial) - #:use-module (guix gexp) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix memoization) #:use-module (guix utils) -- cgit v1.2.3 From 75ca0e52581f7da95f540acadada671ee08a0cda Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 11 May 2022 16:07:53 +0200 Subject: gnu: python2-setuptools: Patch source code. * gnu/packages/python-xyz.scm (python2-setuptools)[arguments]: Add phase 'compatibility-fixes. --- gnu/packages/python-xyz.scm | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index ab4102273a..0ef71605e9 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -1863,7 +1863,17 @@ Python 3 support.") ;; FIXME: Tests require pytest, which itself relies on setuptools. ;; One could bootstrap with an internal untested setuptools. (arguments - `(#:tests? #f)) + `(#:tests? #f + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'compatibility-fixes + (lambda _ + ;; HTMLParser no longer exists. + (substitute* "setuptools/py33compat.py" + (("html_parser.HTMLParser\\(\\).unescape") + "html.unescape")) + ;; This needs distutils.msvc9compiler + (delete-file "setuptools/tests/test_msvc.py")))))) (native-inputs (list unzip)) (home-page "https://pypi.org/project/setuptools/") -- cgit v1.2.3 From 2936acfb37d87d33f1e879a63795aa7c65affb07 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 11 May 2022 16:18:33 +0200 Subject: gnu: python2-numpy: Update name. * gnu/packages/python-xyz.scm (python2-numpy)[name]: Rename to python2-numpy. --- gnu/packages/python-xyz.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 0ef71605e9..d1df93826f 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -5772,7 +5772,7 @@ capabilities.") (strip-python2-variant python-numpy-next)))) (package (inherit numpy) - (name "python-numpy") + (name "python2-numpy") (version "1.16.5") (source (origin (method url-fetch) -- cgit v1.2.3 From a1cb645d83d085382eaf64f4c097642aa47c297a Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 11 May 2022 16:24:53 +0200 Subject: gnu: python-packaging-bootstrap: Add python2-variant property. * gnu/packages/python-build.scm (python-packaging-bootstrap)[properties]: Add python2-variant. (python2-packaging-bootstrap): Strip python2-variant property. --- gnu/packages/python-build.scm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python-build.scm b/gnu/packages/python-build.scm index 2abb781f76..eb291c2c86 100644 --- a/gnu/packages/python-build.scm +++ b/gnu/packages/python-build.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2020 Tanguy Le Carrour ;;; Copyright © 2018, 2021 Maxim Cournoyer ;;; Copyright © 2021 Tobias Geerinckx-Rice -;;; Copyright © 2021 Ricardo Wurmus +;;; Copyright © 2021, 2022 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. ;;; @@ -309,10 +309,12 @@ information.") ;; *either* of the licenses found in LICENSE.APACHE or LICENSE.BSD. ;; Contributions to this software is made under the terms of *both* these ;; licenses. - (license (list license:asl2.0 license:bsd-2)))) + (license (list license:asl2.0 license:bsd-2)) + (properties `((python2-variant . ,(delay python2-packaging-bootstrap)))))) (define-public python2-packaging-bootstrap - (let ((base (package-with-python2 python-packaging-bootstrap))) + (let ((base (package-with-python2 + (strip-python2-variant python-packaging-bootstrap)))) (package/inherit base (version "20.0") ;last version with Python 2 support (source -- cgit v1.2.3 From df53689c512ac7ff38b270596f0cee0f41d12dfb Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 22 Mar 2022 23:36:56 -0400 Subject: gnu: python-ipython: Re-order fields. * gnu/packages/python-xyz.scm (python-ipython): Move the 'arguments' field right after the 'build-system' one, Re-indent 'inputs' field. [propagated-inputs]: Sort inputs. --- gnu/packages/python-xyz.scm | 80 +++++++++++++++++++++------------------------ 1 file changed, 37 insertions(+), 43 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index d1df93826f..95fab20247 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -9026,34 +9026,6 @@ callback signature using a prototype function.") (sha256 (base32 "04xgymypnbfgf2q0d5b0hanjbjsp53f055sh1p8xlq52vyzmxdaq")))) (build-system python-build-system) - (propagated-inputs - (list python-backcall - python-decorator - python-pyzmq - python-prompt-toolkit-2 - python-terminado - python-matplotlib - python-matplotlib-inline - python-numpy - python-numpydoc - python-jedi - python-jinja2 - python-mistune - python-pexpect - python-pickleshare - python-simplegeneric - python-jsonschema - python-traitlets - python-nbformat - python-pygments)) - (inputs - (list readline which)) - (native-inputs - (list graphviz - pkg-config - python-requests ;; for tests - python-testpath - python-nose)) (arguments `(#:phases (modify-phases %standard-phases @@ -9063,20 +9035,6 @@ callback signature using a prototype function.") ((".*import datetime") "") ((".*datetime.datetime.now\\(\\)") "") (("%timeit") "# %timeit")))) - ;; Tests can only be run after the library has been installed and not - ;; within the source directory. - (delete 'check) - (add-after 'install 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) - (if tests? - (begin - ;; Make installed package available for running the tests - (add-installed-pythonpath inputs outputs) - (setenv "HOME" "/tmp/") ;; required by a test - ;; We only test the core because one of the other tests - ;; tries to import ipykernel. - (invoke "python" "IPython/testing/iptest.py" - "-v" "IPython/core/tests"))))) (add-before 'check 'fix-tests (lambda* (#:key inputs #:allow-other-keys) (substitute* "./IPython/utils/_process_posix.py" @@ -9091,7 +9049,43 @@ callback signature using a prototype function.") (delete-file "IPython/core/tests/test_interactiveshell.py") ;; AttributeError: module 'matplotlib_inline' has no ;; attribute 'backend_inline' - (delete-file "IPython/core/tests/test_pylabtools.py")))))) + (delete-file "IPython/core/tests/test_pylabtools.py"))) + (replace 'check + (lambda* (#:key inputs outputs tests? #:allow-other-keys) + (when tests? + ;; Make installed package available for running the tests + (add-installed-pythonpath inputs outputs) + (setenv "HOME" "/tmp/") ;; required by a test + ;; We only test the core because one of the other tests + ;; tries to import ipykernel. + (invoke "python" "IPython/testing/iptest.py" + "-v" "IPython/core/tests"))))))) + (inputs (list readline which)) + (propagated-inputs + (list python-backcall + python-jedi + python-jinja2 + python-jsonschema + python-matplotlib + python-matplotlib-inline + python-mistune + python-nbformat + python-numpy + python-numpydoc + python-pexpect + python-pickleshare + python-prompt-toolkit-2 + python-pygments + python-pyzmq + python-simplegeneric + python-terminado + python-traitlets)) + (native-inputs + (list graphviz + pkg-config + python-requests ;for tests + python-testpath + python-nose)) (home-page "https://ipython.org") (synopsis "IPython is a tool for interactive computing in Python") (description -- cgit v1.2.3 From a116f7fdeeb267146d59ff03e148934e7373496d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 23 Mar 2022 00:21:56 -0400 Subject: gnu: python-astroid: Propagate python-typing-extensions. * gnu/packages/python-xyz.scm (python-astroid) [native-inputs]: Move python-typing-extensions to... [propagated-inputs]: ... here. [synopsis]: Shorten. [description]: Normalize indentation. --- gnu/packages/python-xyz.scm | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 95fab20247..8e1f0fd807 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -19084,21 +19084,19 @@ multitouch applications.") (base32 "19iiys4233cicpm48fd7lrkm31kk47qiv44wvk952rqbcn4rd2dh")))) (build-system python-build-system) (propagated-inputs - (list python-lazy-object-proxy python-wrapt)) + (list python-lazy-object-proxy python-typing-extensions python-wrapt)) (native-inputs - (list python-pytest python-pytest-runner python-typing-extensions)) + (list python-pytest python-pytest-runner)) (home-page "https://github.com/PyCQA/astroid") - (synopsis "Common base representation of python source code for pylint and - other projects") + (synopsis "Python source code base representation") (description "@code{python-astroid} provides a common base representation - of python source code for projects such as pychecker, pyreverse, pylint, etc. - - It provides a compatible representation which comes from the _ast module. It - rebuilds the tree generated by the builtin _ast module by recursively walking - down the AST and building an extended ast. The new node classes have - additional methods and attributes for different usages. They include some - support for static inference and local name scopes. Furthermore, astroid - builds partial trees by inspecting living objects.") +of Python source code for projects such as pychecker, pyreverse, pylint, etc. +It provides a compatible representation which comes from the _ast module. It +rebuilds the tree generated by the builtin _ast module by recursively walking +down the AST and building an extended ast. The new node classes have +additional methods and attributes for different usages. They include some +support for static inference and local name scopes. Furthermore, astroid +builds partial trees by inspecting living objects.") (license license:lgpl2.1+))) (define-public python-isbnlib -- cgit v1.2.3 From dc04cf5598cc17d9220996b65266cb45b175cf7c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 23 Mar 2022 00:28:15 -0400 Subject: gnu: Add python-pure-eval. * gnu/packages/python-xyz.scm (python-pure-eval): New variable. --- gnu/packages/python-xyz.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 8e1f0fd807..9ed49d5cc3 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -9015,6 +9015,24 @@ you're careful. The @code{backcall} package provides a way of specifying the callback signature using a prototype function.") (license license:bsd-3))) +(define-public python-pure-eval + (package + (name "python-pure-eval") + (version "0.2.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pure_eval" version)) + (sha256 + (base32 "1hwsm85cwqwh6d6x4vzcimla2865s6v19ms3ym81ganzyq534i9b")))) + (build-system python-build-system) + (native-inputs (list python-pytest python-setuptools-scm)) + (home-page "https://github.com/alexmojaki/pure_eval") + (synopsis "Python library to evaluate abstract syntax tree nodes") + (description "The @code{pure_eval} Python library can safely evaluate +abstract syntax tree (AST) nodes without side effects.") + (license license:expat))) + (define-public python-ipython (package (name "python-ipython") -- cgit v1.2.3 From 952c8f805cd1f67ae192c0904e89ba8fe490d8ba Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 23 Mar 2022 00:28:29 -0400 Subject: gnu: Add python-asttokens. * gnu/packages/python-xyz.scm (python-asttokens): New variable. --- gnu/packages/python-xyz.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 9ed49d5cc3..1d3c4ca3e1 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -9033,6 +9033,28 @@ callback signature using a prototype function.") abstract syntax tree (AST) nodes without side effects.") (license license:expat))) +(define-public python-asttokens + (package + (name "python-asttokens") + (version "2.0.5") + (source + (origin + (method url-fetch) + (uri (pypi-uri "asttokens" version)) + (sha256 + (base32 "1mglbkikxvnhrk3inbx0v1qzxwd38qjr6l35sn098yicy0ac2m4s")))) + (build-system python-build-system) + (propagated-inputs (list python-six)) + (native-inputs (list python-astroid python-pytest python-setuptools-scm)) + (home-page "https://github.com/gristlabs/asttokens") + (synopsis "Python library to annotate abstract syntax trees") + (description "The @code{asttokens} module annotates Python abstract syntax +trees (ASTs) with the positions of tokens and text in the source code that +generated them. It makes it possible for tools that work with logical AST +nodes to find the particular text that resulted in those nodes, for example +for automated refactoring or highlighting.") + (license license:asl2.0))) + (define-public python-ipython (package (name "python-ipython") -- cgit v1.2.3 From 68d7bc9ee518fd8d4485b1da89180860173e4481 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 23 Mar 2022 00:28:38 -0400 Subject: gnu: Add python-littleutils. * gnu/packages/python-xyz.scm (python-littleutils): New variable. --- gnu/packages/python-xyz.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 1d3c4ca3e1..87c9bb015c 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -9055,6 +9055,23 @@ nodes to find the particular text that resulted in those nodes, for example for automated refactoring or highlighting.") (license license:asl2.0))) +(define-public python-littleutils + (package + (name "python-littleutils") + (version "0.2.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "littleutils" version)) + (sha256 + (base32 "0vwijrylppmk0nbddqvn527r9cg3zw8d6zk6r58hslry42jf7jp6")))) + (build-system python-build-system) + (home-page "https://github.com/alexmojaki/littleutils") + (synopsis "Python utility function collection") + (description "@code{littleutils} is a small collection of Python utility +functions, useful in the context of writing unit tests among other uses.") + (license license:expat))) + (define-public python-ipython (package (name "python-ipython") -- cgit v1.2.3 From 9d31c06992e631167918b04db53c1c281f60222b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 23 Mar 2022 00:28:52 -0400 Subject: gnu: Add python-stack-data. * gnu/packages/python-xyz.scm (python-stack-data): New variable. --- gnu/packages/python-xyz.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 87c9bb015c..622af01927 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -9072,6 +9072,32 @@ for automated refactoring or highlighting.") functions, useful in the context of writing unit tests among other uses.") (license license:expat))) +(define-public python-stack-data + (package + (name "python-stack-data") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "stack_data" version)) + (sha256 + (base32 "04lfcj5qrn4qikjw89qbdzqwm0xm4bgm4m8rll1rafk3pm0jssa5")))) + (build-system python-build-system) + (propagated-inputs (list python-asttokens python-executing python-pure-eval)) + (native-inputs + (list python-cython + python-littleutils + python-pygments + python-pytest + python-setuptools-scm + python-typeguard)) + (home-page "https://github.com/alexmojaki/stack_data") + (synopsis "Python stack frame and traceback manipulation library") + (description "The @code{stack_data} Python library extracts data from +stack frames and tracebacks. Is can be used to display more useful tracebacks +than the default.") + (license license:expat))) + (define-public python-ipython (package (name "python-ipython") -- cgit v1.2.3 From 812f2a185a82beb9dbd6af499a516a49d722932d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 30 Mar 2022 18:05:08 -0400 Subject: gnu: python-traitlets: Update to 5.1.1. * gnu/packages/python-xyz.scm (python-traitlets): Update to 5.1.1. [phases]{check}: Honor TESTS?. [propagated-inputs]: Delete field. --- gnu/packages/python-xyz.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 622af01927..f6bb0fb0f7 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8776,7 +8776,9 @@ connect strings, then issue SQL commands within IPython or IPython Notebook.") (arguments `(#:phases (modify-phases %standard-phases - (replace 'check (lambda _ (invoke "pytest" "-vv" "traitlets")))))) + (replace 'check (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "traitlets"))))))) (native-inputs (list python-pytest)) (home-page "https://ipython.org") -- cgit v1.2.3 From e6f46eabbd1694d0c947af9f53778ca66561c47c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 12:19:05 -0400 Subject: gnu: python-jinja2: Update to 3.1.1. * gnu/packages/python-xyz.scm (python-jinja2): Update to 3.1.1. --- gnu/packages/python-xyz.scm | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index f6bb0fb0f7..6bcb17dfad 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -4075,14 +4075,14 @@ for Python.") (define-public python-jinja2 (package (name "python-jinja2") - (version "3.0.1") + (version "3.1.1") (source (origin (method url-fetch) (uri (pypi-uri "Jinja2" version)) (sha256 (base32 - "197ms1wimxql650245v63wkv04n8bicj549wfhp51bx68x5lhgvh")))) + "1saawzys14l1p4kafs7hkihmnvqjq8fwxjmkjiqx3jq1nm5ys2v4")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases @@ -4091,11 +4091,9 @@ for Python.") (if tests? (invoke "pytest" "-vv") (format #t "test suite not run~%"))))))) - (native-inputs - (list python-pytest)) - (propagated-inputs - (list python-markupsafe)) - (home-page "http://jinja.pocoo.org/") + (native-inputs (list python-pytest)) + (propagated-inputs (list python-markupsafe)) + (home-page "https://jinja.palletsprojects.com/") (synopsis "Python template engine") (description "Jinja2 is a small but fast and easy to use stand-alone template engine -- cgit v1.2.3 From 23d2319f9aab48fbb31d63e04197839600d01967 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 11 Apr 2022 01:07:29 -0400 Subject: gnu: python-prompt-toolkit: Update to 3.0.29. * gnu/packages/python-xyz.scm (python-prompt-toolkit): Update to 3.0.29. [phases]{post-install-check}: Move to... {check}: ... this phase override instead, and streamline. --- gnu/packages/python-xyz.scm | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 6bcb17dfad..5bf168df1f 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -17228,25 +17228,24 @@ collections of data.") (define-public python-prompt-toolkit (package (name "python-prompt-toolkit") - (version "3.0.18") + (version "3.0.29") (source (origin (method url-fetch) (uri (pypi-uri "prompt_toolkit" version)) (sha256 - (base32 "1g1kq1aimhm23k2dmlmnznfzc83l6ly65g0h32hqz8injcdz3d71")))) + (base32 "19vf5cahp3imdpwhgvk55g3dvqmc6ga175r4vkq79kffx1h0yr5x")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases - (delete 'check) - (add-after 'install 'post-install-check - (lambda* (#:key inputs outputs #:allow-other-keys) - ;; HOME is needed for the test - ;; "test_pathcompleter_can_expanduser". - (setenv "HOME" "/tmp") - (add-installed-pythonpath inputs outputs) - (invoke "py.test")))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; HOME is needed for the test + ;; "test_pathcompleter_can_expanduser". + (setenv "HOME" "/tmp") + (invoke "pytest" "-vv"))))))) (propagated-inputs (list python-wcwidth)) (native-inputs -- cgit v1.2.3 From 1c8264d62e16f404786d9b526511cea29138ab9f Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 23 Mar 2022 12:06:26 -0400 Subject: gnu: python-ipython: Update to 8.2.0 [fixes CVE-2022-21699]. * gnu/packages/python-xyz.scm (python-ipython): Update to 8.2.0. [phases]{fix-tests}: Delete phase. {check}: Remove extraneous add-installed-pythonpath call. Invoke Pytest directly. Reported-by: Leo Famulari --- gnu/packages/python-xyz.scm | 45 ++++++++++++++------------------------------- 1 file changed, 14 insertions(+), 31 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 5bf168df1f..bd8ae0e5e5 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -9101,13 +9101,13 @@ than the default.") (define-public python-ipython (package (name "python-ipython") - (version "7.27.0") + (version "8.2.0") (source (origin (method url-fetch) (uri (pypi-uri "ipython" version ".tar.gz")) (sha256 - (base32 "04xgymypnbfgf2q0d5b0hanjbjsp53f055sh1p8xlq52vyzmxdaq")))) + (base32 "1hcxa713wh3axa57412iy02rj0494ljvv6gpnls4lndc5h9yprbh")))) (build-system python-build-system) (arguments `(#:phases @@ -9118,34 +9118,15 @@ than the default.") ((".*import datetime") "") ((".*datetime.datetime.now\\(\\)") "") (("%timeit") "# %timeit")))) - (add-before 'check 'fix-tests - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "./IPython/utils/_process_posix.py" - (("/usr/bin/env', 'which") (which "which"))) - (substitute* "./IPython/core/tests/test_inputtransformer.py" - (("#!/usr/bin/env python") - (string-append "#!" (which "python")))) - ;; This test introduces a circular dependency on ipykernel - ;; (which depends on ipython). - (delete-file "IPython/core/tests/test_display.py") - ;; AttributeError: module 'IPython.core' has no attribute 'formatters' - (delete-file "IPython/core/tests/test_interactiveshell.py") - ;; AttributeError: module 'matplotlib_inline' has no - ;; attribute 'backend_inline' - (delete-file "IPython/core/tests/test_pylabtools.py"))) (replace 'check (lambda* (#:key inputs outputs tests? #:allow-other-keys) (when tests? - ;; Make installed package available for running the tests - (add-installed-pythonpath inputs outputs) - (setenv "HOME" "/tmp/") ;; required by a test - ;; We only test the core because one of the other tests - ;; tries to import ipykernel. - (invoke "python" "IPython/testing/iptest.py" - "-v" "IPython/core/tests"))))))) + (setenv "HOME" "/tmp/") ;required by some tests + (invoke "python" "-m" "pytest" "-vv"))))))) (inputs (list readline which)) (propagated-inputs (list python-backcall + python-decorator python-jedi python-jinja2 python-jsonschema @@ -9157,18 +9138,20 @@ than the default.") python-numpydoc python-pexpect python-pickleshare - python-prompt-toolkit-2 + python-prompt-toolkit python-pygments python-pyzmq python-simplegeneric + python-stack-data python-terminado python-traitlets)) (native-inputs (list graphviz pkg-config - python-requests ;for tests - python-testpath - python-nose)) + ;; For tests. + python-pytest + python-requests + python-testpath)) (home-page "https://ipython.org") (synopsis "IPython is a tool for interactive computing in Python") (description @@ -9215,14 +9198,14 @@ computing.") (mkdir-p info) ;; (copy-file "docs/build/texinfo/ipython.info" ;; (string-append info "/ipython.info")) - (copy-file "COPYING.rst" (string-append doc "/COPYING.rst"))) - #t))))) + (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))))))) (inputs (list python-ipython python-ipykernel)) (native-inputs `(("python-sphinx" ,python-sphinx) ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme) - ;; FIXME: It's possible that a smaller union would work just as well. + ;; FIXME: It's possible that a smaller updmap.cfg would work just as + ;; well. ("texlive" ,(texlive-updmap.cfg (list texlive-amsfonts texlive-capt-of texlive-fonts-ec -- cgit v1.2.3 From 7cab14c3363ae8ccdcec5b67bdad645eabd6b792 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 01:01:33 -0400 Subject: gnu: python-nbformat: Update to 5.3.0. * gnu/packages/python-xyz.scm (python-nbformat): Update to 5.3.0. [source]: Adjust git URL. [native-inputs]: Move python-fastjsonschema to... [propagated-inputs]: ... here. Remove python-ipython-genutils. --- gnu/packages/python-xyz.scm | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index bd8ae0e5e5..e1076b7190 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -12816,16 +12816,16 @@ drafts 04, 06 and 07.") (define-public python-nbformat (package (name "python-nbformat") - (version "5.1.3") + (version "5.3.0") ;; The PyPi release tarball lacks some test cases and test data. (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/jupyter/nbformat.git") + (url "https://github.com/jupyter/nbformat") (commit version))) (sha256 (base32 - "033v16cfmxzh3jn5phnil4p3silr49iwh9wiigzhv0crc6sanvwz")) + "114c5c6cvpxhxj8zrw74351gcfzyzjh1jq3py4xf8wk9rahfay9z")) (file-name (git-file-name name version)))) (build-system python-build-system) (arguments @@ -12836,13 +12836,10 @@ drafts 04, 06 and 07.") (when tests? (invoke "pytest" "-vv"))))))) (propagated-inputs - (list python-ipython-genutils python-jsonschema python-jupyter-core + (list python-fastjsonschema python-jsonschema python-jupyter-core python-traitlets)) (native-inputs (list python-pytest - python-fastjsonschema ; This is only active - ; when setting NBFORMAT_VALIDATOR="fastjsonschema", so include it for - ; testing only. python-testpath)) (home-page "https://jupyter.org") (synopsis "Jupyter Notebook format") -- cgit v1.2.3 From ce73cadd34b6e49a1e6fd0d7b98048e7867f799b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 31 Mar 2022 01:30:53 -0400 Subject: gnu: Add texlive-paralist. * gnu/packages/tex.scm (texlive-paralist): New variable. --- gnu/packages/tex.scm | 47 ++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 46 insertions(+), 1 deletion(-) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 34e9aa1e06..8c31d131b6 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2018, 2020 Arun Isaac ;;; Copyright © 2020 Vincent Legoll ;;; Copyright © 2020, 2021 Paul Garlick -;;; Copyright © 2021 Maxim Cournoyer +;;; Copyright © 2021, 2022 Maxim Cournoyer ;;; Copyright © 2021 Leo Le Bouter ;;; Copyright © 2021 Xinglu Chen ;;; Copyright © 2021 Ivan Gankevich @@ -5417,6 +5417,51 @@ which adds some minor changes to LaTeX maths; a rewrite of LaTeX's tabular and array environments; verbatim handling; and syntax diagrams.") (license license:gpl3+))) +(define-public texlive-paralist + (package + (inherit (simple-texlive-package + "texlive-paralist" + (list "doc/latex/paralist/README" + "source/latex/paralist/paralist.dtx" + "source/latex/paralist/paralist.ins") + (base32 "1lz8yds2i64wkb89a9amydwkzsdbc09s1kbgn7vgh2qsxqrrgwam"))) + (outputs '("out" "doc")) + (arguments + (list + #:tex-directory "latex/paralist" + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'chdir + (lambda _ + (setenv "ROOT_DIR" (getcwd)) + (chdir "source/latex/paralist"))) + (add-after 'build 'build-doc + (lambda* (#:key outputs tex-directory #:allow-other-keys) + (copy-file "paralist.dtx" "build/paralist.dtx") + (chdir "build") + (invoke "pdflatex" "paralist.dtx"))) + (replace 'install + (lambda* (#:key outputs tex-directory #:allow-other-keys) + (let ((doc (string-append (assoc-ref outputs "doc") + "/share/doc/" tex-directory)) + (out (string-append #$output "/share/texmf-dist/tex/" + tex-directory))) + (install-file "paralist.pdf" doc) + (install-file (car (find-files (getenv "ROOT_DIR") "README")) + doc) + (install-file "paralist.sty" out))))))) + (native-inputs (list texlive-latex-base + (texlive-updmap.cfg + (list texlive-cm + texlive-jknappen)))) + (home-page "https://ctan.org/pkg/paralist") + (synopsis "Enumerate and itemize within paragraphs") + (description "The @code{paralist} package provides enumerate and itemize +environments that can be used within paragraphs to format the items either as +running text or as separate paragraphs with a preceding number or symbol. It +also provides compacted versions of enumerate and itemize.") + (license license:lppl1.0+))) + (define-public texlive-latex-polyglossia (package (name "texlive-latex-polyglossia") -- cgit v1.2.3 From ff02979ed56fb046de3f9170820c4c5cdae419d1 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 31 Mar 2022 11:00:30 -0400 Subject: gnu: Add texlive-stix2-otf. * gnu/packages/tex.scm (texlive-stix2-otf): New variable. --- gnu/packages/tex.scm | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 8c31d131b6..c3129ebd60 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -6445,6 +6445,41 @@ package supports pdfTeX (pdfLaTeX) and VTeX. With VTeX it is even possible to use this package to insert PostScript files, in addition to PDF files.") (license license:lppl1.3+))) +(define-public texlive-stix2-otf + (let ((base (simple-texlive-package + "texlive-stix2-otf" + (list "/doc/fonts/stix2-otf/" + "/fonts/opentype/public/stix2-otf/") + (base32 "0i7rd1wn5jgm3gbi779gy78apz63w034ck4pn73xw6s10zgjzmgl") + ;; Building these fonts requires FontLab, which is nonfree. + #:trivial? #t))) + (package + (inherit base) + (arguments + (substitute-keyword-arguments (package-arguments base) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'install 'symlink-fonts-to-system-fonts-prefix + ;; This is so that fontconfig can locate the fonts, such as + ;; when using xetex or xelatex. + (lambda _ + (let ((system-fonts-prefix (string-append #$output + "/share/fonts"))) + (mkdir-p system-fonts-prefix) + (symlink (string-append + #$output "/share/texmf-dist/fonts/opentype" + "/public/stix2-otf") + (string-append system-fonts-prefix + "/stix2-otf"))))))))) + (home-page "https://www.stixfonts.org/") + (synopsis "OpenType Unicode text and maths fonts") + (description "The Scientific and Technical Information eXchange (STIX) +fonts are intended to satisfy the demanding needs of authors, publishers, +printers, and others working in the scientific, medical, and technical fields. +They combine a comprehensive Unicode-based collection of mathematical symbols +and alphabets with a set of text faces suitable for professional publishing.") + (license license:silofl1.1)))) + (define-public texlive-stmaryrd (let ((template (simple-texlive-package "texlive-stmaryrd" -- cgit v1.2.3 From fba5c0ca313d52947f872ebe4ed6612ef3e4c077 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 31 Mar 2022 13:58:19 -0400 Subject: gnu: Add texlive-metalogo. * gnu/packages/tex.scm (texlive-metalogo): New variable. --- gnu/packages/tex.scm | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index c3129ebd60..dea153643d 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -5417,6 +5417,86 @@ which adds some minor changes to LaTeX maths; a rewrite of LaTeX's tabular and array environments; verbatim handling; and syntax diagrams.") (license license:gpl3+))) +(define-public texlive-metalogo + (package + (inherit (simple-texlive-package + "texlive-metalogo" + (list "doc/latex/metalogo/README" + ;; These PDFs are apparently used as graphic files, not + ;; built. + "doc/latex/metalogo/TeXoutline.pdf" + "doc/latex/metalogo/eLaToutline.pdf" + "source/latex/metalogo/metalogo.dtx" + "source/latex/metalogo/metalogo.ins") + (base32 "0v1jwp8xhzwn0a4apiyya17s4r1kpn6q9nmv38jj1wwdvgia0jpi"))) + (outputs '("out" "doc")) + (arguments + (list + #:tex-directory "latex/metalogo" + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'chdir + (lambda _ + (setenv "ROOT_DIR" (getcwd)) + (chdir "source/latex/metalogo"))) + (add-after 'chdir 'patch-metalogo.dtx + (lambda _ + (substitute* "metalogo.dtx" + ;; Prevent embedding a build time date, for reproducibility. + (("^% \\\\date.*") "") + ;; These fonts are not free. + (("^\\\\setmainfont.*") "") + (("^\\\\DeclareSymbolFont\\{SabonMaths}.*") "") + (("^\\\\AtBeginDocument\\{.*") "") + ((".*\\\\expandafter.*\\\\symSabonMaths.*") "") + (("^\\\\setsansfont.*MgOpen Cosmetica.*") "") + (("^\\\\setmonofont.*Consolas.*") "") + ;; The 'stix' texlive font package has been obsoleted by + ;; stix2. + (("^\\\\newfontfamily\\\\stixgeneral\\{STIXGeneral}") + "\\newfontfamily\\stixgeneral{STIX Two Text}")))) + (add-after 'build 'build-doc + (lambda* (#:key outputs tex-directory #:allow-other-keys) + (define doc-sources (string-append (getenv "ROOT_DIR") + "/doc/latex/metalogo")) + (copy-file "metalogo.dtx" "build/metalogo.dtx") + (mkdir "build/graphics") + (copy-file (string-append doc-sources "/TeXoutline.pdf") + "build/graphics/TeXoutline.pdf") + (copy-file (string-append doc-sources "/eLaToutline.pdf") + "build/graphics/eLaToutline.pdf") + (chdir "build") + (invoke "xelatex" "metalogo.dtx"))) ;generate metalogo.pdf + (replace 'install + (lambda* (#:key outputs tex-directory #:allow-other-keys) + (let ((doc (string-append (assoc-ref outputs "doc") + "/share/doc/" tex-directory)) + (out (string-append #$output "/share/texmf-dist/tex/" + tex-directory))) + (install-file "metalogo.pdf" doc) + (install-file (car (find-files (getenv "ROOT_DIR") "README")) + doc) + (install-file "metalogo.sty" out))))))) + (native-inputs (list fontconfig ;for XDG_DATA_DIRS, to locate OTF fonts + texlive-booktabs + texlive-cm + texlive-fontspec + texlive-generic-iftex + texlive-latex-base + texlive-latex-eukdate + texlive-latex-graphics + texlive-latex-multirow + texlive-lm ;for lmroman10-regular + texlive-stix2-otf)) + (propagated-inputs (list texlive-fontspec texlive-generic-iftex + texlive-latex-graphics)) + (home-page "https://ctan.org/pkg/metalogo") + (synopsis "Extended TeX logo macros") + (description "This package exposes spacing parameters for various TeX +logos to the end user, to optimise the logos for different fonts. It is +written especially for XeLaTeX users.") + (license license:lppl1.3c+))) + (define-public texlive-paralist (package (inherit (simple-texlive-package -- cgit v1.2.3 From 92f573f63aadb597031c991adfffe1031e393f89 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 31 Mar 2022 14:48:07 -0400 Subject: gnu: Add texlive-makecmds. * gnu/packages/tex.scm (texlive-makecmds): New variable. --- gnu/packages/tex.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index dea153643d..40390e9970 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -5417,6 +5417,50 @@ which adds some minor changes to LaTeX maths; a rewrite of LaTeX's tabular and array environments; verbatim handling; and syntax diagrams.") (license license:gpl3+))) +(define-public texlive-makecmds + (package + (inherit (simple-texlive-package + "texlive-makecmds" + (list "doc/latex/makecmds/README" + "source/latex/makecmds/makecmds.dtx" + "source/latex/makecmds/makecmds.ins") + (base32 "0znx80x6ic7a25v9dw8yjibq7lx65wangcyii18kk5x5z4jljba9"))) + (outputs '("out" "doc")) + (arguments + (list + #:tex-directory "latex/makecmds" + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'chdir + (lambda _ + (setenv "ROOT_DIR" (getcwd)) + (chdir "source/latex/makecmds"))) + (add-after 'build 'build-doc + (lambda _ + (copy-file "makecmds.dtx" "build/makecmds.dtx") + (chdir "build") + (invoke "pdflatex" "makecmds.dtx"))) ;generate makecmds.pdf + (replace 'install + (lambda* (#:key outputs tex-directory #:allow-other-keys) + (let ((doc (string-append (assoc-ref outputs "doc") + "/share/doc/" tex-directory)) + (out (string-append #$output "/share/texmf-dist/tex/" + tex-directory))) + (install-file "makecmds.pdf" doc) + (install-file (car (find-files (getenv "ROOT_DIR") "README")) + doc) + (install-file "makecmds.sty" out))))))) + (native-inputs (list (texlive-updmap.cfg + (list texlive-amsfonts + texlive-cm)))) + (home-page "https://www.ctan.org/pkg/makecmds") + (synopsis "TeX macro to define or redefine a command") + (description "The package provides a @code{\\makecommand} command, which +is like @code{\\newcommand} or @code{\\renewcommand} except it +always (re)defines a command. There is also @code{\\makeenvironment} and +@code{\\provideenvironment} for environments.") + (license license:lppl1.3c+))) + (define-public texlive-metalogo (package (inherit (simple-texlive-package -- cgit v1.2.3 From 5d40463875703b2aca792bb60581eda2b8f82bbf Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 31 Mar 2022 22:46:40 -0400 Subject: gnu: Add texlive-csplain. * gnu/packages/tex.scm (texlive-csplain): New variable. --- gnu/packages/tex.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 40390e9970..f8fa65e386 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -4081,6 +4081,34 @@ polyglossia package rather than Babel.") (define-deprecated-package texlive-latex-babel texlive-babel) +;;; Note: if this package is modified, its name must be changed to comply with +;;; its license. +(define-public texlive-csplain + (package + (inherit (simple-texlive-package + "texlive-csplain" + (list "tex/csplain/base/") + (base32 "0cgrwc8lgf2x2hq6bb4kqxw597card985zdd9ipn7k98mmwrxhz3") + #:trivial? #t)) + (home-page "http://petr.olsak.net/csplain-e.html") + (synopsis "Plain TeX multilanguage support") + (description "CSplain is a small extension of basic Plain TeX macros from +which the formats @code{csplain} and @code{pdfcsplain} can be generated. It +supports: hyphenation of words for 50+ languages, simple and powerful font +loading system (various sizes of fonts), TeX, pdfTeX, XeTeX and LuaTeX +engines, math fonts simply loaded with full amstex-like features, three +internal encodings (IL2 for Czech/Slovak languages, T1 for many languages with +latin alphabet and Unicode in new TeX engines), natural UTF-8 input in pdfTeX +using encTeX without any active characters, Czech and Slovak special +typesetting features. An important part of the package is OPmac, which +implements most of LaTeX's features (sectioning, font selection, color, hyper +reference and URLs, bibliography, index, table of contents, tables, etc.) by +Plain TeX macros. The OPmac macros can generate a bibliography without any +external program.") + ;; This custom permissive license includes as a redistribution condition + ;; that says the package must be renamed from 'csplain' if it is modified. + (license (license:non-copyleft "file:///tex/csplain/base/csplain.ini")))) + (define-public texlive-generic-babel-english (package (name "texlive-generic-babel-english") -- cgit v1.2.3 From 5289d2851582c31b698b0a7faaa0d216db86b810 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Apr 2022 00:26:20 -0400 Subject: gnu: Add texlive-cs. * gnu/packages/tex.scm (texlive-cs): New variable. --- gnu/packages/tex.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index f8fa65e386..82da10c41a 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -4081,6 +4081,37 @@ polyglossia package rather than Babel.") (define-deprecated-package texlive-latex-babel texlive-babel) +(define-public texlive-cs + (package + (inherit (simple-texlive-package + "texlive-cs" + (list + "fonts/enc/dvips/cs/" + "fonts/map/dvips/cs/" + "fonts/source/public/cs/" + ;; TODO: Remove these pre-built files after the manual + ;; build below is fixed. + ;; The font fails to build from the Metafont sources, with + ;; errors such as: + ;; This is METAFONT, Version 2.71828182 (TeX Live 2021/GNU Guix) [...] + ;; (./csaccent.mf + ;; >> cap_curve#-dot_size# + ;; ! Unknown relation will be considered false. + ;; + "fonts/tfm/cs/cs-a35/" + "fonts/tfm/cs/cs-charter/" + "fonts/tfm/public/cs/" + "fonts/type1/public/cs/" + "fonts/vf/cs/cs-a35/") + (base32 "1ww5lrqja051fh0ygmfdyy5a6bhwq9k5zv857vwiqf5syvw5djps") + #:trivial? #t)) + (home-page "http://petr.olsak.net/cstex/") + (synopsis "Czech/Slovak-tuned Computer Modern fonts") + (description "This package provides Czech/Slovak-tuned Computer Modern +fonts in the Metafont format; Type 1 format versions (csfonts-t1) are also +available.") + (license license:gpl2+))) ;see fonts/source/public/cs/cscode.mf + ;;; Note: if this package is modified, its name must be changed to comply with ;;; its license. (define-public texlive-csplain -- cgit v1.2.3 From 13c19e3bfbf4b72aa149b034c9616eefcee1a53c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Apr 2022 12:13:28 -0400 Subject: gnu: Add texlive-zref. * gnu/packages/tex.scm (texlive-zref): New variable. --- gnu/packages/tex.scm | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 82da10c41a..1ebaceb322 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -6360,6 +6360,76 @@ Adobe's basic set.") ;; No license version specified. (license license:gpl3+))) +(define-public texlive-zref + (package + (inherit (simple-texlive-package + "texlive-zref" + (list "doc/latex/zref/" + "source/latex/zref/") + (base32 "09l2wrqx0navislkx15iazv7jy0ip8bqaw3c0hjf0jy81kqrrm01"))) + (outputs '("out" "doc")) + (arguments + (list + #:build-targets #~(list "zref.dtx") + #:tex-directory "latex/zref" + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'chdir + (lambda _ + (setenv "ROOT_DIR" (getcwd)) + (chdir "source/latex/zref"))) + (add-after 'install 'install-doc + (lambda* (#:key outputs #:allow-other-keys) + (define doc (string-append (assoc-ref outputs "doc") + "/share/texmf-dist/doc")) + (mkdir-p doc) + (copy-recursively (string-append (getenv "ROOT_DIR") "/doc") + doc)))))) + (propagated-inputs (list texlive-generic-atbegshi + texlive-generic-gettitlestring + texlive-generic-iftex + texlive-latex-atveryend + texlive-latex-kvoptions + texlive-latex-pdftexcmds + texlive-latex-xkeyval)) + (home-page "https://github.com/ho-tex/zref") + (synopsis "Reference scheme for LaTeX") + (description "This package offers a means to remove the limitation, of +only two properties, that is inherent in the way LaTeX's reference system +works. The package implements an extensible referencing system, where +properties may be defined and used in the course of a document. It provides +an interface for macro programmers to access the new reference scheme and some +modules that use it. Modules available are: +@table @code +@item zref-user +use zref for traditional labels and references; +@item zref-abspage +retrieve absolute page numbers (physical pages, as opposed to the logical page +number that is normally typeset when a page number is requested; +@item zref-lastpage +provide a zref-label for the last page of the document; +@item zref-nextpage +provide the page number of the next page of the document; +@item zref-totpages +provide the total number of pages in the document; +@item zref-pagelayout +provide the page layout parameters of a each page (which may then be printed +at the end of the document); +@item zref-perpage +make a counter reset for each new page; +@item zref-titleref +make section title or caption text available through the reference system; +@item zref-savepos +make positions on a page available; +@item zref-dotfill +controlled dot-filling +@item zref-env +record the latest environment's name and the line it started on; +@item zref-xr +provide the facilities of the xr and xr-hyper packages. +@end table") + (license license:lppl1.3c+))) + (define-deprecated-package texlive-fonts-adobe-zapfding texlive-zapfding) (define-public texlive-fonts-rsfs -- cgit v1.2.3 From dcd97606a3afba2cf72d2cecd87ecac36cfb4e36 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Apr 2022 14:10:55 -0400 Subject: gnu: Add python-pcpp. * gnu/packages/c.scm (python-pcpp): New variable. --- gnu/packages/c.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/c.scm b/gnu/packages/c.scm index 2680fe63f0..e14e56ad71 100644 --- a/gnu/packages/c.scm +++ b/gnu/packages/c.scm @@ -38,6 +38,7 @@ #:use-module (guix git-download) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) + #:use-module (guix build-system python) #:use-module (guix build-system trivial) #:use-module (guix store) #:use-module (gnu packages) @@ -144,6 +145,37 @@ compiler while still keeping it small, simple, fast and understandable.") ;; preferred. See http://pcc.ludd.ltu.se/licenses/ for more details. (license (list license:bsd-2 license:bsd-3)))) +(define-public python-pcpp + (package + (name "python-pcpp") + (version "1.30") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ned14/pcpp") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1rihvlg11nzk70kfzz4i3gi5izcy46w05ismcx04p5j1hlim0brb")))) + (build-system python-build-system) + (arguments + (list + #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'unbundle-ply + (lambda _ + (rmdir "pcpp/ply") + (substitute* "setup.py" + (("'pcpp/ply/ply'") ""))))))) + (native-inputs (list python-pytest)) + (propagated-inputs (list python-ply)) + (home-page "https://github.com/ned14/pcpp") + (synopsis "C99 preprocessor written in Python") + (description "This package provides a C99 preprocessor written in pure +Python.") + (license license:bsd-3))) + (define-public libbytesize (package (name "libbytesize") -- cgit v1.2.3 From 8907dcce772bb6a38ed520bce25dc9f55b3c3b01 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Apr 2022 14:57:40 -0400 Subject: gnu: Add opentype-sanitizer. * gnu/packages/fontutils.scm (opentype-sanitizer): New variable. --- gnu/packages/fontutils.scm | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index c8c32fd5a9..16c2391179 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -12,7 +12,7 @@ ;;; Copyright © 2019, 2020 Marius Bakke ;;; Copyright © 2020 Roel Janssen ;;; Copyright © 2020, 2021 Nicolas Goaziou -;;; Copyright © 2021 Maxim Cournoyer +;;; Copyright © 2021, 2022 Maxim Cournoyer ;;; Copyright © 2020, 2021 Nicolas Goaziou ;;; Copyright © 2021 Sarah Morgensen ;;; Copyright © 2022 Felipe Balbi @@ -65,6 +65,7 @@ #:use-module (gnu packages xorg) #:use-module (gnu packages tex) #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix svn-download) @@ -108,6 +109,28 @@ anti-aliased glyph bitmap generation with 256 gray levels.") (license license:freetype) ; some files have other licenses (home-page "https://www.freetype.org/"))) +(define-public opentype-sanitizer + (package + (name "opentype-sanitizer") + (version "8.2.1") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/khaledhosny/ots" + "/releases/download/v" version + "/ots-" version ".tar.xz")) + (sha256 + (base32 + "17z8cxv48rfig5k7j3xk3bmbf7rm3kxsc3bazix96l0wws58r569")))) + (build-system meson-build-system) + (native-inputs (list googletest pkg-config)) + (inputs (list freetype lz4 woff2 zlib)) + (home-page "https://github.com/khaledhosny/ots") + (synopsis "Sanitizer for OpenType fonts") + (description "The OpenType Sanitizer (OTS) parses and serializes OpenType +files (OTF, TTF) and WOFF and WOFF2 font files, validating them and sanitizing +them as it goes.") + (license license:bsd-3))) + (define-public ttfautohint (package (name "ttfautohint") -- cgit v1.2.3 From 9e29cf8d73c39fa65a9d4a107b5db614cb88062a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Apr 2022 15:28:00 -0400 Subject: gnu: Add python-opentype-sanitizer. * gnu/packages/fontutils.scm (python-opentype-sanitizer): New variable. --- gnu/packages/fontutils.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 16c2391179..ec6dab37ff 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -131,6 +131,43 @@ files (OTF, TTF) and WOFF and WOFF2 font files, validating them and sanitizing them as it goes.") (license license:bsd-3))) +(define-public python-opentype-sanitizer + (package + (name "python-opentype-sanitizer") + (version "8.2.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "opentype-sanitizer" version)) + (sha256 + (base32 "1wjy6chbnj9ic5yjxal6spln5jfzr8cigqs6ab0gj7q60dndrl5k")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'unbundle-opentype-sanitizer + (lambda* (#:key inputs #:allow-other-keys) + (delete-file-recursively "src/c") + (substitute* "setup.py" + (("^cmdclass\\[\"download\"].*") "") + (("^cmdclass\\[\"build_ext\"].*") "") + (("^cmdclass\\[\"egg_info\"].*") "")) + (substitute* "src/python/ots/__init__.py" + (("^OTS_SANITIZE = .*") + (format #f "OTS_SANITIZE = ~s~%" + (search-input-file inputs "bin/ots-sanitize")))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-pytest python-setuptools-scm)) + (inputs (list opentype-sanitizer)) + (home-page "https://github.com/googlefonts/ots-python") + (synopsis "Python wrapper for OpenType Sanitizer") + (description "Python wrapper for the OpenType Sanitizer library.") + (license license:bsd-3))) + (define-public ttfautohint (package (name "ttfautohint") -- cgit v1.2.3 From 2c7e76ed1413fc564e8ce9a7ea7b480a4d74d74a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Apr 2022 16:22:50 -0400 Subject: gnu: Add python-defcon-bootstrap. * gnu/packages/fontutils.scm (python-defcon-bootstrap): New variable. --- gnu/packages/fontutils.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index ec6dab37ff..61b39e510d 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -821,6 +821,36 @@ generate bitmaps.") files. UFO is a file format that stores fonts source files.") (license license:bsd-3))) +;;; A variant used to break a cycle between python-fontpens and +;;; python-fontparts. +(define-public python-defcon-bootstrap + (package + (name "python-defcon-bootstrap") + (version "0.10.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "defcon" version ".zip")) + (sha256 + (base32 "0g0bjwzdj6sskyh8snbxsxza3czdmvb807qv38mizx631cm8c2d0")))) + (build-system python-build-system) + (propagated-inputs (list python-fontpens-bootstrap python-fonttools-full)) + (native-inputs + (list python-pytest + python-pytest-runner + python-setuptools-scm + unzip)) + (home-page "https://github.com/robotools/defcon") + (synopsis "Flexible objects for representing @acronym{UFO, unified font object} data") + (description "Defcon is a set of @acronym{UFO, unified font object} based +objects optimized for use in font editing applications. The objects are built +to be lightweight, fast and flexible. The objects are very bare-bones and +they are not meant to be end-all, be-all objects. Rather, they are meant to +provide base functionality so that you can focus on your application’s +behavior, not object observing or maintaining cached data. Defcon implements +UFO3 as described by the UFO font format.") + (license license:expat))) + (define-public python2-defcon (package (name "python2-defcon") -- cgit v1.2.3 From dc5cf89205182f7538858993cc603d56aa231035 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Apr 2022 16:40:43 -0400 Subject: gnu: Add python-fontmath. * gnu/packages/fontutils.scm (python-fontmath): New variable. --- gnu/packages/fontutils.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 61b39e510d..8870b87abb 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -57,6 +57,7 @@ #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-xyz) #:use-module (gnu packages sqlite) #:use-module (gnu packages webkit) @@ -131,6 +132,30 @@ files (OTF, TTF) and WOFF and WOFF2 font files, validating them and sanitizing them as it goes.") (license license:bsd-3))) +(define-public python-fontmath + (package + (name "python-fontmath") + (version "0.9.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "fontMath" version ".zip")) + (sha256 + (base32 "001756zxn2386dm4svgqjgw5026hvyacxl09b2qlk7s06phpcphw")))) + (build-system python-build-system) + (propagated-inputs (list python-fonttools)) + (native-inputs + (list python-setuptools-scm + python-pytest + python-pytest-runner + python-wheel + unzip)) + (home-page "https://github.com/robotools/fontMath") + (synopsis "Fast font mathematical operations library") + (description "This package provides a set of objects for performing fast +font, glyph, etc. mathematical operations on font data.") + (license license:expat))) + (define-public python-opentype-sanitizer (package (name "python-opentype-sanitizer") -- cgit v1.2.3 From 9b6bad8c337d8045d9b7041d590eefbb67571482 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 7 Apr 2022 15:29:26 -0400 Subject: gnu: Add python-unicodedata2. * gnu/packages/python-xyz.scm (python-unicodedata2): New variable. --- gnu/packages/python-xyz.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index e1076b7190..e4cb812c53 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -14622,6 +14622,23 @@ numbers with uncertainties. It can also yield the derivatives of any expression.") (license license:bsd-3))) +(define-public python-unicodedata2 + (package + (name "python-unicodedata2") + (version "14.0.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "unicodedata2" version)) + (sha256 + (base32 "110nnvh02ssp92xbmswy39aa186jrmb7m41x4220wigl8c0dzxs1")))) + (build-system python-build-system) + (home-page "https://github.com/fonttools/unicodedata2") + (synopsis "Python unicodedata backport") + (description "This package corresponds to the latest @code{unicodedata} +standard Python module.") + (license license:asl2.0))) + (define-public python-asteval (package (name "python-asteval") -- cgit v1.2.3 From 51b36ab71f1e5051fff55ccc4fd1855a927985dd Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Apr 2022 20:40:53 -0400 Subject: gnu: python-fonttools-with-test: Rename to python-fonttools-full. * gnu/packages/python-xyz.scm (python-fonttools-with-test): Rename to... (python-fonttools-full): ... this. [native-inputs]: Move python-brotli, python-fs, python-scipy and python-zopfli to... [propagated-inputs]: ... here. Add python-lxml, python-lz4 and python-unicodedata2. --- gnu/packages/python-xyz.scm | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index e4cb812c53..f8ef15cea1 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -11379,7 +11379,9 @@ from an XML-based format.") (license license:expat) (properties `((python2-variant . ,(delay python2-fonttools))))))) -(define-public python-fonttools-with-tests +;;; Rename 'python-fonttools' in next cycle, renaming the current +;;; 'python-fonttools' to 'python-fonttools-minimal'. +(define-public python-fonttools-full (package/inherit python-fonttools (arguments (substitute-keyword-arguments (package-arguments python-fonttools) @@ -11404,11 +11406,15 @@ from an XML-based format.") " and not ")))))))))) (native-inputs (modify-inputs (package-native-inputs python-fonttools) - (append python-pytest ;FIXME: indentation is broken - python-brotli - python-fs - python-scipy - python-zopfli))) + (append python-pytest))) + (propagated-inputs + (list python-brotli + python-fs + python-lxml + python-lz4 + python-scipy + python-unicodedata2 + python-zopfli)) (properties (alist-delete 'hidden? (package-properties python-fonttools))))) ;; Fonttools 4.x dropped support for Python 2, so stick with 3.x here. -- cgit v1.2.3 From b24aefa6156bdf42405df1bdc7e5773134ada0e8 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 4 Apr 2022 22:22:00 -0400 Subject: gnu: Add python-mutatormath. * gnu/packages/fontutils.scm (python-mutatormath): New variable. --- gnu/packages/fontutils.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 8870b87abb..4eec234126 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -193,6 +193,27 @@ font, glyph, etc. mathematical operations on font data.") (description "Python wrapper for the OpenType Sanitizer library.") (license license:bsd-3))) +(define-public python-mutatormath + (package + (name "python-mutatormath") + (version "3.0.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "MutatorMath" version ".zip")) + (sha256 + (base32 "0r1qq45np49x14zz1zwkaayqrn7m8dn2jlipjldg2ihnmpzw29w1")))) + (build-system python-build-system) + (propagated-inputs (list python-defcon python-fontmath python-fonttools)) + (native-inputs (list unzip)) + (home-page "https://github.com/LettError/MutatorMath") + (synopsis "Piecewise linear interpolation Python library") + (description "MutatorMath is a Python library for the calculation of +piecewise linear interpolations in n-dimensions with any number of masters. It +was developed for interpolating data related to fonts, but if can handle any +arithmetic object.") + (license license:bsd-3))) + (define-public ttfautohint (package (name "ttfautohint") -- cgit v1.2.3 From 9fffc12efbe8266a7084d014e2a8d7c4ae00d17e Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 00:00:43 -0400 Subject: gnu: Add python-fontpens-bootstrap. * gnu/packages/fontutils.scm (python-fontpens-bootstrap): New variable. --- gnu/packages/fontutils.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 4eec234126..92b8c0a726 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -156,6 +156,27 @@ them as it goes.") font, glyph, etc. mathematical operations on font data.") (license license:expat))) +;;; An untested variant used to break a cycle with python-booleanoperations. +(define-public python-fontpens-bootstrap + (package + (name "python-fontpens-bootstrap") + (version "0.2.4") + (source + (origin + (method url-fetch) + (uri (pypi-uri "fontPens" version ".zip")) + (sha256 + (base32 "1za15dzsnymq6d9x7xdfqwgw4a3003wj75fn2crhyidkfd2s3nd6")))) + (build-system python-build-system) + (arguments (list #:tests? #f)) + (propagated-inputs (list python-fonttools)) + (native-inputs (list unzip)) + (home-page "https://github.com/robofab-developers/fontPens") + (synopsis "Python classes implementing the pen protocol") + (description "This package provides a collection of Python classes +implementing the pen protocol for manipulating glyphs.") + (license license:bsd-3))) + (define-public python-opentype-sanitizer (package (name "python-opentype-sanitizer") -- cgit v1.2.3 From f85c6ae42116e7aad82fd59804cf52e707f36aca Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 4 Apr 2022 22:29:29 -0400 Subject: gnu: Add python-booleanoperations. * gnu/packages/graphics.scm (python-booleanoperations): New variable. --- gnu/packages/graphics.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 9f93205183..b5a81ef196 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -98,6 +98,7 @@ #:use-module (gnu packages pth) #:use-module (gnu packages pulseaudio) ; libsndfile, libsamplerate #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-xyz) #:use-module (gnu packages qt) #:use-module (gnu packages readline) @@ -806,6 +807,31 @@ basic geometries.") ;; https://gitlab.com/inkscape/inkscape/issues/784). (license license:gpl3+))) +(define-public python-booleanoperations + (package + (name "python-booleanoperations") + (version "0.9.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "booleanOperations" version ".zip")) + (sha256 + (base32 "1f41lb19m8azchl1aqz6j5ycbspb8jsf1cnn42hlydxd68f85ylc")))) + (build-system python-build-system) + (propagated-inputs (list python-fonttools python-pyclipper)) + (native-inputs + (list python-defcon-bootstrap + python-fontpens-bootstrap + python-pytest + python-wheel + unzip)) + (home-page "https://github.com/typemytype/booleanOperations") + (synopsis "Boolean operations on paths") + (description "Boolean operations on paths which uses a super fast +@url{http://www.angusj.com/delphi/clipper.php, polygon clipper library by +Angus Johnson}.") + (license license:expat))) + (define-public pstoedit (package (name "pstoedit") -- cgit v1.2.3 From 16ca4673444ed25fe72b12d22bc625adc11e1a3f Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 00:05:07 -0400 Subject: gnu: Add python-fontparts-bootstrap. * gnu/packages/fontutils.scm (python-fontparts-bootstrap): New variable. --- gnu/packages/fontutils.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 92b8c0a726..26c35e26c9 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -50,6 +50,7 @@ #:use-module (gnu packages glib) #:use-module (gnu packages gnome) #:use-module (gnu packages gperf) + #:use-module (gnu packages graphics) #:use-module (gnu packages gtk) #:use-module (gnu packages image) #:use-module (gnu packages linux) @@ -177,6 +178,32 @@ font, glyph, etc. mathematical operations on font data.") implementing the pen protocol for manipulating glyphs.") (license license:bsd-3))) +;;; A variant used to break a cycle with python-fontpens. +(define-public python-fontparts-bootstrap + (hidden-package + (package + (name "python-fontparts-bootstrap") + (version "0.10.4") + (source + (origin + (method url-fetch) + (uri (pypi-uri "fontParts" version ".zip")) + (sha256 + (base32 "1ic453q86s5hsw8mxnclk1vr4qp69fd67gywhv23zqwz9a7kb7lh")))) + (build-system python-build-system) + (propagated-inputs + (list python-booleanoperations + python-defcon-bootstrap + python-fontmath + python-fonttools)) + (native-inputs (list unzip)) + (home-page "https://github.com/robotools/fontParts") + (synopsis "Library for interacting with font parts") + (description "FontParts is an @acronym{API, Application Programming +Interface} for interacting with the parts of fonts during the font development +process. FontParts is the successor of RoboFab.") + (license license:expat)))) + (define-public python-opentype-sanitizer (package (name "python-opentype-sanitizer") -- cgit v1.2.3 From 19cb21c749d8eb3331347884ed18f6c730226560 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 00:06:44 -0400 Subject: gnu: Add python-fontpens. * gnu/packages/fontutils.scm (python-fontpens): New variable. --- gnu/packages/fontutils.scm | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 26c35e26c9..e8839fdca7 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -178,6 +178,21 @@ font, glyph, etc. mathematical operations on font data.") implementing the pen protocol for manipulating glyphs.") (license license:bsd-3))) +(define-public python-fontpens + (hidden-package + (package/inherit python-fontpens-bootstrap + (name "python-fontpens") + (arguments + (substitute-keyword-arguments (package-arguments python-fontpens-bootstrap) + ((#:tests? _ #f) + #t))) + (native-inputs + (modify-inputs (package-native-inputs python-fontpens-bootstrap) + (append python-fontparts-bootstrap + python-fontpens-bootstrap + python-pytest + python-pytest-runner)))))) + ;;; A variant used to break a cycle with python-fontpens. (define-public python-fontparts-bootstrap (hidden-package -- cgit v1.2.3 From 0ce611f56397092ac963efac71be3d509f035733 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 00:09:14 -0400 Subject: gnu: Add python-defcon. * gnu/packages/fontutils.scm (python-defcon): New variable. (python2-defcon): Adjust to inherit from it. --- gnu/packages/fontutils.scm | 36 ++++++++++++++++-------------------- 1 file changed, 16 insertions(+), 20 deletions(-) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index e8839fdca7..503ff7afa3 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -960,35 +960,31 @@ behavior, not object observing or maintaining cached data. Defcon implements UFO3 as described by the UFO font format.") (license license:expat))) +(define-public python-defcon + (hidden-package + (package/inherit python-defcon-bootstrap + (name "python-defcon") + (propagated-inputs + (modify-inputs (package-propagated-inputs python-defcon-bootstrap) + (replace "python-fontpens-bootstrap" python-fontpens)))))) + (define-public python2-defcon (package + (inherit python-defcon) (name "python2-defcon") (version "0.3.5") - (source - (origin - (method url-fetch) - (uri (pypi-uri "defcon" version ".zip")) - (sha256 - (base32 - "03jlm2gy9lvbwj68kfdm43yaddwd634jwkdg4wf0jxx2s8mwbg22")))) - (build-system python-build-system) + (source (origin + (method url-fetch) + (uri (pypi-uri "defcon" version ".zip")) + (sha256 + (base32 + "03jlm2gy9lvbwj68kfdm43yaddwd634jwkdg4wf0jxx2s8mwbg22")))) (arguments `(#:python ,python-2)) (native-inputs (list unzip python2-pytest python2-pytest-runner)) (propagated-inputs - (list python2-fonttools python2-ufolib)) - (home-page "https://pypi.org/project/defcon/") - (synopsis "Flexible objects for representing @acronym{UFO, unified font object} data") - (description - "Defcon is a set of @acronym{UFO, unified font object} based objects -optimized for use in font editing applications. The objects are built to -be lightweight, fast and flexible. The objects are very bare-bones and -they are not meant to be end-all, be-all objects. Rather, they are meant -to provide base functionality so that you can focus on your application’s -behavior, not object observing or maintaining cached data. Defcon -implements UFO3 as described by the UFO font format.") - (license license:expat))) + (list python2-fonttools python2-ufolib)))) (define-public nototools (package -- cgit v1.2.3 From e3d1e821f9be2db1b4a77c8b06f3fbf2b6259481 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 00:10:16 -0400 Subject: gnu: Add python-fontparts. * gnu/packages/fontutils.scm (python-fontparts): New variable. --- gnu/packages/fontutils.scm | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 503ff7afa3..59b4f8075b 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -219,6 +219,16 @@ Interface} for interacting with the parts of fonts during the font development process. FontParts is the successor of RoboFab.") (license license:expat)))) +(define-public python-fontparts + (package/inherit python-fontparts-bootstrap + (name "python-fontparts") + (propagated-inputs + (modify-inputs (package-propagated-inputs python-fontparts-bootstrap) + (replace "python-defcon-bootstrap" python-defcon))) + (properties + (alist-delete 'hidden? + (package-properties python-fontparts-bootstrap))))) + (define-public python-opentype-sanitizer (package (name "python-opentype-sanitizer") -- cgit v1.2.3 From b93a63d4a08e2f0689d79da3879a9bc4ab17c69d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 00:27:45 -0400 Subject: gnu: Add python-cu2qu. * gnu/packages/fontutils.scm (python-cu2qu): New variable. --- gnu/packages/fontutils.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 59b4f8075b..20a03463e6 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -133,6 +133,33 @@ files (OTF, TTF) and WOFF and WOFF2 font files, validating them and sanitizing them as it goes.") (license license:bsd-3))) +(define-public python-cu2qu + (package + (name "python-cu2qu") + (version "1.6.7.post1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "cu2qu" version ".zip")) + (sha256 + (base32 "1x762r7bf39g6aivfvrmq00h6f07abvs9x1xm0fz8l81vq8jz64c")))) + (build-system python-build-system) + (propagated-inputs (list python-fonttools-full)) + (native-inputs + (list python-cython + python-defcon + python-pytest + python-pytest-runner + python-setuptools-scm + unzip)) + (home-page "https://github.com/googlefonts/cu2qu") + (synopsis "Cubic-to-quadratic bezier curve conversion") + (description "This library provides functions which take in @acronym{UFO, +Unified Font Object} objects (such as Defcon Fonts or Robofab RFonts) and +converts any cubic curves to quadratic. The most useful function is probably +@code{fonts_to_quadratic}.") + (license license:asl2.0))) + (define-public python-fontmath (package (name "python-fontmath") -- cgit v1.2.3 From ab2bab6d48e1a878301a708a71721a321c707a6d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 00:44:25 -0400 Subject: gnu: Add python-ufoprocessor. * gnu/packages/fontutils.scm (python-ufoprocessor): New variable. --- gnu/packages/fontutils.scm | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 20a03463e6..062b8fbd62 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -314,6 +314,49 @@ was developed for interpolating data related to fonts, but if can handle any arithmetic object.") (license license:bsd-3))) +(define-public python-ufoprocessor + (package + (name "python-ufoprocessor") + (version "1.9.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "ufoProcessor" version ".zip")) + (sha256 + (base32 "0ns11aamgavgsfj8qf5kq7dvzmgl0mhr1cbych2f075ipfdvva5s")))) + (build-system python-build-system) + (arguments + (list #:phases #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Most of the tests appear to be a work in + ;; progress; run only a subset. + (invoke "python" "Tests/tests.py"))))))) + (propagated-inputs + (list python-defcon + python-fontmath + python-fontparts + python-fonttools + python-mutatormath)) + (native-inputs (list unzip)) + (home-page "https://github.com/LettError/ufoProcessor") + (synopsis "Process and generate @acronym{UFO, Unified Font Object} files") + (description "This Python package processes and generates instances for +@acronym{UFO, Unified Font Object} files, glyphs and other data. It can, +among other things: +@itemize +@item Collect source materials. +@item Provide mutators for specific glyphs, font info, kerning so that other +tools can generate partial instances. +@item Support designspace format 4 with layers. +@item Apply avar-like designspace bending. +@item Apply rules. +@item Generate actual UFO instances in formats 2 and 3. +@item Round geometry as requested. +@end itemize") + (license license:expat))) + (define-public ttfautohint (package (name "ttfautohint") -- cgit v1.2.3 From 63a77de2fc3718e1c8967bbc1281e0735ac2e807 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 00:52:28 -0400 Subject: gnu: Add python-ufonormalizer. * gnu/packages/fontutils.scm (python-ufonormalizer): New variable. --- gnu/packages/fontutils.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 062b8fbd62..a2e71f1ad0 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -357,6 +357,32 @@ tools can generate partial instances. @end itemize") (license license:expat))) +(define-public python-ufonormalizer + (package + (name "python-ufonormalizer") + (version "0.6.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "ufonormalizer" version ".zip")) + (sha256 + (base32 "0v5awian2alap7nvxfz38aahyqbqnma16nrqcpr8602hbbki04g6")))) + (build-system python-build-system) + (native-inputs (list python-setuptools-scm unzip)) + (home-page "https://github.com/unified-font-object/ufoNormalizer") + (synopsis "Script to normalize @acronym{UFO, Unified Font Object} data") + (description "The purpose of the @command{ufonormalizer} command is to +provide a standard formatting so that updates to @acronym{UFO, Unified Font +Object} data can be usefully versioned. Examples of formatting applied by +ufoNormalizer include: +@itemize +@item Changing floating-point numbers to integers where it doesn't alter the +value (e.g. @samp{x=\"95.0\"} becomes @samp{x=\"95\"}) +@item Rounding floating-point numbers to 10 digits +@item Formatting XML with tabs rather than spaces. +@end itemize") + (license license:bsd-3))) + (define-public ttfautohint (package (name "ttfautohint") -- cgit v1.2.3 From 21db2a0848a661883ebc9dfd53c125488541a835 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 10:53:21 -0400 Subject: gnu: Add python-types-toml. * gnu/packages/python-xyz.scm (python-types-toml): New variable. --- gnu/packages/python-xyz.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index f8ef15cea1..f1023c0563 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -29512,6 +29512,24 @@ async I/O support.") "This package adds ANSI colors and decorations to your strings.") (license license:isc))) +(define-public python-types-toml + (package + (name "python-types-toml") + (version "0.10.5") + (source + (origin + (method url-fetch) + (uri (pypi-uri "types-toml" version)) + (sha256 + (base32 "10400bd3yv6rjfnq8galskkbpqz1sfx9sfgr5qwvw04270x4cjgr")))) + (build-system python-build-system) + (home-page "https://github.com/python/typeshed") + (synopsis "Typing stubs for TOML") + (description "This package contains typing stubs for TOML, a very small +subset the Python stubs contained in the complete @code{typeshed} +collection.") + (license license:asl2.0))) + (define-public python-types-ujson (package (name "python-types-ujson") -- cgit v1.2.3 From 5475a267ea2668dd2923b578658e10f031e724a1 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 11:00:27 -0400 Subject: gnu: Add python-pytest-mypy. * gnu/packages/check.scm (python-pytest-mypy): New variable. --- gnu/packages/check.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 335ab7ab11..75b42b945a 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -2200,6 +2200,27 @@ style test suites, summarizing their results, and providing indication of failures.") (license license:ncsa))) +(define-public python-pytest-mypy + (package + (name "python-pytest-mypy") + (version "0.9.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pytest-mypy" version)) + (sha256 + (base32 "0p5bd4r4gbwk1h7mpx1jkhdwkckapfz24bp9x5mmqb610ps3pylz")))) + (build-system python-build-system) + (native-inputs (list python-setuptools-scm)) + (propagated-inputs + (list python-attrs python-filelock python-mypy python-pytest)) + (home-page "https://github.com/dbader/pytest-mypy") + (synopsis "Mypy static type checker plugin for Pytest") + (description "@code{pytest-mypi} is a static type checker plugin for +Pytest that runs the mypy static type checker on your source files as part of +a Pytest test execution.") + (license license:expat))) + (define-public python-pytest-pep8 (package (name "python-pytest-pep8") -- cgit v1.2.3 From ab1dc1f162d131fa4980e9117c419c45b71c5f85 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 11:32:10 -0400 Subject: gnu: Add python-jaraco-context-bootstrap. * gnu/packages/python-xyz.scm (python-jaraco-context-bootstrap): New variable. --- gnu/packages/python-xyz.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index f1023c0563..9c77ef52d0 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8495,6 +8495,27 @@ finding unresolved symbols in Python code and their corresponding imports.") "@code{inotify-simple} is a simple wrapper around inotify library.") (license license:bsd-3))) +;;; Variant used to break a cycle with python-pytest-enabler. +(define-public python-jaraco-context-bootstrap + (hidden-package + (package + (name "python-jaraco-context-bootstrap") + (version "4.1.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "jaraco.context" version)) + (sha256 + (base32 "0hbjm1rpxf4pzmbdp9rh3ali4zqnlcr8m97bhh1nizxvzcpxim7h")))) + (build-system python-build-system) + (arguments (list #:tests? #f)) + (native-inputs (list python-setuptools-scm)) + (home-page "https://github.com/jaraco/jaraco.context") + (synopsis "Context managers Python library") + (description "This Python library provides context managers-related +procedures.") + (license license:expat)))) + (define-public python-jaraco-packaging (package (name "python-jaraco-packaging") -- cgit v1.2.3 From 3d72680d0ea3f9cd42364006e8c1886a9fc3a718 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 11:32:18 -0400 Subject: gnu: Add python-jaraco-functools-bootstrap. * gnu/packages/python-xyz.scm (python-jaraco-functools-bootstrap): New variable. --- gnu/packages/python-xyz.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 9c77ef52d0..58902afd39 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8516,6 +8516,28 @@ finding unresolved symbols in Python code and their corresponding imports.") procedures.") (license license:expat)))) +;;; Variant used to break a cycle with python-pytest-enabler. +(define-public python-jaraco-functools-bootstrap + (hidden-package + (package + (name "python-jaraco-functools-bootstrap") + (version "3.5.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "jaraco.functools" version)) + (sha256 + (base32 "186xqzs3bqhjwajnprxy3sc3h0w5vdld8spc1dxjnn9720yykq1i")))) + (build-system python-build-system) + (arguments (list #:tests? #f)) + (native-inputs (list python-setuptools-scm)) + (propagated-inputs (list python-more-itertools)) + (home-page "https://github.com/jaraco/jaraco.functools") + (synopsis "Python library extending Python's @code{functools}") + (description "This library extends the standard @code{functools} Python +module with a few extra procedures.") + (license license:expat)))) + (define-public python-jaraco-packaging (package (name "python-jaraco-packaging") -- cgit v1.2.3 From 21f29263f3572c4a273d9e548adb8c8c8882e445 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 12:08:31 -0400 Subject: gnu: Add python-autocommand. * gnu/packages/python-xyz.scm (python-autocommand): New variable. --- gnu/packages/python-xyz.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 58902afd39..f7cae9e656 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -7097,6 +7097,36 @@ multiple values for the same key. An ordered multivalue dictionary is a multivalue dictionary that retains the order of insertions and deletions.") (license license:unlicense))) +(define-public python-autocommand + (package + (name "python-autocommand") + (version "2.2.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "autocommand" version)) + (sha256 + (base32 "03qp9xx4dq81ljhf56r21gp5j0lpqs1vaw99g0d84i97s3lj1m7y")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; This test fails with an invalid syntax error on 'task1 = + ;; asyncio.async(coro_1())' (see: + ;; https://github.com/Lucretiel/autocommand/issues/20). + (delete-file "test/test_autoasync.py") + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-pytest python-pytest-asyncio)) + (home-page "https://github.com/Lucretiel/autocommand") + (synopsis "Python library to build a command-line from a function") + (description "@code{autocommand} is library to automatically generate and +run simple @code{argparse} parsers from function signatures.") + (license license:lgpl3+))) + (define-public python-autopep8 (package (name "python-autopep8") -- cgit v1.2.3 From 08b524fa7850e03b15b8d47e8afce2fb5f53a00e Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 13:20:45 -0400 Subject: gnu: Add python-types-freezegun. * gnu/packages/python-xyz.scm (python-types-freezegun): New variable. --- gnu/packages/python-xyz.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index f7cae9e656..ef12d973e6 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -29585,6 +29585,24 @@ async I/O support.") "This package adds ANSI colors and decorations to your strings.") (license license:isc))) +(define-public python-types-freezegun + (package + (name "python-types-freezegun") + (version "1.1.8") + (source + (origin + (method url-fetch) + (uri (pypi-uri "types-freezegun" version)) + (sha256 + (base32 "08g926s8343zwq140zcfwly3qfgmahm7lp0vgb3ics549b2hifzl")))) + (build-system python-build-system) + (home-page "https://github.com/python/typeshed") + (synopsis "Typing stubs for @code{freezegun}") + (description "This package contains typing stubs for for @code{freezegun}, a +very small subset the Python stubs contained in the complete @code{typeshed} +collection.") + (license license:asl2.0))) + (define-public python-types-toml (package (name "python-types-toml") -- cgit v1.2.3 From 586ef9b9cfe0286712c710752e2904fa82be9365 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 13:20:53 -0400 Subject: gnu: Add python-types-pytz. * gnu/packages/python-xyz.scm (python-types-pytz): New variable. --- gnu/packages/python-xyz.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index ef12d973e6..3ef29cccc2 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -29603,6 +29603,24 @@ very small subset the Python stubs contained in the complete @code{typeshed} collection.") (license license:asl2.0))) +(define-public python-types-pytz + (package + (name "python-types-pytz") + (version "2021.3.6") + (source + (origin + (method url-fetch) + (uri (pypi-uri "types-pytz" version)) + (sha256 + (base32 "14yr5hg2ww8s4a0mz2bkd549fv8qgm538fnzxvqv92ld1pcpym3l")))) + (build-system python-build-system) + (home-page "https://github.com/python/typeshed") + (synopsis "Typing stubs for pytz") + (description "This package contains typing stubs for @code{pytz}, a very +small subset the Python stubs contained in the complete @code{typeshed} +collection.") + (license license:asl2.0))) + (define-public python-types-toml (package (name "python-types-toml") -- cgit v1.2.3 From 3ce8459aa728ce85bd1f67194539a33cec0a9d1b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 13:36:25 -0400 Subject: gnu: Add python-pytest-freezegun. * gnu/packages/check.scm (python-pytest-freezegun): New variable. --- gnu/packages/check.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 75b42b945a..1db4457dde 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -2200,6 +2200,38 @@ style test suites, summarizing their results, and providing indication of failures.") (license license:ncsa))) +(define-public python-pytest-freezegun + (package + (name "python-pytest-freezegun") + (version "0.4.2") + (source (origin + ;; The test suite is not included in the PyPI archive. + (method git-fetch) + (uri (git-reference + (url "https://github.com/ktosiek/pytest-freezegun") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "10c4pbh03b4s1q8cjd75lr0fvyf9id0zmdk29566qqsmaz28npas")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (propagated-inputs (list python-freezegun python-pytest)) + (native-inputs (list unzip)) + (home-page "https://github.com/ktosiek/pytest-freezegun") + (synopsis "Pytest plugin to freeze time in test fixtures") + (description "The @code{pytest-freezegun} plugin wraps tests and fixtures +with @code{freeze_time}, which allows to control (i.e., freeze) the time seen +by the test.") + (license license:expat))) + (define-public python-pytest-mypy (package (name "python-pytest-mypy") -- cgit v1.2.3 From e96c2dcabf898c8aaebe4191922cb186f43f376c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 13:45:16 -0400 Subject: gnu: Add python-pytest-enabler-bootstrap. * gnu/packages/check.scm (python-pytest-enabler-bootstrap): New variable. --- gnu/packages/check.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 1db4457dde..135fd671a2 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -2200,6 +2200,31 @@ style test suites, summarizing their results, and providing indication of failures.") (license license:ncsa))) +;;; This is marked as a bootstrap package because it propagates bootstrapped +;;; versions of jaraco-context and jaraco-functools. +(define-public python-pytest-enabler-bootstrap + (hidden-package + (package + (name "python-pytest-enabler-bootstrap") + (version "1.2.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pytest-enabler" version)) + (sha256 + (base32 "023ymm0r2gpn5q7aikvx567s507j0zk46w41w6gxb69c688zgs73")))) + (build-system python-build-system) + (arguments (list #:tests? #f)) + (propagated-inputs + (list python-jaraco-context-bootstrap + python-jaraco-functools-bootstrap + python-toml)) + (native-inputs (list python-setuptools-scm)) + (home-page "https://github.com/jaraco/pytest-enabler") + (synopsis "Enable installed pytest plugins") + (description "Enable installed pytest plugins") + (license license:expat)))) + (define-public python-pytest-freezegun (package (name "python-pytest-freezegun") -- cgit v1.2.3 From fc7fc0764b9deb41c9425f0c1596d2298cb3a935 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 14:35:40 -0400 Subject: gnu: Add python-path-bootstrap. * gnu/packages/python-xyz.scm (python-path-bootstrap): New variable. --- gnu/packages/python-xyz.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 3ef29cccc2..563ff63e7a 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -12572,6 +12572,44 @@ is binding LibSass.") domains support.") (license license:expat))) +;;; Variant used to break a cycle with python-pip-run-bootstrap. +(define-public python-path-bootstrap + (hidden-package + (package + (name "python-path-bootstrap") + (version "16.4.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "path" version)) + (sha256 + (base32 "0lig13gxnfv98v790db1smvsbd3mnj7y8rwyiwhfi6xiqibygwms")))) + (build-system python-build-system) + (arguments + (list + #:tests? #f + #:phases + #~(modify-phases %standard-phases + ;; XXX: PEP 517 manual build/install procedures copied from + ;; python-isort. + (replace 'build + (lambda _ + ;; ZIP does not support timestamps before 1980. + (setenv "SOURCE_DATE_EPOCH" "315532800") + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (native-inputs (list python-pypa-build python-setuptools-scm)) + (home-page "https://github.com/jaraco/path") + (synopsis "Object-oriented file system path manipulation library") + (description "@code{path} (formerly @code{path.py}) implements path +objects as first-class entities, allowing common operations on files to be +invoked on those path objects directly.") + (license license:expat)))) + (define-public python-pretend (package (name "python-pretend") -- cgit v1.2.3 From 040615d8f889ed51e238caad59cb6e1650d96aa1 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 14:41:19 -0400 Subject: gnu: Add python-pip-run-bootstrap. * gnu/packages/python-xyz.scm (python-pip-run-bootstrap): New variable. --- gnu/packages/python-xyz.scm | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 563ff63e7a..c622e1f93d 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -12658,6 +12658,49 @@ Python Package Index (PyPI).") (define-public python2-pip (package-with-python2 python-pip)) +;;; Variant used to break a dependency cycle with +;;; python-pytest-perf-bootstrap. +(define-public python-pip-run-bootstrap + (hidden-package + (package + (name "python-pip-run-bootstrap") + (version "8.8.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/jaraco/pip-run") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0ycrjj3jgqcr9c2k7y8vprq65iblg0q0hvwz8zwi13gmb0ffds0c")))) + (build-system python-build-system) + (arguments + (list + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'pretend-version + ;; The version string is usually derived via setuptools-scm, but + ;; without the git metadata available this fails. + (lambda _ + (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" #$version)))))) + (native-inputs (list python-setuptools-scm)) + (propagated-inputs (list python-autocommand python-path-bootstrap + python-packaging)) + (home-page "https://github.com/jaraco/pip-run") + (synopsis "Dynamic dependency loader for Python") + (description "The @command{pip-run} command provides on-demand temporary +package installation for a single interpreter run. It replaces this series of +commands: +@example +$ virtualenv --python pythonX.X --system-site-packages /tmp/env +$ /tmp/env/bin/pip install pkg1 pkg2 -r reqs.txt +$ /tmp/env/bin/python ... +$ rm -rf /tmp/env +@end example") + (license license:expat)))) + (define-public python-tlsh (package (name "python-tlsh") -- cgit v1.2.3 From b25a2c7c4057106efd9c02807fa7b4cdf2c5a574 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 15:38:27 -0400 Subject: gnu: python-importlib-metadata: Update to 4.11.3. * gnu/packages/python-xyz.scm (python-importlib-metadata): Update to 4.11.3. [phases]{build, install, check}: Override phases. [native-inputs]: Remove python-packaging. Add python-pypa-build and python-pytest. (python2-importlib-metadata): Adjust to keep unchanged. --- gnu/packages/python-xyz.scm | 68 +++++++++++++++++++++++++++++++++------------ 1 file changed, 50 insertions(+), 18 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index c622e1f93d..6f4ffa0c63 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8418,19 +8418,41 @@ for older versions of Python.") (define-public python-importlib-metadata (package (name "python-importlib-metadata") - (version "1.5.0") + (version "4.11.3") (source (origin (method url-fetch) (uri (pypi-uri "importlib_metadata" version)) (sha256 (base32 - "00ikdj4gjhankdljnz7g5ggak4k9lql2926x0x117ir9j2lv7x86")))) + "0f951zynlh39yicqnhrs3p1qa5p3g6ajjfcggf12y51ppxz5jk7a")))) (build-system python-build-system) - (propagated-inputs - (list python-zipp)) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + ;; XXX: PEP 517 manual build/install procedures copied from + ;; python-isort. + (replace 'build + (lambda _ + ;; ZIP does not support timestamps before 1980. + (setenv "SOURCE_DATE_EPOCH" "315532800") + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl)))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "tests"))))))) + (propagated-inputs (list python-zipp)) (native-inputs - (list python-setuptools-scm python-pyfakefs python-packaging)) + (list python-pypa-build + python-pyfakefs + python-pytest + python-setuptools-scm)) (home-page "https://importlib-metadata.readthedocs.io/") (synopsis "Read metadata from Python packages") (description @@ -8446,19 +8468,29 @@ need to use the older and less efficient @code{pkg_resources} package.") (define-public python2-importlib-metadata (let ((base (package-with-python2 (strip-python2-variant python-importlib-metadata)))) - (package/inherit - base - (name "python2-importlib-metadata") - (native-inputs - `(("python-setuptools-scm" ,python2-setuptools-scm) - ("python-pyfakefs" ,python2-pyfakefs-bootstrap) - ("python-packaging" ,python2-packaging-bootstrap))) - (propagated-inputs - `(("python-configparser" ,python2-configparser) - ("python-contextlib2" ,python2-contextlib2) - ("python-importlib-resources" ,python2-importlib-resources) - ("python-pathlib2" ,python2-pathlib2) - ,@(package-propagated-inputs base)))))) + (package/inherit base + (name "python2-importlib-metadata") + (version "1.5.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "importlib_metadata" version)) + (sha256 + (base32 + "00ikdj4gjhankdljnz7g5ggak4k9lql2926x0x117ir9j2lv7x86")))) + (arguments (substitute-keyword-arguments (package-arguments base) + ((#:phases phases) ;reset standard phases + #~%standard-phases))) + (native-inputs + `(("python-setuptools-scm" ,python2-setuptools-scm) + ("python-pyfakefs" ,python2-pyfakefs-bootstrap) + ("python-packaging" ,python2-packaging-bootstrap))) + (propagated-inputs + `(("python-configparser" ,python2-configparser) + ("python-contextlib2" ,python2-contextlib2) + ("python-importlib-resources" ,python2-importlib-resources) + ("python-pathlib2" ,python2-pathlib2) + ,@(package-propagated-inputs base)))))) ;; This package is used by python2-pytest, and thus must not depend on it. (define-public python2-importlib-metadata-bootstrap -- cgit v1.2.3 From c014b00b2800fe46b40692e2cc4aff8bfb9d46e1 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 15:57:27 -0400 Subject: gnu: python-pytest-black: Update to 0.3.12. * gnu/packages/python-xyz.scm (python-pytest-black): Update to 0.3.12. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 6f4ffa0c63..89ca75ddb3 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -12143,14 +12143,14 @@ asyncio.") (define-public python-pytest-black (package (name "python-pytest-black") - (version "0.3.8") + (version "0.3.12") (source (origin (method url-fetch) (uri (pypi-uri "pytest-black" version)) (sha256 (base32 - "04lppqydxm0f3f3x0l8hj7v0j6d8syj34jc37yzqwqcyqsnaga81")))) + "19bmbcnaq02md8nnj6pywri3vps8sxnhysbfy386qkbn9w09ncqx")))) (build-system python-build-system) (propagated-inputs (list python-pytest python-black python-toml)) -- cgit v1.2.3 From c29f9f72cdbdf3d3c937b4eb9f5b49cc9cd99594 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 16:53:20 -0400 Subject: gnu: python-mypy: Update to 0.942 and fix search path. * gnu/packages/patches/python-mypy-use-sys-path.patch: New patch. * gnu/local.mk: Register it. * gnu/packages/python-check.scm (python-mypy): Update to 0.942. [source]: Apply patch. --- gnu/local.mk | 1 + .../patches/python-mypy-use-sys-path.patch | 130 +++++++++++++++++++++ gnu/packages/python-check.scm | 15 +-- 3 files changed, 139 insertions(+), 7 deletions(-) create mode 100644 gnu/packages/patches/python-mypy-use-sys-path.patch diff --git a/gnu/local.mk b/gnu/local.mk index d7788796cc..9c5c6896ba 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1722,6 +1722,7 @@ dist_patch_DATA = \ %D%/packages/patches/python-waitress-fix-tests.patch \ %D%/packages/patches/python-werkzeug-tests.patch \ %D%/packages/patches/python-mypy-12332.patch \ + %D%/packages/patches/python-mypy-use-sys-path.patch \ %D%/packages/patches/qemu-build-info-manual.patch \ %D%/packages/patches/qemu-glibc-2.27.patch \ %D%/packages/patches/qemu-glibc-2.30.patch \ diff --git a/gnu/packages/patches/python-mypy-use-sys-path.patch b/gnu/packages/patches/python-mypy-use-sys-path.patch new file mode 100644 index 0000000000..1b12526456 --- /dev/null +++ b/gnu/packages/patches/python-mypy-use-sys-path.patch @@ -0,0 +1,130 @@ +This patch fixes the annotation files search of mypy on non-FHS distributions. + +Submitted upstream: https://github.com/python/mypy/pull/12530 + +diff --git a/mypy/main.py b/mypy/main.py +index 3d9836587..f9b0cbd39 100644 +--- a/mypy/main.py ++++ b/mypy/main.py +@@ -1033,10 +1033,10 @@ def process_options(args: List[str], + # Set target. + if special_opts.modules + special_opts.packages: + options.build_type = BuildType.MODULE +- egg_dirs, site_packages = get_site_packages_dirs(options.python_executable) ++ site_packages = get_site_packages_dirs(options.python_executable) + search_paths = SearchPaths((os.getcwd(),), + tuple(mypy_path() + options.mypy_path), +- tuple(egg_dirs + site_packages), ++ tuple(site_packages), + ()) + targets = [] + # TODO: use the same cache that the BuildManager will +diff --git a/mypy/modulefinder.py b/mypy/modulefinder.py +index 94d2dd34c..337a2d59b 100644 +--- a/mypy/modulefinder.py ++++ b/mypy/modulefinder.py +@@ -629,7 +629,7 @@ def get_prefixes(python_executable: Optional[str]) -> Tuple[str, str]: + + + @functools.lru_cache(maxsize=None) +-def get_site_packages_dirs(python_executable: Optional[str]) -> Tuple[List[str], List[str]]: ++def get_site_packages_dirs(python_executable: Optional[str]) -> List[str]: + """Find package directories for given python. + + This runs a subprocess call, which generates a list of the egg directories, and the site +@@ -648,51 +648,7 @@ def get_site_packages_dirs(python_executable: Optional[str]) -> Tuple[List[str], + site_packages = ast.literal_eval( + subprocess.check_output([python_executable, pyinfo.__file__, 'getsitepackages'], + stderr=subprocess.PIPE).decode()) +- return expand_site_packages(site_packages) +- +- +-def expand_site_packages(site_packages: List[str]) -> Tuple[List[str], List[str]]: +- """Expands .pth imports in site-packages directories""" +- egg_dirs: List[str] = [] +- for dir in site_packages: +- if not os.path.isdir(dir): +- continue +- pth_filenames = sorted(name for name in os.listdir(dir) if name.endswith(".pth")) +- for pth_filename in pth_filenames: +- egg_dirs.extend(_parse_pth_file(dir, pth_filename)) +- +- return egg_dirs, site_packages +- +- +-def _parse_pth_file(dir: str, pth_filename: str) -> Iterator[str]: +- """ +- Mimics a subset of .pth import hook from Lib/site.py +- See https://github.com/python/cpython/blob/3.5/Lib/site.py#L146-L185 +- """ +- +- pth_file = os.path.join(dir, pth_filename) +- try: +- f = open(pth_file, "r") +- except OSError: +- return +- with f: +- for line in f.readlines(): +- if line.startswith("#"): +- # Skip comment lines +- continue +- if line.startswith(("import ", "import\t")): +- # import statements in .pth files are not supported +- continue +- +- yield _make_abspath(line.rstrip(), dir) +- +- +-def _make_abspath(path: str, root: str) -> str: +- """Take a path and make it absolute relative to root if not already absolute.""" +- if os.path.isabs(path): +- return os.path.normpath(path) +- else: +- return os.path.join(root, os.path.normpath(path)) ++ return site_packages + + + def add_py2_mypypath_entries(mypypath: List[str]) -> List[str]: +@@ -781,7 +737,7 @@ def compute_search_paths(sources: List[BuildSource], + if options.python_version[0] == 2: + mypypath = add_py2_mypypath_entries(mypypath) + +- egg_dirs, site_packages = get_site_packages_dirs(options.python_executable) ++ site_packages = get_site_packages_dirs(options.python_executable) + base_prefix, prefix = get_prefixes(options.python_executable) + is_venv = base_prefix != prefix + for site_dir in site_packages: +@@ -801,7 +757,7 @@ def compute_search_paths(sources: List[BuildSource], + + return SearchPaths(python_path=tuple(reversed(python_path)), + mypy_path=tuple(mypypath), +- package_path=tuple(egg_dirs + site_packages), ++ package_path=tuple(site_packages), + typeshed_path=tuple(lib_path)) + + +diff --git a/mypy/pyinfo.py b/mypy/pyinfo.py +index ab2d3286b..9fb0501a1 100644 +--- a/mypy/pyinfo.py ++++ b/mypy/pyinfo.py +@@ -24,16 +24,11 @@ def getprefixes(): + + def getsitepackages(): + # type: () -> List[str] +- res = [] +- if hasattr(site, 'getsitepackages'): +- res.extend(site.getsitepackages()) + +- if hasattr(site, 'getusersitepackages') and site.ENABLE_USER_SITE: +- res.insert(0, site.getusersitepackages()) +- else: +- from distutils.sysconfig import get_python_lib +- res = [get_python_lib()] +- return res ++ # Simply return sys.path, which has already been expanded ++ # correctly via Python's site.py module, which takes care of .pth, ++ # sitecustomize.py files, etc. ++ return sys.path + + + if __name__ == '__main__': diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 8cf1526242..0a6bf423f0 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2019, 2021, 2022 Ricardo Wurmus ;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2019, 2020, 2021 Efraim Flashner -;;; Copyright © 2019, 2020, 2021 Maxim Cournoyer +;;; Copyright © 2019, 2020, 2021, 2022 Maxim Cournoyer ;;; Copyright © 2019, 2021 Hartmut Goebel ;;; Copyright © 2020 Julien Lepiller ;;; Copyright © 2020, 2022 Marius Bakke @@ -1673,7 +1673,7 @@ supported by the MyPy typechecker.") (define-public python-mypy (package (name "python-mypy") - (version "0.931") + (version "0.942") (source (origin ;; Because of https://github.com/python/mypy/issues/9584, the @@ -1690,9 +1690,10 @@ supported by the MyPy typechecker.") (file-name (git-file-name name version)) (sha256 (base32 - "1v83flrdxh8grcp40qw04q4hzjflih9xwib64078vsxv2w36f817")) + "0hxnrqhvskiclwfj2s4gyfclzjas1dvpfxhyng8v7mq38rqps1j5")) (patches - (search-patches "python-mypy-12332.patch")))) + (search-patches "python-mypy-12332.patch" + "python-mypy-use-sys-path.patch")))) (build-system python-build-system) (arguments `(#:phases @@ -1714,10 +1715,10 @@ supported by the MyPy typechecker.") (home-page "http://www.mypy-lang.org/") (synopsis "Static type checker for Python") (description "Mypy is an optional static type checker for Python that aims -to combine the benefits of dynamic (or 'duck') typing and static typing. Mypy combines +to combine the benefits of dynamic typing and static typing. Mypy combines the expressive power and convenience of Python with a powerful type system and -compile-time type checking. Mypy type checks standard Python programs; run them using -any Python VM with basically no runtime overhead.") +compile-time type checking. Mypy type checks standard Python programs; run +them using any Python VM with basically no runtime overhead.") ;; Most of the code is under MIT license; Some files are under Python Software ;; Foundation License version 2: stdlib-samples/*, mypyc/lib-rt/pythonsupport.h and ;; mypyc/lib-rt/getargs.c -- cgit v1.2.3 From bd152b5475fcf4deab65f9374f4a6ec782881c54 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 23:15:05 -0400 Subject: gnu: Add python-types-docutils. * gnu/packages/python-xyz.scm (python-types-docutils): New variable. --- gnu/packages/python-xyz.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 89ca75ddb3..0ae000d15b 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -29621,6 +29621,23 @@ multipurpose analysis in Python.") static types.") (license license:asl2.0))) +(define-public python-types-docutils + (package + (name "python-types-docutils") + (version "0.18.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "types-docutils" version)) + (sha256 + (base32 "14ypv0x6fk1pjw0bvvr1lkb2g6dvq2pwvbd5b5pzjl6182fhmaim")))) + (build-system python-build-system) + (home-page "https://github.com/python/typeshed") + (synopsis "Typing stubs for docutils") + (description "This package provides a collection of library stubs for +Python, with static types.") + (license license:asl2.0))) + (define-public python-psycopg2-binary (package (name "python-psycopg2-binary") -- cgit v1.2.3 From 529318bd22373557c95e74e1ea9c5365c403af19 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 23:28:44 -0400 Subject: gnu: python-pytest-checkdocs: Update to 2.7.1. * gnu/packages/python-check.scm (python-pytest-checkdocs): Update to 2.7.1. --- gnu/packages/python-check.scm | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 0a6bf423f0..f44ab0ca9a 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -921,18 +921,21 @@ doctest to render the object representations.") (define-public python-pytest-checkdocs (package (name "python-pytest-checkdocs") - (version "1.2.5") + (version "2.7.1") (source (origin (method url-fetch) (uri (pypi-uri "pytest-checkdocs" version)) (sha256 - (base32 "0m4kn7141i6k8qr8ak3lbmk9vim11xsrlnrggcfwczfrglc6jmia")))) + (base32 "1bn1wr3yz8avkwacffyh26za7mg20f9pajpakfk4cn7yvmgbhcrb")))) (build-system python-build-system) + (arguments (list #:tests? #f)) ;no tests in pypi archive (propagated-inputs - (list python-docutils python-importlib-metadata python-more-itertools)) - (native-inputs - (list python-setuptools-scm python-pytest)) + (list python-docutils + python-importlib-metadata + python-pep517 + python-pytest)) + (native-inputs (list python-setuptools-scm)) (home-page "https://github.com/jaraco/pytest-checkdocs") (synopsis "Check the README when running tests") (description -- cgit v1.2.3 From f761974b123d1129849dd2be11dab0893b4d5766 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 11:31:59 -0400 Subject: gnu: Add python-jaraco-classes. * gnu/packages/python-xyz.scm (python-jaraco-classes): New variable. --- gnu/packages/python-xyz.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 0ae000d15b..a9d77fe84c 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8557,6 +8557,44 @@ finding unresolved symbols in Python code and their corresponding imports.") "@code{inotify-simple} is a simple wrapper around inotify library.") (license license:bsd-3))) +(define-public python-jaraco-classes + (package + (name "python-jaraco-classes") + (version "3.2.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "jaraco.classes" version)) + (sha256 + (base32 "0d6g7qvfv1jlzbzh6asprqdblqd59grvlvr3nwbdqdqrmwlbfm7d")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Do not test the myproject.toml build as it tries to pull + ;; dependencies from the Internet. + (invoke "pytest" "-vv" "-k" "not project"))))))) + (native-inputs + (list python-pytest + python-pytest-black + python-pytest-checkdocs + python-pytest-cov + python-pytest-enabler-bootstrap ;OK since not propagated + python-pytest-flake8 + python-pytest-mypy + python-setuptools-scm + python-wheel)) + (propagated-inputs (list python-more-itertools)) + (home-page "https://github.com/jaraco/jaraco.classes") + (synopsis "Utility functions for Python class constructs") + (description "This Python library contains utility functions for Python +class constructs.") + (license license:expat))) + ;;; Variant used to break a cycle with python-pytest-enabler. (define-public python-jaraco-context-bootstrap (hidden-package -- cgit v1.2.3 From 26d92095d6870c0d10ef3a0f16256d7979a8dba5 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 00:12:13 -0400 Subject: gnu: Add python-jaraco-context. * gnu/packages/python-xyz.scm (python-jaraco-context): New variable. --- gnu/packages/python-xyz.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index a9d77fe84c..f586728ce9 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8616,6 +8616,35 @@ class constructs.") procedures.") (license license:expat)))) +(define-public python-jaraco-context + (package/inherit python-jaraco-context-bootstrap + (name "python-jaraco-context") + (arguments + (substitute-keyword-arguments + (package-arguments python-jaraco-context-bootstrap) + ((#:tests? _ #f) + #t) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Do not test the myproject.toml build as it tries to pull + ;; dependencies from the Internet. + (invoke "pytest" "-vv" "-k" "not project")))))))) + (native-inputs + (modify-inputs + (package-native-inputs python-jaraco-context-bootstrap) + (append python-pytest + python-pytest-black + python-pytest-checkdocs + python-pytest-cov + python-pytest-enabler-bootstrap ;OK since not propagated + python-pytest-flake8 + python-pytest-mypy))) + (properties (alist-delete 'hidden? (package-properties + python-jaraco-context-bootstrap))))) + ;;; Variant used to break a cycle with python-pytest-enabler. (define-public python-jaraco-functools-bootstrap (hidden-package -- cgit v1.2.3 From 59944e875af8be1f3501a5f9fd12c644cef4f9d5 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 00:16:46 -0400 Subject: gnu: Add python-jaraco-functools. * gnu/packages/python-xyz.scm (python-jaraco-functools): New variable. --- gnu/packages/python-xyz.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index f586728ce9..458d0d58af 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8667,6 +8667,36 @@ procedures.") module with a few extra procedures.") (license license:expat)))) +(define-public python-jaraco-functools + (package/inherit python-jaraco-functools-bootstrap + (name "python-jaraco-functools") + (arguments + (substitute-keyword-arguments + (package-arguments python-jaraco-functools-bootstrap) + ((#:tests? _ #f) + #t) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Do not test the myproject.toml build as it tries to pull + ;; dependencies from the Internet. + (invoke "pytest" "-vv" "-k" "not project")))))))) + (native-inputs + (modify-inputs + (package-native-inputs python-jaraco-functools-bootstrap) + (append python-jaraco-classes + python-pytest + python-pytest-black + python-pytest-checkdocs + python-pytest-cov + python-pytest-enabler-bootstrap ;OK since not propagated + python-pytest-flake8 + python-pytest-mypy))) + (properties (alist-delete 'hidden? (package-properties + python-jaraco-functools-bootstrap))))) + (define-public python-jaraco-packaging (package (name "python-jaraco-packaging") -- cgit v1.2.3 From 9010b1adfd0c876e9a5971a373ae620378aca686 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 00:28:29 -0400 Subject: gnu: Add python-pytest-enabler. * gnu/packages/check.scm (python-pytest-enabler): New variable. --- gnu/packages/check.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 135fd671a2..8ed53f7e27 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -2225,6 +2225,36 @@ failures.") (description "Enable installed pytest plugins") (license license:expat)))) +(define-public python-pytest-enabler + (package/inherit python-pytest-enabler-bootstrap + (arguments + (substitute-keyword-arguments + (package-arguments python-pytest-enabler-bootstrap) + ((#:tests? _ #f) + #t) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "-m" "pytest" "-vv" "tests")))))))) + (propagated-inputs + (modify-inputs (package-propagated-inputs python-pytest-enabler-bootstrap) + (replace "python-jaraco-context-bootstrap" python-jaraco-context) + (replace "python-jaraco-functools-bootstrap" python-jaraco-functools))) + (native-inputs + (modify-inputs (package-native-inputs python-pytest-enabler-bootstrap) + (append python-pytest + python-pytest-black + python-pytest-checkdocs + python-pytest-cov + python-pytest-flake8 + python-pytest-mypy + python-types-toml))) + (properties (alist-delete 'hidden? + (package-properties + python-pytest-enabler-bootstrap))))) + (define-public python-pytest-freezegun (package (name "python-pytest-freezegun") -- cgit v1.2.3 From 831bf98f6ceed5b1ac400c90f74c3a49587d7d0b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 00:42:34 -0400 Subject: gnu: Add python-path. * gnu/packages/python-xyz.scm (python-path): New variable. --- gnu/packages/python-xyz.scm | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 458d0d58af..88435942ce 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -12739,6 +12739,42 @@ objects as first-class entities, allowing common operations on files to be invoked on those path objects directly.") (license license:expat)))) +(define-public python-path + (package/inherit python-path-bootstrap + (name "python-path") + (arguments + (substitute-keyword-arguments + (package-arguments python-path-bootstrap) + ((#:tests? _ #f) + #t) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Do not test the myproject.toml build as it tries to pull + ;; dependencies from the Internet. + (invoke "pytest" "-vv" "-k" + (string-append + "not project " + ;; This tests assumes a root user exists. + "and not test_get_owner"))))))))) + (native-inputs + (modify-inputs (package-native-inputs python-path-bootstrap) + (append python-appdirs + python-packaging + python-pygments + python-pytest + python-pytest-black + python-pytest-checkdocs + python-pytest-cov + python-pytest-enabler + python-pytest-flake8 + python-pytest-mypy))) + (properties (alist-delete 'hidden? + (package-properties + python-path-bootstrap))))) + (define-public python-pretend (package (name "python-pretend") -- cgit v1.2.3 From a293faef3fbd6a3f8b128ee35a3e56a6cc458734 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 01:09:32 -0400 Subject: gnu: Add python-pip-run. * gnu/packages/python-xyz.scm (python-pip-run): New variable. --- gnu/packages/python-xyz.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 88435942ce..8e6dee235e 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -12866,6 +12866,44 @@ $ rm -rf /tmp/env @end example") (license license:expat)))) +(define-public python-pip-run + (package/inherit python-pip-run-bootstrap + (name "python-pip-run") + (arguments + (substitute-keyword-arguments (package-arguments python-pip-run-bootstrap) + ((#:tests? _ #f) + #t) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-k" + (string-append + ;; Do not test the myproject.toml build as it tries + ;; to pull dependencies from the internet. + "not project " + ;; These tests attempt to install dependencies from + ;; the network and fail. + "and not test_pkg_imported " + "and not test_pkg_loaded_from_alternate_index "))))))))) + (propagated-inputs + (modify-inputs (package-propagated-inputs python-pip-run-bootstrap) + (replace "python-path-bootstrap" python-path))) + (native-inputs + (modify-inputs (package-native-inputs python-pip-run-bootstrap) + (append python-nbformat + python-pygments + python-pytest + python-pytest-black + python-pytest-checkdocs + python-pytest-cov + python-pytest-enabler + python-pytest-flake8 + python-pytest-mypy))) + (properties (alist-delete 'hidden? (package-properties + python-pip-run-bootstrap))))) + (define-public python-tlsh (package (name "python-tlsh") -- cgit v1.2.3 From 0be033d3c569450b347b1fe69ff6a52395afc971 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 15:02:08 -0400 Subject: gnu: Add python-tempora. * gnu/packages/python-xyz.scm (python-tempora): New variable. --- gnu/packages/python-xyz.scm | 54 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 8e6dee235e..1ebdd81f8e 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -21508,6 +21508,60 @@ particularly convenient for use in tests.") (define-public python2-tempdir (package-with-python2 python-tempdir)) +(define-public python-tempora + (package + (name "python-tempora") + (version "5.0.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "tempora" version)) + (sha256 + (base32 "09wirlk5vmxlhl9rnxp7g5qz2nsd6b0gnzk5fczbz0s8lsbz386b")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + ;; XXX: PEP 517 manual build copied from python-isort. + (replace 'build + (lambda _ + (setenv "SOURCE_DATE_EPOCH" "315532800") + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl)))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Do not test the myproject.toml build as it tries to pull + ;; dependencies from the Internet. + (invoke "pytest" "-k" "not project"))))))) + (native-inputs + (list python-pypa-build + python-freezegun + python-pytest + python-pytest-black + python-pytest-checkdocs + python-pytest-cov + python-pytest-enabler + python-pytest-flake8 + python-pytest-freezegun + python-pytest-mypy + python-setuptools-scm + python-types-freezegun + python-types-pytz)) + (propagated-inputs (list python-jaraco-functools python-pytz)) + (home-page "https://github.com/jaraco/tempora") + (synopsis "Python date and time objects and routines") + (description "The @code{tempora} Python library contains miscellaneous +date and time related utilities and constants, routines for measuring, +profiling, and getting datetime-aware @acronym{UTC, Coordinated Universal +Time} values as well as an event scheduler.") + (license license:expat))) + (define-public python-activepapers (package (name "python-activepapers") -- cgit v1.2.3 From 9175b8d6ba7c5939bfee3b76904ee8627f38f949 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 5 Apr 2022 15:04:55 -0400 Subject: gnu: Add python-pytest-perf. * gnu/packages/check.scm (python-pytest-perf): New variable. --- gnu/packages/check.scm | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 8ed53f7e27..e3523d77dc 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -2344,6 +2344,64 @@ a Pytest test execution.") (define-public python2-pytest-pep8 (package-with-python2 python-pytest-pep8)) +(define-public python-pytest-perf + (package + (name "python-pytest-perf") + (version "0.12.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/jaraco/pytest-perf") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "05mgknvrmyz1kmkgw8jzvisavc68wz1g2wxv69i6xvzgqxf17m9f")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-k" + (string-append + ;; Do not test the myproject.toml build as it tries to pull + ;; dependencies from the internet. + "not project " + ;; The benchmark test attempts to install the + ;; package, failing to pull its dependencies from the + ;; network. + "and not BenchmarkRunner " + ;; The upstream_url test requires networking. + "and not upstream_url")))))))) + (native-inputs + (list python-pytest + python-pytest-black + python-pytest-checkdocs + python-pytest-cov + python-pytest-enabler + python-pytest-flake8 + python-pytest-mypy)) + (propagated-inputs + (list python-jaraco-context + python-jaraco-functools + python-more-itertools + python-packaging + python-pip-run + python-tempora)) + (home-page "https://github.com/jaraco/pytest-perf") + (synopsis "Pytest plugin for performance testing") + (description "@code{pytest-perf} makes it easy to compare works by +creating two installs, the control and the experiment, and measuring the +performance of some Python code against each. Under the hood, it uses the +@command{pip-run} command to install from the upstream main +branch (e.g. https://github.com/jaraco/pytest-perf) for the control and from +@file{.} for the experiment. It then runs each of the experiments against +each of the environments.") + (license license:expat))) + (define-public python-pytest-flakes (package (name "python-pytest-flakes") -- cgit v1.2.3 From b391578a2447e677528d6684f424ab798b885dc0 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 08:46:56 -0400 Subject: gnu: python-factory-boy: Update to 3.2.1. * gnu/packages/python-xyz.scm (python-factory-boy): Update to 3.2.1. [propagated-inputs]: Use new style. [description]: Fix indentation and remove blank lines. --- gnu/packages/python-xyz.scm | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 1ebdd81f8e..176fa7ec28 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -20004,30 +20004,26 @@ point is the point of maximum curvature.") (define-public python-factory-boy (package (name "python-factory-boy") - (version "2.8.1") + (version "3.2.1") (source (origin (method url-fetch) (uri (pypi-uri "factory_boy" version)) (sha256 - (base32 "1fvin6san5xsjh2c4y18caj2lnmwxlylyqm8mh1yc6rp38wlwr56")))) + (base32 "0pm5lbvnwm0kg5i6z611rg907yw1gy551f2advmpaz041ixjg3d9")))) (build-system python-build-system) (arguments ;; Tests are not included in the tarball. `(#:tests? #f)) - (propagated-inputs - `(("faker" ,python-faker))) + (propagated-inputs (list python-faker)) (home-page "https://github.com/benhoyt/scandir") (synopsis "Versatile test fixtures replacement") - (description - "Factory_boy is a fixtures replacement based on thoughtbot’s factory_girl. - - As a fixtures replacement tool, it aims to replace static, hard to maintain - fixtures with easy-to-use factories for complex object. - - Instead of building an exhaustive test setup with every possible combination - of corner cases, factory_boy allows you to use objects customized for the - current test, while only declaring the test-specific fields") + (description "Factory_boy is a fixtures replacement based on thoughtbot’s +factory_girl. As a fixtures replacement tool, it aims to replace static, hard +to maintain fixtures with easy-to-use factories for complex object. Instead +of building an exhaustive test setup with every possible combination of corner +cases, factory_boy allows you to use objects customized for the current test, +while only declaring the test-specific fields.") (license license:expat))) (define-public python-translate-toolkit -- cgit v1.2.3 From a749fbea4e5f0f3faaff60b64625921225df2dbb Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 08:52:08 -0400 Subject: gnu: python-faker: Update to 13.3.4 and honor TESTS?. * gnu/packages/python-xyz.scm (python-faker): Update to 13.3.4. [phases]{check}: Honor TESTS?. [native-inputs]: Replace python-pytest-6 by python-pytest. Remove comment. [propagated-inputs]: Remove python-text-unidecode. --- gnu/packages/python-xyz.scm | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 176fa7ec28..43009da908 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -17506,28 +17506,28 @@ parsing UK postcodes.") (define-public python-faker (package (name "python-faker") - (version "9.3.1") + (version "13.3.4") (source (origin (method url-fetch) (uri (pypi-uri "Faker" version)) (sha256 (base32 - "0lpfdc4ndvk7chgqrfd2b1my4n54pccq9b645vp9cp5s5ypyknfd")))) + "04855dqvvi2mr739l5x3qf82rxq0a7spc8gl76k8xixmbw36328q")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (replace 'check - (lambda _ (invoke "python" "-m" "pytest" "-v")))))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "-m" "pytest" "-v"))))))) (native-inputs - (list ;; For testing - python-freezegun - python-pytest-6 + (list python-freezegun + python-pytest python-random2 python-ukpostcodeparser python-validators)) - (propagated-inputs - (list python-dateutil python-text-unidecode)) + (propagated-inputs (list python-dateutil)) (home-page "https://github.com/joke2k/faker") (synopsis "Python package that generates fake data") (description -- cgit v1.2.3 From 1702331d016eba117124299b68ab77cc1ed22270 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 09:16:07 -0400 Subject: gnu: Add python-pytest-randomly. * gnu/packages/check.scm (python-pytest-randomly): New variable. --- gnu/packages/check.scm | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index e3523d77dc..c67a6f2675 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -1242,6 +1242,47 @@ tests. Tests can be rerun in a specific order by passing a seed value reported in a previous test run.") (license license:expat))) +(define-public python-pytest-randomly + (package + (name "python-pytest-randomly") + (version "3.11.0") + (source (origin + (method git-fetch) ;no tests in pypi archive + (uri (git-reference + (url "https://github.com/pytest-dev/pytest-randomly") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1sjgq49g8f8973vhmzrim79b6wz29a765n99azjk1maimqh7mmik")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; The tests validating ordering fail, as well as as two + ;; others, for unknown reasons (see: + ;; https://github.com/pytest-dev/pytest-randomly/issues/454). + (invoke "pytest" "-vv" "-k" + (string-append + "not reordered " + "and not test_it_runs_before_stepwise " + "and not test_entrypoint_injection")))))))) + (native-inputs (list python-coverage + python-factory-boy + python-faker + python-numpy + python-pytest-xdist)) + (propagated-inputs (list python-importlib-metadata python-pytest)) + (home-page "https://github.com/pytest-dev/pytest-randomly") + (synopsis "Pytest plugin to randomly order tests") + (description "This is a Pytest plugin to randomly order tests and control +Python's @code{random.seed}.") + (license license:expat))) + (define-public python-pytest-runner (package (name "python-pytest-runner") -- cgit v1.2.3 From f11eebdd9ecfbf95ea1cb38266f66a2fb4c233ba Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 12:01:53 -0400 Subject: gnu: Add psautohint-font-data. * gnu/packages/fontutils.scm (psautohint-font-data): New variable. --- gnu/packages/fontutils.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index a2e71f1ad0..9cb9caf159 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -72,6 +72,7 @@ #:use-module (guix download) #:use-module (guix svn-download) #:use-module (guix git-download) + #:use-module (guix build-system copy) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) #:use-module (guix build-system python) @@ -314,6 +315,33 @@ was developed for interpolating data related to fonts, but if can handle any arithmetic object.") (license license:bsd-3))) +(define-public psautohint-font-data + ;; There is no release tag, so use the latest commit. + (let ((revision "0") + (commit "1e4c5061d328105c4dcfcb6fdbc27ec49b3e9d23")) + (hidden-package + (package + (name "psautohint-font-data") + (version (git-version "0.0.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/adobe-type-tools/psautohint-testdata") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0p7g8mnndzp8zpbj9h6lkvfdpvd74fy10q8wmkagbg2ahbdi1zva")))) + (build-system copy-build-system) + (home-page "https://github.com/adobe-type-tools/psautohint-testdata") + (synopsis "Test font data psautohint") + (description "This package contains the font data used by the test +suite of the @code{psautohint} package.") + ;; The bundle contains font data from the Cantarell, Libertinus, Source + ;; Code Pro, Source Serif Pro, all available under the same license. + (license license:silofl1.1))))) + (define-public python-ufoprocessor (package (name "python-ufoprocessor") -- cgit v1.2.3 From eba493b369e3353d757a82e116682fdd5ea90b47 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 12:02:01 -0400 Subject: gnu: Add psautohint. * gnu/packages/fontutils.scm (psautohint): New variable. --- gnu/packages/fontutils.scm | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 9cb9caf159..e128ed1003 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -342,6 +342,49 @@ suite of the @code{psautohint} package.") ;; Code Pro, Source Serif Pro, all available under the same license. (license license:silofl1.1))))) +(define-public psautohint + (package + (name "psautohint") + (version "2.4.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "psautohint" version)) + (sha256 + (base32 "0zzz7hy1kkkjfrrm9ly2di3xv2x1ywdqhbyqy21k670jysldw3nm")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'copy-font-data + ;; The data is copied as it needs to be writable for the tests. + (lambda _ + (copy-recursively + #$(this-package-native-input "psautohint-font-data") + "tests/integration/data") + (for-each make-file-writable + (find-files "tests/integration/data")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (propagated-inputs (list python-fonttools)) + (native-inputs + (list psautohint-font-data + python-fs + python-pytest + python-pytest-cov + python-pytest-randomly + python-pytest-xdist + python-setuptools-scm + python-wheel)) + (home-page "https://github.com/adobe-type-tools/psautohint") + (synopsis "Adobe's PostScript autohinter") + (description "This package provides the @command{autohinter} command that +can be used to hint PostScript fonts. A Python wrapper is also included.") + (license license:asl2.0))) + (define-public python-ufoprocessor (package (name "python-ufoprocessor") -- cgit v1.2.3 From e91180f450a3ce0c99b778da0d43d11729adfa6f Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 13:44:02 -0400 Subject: gnu: Add python-ordered-set. * gnu/packages/python-xyz.scm (python-ordered-set): New variable. --- gnu/packages/python-xyz.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 43009da908..9591ced6da 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -29425,6 +29425,32 @@ simple mock/record and a complete capture/replay framework.") interfaces.") (license license:bsd-3))) +(define-public python-ordered-set + (package + (name "python-ordered-set") + (version "4.1.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "ordered-set" version)) + (sha256 + (base32 "1a34fg3r3480nfm6652kyqql3lwixf8jirzdja9camvnr128wjk9")))) + (build-system python-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-cython python-pytest)) + (home-page "https://github.com/simonpercivall/orderedset") + (synopsis "Ordered Set implementation in Cython") + (description "This library provides an @code{OrderedSet} data type that +works like a regular set, but remembers insertion order. It supports the full +Python @code{set} interface.") + (license license:asl2.0))) + (define-public python-orgparse (package (name "python-orgparse") -- cgit v1.2.3 From 06aa3cad61291d4a19cda8833074d99ef5282fff Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 14:14:09 -0400 Subject: gnu: Add python-xdoctest. * gnu/packages/python-xyz.scm (python-xdoctest): New variable. --- gnu/packages/python-xyz.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 9591ced6da..5048b5c04b 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -15204,6 +15204,36 @@ python-xdo for newer bindings.)") (define-public python2-xdo (package-with-python2 python-xdo)) +(define-public python-xdoctest + (package + (name "python-xdoctest") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "xdoctest" version)) + (sha256 + (base32 "0bgbmb9nqv95f9gfxqifqff1qaz5fnanjqy4hv7ygrjp2kksgfvy")))) + (build-system python-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; A writable HOME is needed by the + ;; 'import_module_from_path' test. + (setenv "HOME" "/tmp") + (invoke "pytest" "-vv"))))))) + (propagated-inputs (list python-six)) + (native-inputs (list python-pytest which)) + (home-page "https://github.com/Erotemic/xdoctest") + (synopsis "Rewrite of the Python builtin doctest module") + (description "This package provides a rewrite of the builtin doctest +module which leverages the Python @acronym{AST, Abstract Syntax Tree} instead +of @acronym{REGEXPs, regular expressions}.") + (license license:asl2.0))) + (define-public python-mako (package (name "python-mako") -- cgit v1.2.3 From 5c41c122a5da0855f1a369e8670b26ab28cf86b4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 14:31:46 -0400 Subject: gnu: Add python-ubelt. * gnu/packages/python-xyz.scm (python-ubelt): New variable. --- gnu/packages/python-xyz.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 5048b5c04b..612e69c7bc 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -364,6 +364,50 @@ library’s logging module. It was designed with both complex and simple applications in mind and the idea to make logging fun.") (license license:bsd-3))) +(define-public python-ubelt + (package + (name "python-ubelt") + (version "1.0.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/Erotemic/ubelt") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0hac9nqqvqfbca2s4g0mp1fnj0ah60bg9fb8234ibna3jww8qs33")))) + (build-system python-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "HOME" "/tmp") ;else the test suite hangs + (invoke "pytest" "-vv" "-k" + (string-append + ;; The builder user home doesn't match HOME, + ;; which causes this test to fail. + "not userhome " + ;; This one pointlessly tries + ;; locating various binaries on + ;; the path. + "and not find_exe")))))))) + (propagated-inputs (list python-ordered-set)) + (native-inputs + (list python-pytest + python-requests + python-xdoctest)) + (home-page "https://github.com/Erotemic/ubelt") + (synopsis "Python library for hashing, caching, timing and more") + (description "Ubelt is a small library of simple functions that extend the +Python standard library. It includes an @acronym{API, Application Programming +Interface} to simplify common problems such as caching, timing, computing +progress, among other things.") + (license license:asl2.0))) + (define-public python-ueberzug (package (name "python-ueberzug") -- cgit v1.2.3 From 520cdf80581669646ff61e9f18f3b27045556e76 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 14:46:32 -0400 Subject: gnu: python-setuptools: Update to 62.0.0. * gnu/packages/python-xyz.scm (python-setuptools): Update to 62.0.0. [source]: Simplify snippet and strip trailing #t. [arguments]: Re-indent. [synopsis]: Likewise. [description]: Use @itemize. [license]: Strip leading spaces from in-line comments. --- gnu/packages/python-xyz.scm | 57 +++++++++++++++++++++------------------------ 1 file changed, 27 insertions(+), 30 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 612e69c7bc..b7f7e91e3f 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -1842,44 +1842,41 @@ other machines, such as over the network.") (define-public python-setuptools (package (name "python-setuptools") - (version "52.0.0") + (version "62.0.0") (source (origin - (method url-fetch) - (uri (pypi-uri "setuptools" version)) - (sha256 - (base32 - "15ibjdjhkwgj6qbmpsxikkqdfsb1550z46fly7dm15ah4bk1wfpv")) - (modules '((guix build utils))) - (snippet - '(begin - ;; Remove included binaries which are used to build self-extracting - ;; installers for Windows. - ;; TODO: Find some way to build them ourself so we can include them. - (for-each delete-file (find-files "setuptools" "^(cli|gui).*\\.exe$")) - #t)))) + (method url-fetch) + (uri (pypi-uri "setuptools" version)) + (sha256 + (base32 + "0sm8n6y6q640cpac9wjyggidbgi4n9la7vs7pwriyvhvgzccp6br")) + (modules '((guix build utils))) + (snippet + ;; Remove included binaries which are used to build self-extracting + ;; installers for Windows. + ;; TODO: Find some way to build them ourself so we can include them. + '(for-each delete-file (find-files "setuptools" + "^(cli|gui).*\\.exe$"))))) (build-system python-build-system) ;; FIXME: Tests require pytest, which itself relies on setuptools. ;; One could bootstrap with an internal untested setuptools. - (arguments - `(#:tests? #f)) + (arguments (list #:tests? #f)) (home-page "https://pypi.org/project/setuptools/") - (synopsis - "Library designed to facilitate packaging Python projects") - (description - "Setuptools is a fully-featured, stable library designed to facilitate -packaging Python projects, where packaging includes: -Python package and module definitions, -distribution package metadata, -test hooks, -project installation, -platform-specific details, -Python 3 support.") + (synopsis "Library designed to facilitate packaging Python projects") + (description "Setuptools is a fully-featured, stable library designed to +facilitate packaging Python projects, where packaging includes: +@itemize +@item Python package and module definitions +@item distribution package metadata +@item test hooks +@item project installation +@item platform-specific details. +@end itemize") ;; TODO: setuptools now bundles the following libraries: ;; packaging, pyparsing, six and appdirs. How to unbundle? - (license (list license:psfl ; setuptools itself - license:expat ; six, appdirs, pyparsing - license:asl2.0 ; packaging is dual ASL2/BSD-2 + (license (list license:psfl ;setuptools itself + license:expat ;six, appdirs, pyparsing + license:asl2.0 ;packaging is dual ASL2/BSD-2 license:bsd-2)) (properties `((python2-variant . ,(delay python2-setuptools)))))) -- cgit v1.2.3 From c6c2e3710b91c570fb244e4a5fd3a476ebef33d1 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 15:13:06 -0400 Subject: gnu: python-pathpy: Deprecate by python-path. * gnu/packages/python-xyz.scm (python-pathpy): Mark as deprecated by python-path. --- gnu/packages/python-xyz.scm | 54 +++------------------------------------------ 1 file changed, 3 insertions(+), 51 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index b7f7e91e3f..7913e1eedd 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8766,57 +8766,6 @@ module with a few extra procedures.") releases.") (license license:expat))) -(define-public python-pathpy - (package - (name "python-pathpy") - (version "11.5.1") - (source - (origin - (method url-fetch) - (uri (pypi-uri "path.py" version)) - (sha256 - (base32 "0ir9j1haq2jbi7aip6k2fa9l7q1l03k4hp1awxhjhcwzsnwp3ll8")))) - (outputs '("out" "doc")) - (build-system python-build-system) - (propagated-inputs - (list python-appdirs python-importlib-metadata)) - (native-inputs - (list python-setuptools-scm - python-sphinx - python-rst.linker - python-pytest - python-pytest-runner - python-jaraco-packaging)) - (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'build 'build-doc - (lambda _ - (setenv "LANG" "en_US.UTF-8") - (invoke "python" "setup.py" "build_sphinx"))) - (add-after 'install 'install-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((data (string-append (assoc-ref outputs "doc") "/share")) - (doc (string-append data "/doc/" ,name "-" ,version)) - (html (string-append doc "/html"))) - (mkdir-p html) - (for-each (lambda (file) - (copy-file file (string-append doc "/" file))) - '("README.rst" "CHANGES.rst")) - (copy-recursively "build/sphinx/html" html) - #t))) - (replace 'check - (lambda _ - ;; The import time test aborts if an import takes longer than - ;; 100ms. It may very well take a little longer than that. - (invoke "pytest" "-v" "-k" "not test_import_time")))))) - (home-page "https://github.com/jaraco/path.py") - (synopsis "Python module wrapper for built-in os.path") - (description - "@code{path.py} implements path objects as first-class entities, allowing -common operations on files to be invoked on those path objects directly.") - (license license:expat))) - (define-public python-simplegeneric (package (name "python-simplegeneric") @@ -12816,6 +12765,9 @@ invoked on those path objects directly.") (package-properties python-path-bootstrap))))) +(define-public python-pathpy + (deprecated-package "python-pathpy" python-path)) + (define-public python-pretend (package (name "python-pretend") -- cgit v1.2.3 From f2be0c5b2b19a4c867906f4ae1b4393d92cc4b08 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 15:23:25 -0400 Subject: gnu: python-pytest-shutil: Adjust to use python-path. * gnu/packages/python-check.scm (python-pytest-shutil) [phases]{use-path-instead-of-path.py}: New phase. [propagated-inputs]: Replace python-path.py with python-path. --- gnu/packages/python-check.scm | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index f44ab0ca9a..5469200afc 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -1080,6 +1080,12 @@ isort.") (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'use-path-instead-of-path.py + ;; path.py is obsolete. + (lambda _ + (substitute* "setup.py" + (("'path.py'") + "'path'")))) (add-after 'unpack 'patch-tests (lambda _ (mkdir "/tmp/bin") @@ -1087,11 +1093,9 @@ isort.") (("dirname = '/bin'") "dirname = '/tmp/bin'") (("bindir = os.path.realpath\\('/bin'\\)") - "bindir = os.path.realpath('/tmp/bin')")) - #t))))) + "bindir = os.path.realpath('/tmp/bin')"))))))) (propagated-inputs - (list python-contextlib2 python-execnet python-pathpy - python-termcolor)) + (list python-contextlib2 python-execnet python-path python-termcolor)) (native-inputs (list python-mock python-pytest python-setuptools-git)) (home-page "https://github.com/manahl/pytest-plugins") -- cgit v1.2.3 From 0f8bb67dbb6d21dc56d8237d35fefeee8a3e6dc4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 15:44:12 -0400 Subject: gnu: python-pytest-cov: Update to 3.0.0. This restores the package compatibility with python-pytest-xdist. * gnu/packages/check.scm (python-pytest-cov): Update to 3.0.0. (python2-pytest-cov): Delete package. --- gnu/packages/check.scm | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index c67a6f2675..b7a5a9bd46 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -1150,13 +1150,13 @@ following improvements: (define-public python-pytest-cov (package (name "python-pytest-cov") - (version "2.8.1") + (version "3.0.0") (source (origin (method url-fetch) (uri (pypi-uri "pytest-cov" version)) (sha256 - (base32 "0avzlk9p4nc44k7lpx9109dybq71xqnggxb9f4hp0l64pbc44ryc")))) + (base32 "0w6lfv8gc1lxmnvsz7mq5z9shxac5zz6s9mwrai108kxc6qzbw77")))) (build-system python-build-system) (arguments `(#:phases @@ -1178,9 +1178,6 @@ distributed testing in both @code{load} and @code{each} modes. It also supports coverage of subprocesses.") (license license:expat))) -(define-public python2-pytest-cov - (package-with-python2 python-pytest-cov)) - (define-public python-pytest-httpserver (package (name "python-pytest-httpserver") -- cgit v1.2.3 From 5324bff060654c7185c0be1f2ea9e2e2a3b69bd0 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 17:22:44 -0400 Subject: gnu: Add python-scikit-build. * gnu/packages/python-xyz.scm (python-scikit-build): New variable. --- gnu/packages/python-xyz.scm | 89 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 7913e1eedd..271f948bc5 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -189,6 +189,7 @@ #:use-module (gnu packages multiprecision) #:use-module (gnu packages networking) #:use-module (gnu packages ncurses) + #:use-module (gnu packages ninja) #:use-module (gnu packages openstack) #:use-module (gnu packages pcre) #:use-module (gnu packages pdf) @@ -28325,6 +28326,94 @@ and frame grabber interface.") ;; Yet another variant of the X/MIT license. "https://github.com/python-pillow/Sane/blob/master/COPYING")))) +(define-public python-scikit-build + (package + (name "python-scikit-build") + (version "0.14.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "scikit-build" version)) + (sha256 + (base32 "1wx1m9vnxnnz59lyaisgyxldp313kciyd4af8lf112vb8vbjy9yk")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-cmake-executable + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "skbuild/constants.py" + (("^(CMAKE_DEFAULT_EXECUTABLE = ).*" _ head) + (format #f "~a ~s~%" head + (search-input-file inputs "bin/cmake")))))) + ;; XXX: PEP 517 manual build copied from python-isort. + (replace 'build + (lambda _ + (setenv "SOURCE_DATE_EPOCH" "315532800") + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; These tests attempt to pull dependencies from the Internet. + (delete-file "tests/test_distribution.py") + (delete-file "tests/test_pep518.py") + (invoke "pytest" "-vv" + "-n" (number->string (parallel-job-count)) + "-k" (string-append + ;; These tests attempt to write to read-only + ;; Python install directory. + "not test_install_command " + "and not test_test_command " + "and not test_hello_develop " + ;; These sdist-related tests fail for unknown + ;; reasons (see: + ;; https://github.com/scikit-build/scikit-build/issues/689). + "and not test_hello_sdist_with_base " + "and not test_manifest_in_sdist " + "and not test_hello_sdist " + "and not test_sdist_with_symlinks " + ;; These are not parallel safe and fail + ;; nondeterministically (see: + ;; https://github.com/scikit-build/scikit-build/issues/711). + "and not test_generator_cleanup" + "and not test_generator_selection"))))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (native-inputs + (list cmake-minimal + gfortran + git-minimal + ninja + python-coverage + python-cython + python-mock + python-packaging + python-path + python-pypa-build + python-pytest + python-pytest-cov + python-pytest-mock + python-pytest-virtualenv + python-pytest-xdist + python-requests + python-setuptools-scm + python-wheel)) + (propagated-inputs + (list python-distro python-packaging python-wheel)) + (home-page "https://github.com/scikit-build/scikit-build") + (synopsis "Build system generator for Python C/C++/Fortran/Cython extensions") + (description "Scikit-build is an improved build system generator for +CPython C/C++/Fortran/Cython extensions. It has support for additional +compilers, build systems, cross compilation, and locating dependencies and +determining their build requirements. The scikit-build package is +fundamentally just glue between the @code{setuptools} Python module and +CMake.") + (license license:expat))) + (define-public python-screenkey (package (name "python-screenkey") -- cgit v1.2.3 From 3f66c30dbdee18bf5922bdc6c6d86697d1732314 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 20:46:15 -0400 Subject: gnu: python-jupyter-packaging: Update to 0.12.0, run test suite. * gnu/packages/jupyter.scm (python-jupyter-packaging): Update to 0.12.0. [arguments]: New field. --- gnu/packages/jupyter.scm | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index bea53ba912..d517712bcb 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -21,6 +21,7 @@ (define-module (gnu packages jupyter) #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) @@ -215,15 +216,29 @@ the JupyterLab CSS variables.") (define-public python-jupyter-packaging (package (name "python-jupyter-packaging") - (version "0.9.1") + (version "0.12.0") (source (origin (method url-fetch) (uri (pypi-uri "jupyter_packaging" version)) (sha256 (base32 - "0r015c0m713d19asmpimsw6bk2sqv2lpd2nccgjzjdj5h1crg0bg")))) + "1b7ssc627vgrdl21c09w9sxk5fc1ps3g7f70laxag4yw1bb5ax5j")))) (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Disable isolation so that the package environment can be + ;; setup without connectivity. + (setenv "SOURCE_DATE_EPOCH" "315532800") + (substitute* "tests/test_build_api.py" + (("\"-m\", \"build\"" all) + (string-append all ", \"--no-isolation\""))) + (invoke "python" "-m" "pytest" "-vv"))))))) (propagated-inputs (list python-deprecation python-packaging python-setuptools python-tomlkit python-wheel)) -- cgit v1.2.3 From 5a3634f46127482c18bdeb2cc332af045c852e50 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 20:53:31 -0400 Subject: gnu: python-scipy: Move input fields below arguments field. * gnu/packages/python-science.scm (python-scipy): Move inputs fields below the arguments field. [phases]: Use gexp. {configure-openblas}: Use this-package-input. {check}: Remove extraneous 'add-installed-pythonpath' call. {install-doc}: Adjust accordingly. --- gnu/packages/python-science.scm | 155 ++++++++++++++++++++-------------------- 1 file changed, 77 insertions(+), 78 deletions(-) diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index 2eb3b344c7..d192543f5c 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2016, 2022 Efraim Flashner ;;; Copyright © 2016-2020, 2022 Marius Bakke ;;; Copyright © 2019 Tobias Geerinckx-Rice -;;; Copyright © 2019, 2021 Maxim Cournoyer +;;; Copyright © 2019, 2021, 2022 Maxim Cournoyer ;;; Copyright © 2019 Giacomo Leidi ;;; Copyright © 2020 Pierre Langlois ;;; Copyright © 2020, 2021, 2022 Vinicius Monego @@ -80,49 +80,36 @@ (uri (pypi-uri "scipy" version)) (sha256 (base32 "1gxsnw6viz2j3sm8ak2a8l7fcn4b2zm3kzfm8w57xxyyrzx7an5b")))) - (build-system python-build-system) - (propagated-inputs - (list python-numpy python-matplotlib python-pyparsing)) - (inputs - (list openblas pybind11)) - (native-inputs - (list python-cython - python-pydata-sphinx-theme - python-pytest - python-sphinx - python-sphinx-panels - python-numpydoc - gfortran - perl - which)) (outputs '("out" "doc")) + (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'disable-pythran - (lambda _ - (setenv "SCIPY_USE_PYTHRAN" "0"))) - (add-before 'build 'change-home-dir - (lambda _ - ;; Change from /homeless-shelter to /tmp for write permission. - (setenv "HOME" "/tmp"))) - (add-after 'unpack 'disable-broken-tests - (lambda _ - (substitute* "scipy/sparse/linalg/dsolve/tests/test_linsolve.py" - (("^( +)def test_threads_parallel\\(self\\):" m indent) - (string-append indent - "@pytest.mark.skip(reason=\"Disabled by Guix\")\n" - m))) - (substitute* "scipy/sparse/linalg/eigen/arpack/tests/test_arpack.py" - (("^def test_parallel_threads\\(\\):" m) - (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n" - m))))) - (add-before 'build 'configure-openblas - (lambda* (#:key inputs #:allow-other-keys) - (call-with-output-file "site.cfg" - (lambda (port) - (format port - "[blas] + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-pythran + (lambda _ + (setenv "SCIPY_USE_PYTHRAN" "0"))) + (add-before 'build 'change-home-dir + (lambda _ + ;; Change from /homeless-shelter to /tmp for write permission. + (setenv "HOME" "/tmp"))) + (add-after 'unpack 'disable-broken-tests + (lambda _ + (substitute* "scipy/sparse/linalg/dsolve/tests/test_linsolve.py" + (("^( +)def test_threads_parallel\\(self\\):" m indent) + (string-append indent + "@pytest.mark.skip(reason=\"Disabled by Guix\")\n" + m))) + (substitute* "scipy/sparse/linalg/eigen/arpack/tests/test_arpack.py" + (("^def test_parallel_threads\\(\\):" m) + (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n" + m))))) + (add-before 'build 'configure-openblas + (lambda _ + (call-with-output-file "site.cfg" + (lambda (port) + (format port + "[blas] libraries = openblas library_dirs = ~a/lib include_dirs = ~a/include @@ -132,42 +119,54 @@ include_dirs = ~a/include library_dirs = ~a/lib atlas_libs = openblas " - (assoc-ref inputs "openblas") - (assoc-ref inputs "openblas") - (assoc-ref inputs "openblas")))))) - (add-after 'install 'install-doc - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((data (string-append (assoc-ref outputs "doc") "/share")) - (doc (string-append data "/doc/" ,name "-" ,version)) - (html (string-append doc "/html")) - (pyver ,(string-append "PYVER=" (version-major+minor - (package-version python)))) - ;; By default it tries to run sphinx-build through the Python - ;; interpreter which won't work with our shell wrapper. - (sphinxbuild "SPHINXBUILD=LANG=C sphinx-build")) - ;; Make installed package available for building the - ;; documentation - (add-installed-pythonpath inputs outputs) - (with-directory-excursion "doc" - ;; Fix generation of images for mathematical expressions. - (substitute* (find-files "source" "conf\\.py") - (("pngmath_use_preview = True") - "pngmath_use_preview = False")) - (mkdir-p html) - (invoke "make" "html" pyver sphinxbuild) - (with-directory-excursion "build/html" - (for-each (lambda (file) - (let* ((dir (dirname file)) - (tgt-dir (string-append html "/" dir))) - (install-file file html))) - (find-files "."))))))) - (replace 'check - (lambda* (#:key tests? inputs outputs #:allow-other-keys) - (when tests? - (add-installed-pythonpath inputs outputs) - (with-directory-excursion "/tmp" - (invoke "python" "-c" - "import scipy; scipy.test(verbose=2)")))))))) + #$(this-package-input "openblas") + #$(this-package-input "openblas") + #$(this-package-input "openblas")))))) + (add-after 'install 'install-doc + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((data (string-append (assoc-ref outputs "doc") "/share")) + (doc (string-append data "/doc/" #$name "-" #$version)) + (html (string-append doc "/html")) + (pyver (string-append "PYVER=" + #$(version-major+minor + (package-version python)))) + ;; By default it tries to run sphinx-build through the Python + ;; interpreter which won't work with our shell wrapper. + (sphinxbuild "SPHINXBUILD=LANG=C sphinx-build")) + ;; Make installed package available for building the + ;; documentation + (add-installed-pythonpath inputs outputs) + (with-directory-excursion "doc" + ;; Fix generation of images for mathematical expressions. + (substitute* (find-files "source" "conf\\.py") + (("pngmath_use_preview = True") + "pngmath_use_preview = False")) + (mkdir-p html) + (invoke "make" "html" pyver sphinxbuild) + (with-directory-excursion "build/html" + (for-each (lambda (file) + (let* ((dir (dirname file)) + (tgt-dir (string-append html "/" dir))) + (install-file file html))) + (find-files "."))))))) + (replace 'check + (lambda* (#:key tests? inputs outputs #:allow-other-keys) + (when tests? + (with-directory-excursion "/tmp" + (invoke "python" "-c" + "import scipy; scipy.test(verbose=2)")))))))) + (propagated-inputs (list python-numpy python-matplotlib python-pyparsing)) + (inputs (list openblas pybind11)) + (native-inputs + (list python-cython + python-pydata-sphinx-theme + python-pytest + python-sphinx + python-sphinx-panels + python-numpydoc + gfortran + perl + which)) (home-page "https://www.scipy.org/") (synopsis "The Scipy library provides efficient numerical routines") (description "The SciPy library is one of the core packages that make up -- cgit v1.2.3 From cddedb9c5b0b8417a2afcead164040787e6e1cde Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 6 Apr 2022 22:24:48 -0400 Subject: gnu: python-scipy: Update to 1.8.0 and enable parallel build. * gnu/packages/python-science.scm (python-scipy): Update to 1.8.0. [modules]: New argument. [phases]{disable-broken-tests}: Delete phase. {configure-openblas}: Streamline configuration template. {parallelize-build}: New phase. {install-doc}: Move before 'check phase. Remove now extraneous 'add-installed-pythonpath' call. Remove the SPHINXBUILD and PYVER Make variables, as well as conf.py patching. Provide SPHINXOPTS to build doc in parallel. Simply recursively copy the 'html' output directory to install the doc. {check}: Remove extraneous INPUTS and OUTPUTS arguments. Start tests with the 'runtests.py' launcher, which accepts a '-j' argument to run the tests in parallel. [native-inputs]: Sort inputs. Add python-pytest-xdist and python-threadpoolctl. [home-page]: Update. --- gnu/packages/python-science.scm | 91 ++++++++++++++++------------------------- 1 file changed, 36 insertions(+), 55 deletions(-) diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index d192543f5c..2cabdb490c 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -73,17 +73,20 @@ (define-public python-scipy (package (name "python-scipy") - (version "1.7.3") + (version "1.8.0") (source (origin (method url-fetch) (uri (pypi-uri "scipy" version)) (sha256 - (base32 "1gxsnw6viz2j3sm8ak2a8l7fcn4b2zm3kzfm8w57xxyyrzx7an5b")))) + (base32 "1gghkwn93niyasm36333xbqrnn3yiadq9d97wnc9mg14nzbg5m1i")))) (outputs '("out" "doc")) (build-system python-build-system) (arguments (list + #:modules '((guix build utils) + (guix build python-build-system) + (ice-9 format)) #:phases #~(modify-phases %standard-phases (add-after 'unpack 'disable-pythran @@ -93,81 +96,59 @@ (lambda _ ;; Change from /homeless-shelter to /tmp for write permission. (setenv "HOME" "/tmp"))) - (add-after 'unpack 'disable-broken-tests - (lambda _ - (substitute* "scipy/sparse/linalg/dsolve/tests/test_linsolve.py" - (("^( +)def test_threads_parallel\\(self\\):" m indent) - (string-append indent - "@pytest.mark.skip(reason=\"Disabled by Guix\")\n" - m))) - (substitute* "scipy/sparse/linalg/eigen/arpack/tests/test_arpack.py" - (("^def test_parallel_threads\\(\\):" m) - (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n" - m))))) (add-before 'build 'configure-openblas (lambda _ (call-with-output-file "site.cfg" (lambda (port) (format port - "[blas] + "\ +[blas] libraries = openblas library_dirs = ~a/lib -include_dirs = ~a/include +include_dirs = ~:*~a/include -# backslash-n to make emacs happy -\n[atlas] -library_dirs = ~a/lib -atlas_libs = openblas -" - #$(this-package-input "openblas") - #$(this-package-input "openblas") - #$(this-package-input "openblas")))))) - (add-after 'install 'install-doc - (lambda* (#:key inputs outputs #:allow-other-keys) +[atlas] +library_dirs = ~:*~a/lib +atlas_libs = openblas~%" #$(this-package-input "openblas")))))) + (add-before 'build 'parallelize-build + (lambda _ + (setenv "NPY_NUM_BUILD_JOBS" + (number->string (parallel-job-count))))) + (add-before 'check 'install-doc + (lambda* (#:key outputs #:allow-other-keys) (let* ((data (string-append (assoc-ref outputs "doc") "/share")) (doc (string-append data "/doc/" #$name "-" #$version)) - (html (string-append doc "/html")) - (pyver (string-append "PYVER=" - #$(version-major+minor - (package-version python)))) - ;; By default it tries to run sphinx-build through the Python - ;; interpreter which won't work with our shell wrapper. - (sphinxbuild "SPHINXBUILD=LANG=C sphinx-build")) - ;; Make installed package available for building the - ;; documentation - (add-installed-pythonpath inputs outputs) + (html (string-append doc "/html"))) (with-directory-excursion "doc" - ;; Fix generation of images for mathematical expressions. - (substitute* (find-files "source" "conf\\.py") - (("pngmath_use_preview = True") - "pngmath_use_preview = False")) + ;; Build doc. + (invoke "make" "html" + ;; Building the documentation takes a very long time. + ;; Parallelize it. + (string-append "SPHINXOPTS=-j" + (number->string (parallel-job-count)))) + ;; Install doc. (mkdir-p html) - (invoke "make" "html" pyver sphinxbuild) - (with-directory-excursion "build/html" - (for-each (lambda (file) - (let* ((dir (dirname file)) - (tgt-dir (string-append html "/" dir))) - (install-file file html))) - (find-files "."))))))) + (copy-recursively "build/html" html))))) (replace 'check - (lambda* (#:key tests? inputs outputs #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - (with-directory-excursion "/tmp" - (invoke "python" "-c" - "import scipy; scipy.test(verbose=2)")))))))) + (invoke "./runtests.py" "-vv" "--no-build" "--mode=fast" + "-j" (number->string (parallel-job-count))))))))) (propagated-inputs (list python-numpy python-matplotlib python-pyparsing)) (inputs (list openblas pybind11)) (native-inputs - (list python-cython + (list gfortran + perl + python-cython + python-numpydoc python-pydata-sphinx-theme python-pytest + python-pytest-xdist python-sphinx python-sphinx-panels - python-numpydoc - gfortran - perl + python-threadpoolctl which)) - (home-page "https://www.scipy.org/") + (home-page "https://scipy.org/") (synopsis "The Scipy library provides efficient numerical routines") (description "The SciPy library is one of the core packages that make up the SciPy stack. It provides many user-friendly and efficient numerical -- cgit v1.2.3 From 7eb8ab941211f9bff8148beccc1baf784372604b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 7 Apr 2022 11:30:15 -0400 Subject: gnu: Add java-antlr4-runtime-cpp. * gnu/packages/java.scm (java-antlr4-runtime-cpp): New variable. --- gnu/packages/java.scm | 35 ++++++++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index 97eae386de..36baefaa7a 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -13,7 +13,7 @@ ;;; Copyright © 2019, 2020, 2021 Björn Höfling ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen ;;; Copyright © 2020 Raghav Gururajan -;;; Copyright © 2020 Maxim Cournoyer +;;; Copyright © 2020, 2022 Maxim Cournoyer ;;; Copyright © 2021 Vincent Legoll ;;; Copyright © 2021 Mike Gerwitz ;;; Copyright © 2021 Pierre Langlois @@ -45,6 +45,7 @@ #:use-module (guix utils) #:use-module (guix gexp) #:use-module (guix build-system ant) + #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) #:use-module (guix build-system maven) #:use-module (guix build-system trivial) @@ -8629,6 +8630,38 @@ actual rendering.") sources by ANTLR.") (license license:bsd-3))) +(define-public java-antlr4-runtime-cpp + (package + (inherit java-antlr4-runtime) + (name "java-antlr4-runtime-cpp") + (outputs '("out" "static")) + (build-system cmake-build-system) + (arguments + (list + ;; TODO: try to run the tests under + ;; runtime-testsuite/test/org/antlr/v4/test/runtime/cpp with antlr4. + #:tests? #f ;no CMake test target + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "runtime/Cpp"))) + (add-after 'install 'move-static-library + (lambda* (#:key outputs #:allow-other-keys) + (let ((static (assoc-ref outputs "static")) + (libantlr4-runtime.a (search-input-file + outputs "lib/libantlr4-runtime.a"))) + (mkdir-p (string-append static "/lib")) + (rename-file + libantlr4-runtime.a + (string-append static "/lib/" + (basename libantlr4-runtime.a))))))))) + (native-inputs (list pkg-config)) + (inputs (list `(,util-linux "lib"))) ;libuuid + (synopsis "ANTL C++ runtime library") + (description "This package contains the C++ runtime library used with C++ +generated sources by ANTLR."))) + (define-public antlr4 (package (inherit java-antlr4-runtime) -- cgit v1.2.3 From 4f8bd85506e7016f62647ec9513e53db856c2190 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 7 Apr 2022 14:59:34 -0400 Subject: gnu: Add python-fonttools-next. * gnu/packages/python-xyz.scm (python-fonttools-next): New variable. --- gnu/packages/python-xyz.scm | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 271f948bc5..9d103f1003 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -11623,6 +11623,18 @@ from an XML-based format.") (base32 "0v6399g755f2hn1ry62i5b6gdinf2fpx2966v3bxh6bjw1accb5p"))))))) +(define-public python-fonttools-next + (package + (inherit python-fonttools-full) + (version "4.32.0") + (source (origin + (inherit (package-source python-fonttools-full)) + (method url-fetch) + (uri (pypi-uri "fonttools" version ".zip")) + (sha256 + (base32 + "14nk43z0dmznypm3zp4sdc04x1y608jawlnmwdkk32a947khvaar")))))) + (define-public python-ly (package (name "python-ly") -- cgit v1.2.3 From 6133af89b94c77b0a343197ce55200e2668e2683 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 7 Apr 2022 17:27:55 -0400 Subject: gnu: Add python-afdko. * gnu/packages/fontutils.scm (python-afdko): New variable. --- gnu/packages/fontutils.scm | 139 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 139 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index e128ed1003..0c479cd5de 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -53,8 +53,10 @@ #:use-module (gnu packages graphics) #:use-module (gnu packages gtk) #:use-module (gnu packages image) + #:use-module (gnu packages java) #:use-module (gnu packages linux) #:use-module (gnu packages man) + #:use-module (gnu packages ninja) #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) @@ -134,6 +136,143 @@ files (OTF, TTF) and WOFF and WOFF2 font files, validating them and sanitizing them as it goes.") (license license:bsd-3))) +(define-public python-afdko + (package + (name "python-afdko") + (version "3.8.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "afdko" version)) + (sha256 + (base32 "171r9f7n8fgz37dkcgpzj508lxfafcyzzx43ps12j1z2nk1sk905")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-problematic-requirements + (lambda _ + (substitute* "requirements.txt" + ;; Remove lxml because the version requested here is different + ;; than the one propagated by the python-fonttools package. + (("^lxml==.*") "")))) + (add-after 'unpack 'patch-setup.py + (lambda _ + ;; There is no use for Python-provided CMake nor Ninja binaries. + (substitute* '("pyproject.toml" "setup.py") + ((".*cmake.*") "") + ((".*ninja.*") "")))) + (add-after 'unpack 'unbundle-antlr4-cpp + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "CMakeLists.txt" + (("^include\\(ExternalAntlr4Cpp).*") + (format #f "include_directories(SYSTEM ~a)" + (search-input-directory inputs + "include/antlr4-runtime")))) + (substitute* "c/makeotf/lib/hotconv/CMakeLists.txt" + (("antlr4_static") + "antlr4-runtime")))) + ;; The test suite expects the commands to be Python rather than + ;; shell scripts, so move the wrap phase after the tests. + (delete 'wrap) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "HOME" "/tmp") + (invoke "pytest" "-vv")))) + (add-after 'check 'wrap + (assoc-ref %standard-phases 'wrap)) + (add-before 'wrap 'wrap-PATH + (lambda _ + ;; The commands execute other commands from this package from + ;; PATH; by wrapping them with bindir, they can be found even + ;; when the command is run from its store location. + (let* ((bindir (string-append #$output "/bin")) + (commands (find-files bindir))) + (for-each (lambda (c) + (wrap-program c + `("PATH" prefix (,bindir)))) + commands))))))) + (native-inputs + (list ninja python-pytest python-scikit-build python-wheel)) + (inputs (list java-antlr4-runtime-cpp `(,util-linux "lib"))) + (propagated-inputs + (list psautohint + python-booleanoperations + python-defcon + python-fontmath + python-fonttools-next + python-lxml + python-tqdm + python-ufonormalizer + python-ufoprocessor)) + (home-page "https://github.com/adobe-type-tools/afdko") + (synopsis "Adobe Font Development Kit for OpenType") + (description "The Adobe Font Development Kit for OpenType (AFDKO) is a set +of tools for building OpenType font (OTF) files from PostScript and TrueType +font data. It includes the following commands: +@table @command +@item buildcff2vf +Assemble a CFF2 variable font from a .designspace file. +@item buildmasterotfs +Build master source OpenType/CFF fonts from a @file{.designspace} file +and UFO master source fonts. +@item charplot +@itemx digiplot +@itemx fontplot +@itemx fontsetplot +@itemx hintplot +@itemx waterfallplot +Aliases for the corresponding options of the @command{proofpdf} command. +@item checkoutlinesufo +Perform outline quality checks. It can also remove path overlaps. +@item comparefamily +Look in a specific directory, examine and report on all the OpenType fonts found. +@item type1 +@itemx detype1 +Compile and decompile, respectively, a Type 1 font to and from a plain-text +representation. +@item makeinstancesufo +Generate UFO font instances from a set of master UFO fonts. +@item makeotfexe +Read all the font data and build the final OpenType font. +@item makeotf +This command can be used to prepare the input files needed by +@command{makeotfexe}. +@item mergefonts +Merge one or more fonts into a parent font. +@item otc2otf +Extract all OpenType fonts from the parent OpenType Collection font. +@item otf2otc +Build an OpenType Collection font file from two or more OpenType font +files. +@item otf2ttf +Converts OpenType-CFF fonts to TrueType. +@item rotatefont +Apply a Postscript transform matrix to the source font files. +@item sfntdiff +Low-level comparison of two OpenType font files. +@item sfntedit +Support table-editing, listing, and checksumming options on +sfnt-formatted files such as OpenType Format (OTF) or TrueType. +@item spot +Dump sfnt data from plain files or Macintosh resource files. +@item ttfcomponentizer +Take in a TrueType font and look for a UFO font stored in the same directory. +Use the UFO's components data to compose matching TrueType glyphs. +@item ttfdecomponentizer +Take in a TrueType font and decompose any composite glyphs into simple glyphs. +@item ttxn +Make a normalized dump of the font, or of selected tables. +@item tx +The @command{tx} (Type eXchange) is a test harness for the CoreType libraries +but also provides many useful font conversion and analysis facilities. +@end table") + (license license:asl2.0))) + + (license license:asl2.0))) + (define-public python-cu2qu (package (name "python-cu2qu") -- cgit v1.2.3 From 7e2d11f417861811428d61808d523808048fa80b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 8 Apr 2022 09:01:13 -0400 Subject: gnu: Add python-cffsubr. * gnu/packages/fontutils.scm (python-cffsubr): New variable. --- gnu/packages/fontutils.scm | 49 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 0c479cd5de..9d170da953 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -271,6 +271,55 @@ but also provides many useful font conversion and analysis facilities. @end table") (license license:asl2.0))) +(define-public python-cffsubr + (package + (name "python-cffsubr") + (version "0.2.9.post1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "cffsubr" version)) + (modules '((guix build utils))) + (snippet '(delete-file-recursively "external")) ;unbundle ADFKO + (sha256 + (base32 "0p7wyagkmwf4agr6ysgswrpmpifx5rz8dnjbcs2gmj29rwnl2cbb")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-setup.py + (lambda _ + (substitute* '("pyproject.toml" + "setup.py") + ;; This is not needed when building the package. + (("setuptools-git-ls-files") "") + ;; Do not attempt to build the unbundled ADFKO. + (("cmdclass\\[\"build_ext\"] = ExecutableBuildExt.*") + "")))) + (add-after 'unpack 'patch-tx-path + (lambda* (#:key inputs #:allow-other-keys) + (define tx (search-input-file inputs "bin/tx")) + (substitute* "src/cffsubr/__init__.py" + (("TX_EXE = \"tx\"") + (format #f "TX_EXE = ~s" tx)) + ;; Use the full 'tx' file name directly. + (("with path\\(__name__, TX_EXE) as tx_cli:") + "") + ((" (return subprocess.run\\(\\[)str\\(tx_cli)(].*)" _ h t) + (format #f "~a~s~a" h tx t))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-pytest python-setuptools-scm python-wheel)) + (inputs (list python-afdko)) + (propagated-inputs (list python-fonttools)) + (home-page "https://github.com/adobe-type-tools/cffsubr") + (synopsis "Compact Font Format (CFF) subroutinizer") + (description "This package provides the @command{cffsubr} command, a +Compact Font Format (CFF) subroutinizer based on the Adobe Font Development +Kit for OpenType (AFDKO) @command{tx} tool.") (license license:asl2.0))) (define-public python-cu2qu -- cgit v1.2.3 From f78ef318247741eadda87f3b8806bb0bb2fe11ae Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 8 Apr 2022 16:41:13 -0400 Subject: gnu: Add skia. * gnu/packages/graphics.scm (skia): New variable. --- gnu/packages/graphics.scm | 109 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index b5a81ef196..e966a82dbb 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -55,6 +55,7 @@ #:use-module (gnu packages bash) #:use-module (gnu packages bison) #:use-module (gnu packages boost) + #:use-module (gnu packages build-tools) #:use-module (gnu packages cdrom) #:use-module (gnu packages check) #:use-module (gnu packages compression) @@ -88,6 +89,7 @@ #:use-module (gnu packages maths) #:use-module (gnu packages mp3) #:use-module (gnu packages multiprecision) + #:use-module (gnu packages ninja) #:use-module (gnu packages pciutils) #:use-module (gnu packages pdf) #:use-module (gnu packages perl) @@ -1858,6 +1860,113 @@ library for 3D visualization and visual simulation software in the scientific and engineering community.") (license license:bsd-3))) +(define-public skia + ;; Releases follow those of Chromium, about every 6 weeks. The release + ;; version can be found on this page: + ;; https://skia.org/docs/user/release/release_notes/. The commit used + ;; should be the last commit, as recommended at + ;; https://skia.org/docs/user/release/. + (let ((version "98") + (revision "0") + (commit "55c56abac381e1ae3f0116c410bed81b05e0a38a")) + (package + (name "skia") + (version (git-version version revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://skia.googlesource.com/skia.git") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1ldns2j1g2wj2phlxr9zqkdgs5g64pisxhwxcrq9ijn8a3jhafr2")))) + (build-system gnu-build-system) ;actually GN + Ninja + (arguments + (list + ;; Running the test suite would require 'dm'; unfortunately the tool + ;; can only be built for debug builds, which require fetching third + ;; party sources. + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (replace 'configure + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "BUILD.gn" + ;; Workaround a bug in the zlib third_party definition, that + ;; fails the build even when zlib is found from the system. + (("deps = \\[ \"//third_party/zlib\" ]") + "deps = []")) + (invoke "gn" "gen" "build" + (string-append + ;; + "--args=" + "cc=\"gcc\" " ;defaults to 'cc' + "is_official_build=true " ;to use system libraries + "is_component_build=true " ;build as a shared library + ;; Specify where locate the harfbuzz and freetype + ;; includes. + (format #f "extra_cflags=[\"-I~a\",\"-I~a\"] " + (search-input-directory inputs + "include/harfbuzz") + (search-input-directory inputs + "include/freetype2")) + ;; Otherwise the validate-runpath phase fails. + "extra_ldflags=[\"-Wl,-rpath=" #$output "/lib\"] " + ;; Disabled, otherwise the build system attempts to + ;; download the SDK at build time. + "skia_use_dng_sdk=false ")))) + (replace 'build + (lambda* (#:key parallel-build? #:allow-other-keys) + (let ((job-count (if parallel-build? + (number->string (parallel-job-count)) + "1"))) + (invoke "ninja" "-j" job-count "-C" "build")))) + (replace 'install + (lambda _ + ;; Install headers. + (for-each (lambda (h) + (install-file h (string-append + #$output "/include/skia/" + (dirname h)))) + (find-files "." "\\.h$")) + ;; Install libraries. + (for-each (lambda (lib) + (install-file lib (string-append #$output "/lib"))) + (find-files "build" "^lib.*\\.(a|so)")) + ;; This pkgconfig file is useful at least to the + ;; python-skia-pathops package. + (define skia.pc (string-append #$output + "/lib/pkgconfig/skia.pc")) + (mkdir-p (dirname skia.pc)) + (call-with-output-file skia.pc + (lambda (port) + (format port "\ +prefix=~a +exec_prefix=${prefix} +libdir=${prefix}/lib +includedir=${prefix}/include/skia + +Name: skia +Description: 2D graphic library for drawing text, geometries and images. +URL: https://skia.org/ +Version: ~a +Libs: -L${libdir} -lskia +Cflags: -I${includedir}~%" #$output #$version)))))))) + (native-inputs (list gn libjpeg-turbo ninja pkg-config python-wrapper)) + (inputs (list expat fontconfig freetype harfbuzz mesa libwebp zlib)) + (home-page "https://skia.org/") + (synopsis "2D graphics library") + (description "Skia is an open source 2D graphics library. It can be +used for drawing text, geometries, and images and has support for: +@itemize +@item 3x3 matrices with perspective +@item antialiasing, transparency, filters +@item shaders, xfermodes, maskfilters, patheffects +@item subpixel text +@end itemize") + (license license:bsd-3)))) + (define-public superfamiconv (package (name "superfamiconv") -- cgit v1.2.3 From 25b4c8a0244fdaf0b92b372a9bda81e0bd3adc67 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 8 Apr 2022 21:56:09 -0400 Subject: gnu: Add python-skia-pathops. * gnu/packages/fontutils.scm (python-skia-pathops): New variable. --- gnu/packages/fontutils.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 9d170da953..f2a76b9492 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -573,6 +573,50 @@ suite of the @code{psautohint} package.") can be used to hint PostScript fonts. A Python wrapper is also included.") (license license:asl2.0))) +(define-public python-skia-pathops + (package + (name "python-skia-pathops") + (version "0.7.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "skia-pathops" version ".zip")) + (modules '((guix build utils))) + (snippet '(delete-file-recursively "src/cpp")) ;140+ MiB of stuff + (sha256 + (base32 "1456rclfn6a01c2cchlgyn166zppcjcqij0k5gwmm8gvzsd5rn0r")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'configure-env + (lambda _ + (setenv "BUILD_SKIA_FROM_SOURCE" "0"))) + (add-after 'unpack 'adjust-c++-language + (lambda _ + ;; Our version of Skia requires c++17. + (substitute* "setup.py" + (("-std=c\\+\\+14") + "-std=c++17")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs + (list pkg-config + python-cython + python-pytest + python-setuptools-scm + unzip)) + (inputs (list skia)) + (home-page "https://github.com/fonttools/skia-pathops") + (synopsis "Python bindings for the Skia library's Path Ops module") + (description "This package provides Python bindings for the Path Ops +module of the Skia library, performing boolean operations on +paths (intersection, union, difference, xor).") + (license license:bsd-3))) + (define-public python-ufoprocessor (package (name "python-ufoprocessor") -- cgit v1.2.3 From 7e776ea007b394cb901e771dc2fd838d72f1585f Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 8 Apr 2022 22:33:46 -0400 Subject: gnu: Add python-ufolib2. * gnu/packages/fontutils.scm (python-ufolib2): New variable. --- gnu/packages/fontutils.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index f2a76b9492..3d8447703f 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -1315,6 +1315,52 @@ generate bitmaps.") `(("python" ,python-2) ,@(alist-delete "python" (package-inputs fontforge)))))) +(define-public python-ufolib2 + (package + (name "python-ufolib2") + (version "0.13.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "ufoLib2" version)) + (sha256 + (base32 "0yx4i8q5rfyqhr2fj70a7z1bp1jv7bdlr64ww9z4nv9ycbda4x9j")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + ;; XXX: PEP 517 manual build copied from python-isort. + (replace 'build + (lambda _ + ;; ZIP does not support timestamps before 1980. + (setenv "SOURCE_DATE_EPOCH" "315532800") + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv")))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (native-inputs + (list python-pypa-build + python-pytest + python-setuptools-scm + python-wheel)) + (propagated-inputs (list python-attrs python-fonttools-full)) + (home-page "https://github.com/fonttools/ufoLib2") + (synopsis "Unified Font Object (UFO) font processing library") + (description "The ufoLib2 Python library is meant to be a thin +representation of the Unified Font Object (UFO) version 3 data model, intended +for programmatic manipulation and fast batch processing of UFOs. It resembles +the defcon library, but does without notifications, the layout engine and +other support classes. Where useful and possible, ufoLib2 tries to be +API-compatible with defcon.") + (license license:asl2.0))) + (define-public python2-ufolib (package (name "python2-ufolib") -- cgit v1.2.3 From 1e02c28a2ab5419fca9dd0e82913955b93d7750a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 8 Apr 2022 22:49:17 -0400 Subject: gnu: Add python-compreffor. * gnu/packages/fontutils.scm (python-compreffor): New variable. --- gnu/packages/fontutils.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 3d8447703f..8ba435aa61 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -322,6 +322,35 @@ Compact Font Format (CFF) subroutinizer based on the Adobe Font Development Kit for OpenType (AFDKO) @command{tx} tool.") (license license:asl2.0))) +(define-public python-compreffor + (package + (name "python-compreffor") + (version "0.5.1.post1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "compreffor" version)) + (sha256 + (base32 "1r3wqd67qnz8p6irv68mvadqv1nklgzw53376iarw3pq4gxrma36")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-setup.py + (lambda _ + (substitute* "setup.py" + ;; Not actually needed. + ((", \"setuptools_git_ls_files\"") ""))))))) + (native-inputs (list python-pytest python-pytest-runner + python-setuptools-scm)) + (propagated-inputs (list python-fonttools)) + (home-page "https://github.com/googlefonts/compreffor") + (synopsis "Compact Font Format (CFF) subroutinizer for fontTools") + (description "This package provides a Compact Font Format (CFF) +subroutinizer for fontTools.") + (license license:asl2.0))) + (define-public python-cu2qu (package (name "python-cu2qu") -- cgit v1.2.3 From 51f0c0af2de75292985b943cb808f176dd618585 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 8 Apr 2022 09:16:44 -0400 Subject: gnu: Add python-ufo2ft. * gnu/packages/fontutils.scm (python-ufo2ft): New variable. --- gnu/packages/fontutils.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 8ba435aa61..74b10232b8 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -378,6 +378,36 @@ converts any cubic curves to quadratic. The most useful function is probably @code{fonts_to_quadratic}.") (license license:asl2.0))) +(define-public python-ufo2ft + (package + (name "python-ufo2ft") + (version "2.26.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "ufo2ft" version)) + (sha256 + (base32 "0a6iq5g6qdxj7nvip8nnf0mf8y5wmpd3wwq0dv7d4nm9bjrh0r6m")))) + (build-system python-build-system) + (native-inputs (list python-pytest python-pytest-runner)) + (propagated-inputs + (list python-booleanoperations + python-cffsubr + python-compreffor + python-cu2qu + python-defcon + python-fonttools + python-skia-pathops + python-ufolib2)) + (home-page "https://github.com/googlefonts/ufo2ft") + (synopsis "Generate OpenType fonts from Unified Font Objects (UFOs)") + (description "@code{ufo2ft} (UFO to FontTools) is a fork of @code{ufo2fdk} +intended to leverage FontTools (a Python library) rather than the Adobe Font +Development Kit for OpenType (AFDKO), a set of C libraries/utilities so that +it can be more easily extended. Like @code{ufo2fdk}, its primary purpose is +to generate OpenType font binaries from Unified Font Objects (UFOs).") + (license license:expat))) + (define-public python-fontmath (package (name "python-fontmath") -- cgit v1.2.3 From 05cbfea0b294722da0b95736cc91cf771a3a9f2d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 8 Apr 2022 23:07:36 -0400 Subject: gnu: Add python-sfdlib. * gnu/packages/fontutils.scm (python-sfdlib): New variable. --- gnu/packages/fontutils.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm index 74b10232b8..444d1635cb 100644 --- a/gnu/packages/fontutils.scm +++ b/gnu/packages/fontutils.scm @@ -632,6 +632,28 @@ suite of the @code{psautohint} package.") can be used to hint PostScript fonts. A Python wrapper is also included.") (license license:asl2.0))) +(define-public python-sfdlib + (package + (name "python-sfdlib") + (version "1.2.3") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/aliftype/sfdLib") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1q61km32i1h3cmn8nazcgsbzpm8q2nxp3kq3glqgfgvlxr1s3brm")))) + (build-system python-build-system) + (propagated-inputs (list python-ufolib2)) + (home-page "https://github.com/aliftype/sfdLib") + (synopsis "Simple SFD to UFO converter") + (description "This package provides the @command{sfd2ufo} command, a +converter from FontForge’s @acronym{SFD, Spline Font Database} fonts to +@acronym{UFO, Unified Font Object} fonts.") + (license license:bsd-3))) + (define-public python-skia-pathops (package (name "python-skia-pathops") -- cgit v1.2.3 From e452987714ad57a41ca0f6af95b47eef970244af Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 8 Apr 2022 23:22:46 -0400 Subject: gnu: Add font-amiri. * gnu/packages/fonts.scm (font-amiri): New variable. --- gnu/packages/fonts.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index 97c3b5ec0c..8d7e70046f 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -47,6 +47,7 @@ ;;; Copyright © 2022 Kitzman ;;; Copyright © 2021 Wamm K. D. ;;; Copyright © 2022 Jai Vetrivelan +;;; Copyright © 2022 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -69,11 +70,13 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (guix build-system font) #:use-module (guix build-system gnu) #:use-module (guix build-system meson) #:use-module (guix build-system trivial) + #:use-module (gnu packages c) #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages compression) @@ -695,6 +698,49 @@ following fonts in the OpenType format: Adventor, Bonum, Chorus, Cursor, Heros, Pagella, Schola, Termes.") (license license:gfl1.0))) +(define-public font-amiri + (package + (name "font-amiri") + (version "0.114") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/aliftype/amiri") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "01d54i68pmy37fhvxv8kld3iqlc1m0vr871zd66y5y4c7kn2v7as")))) + (build-system gnu-build-system) + (arguments + (list + #:imported-modules `(,@%gnu-build-system-modules + (guix build font-build-system)) + #:modules `(,@%gnu-build-system-modules + ((guix build font-build-system) #:prefix font:)) + #:phases #~(modify-phases %standard-phases + (delete 'configure) + (replace 'install + (assoc-ref font:%standard-phases 'install))))) + (native-inputs + (list python-fonttools + python-pcpp + python-opentype-sanitizer + python-sfdlib + python-ufolib2 + python-ufo2ft + python-wrapper)) + (home-page "https://www.amirifont.org/") + (synopsis "Body text Naskh typeface") + (description "Amiri (أميري) is a classical Arabic typeface in Naskh style +for typesetting books and other running text. Amiri is a revival of the +typeface pioneered in early 20th century by Bulaq Press in Cairo, also known +as Amiria Press, after which the font is named. The uniqueness of this +typeface comes from its balance between the beauty of Naskh calligraphy on one +hand and the constraints and requirements of elegant typography on the +other.") + (license license:silofl1.1))) + (define-public font-anonymous-pro (package (name "font-anonymous-pro") -- cgit v1.2.3 From dd12832a2506e76beaadd4acb5e2bbe5e8d6f352 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sat, 9 Apr 2022 00:16:45 -0400 Subject: gnu: Add font-sil-ezra. * gnu/packages/fonts.scm (font-sil-ezra): New variable. --- gnu/packages/fonts.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index 8d7e70046f..193a067ee9 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -2041,6 +2041,28 @@ displays (7SEG, 14SEG). DSEG includes the roman alphabet and symbol glyphs. This package provides the TrueType fonts.") (license license:silofl1.1))) +(define-public font-sil-ezra + (package + (name "font-sil-ezra") + (version "2.51") + (source + (origin + (method url-fetch) + (uri (string-append "https://software.sil.org/downloads/r/ezra/EzraSIL-" + version ".zip")) + (sha256 + (base32 + "1h8cfrvjdwxk963bw359jdg86bycwyyhvviqy6lwcfj7qhzcnszi")))) + (build-system font-build-system) + (home-page "https://software.sil.org/ezra/") + (synopsis "Biblia Hebraica Stuttgartensia (BHS) typography inspired typeface") + (description "Ezra SIL is a typeface fashioned after the square letter +forms of the typography of the Biblia Hebraica Stuttgartensia (BHS), a +beautiful Old Testament volume familiar to Biblical Hebrew scholars. This +font package provides @code{Ezra SIL} as well as @code{Ezra SIL SR}, which has +a different style of marking.") + (license license:expat))) + (define-public font-jetbrains-mono (package (name "font-jetbrains-mono") -- cgit v1.2.3 From 4ab2aad02b1d7a215c7ea2e6d24cf1bb84f1cfbc Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sat, 9 Apr 2022 00:44:09 -0400 Subject: gnu: Add texlive-bidi. * gnu/packages/tex.scm (texlive-bidi): New variable. --- gnu/packages/tex.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 1ebaceb322..6fc1d4fdbf 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -561,6 +561,52 @@ This package contains the binaries.") (license (license:fsf-free "https://www.tug.org/texlive/copying.html")) (home-page "https://www.tug.org/texlive/"))) +(define-public texlive-bidi + (package + (name "texlive-bidi") + ;; Take the version from texlive-2022.0 as the one from texlive 2021.0 is + ;; buggy. + (version "36.4") + (source (origin + (method svn-multi-fetch) + (uri (svn-multi-reference + (url (string-append "svn://www.tug.org/texlive/tags/" + "texlive-2022.0/Master/texmf-dist")) + (locations (list "doc/xelatex/bidi/" + "source/xelatex/bidi/")) + (revision 62885))) + (file-name (string-append name "-" version "-checkout")) + (sha256 + (base32 + "09nfvsjfnms3pclyd2rcivyb5qvzw48b934i3bcl83hv69ix2ks7")))) + (outputs '("out" "doc")) + (build-system texlive-build-system) + (arguments + (list + #:tex-directory "xelatex/bidi" + #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "source/xelatex/bidi"))) + (add-after 'install 'install-doc + (lambda* (#:key outputs #:allow-other-keys) + (let ((doc (string-append (assoc-ref outputs "doc") + "/share/texmf-dist/doc"))) + (mkdir-p doc) + (copy-recursively (string-append #$source "/doc") + doc))))))) + (propagated-inputs (list texlive-generic-iftex + texlive-generic-ltxcmds + texlive-hyperref + texlive-latex-xkeyval + texlive-zref)) + (home-page "https://ctan.org/pkg/bidi") + (synopsis "Bidirectional typesetting in plain TeX and LaTeX using XeTeX") + (description "The @code{bidi} package provides a convenient interface for +typesetting bidirectional texts with plain TeX and LaTeX. The package +includes adaptations for use with many other commonly-used packages.") + (license license:lppl1.3+))) + (define-public texlive-libkpathsea (package/inherit texlive-bin (name "texlive-libkpathsea") -- cgit v1.2.3 From 5551f646c7f410cdd998394bfd759b9229bdc3a9 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sat, 9 Apr 2022 01:01:07 -0400 Subject: gnu: Add font-gfs-ambrosia. * gnu/packages/fonts.scm (font-gfs-ambrosia): New variable. --- gnu/packages/fonts.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index 193a067ee9..89c9afedeb 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -269,6 +269,29 @@ The Lato 2.010 family supports more than 100 Latin-based languages, over 50 Cyrillic-based languages as well as Greek and IPA phonetics.") (license license:silofl1.1))) +(define-public font-gfs-ambrosia + ;; Based on + ;; https://src.fedoraproject.org/rpms/gfs-ambrosia-fonts + ;; /blob/rawhide/f/gfs-ambrosia-fonts.spec. + (package + (name "font-gfs-ambrosia") + (version "20080624") + (source + (origin + (method url-fetch) + (uri (string-append "https://www.greekfontsociety-gfs.gr/" + "_assets/fonts/GFS_Ambrosia.zip")) + (sha256 + (base32 + "0vnnsal61slgj9r4q35wiznd4mbcv49dl18n91s3nvv6jzd4r8b4")))) + (build-system font-build-system) + (home-page "https://www.greekfontsociety-gfs.gr/") + (synopsis "GFS Ambrosia, a Greek majuscule font family") + (description "GFS Ambrosia is a Greek typeface that has the main +characteristics of the majuscule forms of the early Christian tradition. The +font is provided in the OpenType font (OTF) format.") + (license license:silofl1.1))) + (define-public font-gnu-freefont (package (name "font-gnu-freefont") -- cgit v1.2.3 From 2b22de8923d2f7a605b51a47013cc77d616547cc Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 10 Apr 2022 13:58:42 -0400 Subject: gnu: python-click: Update to 8.1.2 and honor TESTS?. * gnu/packages/python-xyz.scm (python-click): Update to 8.1.2. [phases]{fix-paths}: Remove obsolete phase. {check}: Invoke pytest directly and honor TESTS?. (python2-click): Delete variable. --- gnu/packages/python-xyz.scm | 22 ++++++---------------- 1 file changed, 6 insertions(+), 16 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 9d103f1003..b1ce2a66e7 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -3515,30 +3515,23 @@ interfaces.") (define-public python-click (package (name "python-click") - (version "7.1.2") + (version "8.1.2") (source (origin (method url-fetch) (uri (pypi-uri "click" version)) (sha256 (base32 - "06kbzd6sjfkqan3miwj9wqyddfxc2b6hi7p5s4dvqjb3gif2bdfj")))) + "0whs38a2i0561kwbgigs6vic9r0a1887m2v1aw3rmv6r2kz0g5s7")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases - (add-after 'unpack 'fix-paths - (lambda* (#:key inputs #:allow-other-keys) - (let ((glibc (assoc-ref inputs ,(if (%current-target-system) - "cross-libc" "libc")))) - (substitute* "src/click/_unicodefun.py" - (("'locale'") - (string-append "'" glibc "/bin/locale'")))))) (replace 'check - (lambda _ - (invoke "python" "-m" "pytest")))))) - (native-inputs - (list python-pytest)) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-pytest)) (home-page "https://palletsprojects.com/p/click/") (synopsis "Command line library for Python") (description @@ -3548,9 +3541,6 @@ composable way with as little code as necessary. Its name stands for with sensible defaults out of the box.") (license license:bsd-3))) -(define-public python2-click - (package-with-python2 python-click)) - (define-public python-click-5 (package (inherit python-click) (name "python-click") -- cgit v1.2.3 From cce678ab8258676e929118f15ab7df3d4601546a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 10 Apr 2022 14:00:06 -0400 Subject: gnu: python-flask: Update to 2.1.1. * gnu/packages/python-web.scm (python-flask): Update to 2.1.1. [propagated-inputs]: Add python-asgiref and python-importlib-metadata. [home-page]: Update. --- gnu/packages/python-web.scm | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 0f9f1e8786..340f84c78f 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -2991,13 +2991,13 @@ minimum of WSGI.") (define-public python-flask (package (name "python-flask") - (version "2.0.2") + (version "2.1.1") (source (origin (method url-fetch) (uri (pypi-uri "Flask" version)) (sha256 (base32 - "1qilnrdakhbw5k951kczdy8ia0wczh0dpp1vi4qhgmfx6klvhbvv")))) + "1j0rjly2yhbm566lq2s8543fs7fz86f77abps539djcfalzbvjd8")))) (build-system python-build-system) (arguments '(#:phases @@ -3009,8 +3009,13 @@ minimum of WSGI.") (native-inputs (list python-pytest)) (propagated-inputs - (list python-itsdangerous python-jinja2 python-click python-werkzeug)) - (home-page "https://www.palletsprojects.com/p/flask/") + (list python-asgiref ;async extra + python-click + python-importlib-metadata + python-itsdangerous + python-jinja2 + python-werkzeug)) + (home-page "https://palletsprojects.com/p/flask/") (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions") (description "Flask is a micro web framework based on the Werkzeug toolkit and Jinja2 template engine. It is called a micro framework because it does not -- cgit v1.2.3 From bd1f8cdf52c8a93630015d70281817a8cae1aa39 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 10 Apr 2022 21:15:03 -0400 Subject: gnu: Add python-untangle. * gnu/packages/xml.scm (python-untangle): New variable. --- gnu/packages/xml.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm index db004c11b6..a0d8d20102 100644 --- a/gnu/packages/xml.scm +++ b/gnu/packages/xml.scm @@ -72,6 +72,7 @@ #:use-module (gnu packages tls) #:use-module (gnu packages web) #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) @@ -2544,6 +2545,35 @@ libxml2 and libxslt.") (define-public python2-lxml (package-with-python2 python-lxml)) +(define-public python-untangle + ;; The latest tagged release is from 2014; use the latest commit. + (let ((revision "1") + (commit "fb916a9621175d000a3b0ca9322d3b3ebf8570c0")) + (package + (name "python-untangle") + ;; PyPI currently offers some untagged 1.1.1 version. + (version (git-version "1.1.1" revision commit)) + (source + (origin + (method git-fetch) ;no tests in pypi archive + (uri (git-reference + (url "https://github.com/stchris/untangle") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0dn2jz9ajncbqx3pdlgqaxmngl6pdiaz03nj8mkddasckdq9lbrh")))) + (build-system python-build-system) + (arguments (list #:phases #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "tests/tests.py"))))))) + (home-page "http://0chris.com/untangle") + (synopsis "XML to Python objects conversion library") + (description "@code{untangle} is a tiny Python library which converts an +XML document to a Python object.") + (license license:expat)))) + (define-public python-xmlschema (package (name "python-xmlschema") -- cgit v1.2.3 From 86be766874a198611f70c1883106cee42361d114 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 10 Apr 2022 21:57:02 -0400 Subject: gnu: python-black: Update to 22.3.0. * gnu/packages/python-xyz.scm (python-black): Update to 22.3.0. [phases]{relax-version-requirements}: Delete phase. {use-absolute-file-names}: Streamline phase. {disable-broken-tests, remove-entrypoint}: Delete phases. --- gnu/packages/python-xyz.scm | 39 ++++----------------------------------- 1 file changed, 4 insertions(+), 35 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index b1ce2a66e7..e7ca4ac84d 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -5451,58 +5451,27 @@ matching of file paths.") (define-public python-black (package (name "python-black") - (version "21.12b0") + (version "22.3.0") (source (origin (method url-fetch) (uri (pypi-uri "black" version)) (sha256 (base32 - "1czjwr1bx9ax5l64xfi54sxb1ycdy4s9ciaqg592x7jn79lhzf3p")))) + "0yfahlqc7dsdp1js0cbv706apldnfnlbal9b53cww8n0hs40n0im")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases - ;; XXX Remove this when updating this package: - ;; https://github.com/psf/black/issues/2703#issuecomment-1004752142 - (add-after 'unpack 'relax-version-requirements - (lambda _ - (substitute* "setup.py" - (("tomli[^\"]*\",") - "tomli\",")))) (add-after 'patch-source-shebangs 'use-absolute-file-names (lambda* (#:key native-inputs inputs #:allow-other-keys) (let* ((inpts (or native-inputs inputs)) - (python3 (search-input-file inpts "/bin/python3")) - (/bin/false (search-input-file inpts "/bin/false")) - (/bin/sleep (search-input-file inpts "/bin/sleep"))) + (python3 (search-input-file inpts "/bin/python3"))) (substitute* (find-files "tests" "\\.py$") (("#!/usr/bin/env python3(\\.[0-9]+)?" _ minor-version) (string-append "#!" python3 (if (string? minor-version) minor-version - "")))) - (substitute* "tests/test_primer.py" - (("/bin/false") /bin/false) - (("/bin/sleep") /bin/sleep))))) - (add-after 'unpack 'disable-broken-tests - (lambda* (#:key outputs inputs #:allow-other-keys) - ;; Make installed package available for running the tests - (setenv "PATH" (string-append (assoc-ref outputs "out") "/bin" - ":" (getenv "PATH"))) - - ;; The source formatting test fails because we patch various - ;; files; just disable it. - (substitute* "tests/test_format.py" - (("def test_source_is_formatted" all) - (format #f "@pytest.mark.skip(\"Disabled by Guix.\")\n~a" - all))))) - ;; Remove blackd, because it depends on python-aiohttp and - ;; python-aiohttp-cors. - (add-after 'unpack 'remove-entrypoint - (lambda _ - (substitute* "setup.py" - (("\\s*\"blackd=blackd:patched_main \\[d\\]\",\n") "") - (("\"blackd\", ") "")))) + ""))))))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? (invoke "pytest" "-vv"))))))) -- cgit v1.2.3 From 476ae98d0bd0be0cddea27edbf99c65c0c798cdb Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 10 Apr 2022 22:04:58 -0400 Subject: gnu: pylint: Run tests in parallel. * gnu/packages/check.scm (python-pylint) [phases]{check}: Add the '-n' option to use xdist with pytest. [native-inputs]: Add python-pytest-xdist. --- gnu/packages/check.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index b7a5a9bd46..005a3bde7c 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -2532,9 +2532,10 @@ statements in the module it tests.") (delete-file "tests/primer/test_primer_external.py") (delete-file "tests/testutils/test_package_to_lint.py") (setenv "HOME" "/tmp") - (invoke "pytest" "-k" "test_functional"))))))) + (invoke "pytest" "-k" "test_functional" + "-n" (number->string (parallel-job-count))))))))) (native-inputs - (list python-pytest)) + (list python-pytest python-pytest-xdist)) (propagated-inputs (list python-astroid python-isort -- cgit v1.2.3 From 33570ca6bd5f16420330d2c60fbef89daa0088c0 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 10 Apr 2022 22:57:17 -0400 Subject: gnu: python-trio: Update to 0.20.0. * gnu/packages/python-xyz.scm (python-trio): Update to 0.20.0. [phases]{patch-sleep}: New phase. [change-home]: Delete trailing #t. {check}: Run tests in parallel. Disable the test_cancel_scope_exit_doesnt_create_cyclic_garbage, test_ipython_exc_handler, test_for_leaking_fds and test_static_tool_sees_all_symbols tests. [native-inputs]: Add python-pytest-xdist. --- gnu/packages/python-xyz.scm | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index e7ca4ac84d..6e05d633b3 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -24426,26 +24426,32 @@ project.") (define-public python-trio (package (name "python-trio") - (version "0.19.0") + (version "0.20.0") (source (origin (method url-fetch) (uri (pypi-uri "trio" version)) (sha256 - (base32 "1qgg4zhca81dxc1nlmcr5pl1bclmvdp3niqbyslwxs65bs732pl9")))) + (base32 "0w30cwmdwfa8zq2agqv3h62jzwwsk7ms8f683ag8f3jx279m42k7")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'patch-sleep + (lambda _ + (substitute* "trio/tests/test_subprocess.py" + (("/bin/sleep") + (which "sleep"))))) (add-before 'check 'change-home (lambda _ ;; Tests require a writable home. - (setenv "HOME" "/tmp") - #t)) + (setenv "HOME" "/tmp"))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? - (invoke "pytest" "-vv" "-k" + (invoke "pytest" "-vv" + "-n" (number->string (parallel-job-count)) + "-k" (string-append ;; This test times out. "not test_ki_protection_works" @@ -24454,7 +24460,10 @@ project.") " and not test_run_in_trio_thread_ki" " and not test_simple_cancel_scope_usage_doesnt_create_cyclic_garbage" " and not test_nursery_cancel_doesnt_create_cyclic_garbage" + " and not test_cancel_scope_exit_doesnt_create_cyclic_garbage" " and not test_locals_destroyed_promptly_on_cancel" + " and not test_ipython_exc_handler" + " and not test_for_leaking_fds" ;; These try to raise KeyboardInterrupt which does not work ;; in the build environment. " and not test_ki_self" @@ -24463,7 +24472,9 @@ project.") " and not test_getnameinfo" " and not test_SocketType_resolve" ;; OSError: protocol not found. - " and not test_getprotobyname")))))))) + " and not test_getprotobyname" + ;; EOFError: Ran out of input. + " and not test_static_tool_sees_all_symbols")))))))) (native-inputs (list python-astor python-ipython @@ -24471,6 +24482,7 @@ project.") python-pylint python-pyopenssl python-pytest + python-pytest-xdist python-pytest-cov python-trustme)) (propagated-inputs -- cgit v1.2.3 From 61c8a13f50e7a12cce751cd3140a4506cc617702 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 11 Apr 2022 00:55:16 -0400 Subject: gnu: Add python-pydevd. * gnu/packages/python-xyz.scm (python-pydevd): New variable. --- gnu/packages/python-xyz.scm | 102 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 6e05d633b3..11c057ad99 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -159,6 +159,7 @@ #:use-module (gnu packages file) #:use-module (gnu packages fontutils) #:use-module (gnu packages freedesktop) + #:use-module (gnu packages gdb) #:use-module (gnu packages gcc) #:use-module (gnu packages geo) #:use-module (gnu packages ghostscript) @@ -13032,6 +13033,107 @@ libmagic."))) (define-public python2-file (package-with-python2 python-file)) +(define-public python-pydevd + ;; Use the latest commit, which includes cleanups that removes Python 2 + ;; syntax that would fail to build. + (let ((revision "0") + (commit "47e298499ef19563bb2ef5941a57046a35ae6868")) + (package + (name "python-pydevd") + (version (git-version "2.8.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/fabioz/PyDev.Debugger") + (commit commit))) + (modules '((guix build utils))) + (snippet '(begin + ;; Delete pre-built binaries. + (for-each delete-file (find-files "." "\\.(so|dylib|dll)")) + ;; This source is generated via Cython. + (delete-file "_pydevd_bundle/pydevd_cython.c"))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1yd017dh6xgxrqcyf8kk8jrr0a3zw895yfjih0z5jghyf0rck38q")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-tests + (lambda _ + (substitute* "tests_python/test_convert_utilities.py" + ;; Add missing trailing '/'. + (("'\\\\\\\\usr\\\\\\\\bin\\\\\\\\') == '/usr/bin" all) + (string-append all "/"))))) + (add-after 'unpack 'patch-command-paths + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "_pydevd_bundle/pydevd_api.py" + (("'kill'") + (format #f "~s" (search-input-file inputs "bin/kill"))) + (("'pgrep'") + (format #f "~s" (search-input-file inputs "bin/pgrep")))))) + (add-after 'unpack 'generate-sources + (lambda _ + (setenv "PYTHONPATH" (getcwd)) + (invoke "python" "build_tools/build.py"))) + (add-after 'unpack 'adjust-attach-binary-name + (lambda _ + (substitute* + '("pydevd_tracing.py" + "pydevd_attach_to_process/add_code_to_python_process.py") + (("def get_(target|python_helper_lib)_filename.*" all) + (format #f "~a return ~s~%" all + (string-append #$output "/lib/attach.so")))))) + (add-after 'unpack 'patch-gdb + (lambda* (#:key inputs #:allow-other-keys) + (substitute* + "pydevd_attach_to_process/add_code_to_python_process.py" + (("'gdb',") + (format #f "~s," (search-input-file inputs "bin/gdb")))))) + (add-after 'build 'build-attach-linux-binary + (lambda _ + (invoke #+(cxx-for-target) "-shared" "-o" "attach.so" + "-fPIC" "-nostartfiles" + "pydevd_attach_to_process/linux_and_mac/attach.cpp"))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "PYDEVD_USE_CYTHON" "YES") + (invoke "pytest" "-vv" + "-n" (number->string (parallel-job-count)) + "-k" + (string-append + ;; the GUI event loop requires an X server. + "not test_gui_event_loop_custom " + ;; This test validates that 'pydevd' is not in the + ;; exception message, but it is due to being part + ;; of the build file name present in the message. + "and not test_evaluate_exception_trace"))))) + (add-after 'install 'install-attach-binary + (lambda _ + (install-file "attach.so" + (string-append #$output "/lib")))) + ;; Some modules aren't designed to be loadable by themselves, such + ;; as 'pydev_app_engine_debug_startup' and fail. + (delete 'sanity-check)))) + (native-inputs + (list python-cython + python-numpy + python-psutil + python-pytest + python-pytest-xdist + python-trio + python-untangle)) + (inputs (list coreutils gdb procps)) + (home-page "https://github.com/fabioz/PyDev.Debugger/") + (synopsis "Python debugger") + (description "PyDev.Debugger is a capable Python debugger used in PyDev +and other @acronym{IDEs, Integrated Development Environments}.") + (license license:epl1.0)))) + (define-public python-debian (package (name "python-debian") -- cgit v1.2.3 From 08199a93c8e986841dde05b1c249a01e7e29430a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 11 Apr 2022 01:15:28 -0400 Subject: gnu: Add python-debugpy. * gnu/packages/python-xyz.scm (python-debugpy): New variable. * gnu/packages/patches/python-debugpy-unbundle-pydevd.patch: New file. * gnu/local.mk: Register it. --- gnu/local.mk | 1 + .../patches/python-debugpy-unbundle-pydevd.patch | 254 +++++++++++++++++++++ gnu/packages/python-xyz.scm | 72 ++++++ 3 files changed, 327 insertions(+) create mode 100644 gnu/packages/patches/python-debugpy-unbundle-pydevd.patch diff --git a/gnu/local.mk b/gnu/local.mk index 9c5c6896ba..06367fac5e 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1681,6 +1681,7 @@ dist_patch_DATA = \ %D%/packages/patches/python-argcomplete-1.11.1-fish31.patch \ %D%/packages/patches/python-cross-compile.patch \ %D%/packages/patches/python-configobj-setuptools.patch \ + %D%/packages/patches/python-debugpy-unbundle-pydevd.patch \ %D%/packages/patches/python-docopt-pytest6-compat.patch \ %D%/packages/patches/python-execnet-read-only-fix.patch \ %D%/packages/patches/python-fixtures-remove-monkeypatch-test.patch \ diff --git a/gnu/packages/patches/python-debugpy-unbundle-pydevd.patch b/gnu/packages/patches/python-debugpy-unbundle-pydevd.patch new file mode 100644 index 0000000000..7a6ad54489 --- /dev/null +++ b/gnu/packages/patches/python-debugpy-unbundle-pydevd.patch @@ -0,0 +1,254 @@ +Allow using pydevd as a regular dependency. +Submitted upstream at: https://github.com/microsoft/debugpy/pull/902 + +diff --git a/setup.py b/setup.py +index 5fc40070..3a530a29 100644 +--- a/setup.py ++++ b/setup.py +@@ -11,6 +11,9 @@ import subprocess + import sys + + ++DEBUGPY_BUNDLING_DISABLED = bool(os.getenv('DEBUGPY_BUNDLING_DISABLED')) ++ ++ + sys.path.insert(0, os.path.dirname(os.path.abspath(__file__))) + import versioneer # noqa + +@@ -18,12 +21,15 @@ del sys.path[0] + + sys.path.insert(0, os.path.join(os.path.dirname(os.path.abspath(__file__)), "src")) + import debugpy +-import debugpy._vendored ++ ++if not DEBUGPY_BUNDLING_DISABLED: ++ import debugpy._vendored + + del sys.path[0] + + +-PYDEVD_ROOT = debugpy._vendored.project_root("pydevd") ++PYDEVD_ROOT = (None if DEBUGPY_BUNDLING_DISABLED else ++ debugpy._vendored.project_root("pydevd")) + DEBUGBY_ROOT = os.path.dirname(os.path.abspath(debugpy.__file__)) + + +@@ -67,7 +73,7 @@ def iter_vendored_files(): + # relevant setuptools versions. + class ExtModules(list): + def __bool__(self): +- return True ++ return not DEBUGPY_BUNDLING_DISABLED + + + def override_build(cmds): +@@ -133,9 +139,24 @@ with open("DESCRIPTION.md", "r") as fh: + + + if __name__ == "__main__": +- if not os.getenv("SKIP_CYTHON_BUILD"): ++ if not (os.getenv("SKIP_CYTHON_BUILD") or DEBUGPY_BUNDLING_DISABLED): + cython_build() + ++ # Etch bundling status in the source. ++ if debugpy.__bundling_disabled__ != DEBUGPY_BUNDLING_DISABLED: ++ ++ with open(os.path.join(DEBUGBY_ROOT, '__init__.py'), 'r') as f: ++ lines = f.readlines() ++ with open(os.path.join(DEBUGBY_ROOT, '__init__.py'), 'w') as f: ++ edited = [] ++ for line in lines: ++ if line.startswith('__bundling_disabled__'): ++ edited.append( ++ f'__bundling_disabled__ = {DEBUGPY_BUNDLING_DISABLED}\n') ++ else: ++ edited.append(line) ++ f.writelines(edited) ++ + extras = {} + platforms = get_buildplatform() + if platforms is not None: +@@ -145,6 +166,18 @@ if __name__ == "__main__": + override_build(cmds) + override_build_py(cmds) + ++ data = {"debugpy": ["ThirdPartyNotices.txt"]} ++ packages = [ ++ "debugpy", ++ "debugpy.adapter", ++ "debugpy.common", ++ "debugpy.launcher", ++ "debugpy.server", ++ ] ++ if not DEBUGPY_BUNDLING_DISABLED: ++ data.update({"debugpy._vendored": list(iter_vendored_files())}) ++ packages.append("debugpy._vendored") ++ + setuptools.setup( + name="debugpy", + version=versioneer.get_version(), +@@ -173,20 +206,10 @@ if __name__ == "__main__": + "License :: OSI Approved :: MIT License", + ], + package_dir={"": "src"}, +- packages=[ +- "debugpy", +- "debugpy.adapter", +- "debugpy.common", +- "debugpy.launcher", +- "debugpy.server", +- "debugpy._vendored", +- ], +- package_data={ +- "debugpy": ["ThirdPartyNotices.txt"], +- "debugpy._vendored": list(iter_vendored_files()), +- }, ++ packages=packages, ++ package_data=data, + ext_modules=ExtModules(), +- has_ext_modules=lambda: True, ++ has_ext_modules=lambda: not DEBUGPY_BUNDLING_DISABLED, + cmdclass=cmds, + **extras + ) +diff --git a/src/debugpy/__init__.py b/src/debugpy/__init__.py +index baa5a7c5..7b7a29aa 100644 +--- a/src/debugpy/__init__.py ++++ b/src/debugpy/__init__.py +@@ -206,6 +206,8 @@ def trace_this_thread(should_trace): + + __version__ = _version.get_versions()["version"] + ++__bundling_disabled__ = False ++ + # Force absolute path on Python 2. + __file__ = os.path.abspath(__file__) + +diff --git a/src/debugpy/server/__init__.py b/src/debugpy/server/__init__.py +index e6a1ad66..5f29a87a 100644 +--- a/src/debugpy/server/__init__.py ++++ b/src/debugpy/server/__init__.py +@@ -4,6 +4,50 @@ + + from __future__ import absolute_import, division, print_function, unicode_literals + ++from importlib import import_module ++import os ++ + # "force_pydevd" must be imported first to ensure (via side effects) + # that the debugpy-vendored copy of pydevd gets used. +-import debugpy._vendored.force_pydevd # noqa ++import debugpy ++if debugpy.__bundling_disabled__: ++ # Do what force_pydevd.py does, but using the system-provided ++ # pydevd. ++ ++ # XXX: This is copied here so that the whole '_vendored' directory ++ # can be deleted when DEBUGPY_BUNDLING_DISABLED is set. ++ ++ # If debugpy logging is enabled, enable it for pydevd as well ++ if "DEBUGPY_LOG_DIR" in os.environ: ++ os.environ[str("PYDEVD_DEBUG")] = str("True") ++ os.environ[str("PYDEVD_DEBUG_FILE")] = \ ++ os.environ["DEBUGPY_LOG_DIR"] + str("/debugpy.pydevd.log") ++ ++ # Work around https://github.com/microsoft/debugpy/issues/346. ++ # Disable pydevd frame-eval optimizations only if unset, to allow opt-in. ++ if "PYDEVD_USE_FRAME_EVAL" not in os.environ: ++ os.environ[str("PYDEVD_USE_FRAME_EVAL")] = str("NO") ++ ++ # Constants must be set before importing any other pydevd module ++ # due to heavy use of "from" in them. ++ pydevd_constants = import_module('_pydevd_bundle.pydevd_constants') ++ # The default pydevd value is 1000. ++ pydevd_constants.MAXIMUM_VARIABLE_REPRESENTATION_SIZE = 2 ** 32 ++ ++ # When pydevd is imported it sets the breakpoint behavior, but it needs to be ++ # overridden because by default pydevd will connect to the remote debugger using ++ # its own custom protocol rather than DAP. ++ import pydevd # noqa ++ import debugpy # noqa ++ ++ def debugpy_breakpointhook(): ++ debugpy.breakpoint() ++ ++ pydevd.install_breakpointhook(debugpy_breakpointhook) ++ ++ # Ensure that pydevd uses JSON protocol ++ from _pydevd_bundle import pydevd_constants ++ from _pydevd_bundle import pydevd_defaults ++ pydevd_defaults.PydevdCustomization.DEFAULT_PROTOCOL = pydevd_constants.HTTP_JSON_PROTOCOL ++else: ++ import debugpy._vendored.force_pydevd # noqa +diff --git a/src/debugpy/server/attach_pid_injected.py b/src/debugpy/server/attach_pid_injected.py +index e6345996..87cfdd53 100644 +--- a/src/debugpy/server/attach_pid_injected.py ++++ b/src/debugpy/server/attach_pid_injected.py +@@ -8,6 +8,7 @@ from __future__ import absolute_import, division, print_function, unicode_litera + + import os + ++import debugpy + + __file__ = os.path.abspath(__file__) + _debugpy_dir = os.path.dirname(os.path.dirname(os.path.dirname(__file__))) +@@ -30,25 +31,29 @@ def attach(setup): + def on_critical(msg): + print(msg, file=sys.stderr) + +- pydevd_attach_to_process_path = os.path.join( +- _debugpy_dir, +- "debugpy", +- "_vendored", +- "pydevd", +- "pydevd_attach_to_process", +- ) +- assert os.path.exists(pydevd_attach_to_process_path) +- sys.path.insert(0, pydevd_attach_to_process_path) +- +- # NOTE: that it's not a part of the pydevd PYTHONPATH +- import attach_script ++ if debugpy.__bundling_disabled__: ++ from pydevd_attach_to_process import attach_script ++ else: ++ pydevd_attach_to_process_path = os.path.join( ++ _debugpy_dir, ++ "debugpy", ++ "_vendored", ++ "pydevd", ++ "pydevd_attach_to_process", ++ ) ++ assert os.path.exists(pydevd_attach_to_process_path) ++ sys.path.insert(0, pydevd_attach_to_process_path) ++ ++ # NOTE: that it's not a part of the pydevd PYTHONPATH ++ import attach_script + + attach_script.fix_main_thread_id( + on_warn=on_warn, on_exception=on_exception, on_critical=on_critical + ) + +- # NOTE: At this point it should be safe to remove this. +- sys.path.remove(pydevd_attach_to_process_path) ++ if not debugpy.__bundling_disabled__: ++ # NOTE: At this point it should be safe to remove this. ++ sys.path.remove(pydevd_attach_to_process_path) + except: + import traceback + +diff --git a/tests/tests/test_vendoring.py b/tests/tests/test_vendoring.py +index dd6c4269..28c03702 100644 +--- a/tests/tests/test_vendoring.py ++++ b/tests/tests/test_vendoring.py +@@ -1,3 +1,8 @@ ++import pytest ++ ++import debugpy ++ ++@pytest.mark.skipif(debugpy.__bundling_disabled__, reason='Bundling disabled') + def test_vendoring(pyfile): + @pyfile + def import_debugpy(): +-- +2.34.0 + diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 11c057ad99..0034ed703b 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -13134,6 +13134,78 @@ libmagic."))) and other @acronym{IDEs, Integrated Development Environments}.") (license license:epl1.0)))) +(define-public python-debugpy + (package + (name "python-debugpy") + (version "1.6.0") + (source + (origin + (method git-fetch) + (uri (git-reference ;no tests in PyPI archive + (url "https://github.com/microsoft/debugpy") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (modules '((guix build utils))) + ;; Remove the bundled PyDev-Debugger copy, including its pre-built + ;; attach binary. + (snippet '(delete-file-recursively "src/debugpy/_vendored")) + (patches (search-patches "python-debugpy-unbundle-pydevd.patch")) + (sha256 + (base32 + "1dpfzs3p51648i7f3fz8dw5d0vrj39iwn1jhn0226idc02ybyqih")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-sh-in-tests + (lambda _ + (substitute* "tests/debugpy/test_run.py" + (("#!/bin/sh") + (string-append "#!" (which "sh")))))) + (add-after 'unpack 'fix-version + ;; Versioneer is useless when there is no git metadata. + (lambda _ + (substitute* "setup.py" + (("version=versioneer.get_version\\(),") + (format #f "version=~s," #$version))))) + (add-before 'build 'configure + (lambda _ + ;; This adjusts the behavior of debugpy to load pydevd from + ;; Python site packages. + (setenv "DEBUGPY_BUNDLING_DISABLED" "1"))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (invoke "pytest" "-vv" + "-n" (number->string (parallel-job-count)) + "-k" + (string-append + ;; These tests cannot be run in parallel because their + ;; test data would not be copied by xdist and lead to + ;; import errors. (see: + ;; https://github.com/microsoft/debugpy/issues/342 and + ;; https://github.com/microsoft/debugpy/issues/880). + "not test_custom_python_args " + "and not test_autokill "))))))) + (native-inputs + ;; See: https://raw.githubusercontent.com/microsoft/debugpy/ + ;; main/tests/requirements.txt. + (list python-django + python-gevent + python-flask + python-psutil + python-pytest + python-pytest-cov + python-pytest-timeout + python-pytest-xdist + python-requests)) + (propagated-inputs (list python-pydevd)) + (home-page "https://aka.ms/debugpy") + (synopsis "Debug Adapter Protocol Python implementation") + (description "An implementation of the Debug Adapter Protocol for +Python.") + (license license:expat))) + (define-public python-debian (package (name "python-debian") -- cgit v1.2.3 From 4b6500f972cd9c6fd5f4a06b3a778b0b5ccb53f4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 00:41:04 -0400 Subject: gnu: python-greenlet: Update to 1.1.2. * gnu/packages/python-xyz.scm (python-greenlet): Update to 1.1.2. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 0034ed703b..22869bcaa3 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -16708,13 +16708,13 @@ library. It can be used to act both as a TFTP client or TFTP server.") (define-public python-greenlet (package (name "python-greenlet") - (version "1.1.1") + (version "1.1.2") (source (origin (method url-fetch) (uri (pypi-uri "greenlet" version)) (sha256 (base32 - "10gllbrcbazxck84nr7dw3js3gq0rxrsr4kkvy5hg542rms2gwn0")))) + "0jkln5bf6rq7dbvpv7ypin3pp9jqd2jr91yyxlnfcii3msj5w3z3")))) (build-system python-build-system) (home-page "https://greenlet.readthedocs.io/") (synopsis "Lightweight in-process concurrent programming") -- cgit v1.2.3 From 44dc0f0f0b1129b944e6b0c3d60f1ab9acdaccf9 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 15:14:56 -0400 Subject: gnu: Add python-pytest-forked-next. * gnu/packages/check.scm (python-pytest-forked-next): New variable. --- gnu/packages/check.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 005a3bde7c..5e0b653983 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -1570,6 +1570,23 @@ can be useful to isolate tests against undesirable global environment side-effects (such as setting environment variables).") (license license:expat))) +(define-public python-pytest-forked-next + (package + (inherit python-pytest-forked) + (name "python-pytest-forked") + (version "1.4.0") + (source + (origin + (method git-fetch) ;for tests + (uri (git-reference + (url "https://github.com/pytest-dev/pytest-forked") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0j9bbjny7h3b4fig6l26f26c697r67mm62fzdd9m9rqyy2bmnqjs")))) + (native-inputs (list python-pytest-bootstrap python-setuptools-scm)))) + (define-public python-scripttest (package (name "python-scripttest") -- cgit v1.2.3 From 59e51d8f1c1492a2ea876b1f61a4a27372cbcde8 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 15:15:06 -0400 Subject: gnu: python-pytest-xdist-next: Update to 2.5.0. * gnu/packages/check.scm (python-pytest-xdist-next): Update to 2.5.0. [propagated-inputs]: replace python-pytest-forked with python-pytest-forked-next. --- gnu/packages/check.scm | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 5e0b653983..957d7a4262 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -1483,18 +1483,16 @@ result back.") (define-public python-pytest-xdist-next (package/inherit python-pytest-xdist (name "python-pytest-xdist") - (version "2.3.0") + (version "2.5.0") (source (origin (method url-fetch) (uri (pypi-uri "pytest-xdist" version)) (sha256 (base32 - "19cy57jrf3pwi7x6fnbxryjvqagsl0yv736jnynvr3yqhlpxxv78")))) - (propagated-inputs - `(("python-execnet" ,python-execnet) - ("python-pytest" ,python-pytest-6) - ("python-pytest-forked" ,python-pytest-forked))))) + "1psf5dqxvc38qzxvc305mkg5xpdmdkbkkfiyqlmdnkgh7z5dx025")))) + (propagated-inputs (list python-execnet python-pytest + python-pytest-forked-next)))) (define-public python-pytest-timeout (package -- cgit v1.2.3 From d5ee3dcf9e997dc8ad527e73b9e07ea983f8610b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 16:21:56 -0400 Subject: gnu: Add python-ipyparallel-bootstrap. * gnu/packages/python-xyz.scm (python-ipyparallel): Morph into... (python-ipyparallel-bootstrap): ... this, moving native inputs to a new definition of... (python-ipyparallel): ... this. --- gnu/packages/python-xyz.scm | 97 +++++++++++++++++++++++++++------------------ 1 file changed, 58 insertions(+), 39 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 22869bcaa3..b8f66486d3 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8782,47 +8782,41 @@ away.") (define-public python2-ipython-genutils (package-with-python2 python-ipython-genutils)) -(define-public python-ipyparallel - (package - (name "python-ipyparallel") - (version "6.2.4") - (source +;;; Variant used to break a cycle with python-ipykernel. +(define-public python-ipyparallel-bootstrap + (hidden-package + (package + (name "python-ipyparallel-bootstrap") + (version "6.2.4") + (source (origin (method url-fetch) (uri (pypi-uri "ipyparallel" version)) (sha256 (base32 "0rf0dbpxf5z82bw8lsjj45r3wdd4wc74anz4wiiaf2rbjqlb1ivn")))) - (build-system python-build-system) - (arguments - `(#:tests? #f ; RuntimeError: IO Loop failed to start - #:phases - (modify-phases %standard-phases - (add-before 'check 'prepare-for-tests - (lambda _ - (setenv "HOME" (getcwd)) - #t))))) - (propagated-inputs - (list python-dateutil - python-decorator - python-ipykernel - python-ipython - python-ipython-genutils - python-jupyter-client - python-pyzmq - python-tornado - python-traitlets)) - (native-inputs - (list python-ipython - python-mock - python-nose - python-pytest - python-pytest-cov - python-testpath)) - (home-page "https://ipython.org/") - (synopsis "Interactive Parallel Computing with IPython") - (description - "@code{ipyparallel} is a Python package and collection of CLI scripts for + (build-system python-build-system) + (arguments + (list + #:tests? #f + #:phases #~(modify-phases %standard-phases + ;; The python-ipykernel is normally propagated but is + ;; removed from this package to break the cycle. + (delete 'sanity-check)))) + (propagated-inputs + (list python-dateutil + python-decorator + ;; python-ipykernel is omitted here to avoid a cycle. + python-ipython + python-ipython-genutils + python-jupyter-client-bootstrap + python-pyzmq + python-tornado + python-traitlets)) + (home-page "https://ipython.org/") + (synopsis "Interactive Parallel Computing with IPython") + (description + "@code{ipyparallel} is a Python package and collection of CLI scripts for controlling clusters for Jupyter. @code{ipyparallel} contains the following CLI scripts: @enumerate @@ -8830,7 +8824,26 @@ CLI scripts: @item ipcontroller - start a scheduler @item ipengine - start an engine @end enumerate") - (license license:bsd-3))) + (license license:bsd-3)))) + +(define-public python-ipyparallel + (package + (inherit python-ipyparallel-bootstrap) + (name "python-ipyparallel") + (arguments (list #:tests? #t)) + (native-inputs + (list python-ipython + python-mock + python-nose + python-pytest + python-pytest-cov + python-testpath)) + (propagated-inputs + (modify-inputs (package-propagated-inputs python-ipyparallel-bootstrap) + (replace "python-jupyter-client-bootstrap" python-jupyter-client) + (append python-ipykernel))) + (properties (alist-delete 'hidden? (package-properties + python-ipyparallel-bootstrap))))) (define-public python-ipython-cluster-helper (package @@ -9119,10 +9132,16 @@ installing @code{kernelspec}s for use with Jupyter frontends.") (package (inherit parent) (name "python-ipykernel-bootstrap") + (arguments (list #:tests? #f + ;; The package should normally propagate ipykernel, + ;; left out here to break the cycle. + #:phases #~(modify-phases %standard-phases + (delete 'sanity-check)))) + (native-inputs '()) (propagated-inputs - `(("python-jupyter-client" ,python-jupyter-client-bootstrap) - ,@(fold alist-delete (package-propagated-inputs parent) - '("python-jupyter-client")))))))) + (modify-inputs (package-propagated-inputs parent) + (replace "python-jupyter-client" python-jupyter-client-bootstrap) + (append python-ipyparallel-bootstrap))))))) (define-public python-pari-jupyter (package -- cgit v1.2.3 From 1ca00ddbbe882db08df55e3694f958c068aa457d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 16:49:31 -0400 Subject: gnu: python-nest-asyncio: Update to 1.5.5. * gnu/packages/python-xyz.scm (python-nest-asyncio): Update to 1.5.5. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index b8f66486d3..5c1fcfb725 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -27874,14 +27874,14 @@ a text editor and easily understood and used by both programmers and non-program (define-public python-nest-asyncio (package (name "python-nest-asyncio") - (version "1.5.1") + (version "1.5.5") (source (origin (method url-fetch) (uri (pypi-uri "nest_asyncio" version)) (sha256 (base32 - "1anha29fcijminn5bh2icnx8x7nk39lna9wkc72262i12p2s3idg")))) + "0rbdw7lry66yj13hh4w63yzflnapdal1ffl237k8nsa2v4f2jhp4")))) (build-system python-build-system) (home-page "https://github.com/erdewit/nest_asyncio") (synopsis "Patch asyncio to allow nested event loops") -- cgit v1.2.3 From d54b8754fdba52d89aafaaf80b6c8e89bcea92bd Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 17:31:43 -0400 Subject: gnu: python-jupyter-core: Update to 4.10.0. * gnu/packages/python-xyz.scm (python-jupyter-core): Update to 4.10.0. [phases]: Delete trailing #t. {check}: Remove extraneous add-installed-pythonpath. Skip the test_argv0, test_path_priority and test_not_on_path tests. [propagated-inputs, native-inputs]: Fix indentation. --- gnu/packages/python-xyz.scm | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 5c1fcfb725..8bd7258f9e 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8959,26 +8959,30 @@ without using the configuration machinery.") (define-public python-jupyter-core (package (name "python-jupyter-core") - (version "4.7.1") + (version "4.10.0") (source (origin (method url-fetch) (uri (string-append (pypi-uri "jupyter_core" version))) (sha256 (base32 - "1d12j5hkff0xiax87pnhmzbsph3jqqzhz16h8xld7z2y4armq0kr")))) + "1v0s31rmwppdmww135hif03hy164j9kimirh24kxfcbvdfql9pm6")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - ; Some tests write to $HOME. + ;; Some tests write to $HOME. (setenv "HOME" "/tmp") - ; Some tests load the installed package. - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv")))) + (invoke "pytest" "-vv" + "-k" + (string-append + ;; XXX: These tests fail with "ModuleNotFoundError: No + ;; module named 'jupyter_core'". + "not test_argv0 and not test_path_priority " + "and not test_not_on_path"))))) (add-after 'unpack 'patch-testsuite (lambda _ ;; test_not_on_path() and test_path_priority() try to run a test @@ -8987,8 +8991,7 @@ without using the configuration machinery.") (("env = \\{'PATH': ''\\}") "env = {'PATH': '', 'PYTHONPATH': os.environ['GUIX_PYTHONPATH']}") (("env = \\{'PATH': str\\(b\\)\\}") - "env = {'PATH': str(b), 'PYTHONPATH': os.environ['GUIX_PYTHONPATH']}")) - #t)) + "env = {'PATH': str(b), 'PYTHONPATH': os.environ['GUIX_PYTHONPATH']}")))) ;; Migration is running whenever etc/jupyter exists, but the ;; Guix-managed directory will never contain any migratable IPython ;; config files and cannot be written to anyway, so just pretend we @@ -9000,10 +9003,8 @@ without using the configuration machinery.") (string-append (assoc-ref outputs "out") "/etc/jupyter/migrated"))))))) - (propagated-inputs - (list python-traitlets)) - (native-inputs - (list python-six python-pytest)) + (propagated-inputs (list python-traitlets)) + (native-inputs (list python-pytest)) ;; This package provides the `jupyter` binary and thus also exports the ;; search paths. (native-search-paths -- cgit v1.2.3 From f30bdda88f6103a004ff118d568950aa42d36ad3 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 17:33:51 -0400 Subject: gnu: python-jupyter-client: Update to 7.2.2. * gnu/packages/python-xyz.scm (python-jupyter-client-bootstrap): Make the base package definition, moving most fields. Update to 7.2.2. [propagated-inputs]: Add python-entrypoints and python-nest-asyncio. (python-jupyter-client): Inherit from python-jupyter-client-bootstrap, adjusting accordingly. [native-inputs]: Add python-pytest-asyncio. --- gnu/packages/python-xyz.scm | 120 +++++++++++++++++++++++--------------------- 1 file changed, 63 insertions(+), 57 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 8bd7258f9e..9ede07e505 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -9020,69 +9020,75 @@ without using the configuration machinery.") "Jupyter core is the base package on which Jupyter projects rely.") (license license:bsd-3))) -(define-public python-jupyter-client - (package - (name "python-jupyter-client") - (version "6.1.12") - (source - (origin - (method url-fetch) - (uri (pypi-uri "jupyter_client" version)) - (sha256 - (base32 - "10p7fcgvv9hvz9zical9wk68ks5ssak2ykbzx65wm1k1hk8a3g64")))) - (build-system python-build-system) - (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'set-tool-file-names - (lambda* (#:key inputs #:allow-other-keys) - (let ((iproute (assoc-ref inputs "iproute"))) +;; Bootstrap variant of jupyter-client, which breaks the loop between ipykernel +;; and jupyter-client by removing the former from its native-inputs and +;; disabling tests. +(define-public python-jupyter-client-bootstrap + (hidden-package + (package + (name "python-jupyter-client-bootstrap") + (version "7.2.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "jupyter_client" version)) + (sha256 + (base32 + "12pbp177bfb3710y1a5598mwn8ffhyzmpll67m0nmalb98savnwg")))) + (build-system python-build-system) + (arguments + (list + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'set-tool-file-names + (lambda* (#:key inputs #:allow-other-keys) (substitute* "jupyter_client/localinterfaces.py" (("'ip'") - (string-append "'" iproute "/sbin/ip'"))) - #t))) - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - ;; Some tests try to write to $HOME. - (setenv "HOME" "/tmp") - (invoke "pytest" "-vv"))))))) - (inputs - `(("iproute" ,iproute))) - (propagated-inputs - (list python-dateutil python-jupyter-core python-pyzmq - python-tornado-6 python-traitlets)) - (native-inputs - `(("python-pytest" ,python-pytest) - ("python-pytest-timeout" ,python-pytest-timeout) - ("python-async-generator" ,python-async-generator) - ("python-mock" ,python-mock) - ("python-msgpack" ,python-msgpack) - ("python-ipython" ,python-ipython) - ("python-ipykernel" ,python-ipykernel-bootstrap))) - (home-page "https://jupyter.org/") - (synopsis "Jupyter protocol implementation and client libraries") - (description - "The @code{jupyter_client} package contains the reference implementation + (format #f "'~a'" (search-input-file inputs "sbin/ip"))))))))) + (inputs (list iproute)) + (propagated-inputs + (list python-dateutil + python-entrypoints + python-jupyter-core + python-nest-asyncio + python-pyzmq + python-tornado-6 + python-traitlets)) + (home-page "https://jupyter.org/") + (synopsis "Jupyter protocol implementation and client libraries") + (description + "The @code{jupyter_client} package contains the reference implementation of the Jupyter protocol. It also provides client and kernel management APIs for working with kernels, and the @code{jupyter kernelspec} entrypoint for installing @code{kernelspec}s for use with Jupyter frontends.") - (license license:bsd-3))) + (license license:bsd-3)))) -;; Bootstrap variant of jupyter-client, which breaks the loop between ipykernel -;; and jupyter-client by removing the former from its native-inputs and -;; disabling tests. -(define-public python-jupyter-client-bootstrap - (let ((base python-jupyter-client)) - (hidden-package - (package - (inherit base) - (name "python-jupyter-client-bootstrap") - (arguments - `(#:tests? #f - ,@(package-arguments base))) - (native-inputs `()))))) +(define-public python-jupyter-client + (let ((base python-jupyter-client-bootstrap)) + (package + (inherit base) + (name "python-jupyter-client") + (arguments + (substitute-keyword-arguments (package-arguments base) + ((#:tests? _ #f) + #t) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Some tests try to write to $HOME. + (setenv "HOME" "/tmp") + (invoke "pytest" "-vv")))))))) + (native-inputs + (list python-pytest + python-pytest-asyncio + python-pytest-timeout + python-async-generator + python-ipython + python-ipykernel-bootstrap)) + (properties (alist-delete 'hidden? (package-properties base)))))) (define-public python-ipykernel (package -- cgit v1.2.3 From 53e179c752a7e0a289d845f1dc92883dd335e1f2 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 23:36:01 -0400 Subject: gnu: python-ipykernel: Update to 6.13.0. * gnu/packages/python-xyz.scm (python-ipykernel): Update to 6.13.0. [origin]: Fix indentation. [phases]: Use gexps. {check}: Invoke pytest via tini {set-python-file-name}: Adjust to use search-input-file. [propagated-inputs]: Add python-debugpy, python-matplotlib-inline and python-psutil. [native-inputs]{python-nose}: Delete. {python-ipyrallel-bootstrap}: New native input. {python-pytest}: Replace with... {python-pytest-bootstrap}: ... this. {python-pytest-timeout, tini}: New native inputs. --- gnu/packages/python-xyz.scm | 94 ++++++++++++++++++++++++++++++--------------- 1 file changed, 64 insertions(+), 30 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 9ede07e505..7055b58094 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -9093,42 +9093,76 @@ installing @code{kernelspec}s for use with Jupyter frontends.") (define-public python-ipykernel (package (name "python-ipykernel") - (version "5.5.3") + (version "6.13.0") (source (origin - (method url-fetch) - (uri (pypi-uri "ipykernel" version)) - (sha256 - (base32 "02f55cjkp5q64x7ikjxznbxwjpkdmfy237b9kg7dk1pxmzvy90m6")))) + (method url-fetch) + (uri (pypi-uri "ipykernel" version)) + (sha256 + (base32 "0q5yni8h08nadsn53f957p0pjsjhwl2b2lp1hqz3jn0854z2fa0f")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (setenv "HOME" "/tmp") - (invoke "pytest" "-v")))) - (add-after 'install 'set-python-file-name - (lambda* (#:key outputs #:allow-other-keys) - ;; Record the absolute file name of the 'python' executable in - ;; 'kernel.json'. - (let ((out (assoc-ref outputs "out"))) - (substitute* (string-append out "/share/jupyter" - "/kernels/python3/kernel.json") - (("\"python\"") - (string-append "\"" (which "python") "\""))) - #t)))))) - (propagated-inputs - (list python-ipython python-tornado-6 python-traitlets - ;; imported at runtime during connect - python-jupyter-client)) - (native-inputs - (list python-flaky python-nose python-pytest)) + (list + #:imported-modules `(,@%python-build-system-modules + (guix build syscalls)) + #:modules '((guix build python-build-system) + (guix build syscalls) + (guix build utils) + (ice-9 match)) + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (match (primitive-fork) + (0 ;child process + (set-child-subreaper!) + ;; XXX: Tini provides proper PID1-like signal handling that + ;; reaps zombie processes, necessary for the + ;; 'test_shutdown_subprocesses' test to pass. + + ;; TODO: Complete https://issues.guix.gnu.org/30948. + (setenv "HOME" "/tmp") + (execlp "tini" "--" "pytest" "-vv")) + (pid + (match (waitpid pid) + ((_ . status) + (unless (zero? status) + (error "`pytest' exited with status" + status))))))))) + (add-after 'install 'set-python-file-name + (lambda* (#:key inputs #:allow-other-keys) + ;; Record the absolute file name of the 'python' executable in + ;; 'kernel.json'. + (substitute* (string-append #$output "/share/jupyter" + "/kernels/python3/kernel.json") + (("\"python\"") + (format #f "~s" (search-input-file inputs + "/bin/python3"))))))))) + (propagated-inputs + (list python-debugpy + python-ipython + python-jupyter-client ;imported at runtime during connect + python-matplotlib-inline + ;;python-nest-asyncio + ;;python-packaging + python-psutil + python-tornado-6 + python-traitlets)) + (inputs (list python)) ;for cross compilation + (native-inputs + (list python-flaky + python-ipyparallel-bootstrap + ;; XXX: Our Pytest package captures its native inputs in its + ;; wrapper script (such as python-nose), which is used in the code + ;; and causes deprecation warnings. Using the bootstrap variant + ;; avoids that. + python-pytest-bootstrap + python-pytest-timeout + tini)) (home-page "https://ipython.org") (synopsis "IPython Kernel for Jupyter") - (description - "This package provides the IPython kernel for Jupyter.") + (description "This package provides the IPython kernel for Jupyter.") (license license:bsd-3))) ;; Bootstrap variant of ipykernel, which uses the bootstrap jupyter-client to -- cgit v1.2.3 From 8194b36ddf34fdae110c7feb5b3c7c3a97c6e42a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 12 Apr 2022 23:53:54 -0400 Subject: gnu: Add python-pytest-tornado. * gnu/packages/python-check.scm (python-pytest-tornado): New variable. --- gnu/packages/python-check.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 5469200afc..465c425a79 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -1420,6 +1420,36 @@ also ensuring that the notebooks are running without errors.") "This package provides a pytest plugin for testing console scripts.") (license license:expat))) +(define-public python-pytest-tornado + (package + (name "python-pytest-tornado") + (version "0.8.1") + (source (origin + (method git-fetch) ;no tests in pypi archive + (uri (git-reference + (url "https://github.com/eugeniy/pytest-tornado") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "05hgq1m9g35kpc01im7ci1wd85xi1rdxnyms9izjg65c9976zn6x")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (propagated-inputs (list python-pytest python-setuptools python-tornado)) + (home-page "https://github.com/eugeniy/pytest-tornado") + (synopsis "Pytest plugin to ease testing tornado applications") + (description + "This package provides a py.test plugin providing fixtures and markers to +simplify testing of asynchronous tornado applications.") + (license license:asl2.0))) + (define-public python-pytest-tornasync (package (name "python-pytest-tornasync") -- cgit v1.2.3 From 0f446f1bc4cfc0752faa49efcd11914d7b4e977c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 00:35:21 -0400 Subject: gnu: python-ipyparallel: Update to 8.2.1. * gnu/packages/python-xyz.scm (python-ipyparallel-bootstrap): Update to 8.2.1. [propagated-inputs]: Add python-entrypoints, python-psutil and python-tqdm. Update python-tornado to version 6. (python-ipyparallel)[phases]{check}: Override phase. [native-inputs]: Remove python-mock and python-nose. Add python-pytest-asyncio and python-pytest-tornado. --- gnu/packages/python-xyz.scm | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 7055b58094..b573a7cd15 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -8787,14 +8787,14 @@ away.") (hidden-package (package (name "python-ipyparallel-bootstrap") - (version "6.2.4") + (version "8.2.1") (source (origin (method url-fetch) (uri (pypi-uri "ipyparallel" version)) (sha256 (base32 - "0rf0dbpxf5z82bw8lsjj45r3wdd4wc74anz4wiiaf2rbjqlb1ivn")))) + "0wiwfd7870zbmczzn96jqxxjf2zcbcaxnsl1ddn8hspwa8y4frzj")))) (build-system python-build-system) (arguments (list @@ -8806,12 +8806,14 @@ away.") (propagated-inputs (list python-dateutil python-decorator - ;; python-ipykernel is omitted here to avoid a cycle. + python-entrypoints python-ipython - python-ipython-genutils + ;; python-ipykernel is omitted here to break a cycle. python-jupyter-client-bootstrap + python-psutil python-pyzmq - python-tornado + python-tornado-6 + python-tqdm python-traitlets)) (home-page "https://ipython.org/") (synopsis "Interactive Parallel Computing with IPython") @@ -8830,13 +8832,19 @@ CLI scripts: (package (inherit python-ipyparallel-bootstrap) (name "python-ipyparallel") - (arguments (list #:tests? #t)) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda _ + (invoke "pytest" "-vv")))))) (native-inputs (list python-ipython - python-mock - python-nose python-pytest + python-pytest-asyncio python-pytest-cov + python-pytest-tornado python-testpath)) (propagated-inputs (modify-inputs (package-propagated-inputs python-ipyparallel-bootstrap) -- cgit v1.2.3 From abb7617f204fe800cb19233101cb7334bfd1d0ff Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 10:36:21 -0400 Subject: gnu: python-anyio: Replace python-pytest-trio with python-trio. * gnu/packages/python-xyz.scm (python-anyio) [phases]{check}: Remove extraneous add-installed-pythonpath call. Expound comment about IPv6 issues. [native-inputs]: Use regular python-pytest. Replace python-pytest-trio by python-trio. --- gnu/packages/python-xyz.scm | 76 ++++++++++++++++++++++----------------------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index b573a7cd15..60c2e0e3cd 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -25610,43 +25610,44 @@ standard error channel (stderr) in your program.") `(#:phases (modify-phases %standard-phases (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv" "-p" "no:asyncio" - "-m" "not network" - "-k" - (string-append - "not test_is_block_device" - - ;; These fail because of network (or specifically - ;; IPv6 network) access. - " and not test_accept" - " and not test_accept_after_close" - " and not test_close_during_receive" - " and not test_close_from_other_task" - " and not test_concurrent_receive" - " and not test_concurrent_send" - " and not test_connect_tcp_with_tls" - " and not test_connect_tcp_with_tls_cert_check_fail" - " and not test_connection_refused" - " and not test_extra_attributes" - " and not test_getaddrinfo" - " and not test_getnameinfo" - " and not test_happy_eyeballs" - " and not test_iterate" - " and not test_receive_after_close" - " and not test_receive_timeout" - " and not test_reuse_port" - " and not test_run_process" - " and not test_send_after_close" - " and not test_send_after_eof" - " and not test_send_after_peer_closed" - " and not test_send_eof" - " and not test_send_large_buffer" - " and not test_send_receive" - " and not test_socket_options" - " and not test_unretrieved_future_exception_server_crash")))))))) + (invoke + "pytest" "-vv" "-p" "no:asyncio" + "-m" "not network" + "-k" + (string-append + "not test_is_block_device" + + ;; These fail because of network (or specifically IPv6 + ;; network) access (see: + ;; https://github.com/agronholm/anyio/issues/417). + " and not test_accept" + " and not test_accept_after_close" + " and not test_close_during_receive" + " and not test_close_from_other_task" + " and not test_concurrent_receive" + " and not test_concurrent_send" + " and not test_connect_tcp_with_tls" + " and not test_connect_tcp_with_tls_cert_check_fail" + " and not test_connection_refused" + " and not test_extra_attributes" + " and not test_getaddrinfo" + " and not test_getnameinfo" + " and not test_happy_eyeballs" + " and not test_iterate" + " and not test_receive_after_close" + " and not test_receive_timeout" + " and not test_reuse_port" + " and not test_run_process" + " and not test_send_after_close" + " and not test_send_after_eof" + " and not test_send_after_peer_closed" + " and not test_send_eof" + " and not test_send_large_buffer" + " and not test_send_receive" + " and not test_socket_options" + " and not test_unretrieved_future_exception_server_crash")))))))) (propagated-inputs (list python-contextvars python-dataclasses @@ -25658,9 +25659,8 @@ standard error channel (stderr) in your program.") python-coverage python-hypothesis python-mock - python-pytest-6 + python-pytest python-pytest-mock - python-pytest-trio python-setuptools-scm python-trio python-trustme -- cgit v1.2.3 From 4bc0d5300bcf07aa7ff7049350262e6d65a85ff2 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 11:19:59 -0400 Subject: gnu: python-nbclient: Update to 0.6.0. * gnu/packages/jupyter.scm (python-nbclient): Update to 0.6.0. [tests?]: Update comment. [propagated-inputs]: Remove python-async-generator. [native-inputs]: Delete field. [description]: Fix spacing. --- gnu/packages/jupyter.scm | 37 +++++++++---------------------------- 1 file changed, 9 insertions(+), 28 deletions(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index d517712bcb..175c12496a 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -342,46 +342,27 @@ are interactive HTML widgets for Jupyter notebooks and the IPython kernel.") (define-public python-nbclient (package (name "python-nbclient") - (version "0.5.3") + (version "0.6.0") (source (origin (method url-fetch) (uri (pypi-uri "nbclient" version)) (sha256 (base32 - "172q4r6mq0lg394di0pc6ipvniy14jg38wkdsj48r366609jf5yv")))) + "0cbhs8l8ma5nzm1i4484gsrb7189m1lmniashp929pxsqq1s929z")))) (build-system python-build-system) - ;; Tests require a kernel via python-ipykernel, and also tools from - ;; nbconvert. + ;; Tests require tools from nbconvert, which would introduces a cycle. (arguments '(#:tests? #false)) (propagated-inputs - (list python-async-generator python-jupyter-client python-nbformat - python-nest-asyncio python-traitlets)) - (native-inputs - (list python-black - python-bumpversion - python-check-manifest - python-codecov - python-coverage - python-flake8 - ;; ("python-ipykernel" ,python-ipykernel) - ;; ("python-ipython" ,python-ipython) - ;; ("python-ipywidgets" ,python-ipywidgets) - python-mypy - python-pip - python-pytest - python-pytest-cov - python-setuptools - python-testpath - python-tox - python-twine - python-wheel - python-xmltodict)) + (list python-jupyter-client + python-nbformat + python-nest-asyncio + python-traitlets)) (home-page "https://jupyter.org") (synopsis "Client library for executing notebooks") (description - "This package provides a client library for executing notebooks. Formerly -nbconvert's @code{ExecutePreprocessor.}") + "This package provides a client library for executing notebooks. +It was formerly known as nbconvert's @code{ExecutePreprocessor.}") (license license:bsd-3))) (define-public repo2docker -- cgit v1.2.3 From 10d69f20be51c25deebb8086a6391c11b2c29a5b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 11:33:51 -0400 Subject: gnu: python-bleach: Update to 5.0.0. * gnu/packages/python-xyz.scm (python-bleach): Update to 5.0.0. [propagated-inputs]: Remove python-packaging and python-six. Add python-tinycss2. --- gnu/packages/python-xyz.scm | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 60c2e0e3cd..905086f133 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -13441,23 +13441,21 @@ systems, as a command line tool, and as a Python library.") (define-public python-bleach (package (name "python-bleach") - (version "4.1.0") + (version "5.0.0") (source (origin (method url-fetch) (uri (pypi-uri "bleach" version)) (sha256 - (base32 "1nkibazmw1ry4cfxs9qrkkidxdf2z1hh1b20xq1ahqdsgsrxh009")))) + (base32 "0rc5avysbsl3w3i2qvb6522263zhwlvf50w0ifs8776w9c2wrmn6")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? (invoke "pytest" "-vv"))))))) - (propagated-inputs - (list python-packaging python-six python-webencodings)) - (native-inputs - (list python-pytest)) + (propagated-inputs (list python-tinycss2 python-webencodings)) + (native-inputs (list python-pytest)) (home-page "https://github.com/mozilla/bleach") (synopsis "Whitelist-based HTML-sanitizing tool") (description "Bleach is an easy whitelist-based HTML-sanitizing tool.") -- cgit v1.2.3 From 9dd2e1bb9207ff6e31be7d6264687e0a16acc832 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 13:44:22 -0400 Subject: gnu: Add texlive-unicode-math. * gnu/packages/tex.scm (texlive-unicode-math): New variable. --- gnu/packages/tex.scm | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 6fc1d4fdbf..527095911c 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -10546,6 +10546,57 @@ on the page, and which specifies where it is to be placed. The environment is accompanied by various configuration commands.") (license license:lppl))) +(define-public texlive-unicode-math + (package + (inherit (simple-texlive-package + "texlive-unicode-math" + (list "source/latex/unicode-math/" + "doc/latex/unicode-math/" + "tex/latex/unicode-math/unicode-math-table.tex") + (base32 "1j3041dcm7wqj0x26rxm9bb7q4xa1rqsqynqdb6cbjk3jmfvskxn"))) + (outputs '("out" "doc")) + (arguments + (list + #:tex-directory "latex/unicode-math" + #:tex-format "xelatex" + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'copy-files + ;; The documentation isn't built. + (lambda* (#:key outputs tex-directory #:allow-other-keys) + (let ((doc (assoc-ref outputs "doc")) + (tex (string-append #$output "/share/texmf-dist/tex/" + tex-directory))) + ;; Install documentation. + (mkdir-p (string-append doc "/share/texmf-dist/doc" )) + (copy-recursively "doc" doc) + ;; Install unicode-math-table.tex, which is not + ;; built. + (install-file "tex/latex/unicode-math/unicode-math-table.tex" + tex)))) + (add-after 'copy-files 'chdir + (lambda* (#:key tex-directory #:allow-other-keys) + (chdir (string-append "source/" tex-directory))))))) + (home-page "https://ctan.org/pkg/unicode-math") + (synopsis "Unicode mathematics support for XeTeX and LuaTeX") + (description "This package will provide a complete implementation of +Unicode maths for XeLaTeX and LuaLaTeX. Unicode maths is currently supported +by the following fonts: +@itemize +@item Latin Modern Math +@item TeX Gyre Bonum Math +@item TeX Gyre Pagella Math +@item TeX Gyre Schola Math +@item TeX Gyre Termes Math +@item DejaVu Math TeX Gyre +@item Asana-Math +@item STIX +@item XITS Math +@item Libertinus Math +@item Fira Math +@end itemize") + (license license:lppl1.3c+))) + (define-public texlive-xifthen (package (inherit (simple-texlive-package -- cgit v1.2.3 From 15d4664f87359288f9e0151bd792ce35747d94aa Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 15:32:54 -0400 Subject: gnu: Add texlive-lm-math. * gnu/packages/tex.scm (texlive-lm-math): New variable. --- gnu/packages/tex.scm | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 527095911c..a861b40950 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -1117,6 +1117,22 @@ Computers & Typesetting series.") (define-deprecated-package texlive-fonts-lm texlive-lm) +(define-public texlive-lm-math + (package + (inherit (simple-texlive-package + "texlive-lm-math" + (list "/doc/fonts/lm-math/" + "/fonts/opentype/public/lm-math/") + (base32 + "0gqdk8x3r1iz4n8j6r3pcqbwalxvkihayvmjfq4iv6hwb0pvys8z") + #:trivial? #t)) + (home-page "http://www.gust.org.pl/projects/e-foundry/latin-modern") + (synopsis "OpenType maths fonts for Latin Modern") + (description "Latin Modern Math is a maths companion for the Latin Modern +family of fonts, in OpenType format. For use with LuaLaTeX or XeLaTeX, +support is available from the @code{unicode-math} package.") + (license license:gfl1.0))) + (define-public texlive-knuth-lib (let ((template (simple-texlive-package "texlive-knuth-lib" -- cgit v1.2.3 From 724731de4c3e8445a347d85891e96c0f341bcc3e Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 15:50:36 -0400 Subject: gnu: python-nbconvert: Update to 6.5.0. * gnu/packages/python-xyz.scm (python-nbconvert): Update to 6.5.0. [arguments]: Use gexps. [phases]{fix-paths-and-tests}: Rename to... {fix-paths}: ... this. Find inputs via search-input-file. Patch inskcape file name. Disable tests in... {check}: ... this phase instead. Do not set HOME. Execute installed test suite. Run tests in parallel. Disable and not test_execute_widgets_from_nbconvert and test_execute_multiple_notebooks tests. [inputs]: Add inkscape. [native-inputs]: Delete python-pytest-cov and python-pytest-dependency. Use new style. [propagated-inputs]: Add python-beautifulsoup4. Reduce the texlive packages part of the generated updmap.cfg input, moving them to regular propagated inputs. Add texlive-unicode-math and texlive-lm-math. --- gnu/packages/python-xyz.scm | 160 +++++++++++++++++++++++--------------------- 1 file changed, 82 insertions(+), 78 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 905086f133..8d82b2e5d0 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -174,6 +174,7 @@ #:use-module (gnu packages gtk) #:use-module (gnu packages haskell-xyz) #:use-module (gnu packages icu4c) + #:use-module (gnu packages inkscape) #:use-module (gnu packages image) #:use-module (gnu packages imagemagick) #:use-module (gnu packages jupyter) @@ -13587,70 +13588,71 @@ time.") (define-public python-nbconvert (package (name "python-nbconvert") - (version "6.0.7") + (version "6.5.0") (source (origin (method url-fetch) (uri (pypi-uri "nbconvert" version)) (sha256 (base32 - "00lhqaxn481qvk2w5568asqlsnvrw2fm61p1vssx3m7vdnl17g6b")))) + "17g9xq4za7vvzml6l6d8zrzknhxsvgx02hymmsw9d1dygbi4cgi2")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-paths-and-tests - (lambda _ - ;; Use pandoc binary from input. - (substitute* "nbconvert/utils/pandoc.py" - (("'pandoc'") (string-append "'" (which "pandoc") "'"))) - ;; Same for LaTeX. - (substitute* "nbconvert/exporters/pdf.py" - (("\"xelatex\"") (string-append "\"" (which "xelatex") "\"")) - (("\"bibtex\"") (string-append "\"" (which "bibtex") "\""))) - ;; Make sure tests are not skipped. - (substitute* (find-files "." "test_.+\\.py$") - (("@onlyif_cmds_exist\\(('(pandoc|xelatex)'(, )?)+\\)") "")) - ;; Pandoc is never missing, disable test. - (substitute* "nbconvert/utils/tests/test_pandoc.py" - (("import os" all) (string-append all "\nimport pytest")) - (("(.+)(def test_pandoc_available)" all indent def) - (string-append indent "@pytest.mark.skip('disabled by guix')\n" - indent def))) - ;; Not installing pyppeteer, delete test. - (delete-file "nbconvert/exporters/tests/test_webpdf.py") - (substitute* "nbconvert/tests/test_nbconvertapp.py" - (("(.+)(def test_webpdf_with_chromium)" all indent def) - (string-append indent "@pytest.mark.skip('disabled by guix')\n" - indent def))))) - (replace 'check - (lambda* (#:key tests? inputs outputs #:allow-other-keys) - (when tests? - ;; Some tests invoke the installed nbconvert binary. - (add-installed-pythonpath inputs outputs) - ;; Tests depend on templates installed to output. - (setenv "JUPYTER_PATH" - (string-append - (assoc-ref outputs "out") - "/share/jupyter:" - (getenv "JUPYTER_PATH"))) - ;; Some tests need HOME - (setenv "HOME" "/tmp") - (invoke "pytest" "-vv"))))))) + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-paths + (lambda* (#:key inputs #:allow-other-keys) + ;; Use pandoc binary from input. + (substitute* "nbconvert/utils/pandoc.py" + (("'pandoc'") + (format #f "~s" (search-input-file inputs "bin/pandoc")))) + ;; Same for LaTeX. + (substitute* "nbconvert/exporters/pdf.py" + (("\"xelatex\"") + (format #f "~s" (search-input-file inputs "bin/xelatex"))) + (("\"bibtex\"") + (format #f "~s" (search-input-file inputs "bin/bibtex")))) + ;; Likewise for Inkscape. + (substitute* "nbconvert/preprocessors/svg2pdf.py" + (("inkscape_path = which\\(\"inkscape\")") + (format #f "inkscape_path = ~s" + (search-input-file inputs "bin/inkscape")))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + ;; Tests depend on templates installed to output. + (setenv "JUPYTER_PATH" + (string-append #$output "/share/jupyter:" + (getenv "JUPYTER_PATH"))) + ;; Step outside of the source directory to avoid having both + ;; the installed package *and* the package from the source on + ;; Python's path. + (with-directory-excursion "/tmp" + (invoke "pytest" "--pyargs" "nbconvert" + "-vv" "-n" (number->string (parallel-job-count)) + "-k" + (string-append + ;; These tests require pyppeteer, not yet + ;; available in Guix. + "not test_webpdf_with_chromium " + "and not test_webpdf.py " + ;; These tests require ipywidgets, which would + ;; introduce a dependency cycle. + "and not test_execute_widgets_from_nbconvert " + "and not test_execute_multiple_notebooks "))))))))) (inputs - (list pandoc - ;; XXX: Disabled, needs substitute*. - ;;("inkscape" ,inkscape) - )) - (native-inputs - `(("python-ipykernel" ,python-ipykernel) - ;; XXX: Disabled, not in guix. - ;;("python-pyppeteer" ,python-pyppeteer) - ("python-pytest" ,python-pytest) - ("python-pytest-cov" ,python-pytest-cov) - ("python-pytest-dependency" ,python-pytest-dependency))) + (list inkscape pandoc)) + (native-inputs + (list python-ipykernel + ;; Adding ipywidgets would create a cycle. + ;;python-ipywidgets + ;;python-pyppeteer ;TODO: package me + python-pytest + python-pytest-xdist)) (propagated-inputs - (list python-bleach + (list python-beautifulsoup4 + python-bleach python-defusedxml python-entrypoints python-jinja2 @@ -13666,37 +13668,39 @@ time.") ;; Required, even if [serve] is not used. python-tornado-6 ;; Required at runtime for `jupyter nbconvert --to=pdf`. - (texlive-updmap.cfg (list texlive-adjustbox - texlive-amsfonts - texlive-booktabs - texlive-caption - texlive-enumitem + texlive-adjustbox + texlive-booktabs + texlive-caption + texlive-enumitem + texlive-fontspec + texlive-generic-iftex + texlive-grffile + texlive-hyperref + texlive-latex-fancyvrb + texlive-latex-float + texlive-latex-geometry + texlive-latex-jknapltx + texlive-latex-ms + texlive-latex-parskip + texlive-latex-trimspaces + texlive-latex-upquote + texlive-stringenc + texlive-tcolorbox + texlive-titling + texlive-tools + texlive-ulem + texlive-unicode-math + texlive-xcolor + (texlive-updmap.cfg (list texlive-amsfonts texlive-eurosym texlive-fonts-rsfs - texlive-generic-iftex texlive-jknappen texlive-latex-amsmath - texlive-latex-fancyvrb - texlive-latex-float - texlive-fontspec - texlive-latex-geometry - texlive-grffile - texlive-hyperref - texlive-latex-jknapltx - texlive-latex-ms - texlive-oberdiek - texlive-latex-parskip - texlive-latex-trimspaces - texlive-latex-upquote texlive-latex-ucs texlive-lm + texlive-lm-math texlive-mathpazo - texlive-stringenc - texlive-tcolorbox - texlive-titling - texlive-tools - texlive-ulem - texlive-xcolor + texlive-oberdiek texlive-zapfding)))) (home-page "https://jupyter.org") (synopsis "Converting Jupyter Notebooks") -- cgit v1.2.3 From 7d79d30e3a6911468a2eda0ba1e4d4494b411c01 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 16:23:39 -0400 Subject: gnu: Add python-jupyter-server-mathjax. * gnu/packages/jupyter.scm (python-jupyter-server-mathjax): New variable. --- gnu/packages/jupyter.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index 175c12496a..18efc9bb8b 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -339,6 +339,39 @@ endpoints—to Jupyter web applications.") are interactive HTML widgets for Jupyter notebooks and the IPython kernel.") (license license:bsd-3))) +(define-public python-jupyter-server-mathjax + (package + (name "python-jupyter-server-mathjax") + (version "0.2.5") + (source + (origin + (method url-fetch) + (uri (pypi-uri "jupyter_server_mathjax" version)) + (sha256 + (base32 "1cz7grhj9jih9mgw4xk7a4bqy1fwlb1jsawh6ykxnvpydn76rnb4")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (with-directory-excursion "/tmp" + (invoke "pytest" "-vv" + "--pyargs" "jupyter_server_mathjax")))))))) + (propagated-inputs (list python-jupyter-server)) + (native-inputs + (list python-jupyter-server + python-jupyter-packaging + python-pytest + python-pytest-tornasync)) + (home-page "https://jupyter.org") + (synopsis "Jupyter Server extension for serving Mathjax") + (description "This package provides a Jupyter Server extension for serving +Mathjax, the JavaScript display engine for mathematics.") + (license license:bsd-3))) + (define-public python-nbclient (package (name "python-nbclient") -- cgit v1.2.3 From d72c53fa43a02cf7f9ddb975de01cb8514a6f806 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 16:40:00 -0400 Subject: gnu: python-nbval: Fix build. * gnu/packages/python-check.scm (python-nbval) [phases]: Delete trailing #t. {check}: Skip newly failing 'test_conf_ignore_stderr' test. Remove INPUTS and OUTPUTS arguments. Add TESTS? and honor it. --- gnu/packages/python-check.scm | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 465c425a79..41b73172b0 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -1342,17 +1342,21 @@ new fixtures, new methods and new comparison objects.") (lambda _ ;; This test fails because of a mismatch in the output of LaTeX ;; equation environments. Seems OK to skip. - (delete-file "tests/ipynb-test-samples/test-latex-pass-correctouput.ipynb") - #t)) + (delete-file + "tests/ipynb-test-samples/test-latex-pass-correctouput.ipynb"))) (replace 'check - (lambda* (#:key inputs outputs #:allow-other-keys) - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv" "-k" - (string-append - ;; This only works with Pytest < 5. - "not nbdime_reporter" - ;; https://github.com/computationalmodelling/nbval/pull/148. - " and not test_timeouts"))))))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "-k" + (string-append + ;; This only works with Pytest < 5. + "not nbdime_reporter" + ;; https://github.com/computationalmodelling/nbval/pull/148. + " and not test_timeouts" + ;; It seems the output format has changed; the following + ;; test fails with "Unexpected output fields from + ;; running code: {'text/plain'}". + " and not test_conf_ignore_stderr ")))))))) (native-inputs (list python-pytest python-pytest-cov python-sympy)) (propagated-inputs -- cgit v1.2.3 From 1e76c82ca6c59b96210ed72726ec9c9179db409d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 21:35:02 -0400 Subject: gnu: python-send2trash: Update to 1.8.0 and update home page. * gnu/packages/python-xyz.scm (python-send2trash): Update to 1.8.0. [source]: Update Git URL. [phases]{pre-check}: Set HOME to /tmp directly. {check}: Override phase. [native-inputs]: Add python-pytest. [properties]: Delete field. (python2-send2trash): Delete variable. [home-page]: Update URL. --- gnu/packages/python-xyz.scm | 31 ++++++++++--------------------- 1 file changed, 10 insertions(+), 21 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 8d82b2e5d0..2bcb51a651 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -22100,46 +22100,35 @@ systems policies.") (define-public python-send2trash (package (name "python-send2trash") - (version "1.5.0") + (version "1.8.0") (source (origin (method git-fetch) ;; Source tarball on PyPI doesn't include tests. (uri (git-reference - (url "https://github.com/hsoft/send2trash") + (url "https://github.com/arsenetar/send2trash") (commit version))) (file-name (git-file-name name version)) (sha256 (base32 - "1c76zldhw2ay7q7r00nnzcampjz9lkqfcbzqpm0iqp5i6bmmv30v")))) + "1k7dfypaaq4f36fbciaasv72j6wgjihw8d88axmz9c329bz8v5qx")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (add-before 'check 'pre-check (lambda _ - (mkdir-p "/tmp/foo") - (setenv "HOME" "/tmp/foo") - #t))))) - (home-page "https://github.com/hsoft/send2trash") + (setenv "HOME" "/tmp"))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-pytest)) + (home-page "https://github.com/arsenetar/send2trash") (synopsis "Send files to the user's @file{~/Trash} directory") (description "This package provides a Python library to send files to the user's @file{~/Trash} directory.") - (properties `((python2-variant . ,(delay python2-send2trash)))) (license license:bsd-3))) -(define-public python2-send2trash - (let ((base (package-with-python2 - (strip-python2-variant python-send2trash)))) - (package/inherit base - (arguments - (substitute-keyword-arguments (package-arguments python-send2trash) - ((#:phases phases) - `(modify-phases ,phases - (add-before 'check 'setenv - (lambda _ - (setenv "GUIX_PYTHONPATH" - (string-append (getcwd) ":" (getenv "GUIX_PYTHONPATH")))))))))))) - (define-public python-pyfavicon (package (name "python-pyfavicon") -- cgit v1.2.3 From 73728b3942fc29aadd0cc6c8935a6704cf646858 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 21:53:25 -0400 Subject: gnu: python-notebook: Update to 6.4.10. * gnu/packages/python-xyz.scm (python-notebook): Update to 6.4.10. [phases]{check}: Remove add-installed-pythonpath. [native-inputs]: python-nest-asyncio. --- gnu/packages/python-xyz.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 2bcb51a651..ca293f5f54 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -13722,13 +13722,13 @@ convert an @code{.ipynb} notebook file into various static formats including: (define-public python-notebook (package (name "python-notebook") - (version "6.3.0") + (version "6.4.10") (source (origin (method url-fetch) (uri (pypi-uri "notebook" version)) (sha256 (base32 - "0zfwr87ndjzmdp9adpc9lby1hdqdkjp2q7c9vff3wiw1dj6kkjfb")))) + "03p976xq1l9xf4djwk0snmywd0zck3i6gjngxsl874i8qrmsf214")))) (build-system python-build-system) (arguments `(#:phases @@ -13747,10 +13747,9 @@ convert an @code{.ipynb} notebook file into various static formats including: (setenv "HOME" (getcwd)))) (replace 'check (lambda* (#:key tests? inputs outputs #:allow-other-keys) - ;; These tests require a browser + ;; These tests require a browser. (delete-file-recursively "notebook/tests/selenium") (when tests? - (add-installed-pythonpath inputs outputs) ;; Interferes with test expectations. (unsetenv "JUPYTER_CONFIG_PATH") ;; Some tests do not expect all files to be installed in the @@ -13767,6 +13766,7 @@ convert an @code{.ipynb} notebook file into various static formats including: python-jinja2 python-jupyter-client python-jupyter-core + python-nest-asyncio python-nbconvert python-nbformat python-prometheus-client -- cgit v1.2.3 From b6021d38ab215a9de25df3d4131e5cc681e22895 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 13 Apr 2022 22:34:05 -0400 Subject: gnu: Add python-nbdime. * gnu/packages/jupyter.scm (python-nbdime): New variable. --- gnu/packages/jupyter.scm | 57 +++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 56 insertions(+), 1 deletion(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index 18efc9bb8b..9bda6e23bd 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2021 Ricardo Wurmus ;;; Copyright © 2021 Hugo Lecomte ;;; Copyright © 2022 Marius Bakke +;;; Copyright © 2022 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -30,6 +31,7 @@ #:use-module (gnu packages bash) #:use-module (gnu packages check) #:use-module (gnu packages cpp) + #:use-module (gnu packages docker) #:use-module (gnu packages linux) #:use-module (gnu packages monitoring) #:use-module (gnu packages networking) @@ -47,7 +49,7 @@ #:use-module (gnu packages tls) #:use-module (gnu packages sphinx) #:use-module (gnu packages serialization) - #:use-module (gnu packages docker)) + #:use-module (gnu packages version-control)) (define-public python-jupyter-protocol (package @@ -398,6 +400,59 @@ Mathjax, the JavaScript display engine for mathematics.") It was formerly known as nbconvert's @code{ExecutePreprocessor.}") (license license:bsd-3))) +(define-public python-nbdime + (package + (name "python-nbdime") + (version "3.1.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "nbdime" version)) + (sha256 + (base32 "12v41lricbg713lzlfcx0cilfm9spndaanhp39q4ydvix4h76xk7")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'remove-ipython-genutils + ;; TODO: Remove when a release newer than 3.1.1 is made. + (lambda _ + (substitute* "nbdime/config.py" + (("from ipython_genutils import py3compat") + "") + (("py3compat\\.getcwd") + "os.getcwd"))))))) + (propagated-inputs + (list python-colorama + python-gitpython + python-jinja2 + python-jupyter-server + python-jupyter-server-mathjax + python-nbformat + python-pygments + python-requests + python-tornado-6)) + (native-inputs + (list python-jupyter-server + python-mock + python-notebook + python-pytest + python-pytest-tornado + python-tabulate)) + (home-page "https://nbdime.readthedocs.io") + (synopsis "Diff tools for Jupyter Notebooks") + (description "@code{nbdime} provides tools for diffing and merging of +Jupyter Notebooks. It includes the following commands: +@table @command +@item nbdiff compare notebooks in a terminal-friendly way +@item nbmerge three-way merge of notebooks with automatic conflict resolution +@item nbdiff-web rich rendered diff of notebooks +@item nbmerge-web web-based three-way merge tool for notebooks +nbshow present a single notebook in a terminal-friendly way +@end table") + (license license:bsd-3))) + (define-public repo2docker (package (name "repo2docker") -- cgit v1.2.3 From 7e679ea7f71abf233512c30cf2a951dfe3f03f6b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 14 Apr 2022 00:35:58 -0400 Subject: gnu: Add python-docrepr. * gnu/packages/documentation.scm (python-docrepr): New variable. --- gnu/packages/documentation.scm | 57 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/gnu/packages/documentation.scm b/gnu/packages/documentation.scm index 6a0d8e8f2e..9f87e67043 100644 --- a/gnu/packages/documentation.scm +++ b/gnu/packages/documentation.scm @@ -11,6 +11,7 @@ ;;; Copyright © 2020 Ricardo Wurmus ;;; Copyright © 2020, 2021 Michael Rohleder ;;; Copyright © 2021 Marius Bakke +;;; Copyright © 2022 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -31,9 +32,11 @@ #:use-module (guix licenses) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (guix build-system gnu) #:use-module (guix build-system cmake) + #:use-module (guix build-system python) #:use-module (guix build-system qt) #:use-module (guix deprecation) #:use-module (gnu packages) @@ -41,7 +44,9 @@ #:use-module (gnu packages backup) #:use-module (gnu packages base) #:use-module (gnu packages bash) + #:use-module (gnu packages check) #:use-module (gnu packages python) + #:use-module (gnu packages python-xyz) #:use-module (gnu packages bison) #:use-module (gnu packages kde-frameworks) #:use-module (gnu packages docbook) @@ -53,6 +58,7 @@ #:use-module (gnu packages pkg-config) #:use-module (gnu packages qt) #:use-module (gnu packages sqlite) + #:use-module (gnu packages sphinx) #:use-module (gnu packages xml) #:use-module (gnu packages xorg)) @@ -256,6 +262,57 @@ browsing. The documentation is extracted directly from the C/C++/IDL source or Java class files.") (license gpl2+))) +(define-public python-docrepr + (package + (name "python-docrepr") + (version "0.2.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/spyder-ide/docrepr") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1ma5gwy93m1djd3zdlnqfrwhgr8ic1qbsz5kkrb9f987ax40lfkd")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-sources + (lambda _ + ;; XXX: This fixes an issue where shutil.copytree would fail + ;; merging directories with same files copied by Sphinx from the + ;; store (hence read-only, throwing a Permission denied error). + ;; In the case this happens, it falls back to a manual copy + ;; routine that omits overwriting same-named files (see: + ;; https://github.com/spyder-ide/docrepr/issues/54). + (substitute* "docrepr/utils.py" + (("except TypeError") + "except (TypeError, shutil.Error)")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-p" "no:warnings" "-vv"))))))) + (native-inputs + (list python-ipython + python-matplotlib + python-numpy + python-pytest + python-pytest-asyncio)) + (propagated-inputs + (list python-docutils + python-jinja2 + python-matplotlib + python-sphinx)) + (home-page "https://github.com/spyder-ide/docrepr/") + (synopsis "Python docstrings to HTML renderer") + (description "Docrepr renders Python docstrings to HTML with Sphinx. It +can generate rich and plain representations of docstrings, alongside +additional metadata about the object to which the docstring belongs.") + (license bsd-3))) + (define-public scrollkeeper (package (name "scrollkeeper") -- cgit v1.2.3 From efb791ba4f3559ca9306289889af02da96b822f3 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 14 Apr 2022 17:25:30 -0400 Subject: gnu: python-sphinx: Propagate TexLive dependencies. * gnu/packages/sphinx.scm (python-sphinx): [propagated-inputs]: Add texlive-amsfonts, texlive-amsmath, texlive-capt-of, texlive-carlisle, texlive-etoolbox, texlive-generic-ltxcmds, texlive-hyperref, texlive-latex-base, texlive-latex-cmap, texlive-latex-fancyhdr, texlive-latex-fancyvrb, texlive-latex-fncychap, texlive-latex-float, texlive-latex-framed, texlive-latex-geometry, texlive-latex-graphics, texlive-latex-kvoptions, texlive-latex-needspace, texlive-latex-parskip, texlive-latex-preview, texlive-latex-tabulary, texlive-latex-titlesec, texlive-latex-tools, texlive-latex-upquote, texlive-latex-varwidth, texlive-oberdiek, texlive-stringenc, texlive-wrapfig, texlive-xcolor and texlive-zapfding. [native-inputs]: Remove graphviz, python-mock and python-nose. * gnu/packages/tex.scm (texlive-xcolor): Add TODO comment. * gnu/packages/tex.scm (texlive-hyperref): Likewise. --- gnu/packages/sphinx.scm | 47 ++++++++++++++++++++++++++++++++++++++++------- gnu/packages/tex.scm | 11 ++++++++++- 2 files changed, 50 insertions(+), 8 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 69a92b8b97..a377729397 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -17,7 +17,7 @@ ;;; Copyright © 2021 Eric Bavier ;;; Copyright © 2021, 2022 Vinicius Monego ;;; Copyright © 2021 Hugo Lecomte -;;; Copyright © 2021 Maxim Cournoyer +;;; Copyright © 2021, 2022 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -54,7 +54,8 @@ #:use-module (gnu packages python-xyz) #:use-module (gnu packages time) #:use-module (gnu packages python-science) - #:use-module (gnu packages graph)) + #:use-module (gnu packages graph) + #:use-module (gnu packages tex)) (define-public python-sphinx (package @@ -95,13 +96,45 @@ python-sphinxcontrib-htmlhelp python-sphinxcontrib-jsmath python-sphinxcontrib-qthelp - python-sphinxcontrib-serializinghtml)) + python-sphinxcontrib-serializinghtml + + ;; The Sphinx LaTeX library '\RequirePackage' or \\usepackage + ;; these: + texlive-amsfonts ;amsmath, amssymb, amstext + texlive-amsmath + texlive-capt-of + texlive-carlisle ;remreset + texlive-etoolbox + texlive-generic-ltxcmds + texlive-hyperref + ;; TODO: Remove texlive-stringenc and texlive-zapfding after + ;; propagating them in texlive-hyperref in next rebuild cycle. + texlive-stringenc + texlive-zapfding + texlive-latex-base ;alltt, atbegshi, makeidx, textcomp + texlive-latex-cmap + texlive-latex-fancyhdr + texlive-latex-fancyvrb + texlive-latex-float + texlive-latex-fncychap + texlive-latex-framed + texlive-latex-geometry + texlive-latex-graphics ;graphicx, color + texlive-latex-kvoptions + texlive-latex-needspace + texlive-latex-parskip + texlive-latex-preview + texlive-latex-tabulary + texlive-latex-titlesec + texlive-latex-tools ;multicol, longtable + texlive-latex-upquote + texlive-latex-varwidth + texlive-oberdiek ;hypcap + texlive-wrapfig + texlive-xcolor)) (native-inputs - (list graphviz - imagemagick ;for "convert" + (list imagemagick ;for "convert" python-html5lib - python-mock - python-nose python-pytest)) (home-page "https://www.sphinx-doc.org") (synopsis "Python documentation generator") diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index a861b40950..0aa6a8bf95 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -3326,6 +3326,9 @@ used by @code{hyperref} and @code{bookmark}.") (rename-file (string-append share "/tex/latex/xcolor/xcolor.pro") (string-append share "/dvips/xcolor/xcolor.pro")) #t))))))) + ;; TODO: Propagate texlive-hyperref and many others in the next rebuild + ;; cycle. Grep for '\usepackage' to see what packages it requires. + ;; (propagated-inputs (list texlive-hyperref ...)) (home-page "https://www.ctan.org/pkg/xcolor") (synopsis "Driver-independent color extensions for LaTeX and pdfLaTeX") (description @@ -3449,7 +3452,13 @@ XML, using UTF-8 or a suitable 8-bit encoding.") texlive-latex-pdftexcmds texlive-latex-refcount texlive-latex-rerunfilecheck - texlive-url)) + texlive-url + ;; TODO: Add this in next rebuild cycle. + ;;texlive-cm + ;;texlive-latex-graphics ;for keyval + ;;texlive-stringenc + ;;texlive-zapfding + )) (home-page "https://www.ctan.org/pkg/hyperref") (synopsis "Extensive support for hypertext in LaTeX") (description -- cgit v1.2.3 From 6c7834f46aade4771d53434b6fd04c93e8746b7c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 14 Apr 2022 23:25:31 -0400 Subject: gnu: Add python-pep621. * gnu/packages/python-xyz.scm (python-pep621): New variable. --- gnu/packages/python-xyz.scm | 52 ++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 51 insertions(+), 1 deletion(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index ca293f5f54..23bf8add15 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -10813,7 +10813,57 @@ plugin for flake8 to check PEP-8 naming conventions.") (arguments `(#:tests? #f ,@(package-arguments base))) - (native-inputs `())))) + (native-inputs `())))) + +(define-public python-pep621 + (package + (name "python-pep621") + (version "0.4.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/FFY00/python-pep621") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0nzig7bmzf0xx5svxlf065mrzihr0ci4p1yaxka9flqjba98flpr")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + ;; XXX: PEP 517 manual build/install procedures copied from + ;; python-isort. + (replace 'build + (lambda _ + ;; ZIP does not support timestamps before 1980. + (setenv "SOURCE_DATE_EPOCH" "315532800") + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'check + (lambda* (#:key tests? inputs outputs #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" + ;; Two parameterized test_load tests are currently + ;; failing (see: + ;; https://github.com/FFY00/python-pep621/issues/14). + "-k" "not test_load")))) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (propagated-inputs (list python-packaging)) + (native-inputs (list python-pypa-build python-pytest python-tomli)) + (home-page "https://github.com/FFY00/python-pep621") + (synopsis "Dataclass for PEP 621 metadata") + (description "This project does not implement the parsing of +@file{pyproject.toml} containing PEP 621 metadata. Instead, given a Python +data structure representing PEP 621 metadata (already parsed), it will +validate this input and generate a PEP 643-compliant metadata +file (e.g. @file{PKG-INFO}).") + (license license:expat))) (define-public python-pyflakes (package -- cgit v1.2.3 From 28b602d0f664e92b6edf1f36656242a747c67d58 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 14 Apr 2022 23:35:28 -0400 Subject: gnu: Add python-sphinx-theme-builder. * gnu/packages/sphinx.scm (python-sphinx-theme-builder): New variable. --- gnu/packages/sphinx.scm | 50 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index a377729397..406fc8536b 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -1002,6 +1002,56 @@ automated way to document command-line programs. It scans @code{.. program::} and @code{.. option::} directives.") (license license:bsd-2))) +(define-public python-sphinx-theme-builder + (package + (name "python-sphinx-theme-builder") + (version "0.2.0a14") + (source + (origin + (method git-fetch) ;no tests in pypi archive + (uri (git-reference + (url "https://github.com/pradyunsg/sphinx-theme-builder") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1brqp34q716gglliallbgq4m63hl3nk8j6w8wcl8f2vvnkch6v98")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + ;; XXX: PEP 517 manual build copied from python-isort. + (replace 'build + (lambda _ + ;; ZIP does not support timestamps before 1980. + (setenv "SOURCE_DATE_EPOCH" "315532800") + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv")))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (native-inputs (list python-flit-core python-pytest)) + (propagated-inputs + (list python-pypa-build + python-click + python-nodeenv + python-packaging + python-pep621 + python-rich + python-sphinx-autobuild + python-tomli)) + (home-page "https://github.com/pradyunsg/sphinx-theme-builder") + (synopsis "Tool for authoring Sphinx themes") + (description "This package provides a tool for authoring Sphinx themes +with a simple (opinionated) workflow.") + (license license:expat))) + (define-public python-pydata-sphinx-theme (package (name "python-pydata-sphinx-theme") -- cgit v1.2.3 From d09edfec5ffc22843a6bb6df2678dc1e76ded11f Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 15 Apr 2022 00:00:08 -0400 Subject: gnu: Add python-sphinx-sitemap. * gnu/packages/sphinx.scm (python-sphinx-sitemap): New variable. --- gnu/packages/sphinx.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 406fc8536b..cb1897041b 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -1052,6 +1052,25 @@ automated way to document command-line programs. It scans with a simple (opinionated) workflow.") (license license:expat))) +(define-public python-sphinx-sitemap + (package + (name "python-sphinx-sitemap") + (version "2.2.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "sphinx-sitemap" version)) + (sha256 + (base32 "0dvpryrz7vn8rvayzy5nrmqy4wyzlaxcx88bl46prc9w4cwxmbb5")))) + (build-system python-build-system) + (propagated-inputs (list python-sphinx)) + (home-page "https://github.com/jdillard/sphinx-sitemap") + (synopsis "Sitemap generator for Sphinx") + (description "A Sphinx extension to generate multiversion and +multilanguage sitemaps.org compliant sitemaps for the HTML version of your +Sphinx documentation.") + (license license:expat))) + (define-public python-pydata-sphinx-theme (package (name "python-pydata-sphinx-theme") -- cgit v1.2.3 From cea6ff3d805f86758f779dd7804d70ba077bbe84 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sat, 16 Apr 2022 23:13:06 -0400 Subject: gnu: texlive-fontspec: Add missing propagated inputs. * gnu/packages/tex.scm (texlive-fontspec) [propagated-inputs]: Add texlive-cm and texlive-lm. --- gnu/packages/tex.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 0aa6a8bf95..4bd65329c2 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -3775,7 +3775,7 @@ here are defined for the dvips engine only.") (add-after 'unpack 'chdir (lambda _ (chdir "source/latex/fontspec/") #t)))))) (propagated-inputs - (list texlive-latex-l3packages)) + (list texlive-cm texlive-latex-l3packages texlive-lm)) (home-page "https://www.ctan.org/pkg/fontspec") (synopsis "Advanced font selection in XeLaTeX and LuaLaTeX") (description -- cgit v1.2.3 From 1ee15c8d6821eab4452a57dae00c74178a32a058 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sat, 9 Apr 2022 13:07:33 -0400 Subject: gnu: texlive-polyglossia: Rename and fix package. Fixes . * gnu/packages/tex.scm (texlive-latex-polyglossia): Rename to... (texlive-polyglossia): ... this. Inherit from a simple-texlive-package package. [version, source, build-system]: Remove field, now inherited. [outputs]: New field. [arguments]: Add the #:tex-format and #:phases arguments. [native-inputs, propagated-inputs]: New fields. [description]: Expound description. Reported-by: Josh Holland --- gnu/packages/tex.scm | 147 +++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 130 insertions(+), 17 deletions(-) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 4bd65329c2..1840401ba1 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -58,6 +58,7 @@ #:use-module (gnu packages bash) #:use-module (gnu packages boost) #:use-module (gnu packages compression) + #:use-module (gnu packages fonts) #:use-module (gnu packages fontutils) #:use-module (gnu packages gd) #:use-module (gnu packages ghostscript) @@ -5716,25 +5717,137 @@ running text or as separate paragraphs with a preceding number or symbol. It also provides compacted versions of enumerate and itemize.") (license license:lppl1.0+))) -(define-public texlive-latex-polyglossia +(define-public texlive-polyglossia (package - (name "texlive-latex-polyglossia") - (version (number->string %texlive-revision)) - (source (origin - (method svn-fetch) - (uri (texlive-ref "latex" "polyglossia")) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "1ci6hr8hx4g2x359n6wqvw6w8fv42cjjpzxxxd3pn6av5nkaiav3")))) - (build-system texlive-build-system) - (arguments '(#:tex-directory "latex/polyglossia")) + (inherit (simple-texlive-package + "texlive-polyglossia" + (list "source/latex/polyglossia/" + ;; These files are not part of polyglossia.dtx + "tex/latex/polyglossia/arabicnumbers.sty" + "tex/latex/polyglossia/xpg-cyrillicnumbers.sty") + (base32 "1p0hhclypv2zbs8h64c6sd689m9ym3vvpn966qpwpjxbymsrc49g"))) + (outputs '("out" "doc")) + (arguments + (list + #:tex-directory "latex/polyglossia" + #:tex-format "xelatex" + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'build-and-install-xelatex.fmt + (lambda* (#:key tex-format #:allow-other-keys) + (invoke "fmtutil-sys" "--byfmt" tex-format "--fmtdir=web2c") + ;; Extend the current TEXMF environment variable to make + ;; available the newly built formats. + (setenv "GUIX_TEXMF" (string-append (getcwd) ":" + (getenv "GUIX_TEXMF"))) + ;; XXX: Extend the base (more limited) xelatex.fmt provided by + ;; texlive-latex-base, otherwise packages using Polyglossia + ;; would encounter the same lack of hyphenation support problem. + (install-file "web2c/xetex/xelatex.fmt" + (string-append #$output + "/share/texmf-dist/web2c/xetex")))) + (add-before 'build 'chdir + (lambda _ + ;; This is so the build can find the files not part of the .dtx. + (setenv "TEXINPUTS" (string-append (getcwd) + "/tex/latex/polyglossia:")) + (chdir "source/latex/polyglossia"))) + (add-after 'chdir 'substitute-nonfree-fonts + (lambda _ + (substitute* "polyglossia.dtx" + (("\\{Serto Jerusalem}") + "{FreeSans}")))) + (add-after 'substitute-nonfree-fonts 'extract-dtx + (lambda* (#:key tex-format #:allow-other-keys) + (invoke tex-format "polyglossia.dtx"))) + (add-after 'install 'install-doc + (lambda* (#:key outputs tex-directory #:allow-other-keys) + (let ((doc (string-append (assoc-ref outputs "doc") + "/share/texmf-dist/doc" tex-directory))) + (install-file "README.md" doc) + (install-file "polyglossia.pdf" doc))))))) + (native-inputs (list fontconfig ;for XDG_DATA_DIRS (to locate fonts) + font-amiri + font-dejavu + font-gfs-ambrosia + font-gnu-freefont + font-linuxlibertine + font-sil-ezra + texlive-latex-base + texlive-babel + texlive-bin ;for fmtutil.cnf + texlive-bidi + texlive-booktabs + texlive-caption + texlive-context + texlive-latex-fancyvrb + texlive-etoolbox + texlive-fonts-latex + texlive-fontspec + texlive-hyperref + ;; TODO: Remove texlive-stringenc and + ;; texlive-zapfding after texlive-hyperref propagates + ;; them. + texlive-stringenc + texlive-zapfding + texlive-latex-graphics + texlive-kpathsea ;for cp227.tcx & friends + texlive-makecmds + texlive-metalogo + texlive-microtype + texlive-paralist + texlive-latex-tools + texlive-tex-ini-files)) ;for pdftexconfig + ;; polyglossia.sty \RequirePackage or \\usepackage these other TexLive + ;; packages. + (propagated-inputs + (list texlive-bidi + texlive-etoolbox + texlive-fontspec + texlive-hyperref + ;; TODO: Remove texlive-stringenc and + ;; texlive-zapfding after texlive-hyperref propagates + ;; them. + texlive-stringenc + texlive-zapfding + texlive-makecmds + texlive-latex-l3packages ;expl3, l3keys2e, xparse + texlive-latex-tools + texlive-latex-xkeyval)) (home-page "https://www.ctan.org/pkg/polyglossia") - (synopsis "Alternative to babel for XeLaTeX and LuaLaTeX") - (description - "This package provides a complete Babel replacement for users of LuaLaTeX -and XeLaTeX; it relies on the @code{fontspec} package, version 2.0 at least.") - (license license:lppl1.3+))) + (synopsis "Alternative to Babel for XeLaTeX and LuaLaTeX") + (description "This package provides a complete Babel replacement for users +of LuaLaTeX and XeLaTeX. It includes support for over 70 different languages, +some of which in different regional or national varieties, or using a +different writing system. It enables: +@itemize +@item +Loading the appropriate hyphenation patterns. +@item +Setting the script and language tags of the current font (if possible and +available), using the package fontspec. +@item +Switching to a font assigned by the user to a particular script or language. +@item +Adjusting some typographical conventions in function of the current language +(such as afterindent, frenchindent, spaces before or after punctuation marks, +etc.) +@item +Redefining the document strings (like @samp{chapter}, @samp{figure}, +@samp{bibliography}). Adapting the formatting of dates (for non-gregorian +calendars via external packages bundled with polyglossia: currently the +Hebrew, Islamic and Farsi calendars are supported). +@item +For languages that have their own numeration system, modifying the formatting +of numbers appropriately. +@item +Ensuring the proper directionality if the document contains languages +written from right to left (via the packages bidi and luabidi, available +separately). +@end itemize") + (license license:expat))) + +(define-deprecated-package texlive-latex-polyglossia texlive-polyglossia) (define-public texlive-latex-supertabular (package -- cgit v1.2.3 From 75646d51c2a76e54c92346ee91d97277473fea57 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 21:43:08 -0400 Subject: gnu: Add texlive-cbfonts-fd. * gnu/packages/tex.scm (texlive-cbfonts-fd): New variable. --- gnu/packages/tex.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 1840401ba1..d54c1b1160 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -915,6 +915,25 @@ from (almost) arbitrarily complex font names, thus helping portability of TeX documents.") (license license:public-domain))) +(define-public texlive-cbfonts-fd + (package + (inherit (simple-texlive-package + "texlive-cbfonts-fd" + (list "/doc/fonts/cbfonts/" + "/tex/latex/cbfonts-fd/") + (base32 + "0g91p2qcgqn916vgf777h45dabv2r6l6f9xkcq0b3gpir3qsj3d4") + #:trivial? #t)) + (home-page "https://www.ctan.org/pkg/cbfonts-fd") + (synopsis "LaTeX font description files for the CB Greek fonts") + (description "The package provides font description files for all the many +shapes available from the cbfonts collection. The files provide the means +whereby the @acronym{NFSS, New Font Selection Scheme} knows which fonts a +LaTeX user is requesting. + +Tip: installing @code{texlive-cbfonts} will automatically propagate this one.") + (license license:lppl1.3c+))) + (define-public texlive-cm (let ((template (simple-texlive-package "texlive-cm" -- cgit v1.2.3 From ee96537d0c062312c64a2a58f8d35f9dc6674f38 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 21:45:44 -0400 Subject: gnu: Add texlive-cbfonts. * gnu/packages/tex.scm (texlive-cbfonts): New variable. --- gnu/packages/tex.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index d54c1b1160..0ea0b3344d 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -915,6 +915,25 @@ from (almost) arbitrarily complex font names, thus helping portability of TeX documents.") (license license:public-domain))) +(define-public texlive-cbfonts ;71 MiB of greek fonts + (package + (inherit (simple-texlive-package + "texlive-cbfonts" + (list "/doc/fonts/cbfonts/" + "/fonts/type1/public/cbfonts/") + (base32 + "01j22cbwq9jkni5vvrpz2mg1799cbx3aq801sni74i8wb1zcf6y1") + #:trivial? #t)) + (propagated-inputs (list texlive-cbfonts-fd)) + (home-page "https://www.ctan.org/pkg/cbgreek-complete") + (synopsis "Complete set of Greek fonts") + (description "This bundle presents the whole of Beccari's original Greek +font set, which use the @i{Lispiakos} font shape derived from the shape of the +fonts used in printers' shops in Lispia. The fonts are available both as +Metafont source and in Adobe Type 1 format, and at the same wide set of design +sizes as are such font sets as the EC fonts.") + (license license:lppl1.3c+))) + (define-public texlive-cbfonts-fd (package (inherit (simple-texlive-package -- cgit v1.2.3 From 8cdad3484cc5787e50544ae1a573474e40e7bbed Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 21:57:30 -0400 Subject: download: Add a mirror for CTAN. * guix/download.scm (%mirrors)[ctan]: New entry. --- guix/download.scm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/guix/download.scm b/guix/download.scm index 47a2fcb180..1a80e3abd2 100644 --- a/guix/download.scm +++ b/guix/download.scm @@ -246,6 +246,11 @@ "http://cran.stat.auckland.ac.nz/" "http://cran.mirror.ac.za/" "http://cran.csie.ntu.edu.tw/") + (ctan + ;; This is the CTAN mirror multiplexor service, which automatically + ;; redirect to a mirror in or close to the country of the requester + ;; (see: https://ctan.org/mirrors/). + "https://mirror.ctan.org/") (imagemagick ;; from http://www.imagemagick.org/script/download.php ;; (without mirrors that are unavailable or not up to date) -- cgit v1.2.3 From e2c570003225200965c4485b73833e69ddd444ce Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 22:57:06 -0400 Subject: gnu: texlive-latex-geometry: Propagate texlive-latex-graphics. * gnu/packages/tex.scm (texlive-latex-geometry) [propagated-inputs]: Add texlive-latex-graphics. --- gnu/packages/tex.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 0ea0b3344d..c0b874faec 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -5549,7 +5549,8 @@ BibLaTeX, and is considered experimental.") (build-system texlive-build-system) (arguments '(#:tex-directory "latex/geometry")) (propagated-inputs - (list texlive-oberdiek)) ;for ifpdf + (list texlive-oberdiek ;for ifpdf + texlive-latex-graphics)) ;for keyval (home-page "https://www.ctan.org/pkg/geometry") (synopsis "Flexible and complete interface to document dimensions") (description -- cgit v1.2.3 From cf44f00b5b64ef7908629e049561f58aadc407d9 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 23:21:59 -0400 Subject: gnu: Add texlive-cm-lgc. * gnu/packages/tex.scm (texlive-cm-lgc): New variable. --- gnu/packages/tex.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index c0b874faec..994f03987e 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -1028,6 +1028,31 @@ display, and mathematical fonts in a range of styles, based on Monotype Modern (define-deprecated-package texlive-fonts-cm texlive-cm) +(define-public texlive-cm-lgc + (package + (inherit (simple-texlive-package + "texlive-cm-lgc" + (list "/doc/fonts/cm-lgc/" + "/fonts/afm/public/cm-lgc/" + "/fonts/type1/public/cm-lgc/" + "/fonts/vf/public/cm-lgc/" + "/tex/latex/cm-lgc/") + (base32 + "0rm7wgyb07y8h6vbvc2xzsqnxy322d4j9ly2p67z84b81c8i3zpc") + #:trivial? #t)) + (home-page "https://www.ctan.org/pkg/cm-lgc") + (synopsis "Type 1 CM-based fonts for Latin, Greek and Cyrillic") + (description "The fonts are converted from Metafont sources of the +Computer Modern font families, using @command{textrace}. Supported encodings +are: T1 (Latin), T2A (Cyrillic), LGR (Greek) and TS1. The package also +includes Unicode virtual fonts for use with Omega. The font set is not a +replacement for any of the other Computer Modern-based font sets (for example, +cm-super for Latin and Cyrillic, or cbgreek for Greek), since it is available +at a single size only; it offers a compact set for @i{general} working. The +fonts themselves are encoded to external standards, and virtual fonts are +provided for use with TeX.") + (license license:gpl2+))) + (define-public texlive-cm-super (let ((template (simple-texlive-package "texlive-cm-super" -- cgit v1.2.3 From 5fdae311a0a5beaff5f048001f56ff0fa7d05e4c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 23:55:07 -0400 Subject: gnu: Add texlive-xindy. * gnu/packages/tex.scm (texlive-xindy): New variable. --- gnu/packages/tex.scm | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 994f03987e..9f8fdbafdc 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -50,6 +50,7 @@ #:use-module (guix build-system texlive) #:use-module (guix utils) #:use-module (guix deprecation) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (guix svn-download) #:use-module (gnu packages) @@ -58,6 +59,7 @@ #:use-module (gnu packages bash) #:use-module (gnu packages boost) #:use-module (gnu packages compression) + #:use-module (gnu packages lisp) #:use-module (gnu packages fonts) #:use-module (gnu packages fontutils) #:use-module (gnu packages gd) @@ -10820,6 +10822,54 @@ the package @code{calc}, together with the ability of defining new commands to handle complex tests.") (license license:lppl))) +(define-public texlive-xindy + (package + (name "texlive-xindy") + (version "2.5.1") + (source (origin + (method url-fetch) + (uri (string-append "mirror://ctan/indexing/xindy/base/xindy-" + version ".tar.gz")) + (sha256 + (base32 + "0hxsx4zw19kmixkmrln17sxgg1ln4pfp4lpfn5v5fyr1nwfyk3ic")))) + (build-system gnu-build-system) + (arguments + (list + #:configure-flags #~(list "--enable-docs") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-clisp + (lambda* (#:key inputs #:allow-other-keys) + ;; The xindy.in file is encoded in ISO-8859-1 (or iso-latin-1). + (with-fluids ((%default-port-encoding "ISO-8859-1")) + (substitute* "user-commands/xindy.in" + (("(our \\$clisp = ).*" _ head) + (format #f "our $clisp = ~s;~%" + (search-input-file inputs "bin/clisp")))))))))) + (native-inputs (list clisp + glibc-locales + perl + texlive-bin + texlive-greek-fontenc + texlive-hyperref + texlive-latex-base + texlive-latex-cyrillic + texlive-latex-geometry + (texlive-updmap.cfg ;fonts + (list texlive-cbfonts + texlive-lh + texlive-jknappen)))) + (inputs (list clisp perl)) ;used at run time + (home-page "https://www.ctan.org/pkg/xindy") + (synopsis "General-purpose index processor") + (description "Xindy was developed after an impasse had been encountered in +the attempt to complete internationalisation of @command{makeindex}. Xindy +can be used to process indexes for documents marked up using (La)TeX, Nroff +family and SGML-based languages. Xindy is highly configurable, both in markup +terms and in terms of the collating order of the text being processed.") + (license license:gpl2+))) + (define-public bibtool (package (name "bibtool") -- cgit v1.2.3 From 2576d9ffc4c5cf84c4c6c1dfee2d2d8655fba4b4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sat, 16 Apr 2022 23:44:01 -0400 Subject: gnu: python-ipython-documentation: Also build info and pdf targets. * gnu/packages/patches/python-ipython-documentation-chars.patch: New file. * gnu/packages/patches/python-ipython-documentation-repro.patch: Likewise. * gnu/local.mk: Register them. * gnu/packages/python-xyz.scm (python-ipython-documentation) [source]: Apply patches. [arguments]: Use gexps. [phases]{sanitize-sources}: New phase. {configure-sphinx-for-xelatex}: Likewise. {install}: Streamline. Also build and install the PDF and info manual. Enable parallel processing. [inputs]: Delete field. [propagated-inputs]: Remove texlive-updmap.cfg input. Add fontconfig, font-gnu-freefont, graphviz, python-docrepr, texlive-polyglossia, texlive-bin and texlive-xindy. --- gnu/local.mk | 2 + .../python-ipython-documentation-chars.patch | 18 +++ .../python-ipython-documentation-repro.patch | 25 ++++ gnu/packages/python-xyz.scm | 145 +++++++++++---------- 4 files changed, 118 insertions(+), 72 deletions(-) create mode 100644 gnu/packages/patches/python-ipython-documentation-chars.patch create mode 100644 gnu/packages/patches/python-ipython-documentation-repro.patch diff --git a/gnu/local.mk b/gnu/local.mk index 06367fac5e..a5cf82ab28 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1686,6 +1686,8 @@ dist_patch_DATA = \ %D%/packages/patches/python-execnet-read-only-fix.patch \ %D%/packages/patches/python-fixtures-remove-monkeypatch-test.patch \ %D%/packages/patches/python-flask-restful-werkzeug-compat.patch \ + %D%/packages/patches/python-ipython-documentation-chars.patch \ + %D%/packages/patches/python-ipython-documentation-repro.patch \ %D%/packages/patches/python-keras-integration-test.patch \ %D%/packages/patches/python-pdoc3-tests.patch \ %D%/packages/patches/python-peachpy-determinism.patch \ diff --git a/gnu/packages/patches/python-ipython-documentation-chars.patch b/gnu/packages/patches/python-ipython-documentation-chars.patch new file mode 100644 index 0000000000..a52c54f513 --- /dev/null +++ b/gnu/packages/patches/python-ipython-documentation-chars.patch @@ -0,0 +1,18 @@ +Avoid LaTeX errors due to non-printable characters. +Submitted upstream: https://github.com/ipython/ipython/pull/13640 + +diff --git a/IPython/utils/coloransi.py b/IPython/utils/coloransi.py +index e33142180..9300b0108 100644 +--- a/IPython/utils/coloransi.py ++++ b/IPython/utils/coloransi.py +@@ -74,8 +74,8 @@ class TermColors: + class InputTermColors: + """Color escape sequences for input prompts. + +- This class is similar to TermColors, but the escapes are wrapped in \001 +- and \002 so that readline can properly know the length of each line and ++ This class is similar to TermColors, but the escapes are wrapped in \\001 ++ and \\002 so that readline can properly know the length of each line and + can wrap lines accordingly. Use this class for any colored text which + needs to be used in input prompts, such as in calls to raw_input(). + diff --git a/gnu/packages/patches/python-ipython-documentation-repro.patch b/gnu/packages/patches/python-ipython-documentation-repro.patch new file mode 100644 index 0000000000..d6a6e9c3fd --- /dev/null +++ b/gnu/packages/patches/python-ipython-documentation-repro.patch @@ -0,0 +1,25 @@ +Fix non-reproducibilities caused by time-dependent procedures. +Submitted upstream: https://github.com/ipython/ipython/pull/13640 + +diff --git a/IPython/sphinxext/ipython_directive.py b/IPython/sphinxext/ipython_directive.py +index 18bdfcae9..2c665ac87 100644 +--- a/IPython/sphinxext/ipython_directive.py ++++ b/IPython/sphinxext/ipython_directive.py +@@ -19,7 +19,7 @@ + In [1]: 1+1 + + In [1]: import datetime +- ...: datetime.datetime.now() ++ ...: datetime.date.fromisoformat('2022-02-22') + + It supports IPython construct that plain + Python does not understand (like magics): +@@ -28,7 +28,7 @@ + + In [0]: import time + +- In [0]: %timeit time.sleep(0.05) ++ In [0]: %pdoc time + + This will also support top-level async when using IPython 7.0+ + diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 23bf8add15..78e5334bce 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -155,9 +155,11 @@ #:use-module (gnu packages django) #:use-module (gnu packages djvu) #:use-module (gnu packages docker) + #:use-module (gnu packages documentation) #:use-module (gnu packages enchant) #:use-module (gnu packages file) #:use-module (gnu packages fontutils) + #:use-module (gnu packages fonts) #:use-module (gnu packages freedesktop) #:use-module (gnu packages gdb) #:use-module (gnu packages gcc) @@ -9389,79 +9391,78 @@ computing.") (inherit python-ipython) (name "python-ipython-documentation") (version (package-version python-ipython)) + (source + (origin + (inherit (package-source python-ipython)) + (patches (append (search-patches + "python-ipython-documentation-chars.patch" + "python-ipython-documentation-repro.patch") + (origin-patches (package-source python-ipython)))))) (arguments - `(#:phases - (modify-phases %standard-phases - (delete 'build) - (delete 'check) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (let* ((data (string-append (assoc-ref outputs "out") "/share")) - (doc (string-append data "/doc/" ,name "-" ,version)) - (html (string-append doc "/html")) - (man1 (string-append data "/man/man1")) - (info (string-append data "/info")) - (examples (string-append doc "/examples")) - (python-arg (string-append "PYTHON=" (which "python")))) - (setenv "LANG" "en_US.utf8") - (with-directory-excursion "docs" - ;; FIXME: pdf fails to build - ;;(system* "make" "pdf" "PAPER=a4") - (system* "make" python-arg "html") - ;; FIXME: the generated texi file contains ^@^@, which trips - ;; up the parser. - ;; (system* "make" python-arg "info") - ) - (copy-recursively "docs/man" man1) - (copy-recursively "examples" examples) - (copy-recursively "docs/build/html" html) - ;; (copy-file "docs/build/latex/ipython.pdf" - ;; (string-append doc "/ipython.pdf")) - (mkdir-p info) - ;; (copy-file "docs/build/texinfo/ipython.info" - ;; (string-append info "/ipython.info")) - (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))))))) - (inputs - (list python-ipython python-ipykernel)) - (native-inputs - `(("python-sphinx" ,python-sphinx) - ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme) - ;; FIXME: It's possible that a smaller updmap.cfg would work just as - ;; well. - ("texlive" ,(texlive-updmap.cfg (list texlive-amsfonts - texlive-capt-of - texlive-fonts-ec - texlive-generic-iftex - texlive-pdftex - texlive-latex-cmap - texlive-latex-environ - texlive-latex-eqparbox - texlive-etoolbox - texlive-latex-expdlist - texlive-latex-fancyhdr - texlive-latex-fancyvrb - texlive-latex-fncychap - texlive-latex-float - texlive-latex-framed - texlive-latex-geometry - texlive-latex-graphics - texlive-hyperref - texlive-latex-mdwtools - texlive-latex-multirow - texlive-latex-needspace - texlive-oberdiek - texlive-latex-parskip - texlive-latex-preview - texlive-latex-tabulary - texlive-latex-threeparttable - texlive-latex-titlesec - texlive-latex-trimspaces - texlive-latex-ucs - texlive-latex-upquote - texlive-url - texlive-latex-varwidth - texlive-wrapfig))) - ("texinfo" ,texinfo))))) + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'set-pythonpath + (lambda _ + ;; Ensure this fixed (via the + ;; "python-ipython-documentation-chars.patch" patch) copy of + ;; IPython gets used. + (setenv "PYTHONPATH" (string-append (getcwd))))) + (add-before 'build 'configure-sphinx-for-xelatex + (lambda _ + ;; Use XeLaTeX instead of PDFLaTeX, as it can + ;; cope with the Unicode characters present in the + ;; contributors page, for example. + (substitute* "docs/source/conf.py" + (("project = 'IPython'.*" all) + (string-append all "latex_engine = 'xelatex'\n"))) + ;; XXX: The Sphinx-generated ipython.tex specifies the GNU + ;; FreeFont font to be searched via its extension, which uses + ;; kpathsea instead of fontconfig and fail (see: + ;; https://github.com/sphinx-doc/sphinx/issues/10347). Create a + ;; symlink to GNU FreeFont and add it to the TEXMF tree via + ;; GUIX_TEXMF. + (mkdir-p "texmf-dist/fonts/opentype/public") + (symlink (string-append + #$(this-package-native-input "font-gnu-freefont") + "/share/fonts/opentype") + (string-append + (getcwd) "/" + "texmf-dist/fonts/opentype/public/gnu-freefont")) + (setenv "GUIX_TEXMF" (string-append (getenv "GUIX_TEXMF") ":" + (getcwd) "/texmf-dist")))) + (delete 'build) + (delete 'check) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((data (string-append #$output "/share")) + (doc (string-append data "/doc/" #$name "-" #$version)) + (html (string-append doc "/html")) + (info (string-append data "/info"))) + (invoke "make" "-C" "docs" "info" "html" "pdf" + (string-append "SPHINXOPTS=-j" + (number->string (parallel-job-count)))) + (install-file "COPYING.rst" doc) + (copy-recursively "examples" (string-append doc "/examples")) + ;; Install HTML documentation. + (copy-recursively "docs/build/html" html) + ;; Likewise for the PDF. + (install-file "docs/build/latex/ipython.pdf" doc) + ;; Likewise for the info manual. + (install-file "docs/build/texinfo/ipython.info" info) + (symlink (string-append html "/_images") + (string-append info "/ipython-figures")))))))) + (native-inputs + (list fontconfig ;for XDG_DATA_DIRS to locate fonts + font-gnu-freefont + graphviz + python-docrepr + python-sphinx + python-sphinx-rtd-theme + texinfo + texlive-bin + texlive-polyglossia + texlive-xindy)))) (define-public python-urwid (package -- cgit v1.2.3 From 37caa64189b1cd35a806d42fcc9cad7001388164 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 17 Apr 2022 08:07:00 -0400 Subject: gnu: python-websockets: Update to 10.3 and enable tests. * gnu/packages/python-web.scm (python-websockets): Fetch from git. Update to 10.3. [arguments]: Delete field, enabling tests. --- gnu/packages/python-web.scm | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 340f84c78f..aaa45c5f4c 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -5345,24 +5345,18 @@ files.") (define-public python-websockets (package (name "python-websockets") - (version "8.1") + (version "10.3") (source - (origin - (method url-fetch) - (uri (pypi-uri "websockets" version)) - (sha256 - (base32 - "03s3ml6sbki24aajllf8aily0xzrn929zxi84p50zkkbikdd4raw")))) + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/aaugustin/websockets") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1vk7g5z977mi89hamwiqawpmibwvv9ghrf3pqva1waxmyc7gyjb5")))) (build-system python-build-system) - (arguments - '(#:tests? #f ; Tests not included in release tarball. - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-websockets-package-name-requirement - (lambda* (#:key inputs #:allow-other-keys) - ;; Python package names use dot as separator. - (substitute* "setup.py" - (("websockets/extensions") "websockets.extensions"))))))) (home-page "https://github.com/aaugustin/websockets") (synopsis "Python implementation of the WebSocket Protocol (RFC 6455 & 7692)") -- cgit v1.2.3 From 34c98f2cd387675313b06d1ff1baab2848a413bf Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 17 Apr 2022 08:46:41 -0400 Subject: gnu: Add python-strict-rfc3339. * gnu/packages/python-xyz.scm (python-strict-rfc3339): New variable. --- gnu/packages/python-xyz.scm | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 78e5334bce..1ca87fee50 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -29550,6 +29550,48 @@ from multiple sources. Online trading accounts also often provide account statements in OFX files.") (license license:expat))) +(define-public python-strict-rfc3339 + (package + (name "python-strict-rfc3339") + (version "0.7") + (source + (origin + (method git-fetch) ;no tests in pypi release + (uri (git-reference + (url "https://github.com/danielrichman/strict-rfc3339") + (commit (string-append "version-" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0b12bh9v9gwkm89kxbidxw2z81lg8fx1v5fzgs313v1wgx6qb09p")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" + ;; The timestamp to local offset tests fail due to + ;; missing timezone data (see: + ;; https://github.com/danielrichman/strict-rfc3339/issues/9). + "-k" "not LocalOffset"))))))) + (native-inputs (list python-pytest)) + (home-page "https://github.com/danielrichman/strict-rfc3339") + (synopsis "RFC3339 procedures library") + (description "The @code{strict_rfc3339} Python module provides strict, +simple, lightweight RFC3339 procedures. It enables or aims to: +@itemize +@item Convert UNIX timestamps to and from RFC3339. +@item Produce RFC3339 strings with a UTC offset (Z) or with the offset that +the C time module reports is the local timezone offset. +@item Be simple with minimal dependencies/libraries. +@item Avoid timezones as much as possible. +@item Be very strict and follow RFC3339. +@end itemize") + (license license:gpl3+))) + (define-public python-stripe (package (name "python-stripe") -- cgit v1.2.3 From ac4a73a1af3e0deb240407dbb1ccba40a8507068 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 17 Apr 2022 09:00:45 -0400 Subject: gnu: Add python-rfc3339-validator. * gnu/packages/python-xyz.scm (python-rfc3339-validator): New variable. --- gnu/packages/python-xyz.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 1ca87fee50..d2245e5605 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -29550,6 +29550,27 @@ from multiple sources. Online trading accounts also often provide account statements in OFX files.") (license license:expat))) +(define-public python-rfc3339-validator + (package + (name "python-rfc3339-validator") + (version "0.1.4") + (source + (origin + (method url-fetch) + (uri (pypi-uri "rfc3339_validator" version)) + (sha256 + (base32 "0srg0b89aikzinw72s433994k5gv5lfyarq1adhas11kz6yjm2hk")))) + (build-system python-build-system) + (native-inputs (list python-hypothesis + python-pytest + python-pytest-runner + python-strict-rfc3339)) + (propagated-inputs (list python-six)) + (home-page "https://github.com/naimetti/rfc3339-validator") + (synopsis "Python RFC3339 validator") + (description "This package provides a pure Python RFC3339 validator.") + (license license:expat))) + (define-public python-strict-rfc3339 (package (name "python-strict-rfc3339") -- cgit v1.2.3 From 27c49acf0662b9b1bcad070888d19bcef3ceb27d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 17 Apr 2022 09:10:38 -0400 Subject: gnu: Add python-openapi-schema-validator. * gnu/packages/python-web.scm (python-openapi-schema-validator): New variable. --- gnu/packages/python-web.scm | 54 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index aaa45c5f4c..4b7d01052d 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -1429,6 +1429,60 @@ is Python’s.") (define-public python2-webencodings (package-with-python2 python-webencodings)) +(define-public python-openapi-schema-validator + (package + (name "python-openapi-schema-validator") + (version "0.2.3") + (source + (origin + (method git-fetch) ;no tests in pypi release + (uri (git-reference + (url "https://github.com/p1c2u/openapi-schema-validator") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1swm8h74nhg63nxk347blwq9f1qn6iiq3zisndcvm7axkq3pc2df")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'remove-coverage-pytest-options + (lambda _ + (substitute* "pyproject.toml" + (("^--cov.*") "")))) + ;; XXX: PEP 517 manual build copied from python-isort. + (replace 'build + (lambda _ + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest")))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (native-inputs (list python-poetry-core python-pypa-build python-pytest)) + (propagated-inputs + (list python-isodate + python-jsonschema + python-rfc3339-validator + python-strict-rfc3339)) + (home-page "https://github.com/p1c2u/openapi-schema-validator") + (synopsis "OpenAPI schema validation library for Python") + (description "Openapi-schema-validator is a Python library that validates +a schema against: +@itemize +@item OpenAPI Schema Specification v3.0 which is an extended subset of the +JSON Schema Specification Wright Draft 00. +@item OpenAPI Schema Specification v3.1 which is an extended superset of the +JSON Schema Specification Draft 2020-12. +@end itemize") + (license license:bsd-3))) + (define-public python-openid (package (name "python-openid") -- cgit v1.2.3 From a81161c1a484da7d54626f76f08aa8c3c6fec96b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 17 Apr 2022 14:22:02 -0400 Subject: gnu: Add python-openapi-spec-validator. * gnu/packages/python-web.scm (python-openapi-spec-validator): New variable. --- gnu/packages/python-web.scm | 55 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 4b7d01052d..9c026ba53c 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -1483,6 +1483,61 @@ JSON Schema Specification Draft 2020-12. @end itemize") (license license:bsd-3))) +(define-public python-openapi-spec-validator + (package + (name "python-openapi-spec-validator") + (version "0.4.0") + (source + (origin + (method git-fetch) ;no tests in pypi release + (uri (git-reference + (url "https://github.com/p1c2u/openapi-spec-validator") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1q09sjh4hsc0c8yqbd97h5mp6rwh427y6zyn8kv8wljk6sa0fs4q")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'remove-coverage-pytest-options + (lambda _ + (substitute* "pyproject.toml" + (("^--cov.*") "")))) + ;; XXX: PEP 517 manual build copied from python-isort. + (replace 'build + (lambda _ + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" + ;; The example tests attempt to fetch resources from + ;; the Internet (see: + ;; https://github.com/p1c2u/openapi-spec-validator/issues/151). + "-k" "not Example and not Exampe")))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (native-inputs (list python-poetry-core python-pypa-build python-pytest)) + (propagated-inputs + (list python-jsonschema + python-openapi-schema-validator + python-pyyaml + python-requests + python-setuptools)) + (home-page "https://github.com/p1c2u/openapi-spec-validator") + (synopsis "OpenAPI spec validator") + (description "OpenAPI Spec Validator is a Python library that validates an +OpenAPI specification against the OpenAPI 2.0 (also known as Swagger), OpenAPI +3.0 and OpenAPI 3.1 specifications. The validator aims to check for full +compliance with the specification.") + (license license:asl2.0))) + (define-public python-openid (package (name "python-openid") -- cgit v1.2.3 From c5d5c14101535b0a44ccb5fdfb72fad265702a8b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 17 Apr 2022 23:18:30 -0400 Subject: gnu: Add python-cbor2. * gnu/packages/python-web.scm (python-cbor2): New variable. --- gnu/packages/python-web.scm | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 9c026ba53c..36d7fb03f9 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -575,6 +575,46 @@ Model} (SAM) templates into AWS CloudFormation templates.") emit information from within their applications to the AWS X-Ray service.") (license license:asl2.0))) +(define-public python-cbor2 + (package + (name "python-cbor2") + (version "5.4.2.post1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "cbor2" version)) + (sha256 + (base32 "15y78xcc3zkmvj1mdzz8gyhf3apbl91073kwhzbjk5abc1civwlw")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-pytest python-pytest-cov python-setuptools-scm)) + (home-page "https://github.com/agronholm/cbor2") + (synopsis "Concise Binary Object Representation (CBOR) (de)serializer") + (description "This Python library provides encoding and decoding for the +Concise Binary Object +Representation (CBOR) (@url{https://www.rfc-editor.org/rfc/rfc8949.html, RFC +8949}) serialization format. The specification is fully compatible with the +original RFC 7049. Among its features are: +@itemize +@item Simple API like the @code{json} or @code{pickle} modules. +@item Support many CBOR tags with stdlib objects. +@item Generic tag decoding. +@item Shared value references including cyclic references. +@item String references compact encoding with repeated strings replaced with +indices. +@item Optional C module backend tested on big- and little-endian architectures. +@item Extensible tagged value handling using tag_hook and object_hook on +decode and default on encode. +@end itemize") + (license license:expat))) + (define-public python-cfn-lint (package (name "python-cfn-lint") -- cgit v1.2.3 From f17611f3bef3ee28a88b53a74e6e84bcfdbed966 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 00:07:48 -0400 Subject: gnu: python-httpcore: Update to 0.14.7 and enable tests. * gnu/packages/python-web.scm (python-httpcore): Update to 0.14.7. [tests?]: Delete argument. [phases]{check}: Streamline and delete coverage related pytest options. Strip trailing #t. [native-inputs]: Delete python-autoflake, python-flake8, python-flake8-bugbear, python-flake8-pie and python-mypy. Add python-pytest-httpbin. [propagated-inputs]: Add python-anyio, python-certifi and python-socksio. --- gnu/packages/python-web.scm | 31 ++++++++++++++----------------- 1 file changed, 14 insertions(+), 17 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 36d7fb03f9..d658985520 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -5254,7 +5254,7 @@ and serve updated contents upon changes to the directory.") (define-public python-httpcore (package (name "python-httpcore") - (version "0.12.2") + (version "0.14.7") (source (origin ;; PyPI tarball does not contain tests. @@ -5264,34 +5264,31 @@ and serve updated contents upon changes to the directory.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1nrwwfdqjfc2a1k3j41cdwkprwvplf95fwmypdl2aq2qgp3209q0")))) + (base32 "0wdr28vf03l6yxhk8nrvhh7y7x18rqdcfzv1sb6jgzk9zmycrvc7")))) (build-system python-build-system) (arguments - `(#:tests? #f ; Tests hang at 98% - #:phases + `(#:phases (modify-phases %standard-phases (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv" "--cov=httpcore" - "--cov=tests" "tests")) - #t))))) + (invoke "pytest" "-vv" "tests"))))))) (native-inputs - (list python-autoflake - python-flake8 - python-flake8-bugbear - python-flake8-pie - python-isort - python-mypy - python-pytest + (list python-pytest python-pytest-asyncio python-pytest-cov + python-pytest-httpbin python-pytest-trio python-uvicorn python-trustme)) (propagated-inputs - (list python-h11 python-h2 python-sniffio python-trio + (list python-anyio + python-certifi + python-h11 + python-h2 + python-sniffio + python-socksio + python-trio python-trio-typing)) (home-page "https://github.com/encode/httpcore") (synopsis "Minimal, low-level HTTP client") -- cgit v1.2.3 From b9fc4781925fd783c89d8c75ee47cafa2171a78a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 00:10:02 -0400 Subject: gnu: Add python-httpcore-bootstrap. * gnu/packages/python-web.scm (python-httpcore-bootstrap): New variable. --- gnu/packages/python-web.scm | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index d658985520..28c2ae9b13 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -5308,6 +5308,14 @@ Some things HTTP Core does do: @end itemize") (license license:bsd-3))) +;;; Variant used to break a cycle between python-httpx and python-uvicorn. +(define-public python-httpcore-bootstrap + (hidden-package + (package/inherit python-httpcore + (name "python-httpcore-bootstrap") + (arguments (list #:tests? #f)) + (native-inputs '())))) + (define-public python-httpx (package (name "python-httpx") -- cgit v1.2.3 From ef370c850115bcb5f158d4ac1bc386c3df9f7af1 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 00:10:28 -0400 Subject: gnu: Add python-httpx-bootstrap. * gnu/packages/python-web.scm (python-httpx-bootstrap): New variable. --- gnu/packages/python-web.scm | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 28c2ae9b13..1aa5342e8d 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -5412,6 +5412,17 @@ Plus all the standard features of requests: @end itemize") (license license:bsd-3))) +;;; Variant used to break a cycle with python-uvicorn. +(define-public python-httpx-bootstrap + (hidden-package + (package/inherit python-httpx + (name "python-httpx-bootstrap") + (arguments (list #:tests? #f)) + (native-inputs '()) + (propagated-inputs + (modify-inputs (package-propagated-inputs python-httpx) + (replace "python-httpcore" python-httpcore-bootstrap)))))) + (define-public python-wsgiprox (package (name "python-wsgiprox") -- cgit v1.2.3 From b4c4c2f82e91736bfc623df2b3f61335ec702231 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 00:10:52 -0400 Subject: gnu: python-httpx: Update to 0.22.0. * gnu/packages/python-web.scm (python-httpx): Update to 0.22.0. [phases]{check}: Add 'asyncio_mode=auto' pytest-asyncio option. Skip the 'test_main' test. [native-inputs]: Delete python-autoflake, python-black, python-cryptography, python-flake8, python-flake8-bugbear, python-flake8-pie, python-isort, python-mypy and python-pytest-cov. [propagated-inputs]: Add python-charset-normalizer. --- gnu/packages/python-web.scm | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 1aa5342e8d..3e024b4fae 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -5319,7 +5319,7 @@ Some things HTTP Core does do: (define-public python-httpx (package (name "python-httpx") - (version "0.16.1") + (version "0.22.0") (source (origin ;; PyPI tarball does not contain tests. @@ -5329,7 +5329,7 @@ Some things HTTP Core does do: (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "00gmq45fckcqkj910bvd7pyqz1mvgsdvz4s0k7dzbnc5czzq1f4a")))) + (base32 "1awr56488b66zyl3cx1f03lq2n07xdg5kb4l46vnsm59s6hr02c5")))) (build-system python-build-system) (arguments `(#:phases @@ -5337,7 +5337,8 @@ Some things HTTP Core does do: (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? - (invoke "pytest" "-vv" "-k" + (invoke "pytest" "-vv" "-o" "asyncio_mode=auto" + "-k" ;; These tests try to open an outgoing connection. (string-append "not test_connect_timeout" @@ -5347,26 +5348,23 @@ Some things HTTP Core does do: "being_deleted" " and not test_that_send_cause_client_to_be_not_closed" " and not test_async_proxy_close" - " and not test_sync_proxy_close")))))))) + " and not test_sync_proxy_close" + ;; This test is apparently incompatible with + ;; python-click 8, fails with " AttributeError: + ;; 'function' object has no attribute 'name'". + " and not test_main")))))))) (native-inputs - (list python-autoflake - python-black - python-cryptography - python-flake8 - python-flake8-bugbear - python-flake8-pie - python-isort - python-mypy + (list python-cryptography python-pytest python-pytest-asyncio python-pytest-trio - python-pytest-cov python-trio python-trio-typing python-trustme python-uvicorn)) (propagated-inputs - (list python-brotli + (list python-charset-normalizer + python-brotli python-certifi python-chardet python-httpcore -- cgit v1.2.3 From 634a798f51c7c31d882b7888e49697aa0e8f32e4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 00:11:32 -0400 Subject: gnu: python-uvicorn: Update to 0.17.6. * gnu/packages/python-web.scm (python-uvicorn): Update to 0.17.6. [phases]{check}: Delete extraneous add-installed-pythonpath and inputs/outputs arguments. Add the '-o' 'asyncio_mode=auto' option to pytest invocation, and skip two tests. [native-inputs]: Add python-httpx-bootstrap and python-pytest-asyncio. [propagated-inputs]: Add python-asgiref and python-dotenv. --- gnu/packages/python-web.scm | 29 +++++++++++++++++++++-------- 1 file changed, 21 insertions(+), 8 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 3e024b4fae..41de186b6f 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -5014,7 +5014,7 @@ and fairly speedy.") (define-public python-uvicorn (package (name "python-uvicorn") - (version "0.13.2") + (version "0.17.6") (source (origin ;; PyPI tarball has no tests. @@ -5024,20 +5024,33 @@ and fairly speedy.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "04zgmp9z46k72ay6cz7plga6d3w3a6x41anabm7ramp7jdqf6na9")))) + (base32 "0npwls02nhna2lyw2nksxij16l9agf12c9f42pvxb5yrpi9l16c8")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv")))))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "-o" "asyncio_mode=auto" + "-k" + (string-append + ;; These error or fail due to networking. + "not test_keepalive " + "and not test_bind_unix_socket_works_with_" + "reload_or_workers ")))))))) (native-inputs - (list python-pytest python-pytest-mock python-requests - python-trustme python-wsproto)) + (list python-httpx-bootstrap + python-pytest + python-pytest-asyncio + python-pytest-mock + python-requests + python-trustme + python-wsproto)) (propagated-inputs - (list python-click + (list python-asgiref + python-click + python-dotenv python-h11 python-httptools python-pyyaml -- cgit v1.2.3 From 1f5f4cc1a2076ef40121f9e6c858e7c3081c7ef4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 00:21:31 -0400 Subject: gnu: Add python-socksio. * gnu/packages/python-web.scm (python-socksio): New variable. --- gnu/packages/python-web.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 41de186b6f..0e837c8180 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -6336,6 +6336,27 @@ your code non-blocking and speedy.") functionality.") (license license:asl2.0))) +(define-public python-socksio + (package + (name "python-socksio") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "socksio" version)) + (sha256 + (base32 "1b64j45w35jzhjhnq44bnyad9ydh1iyyd7a6j2c8phxmllyyp2zq")))) + (build-system python-build-system) + (home-page "https://github.com/sethmlarson/socksio") + (synopsis "Sans-I/O implementation of SOCKS4, SOCKS4A, and SOCKS5.") + (description "The @code{socksio} Python module is a client-side sans-I/O +SOCKS proxy implementation. It supports SOCKS4, SOCKS4A, and SOCKS5. +@code{socksio} is a sans-I/O library similar to @code{h11} or @code{h2}; this +means the library itself does not handle the actual sending of the bytes +through the network, it only deals with the implementation details of the +SOCKS protocols. It can be paired with any I/O library.") + (license license:expat))) + (define-public python-azure-nspkg (package (name "python-azure-nspkg") -- cgit v1.2.3 From 72d292eac0345918f7313588f9e6de1a83e57952 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 01:23:56 -0400 Subject: gnu: python-sqlalchemy: Run tests in parallel via xdist. * gnu/packages/databases.scm (python-sqlalchemy)[phases]: Use gexps. {check}: Run tests in parallel; skip slow test_memusage. * gnu/packages/databases.scm (python2-sqlalchemy): Adjust to avoid xdist. --- gnu/packages/databases.scm | 39 ++++++++++++++++++++++++++++++--------- 1 file changed, 30 insertions(+), 9 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index c70173b329..ce0e035f76 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -32,7 +32,7 @@ ;;; Copyright © 2017 Kristofer Buffington ;;; Copyright © 2018 Amirouche Boubekki ;;; Copyright © 2018 Joshua Sierles, Nextjournal -;;; Copyright © 2018, 2021 Maxim Cournoyer +;;; Copyright © 2018, 2021, 2022 Maxim Cournoyer ;;; Copyright © 2019 Jack Hill ;;; Copyright © 2019 Alex Griffin ;;; Copyright © 2019 Gábor Boskovits @@ -3367,16 +3367,21 @@ Database API 2.0T.") (build-system python-build-system) (native-inputs (list python-cython ; for C extensions - python-pytest python-mock)) ; for tests + python-pytest python-mock python-pytest-xdist)) ; for tests (propagated-inputs (list python-greenlet)) (arguments - `(#:phases - (modify-phases %standard-phases - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "py.test"))))))) + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" + "-n" (number->string (parallel-job-count)) + ;; The memory usage tests are very expensive and run in + ;; sequence; skip them. + "-k" "not test_memusage.py"))))))) (home-page "https://www.sqlalchemy.org") (synopsis "Database abstraction library") (description @@ -3388,7 +3393,23 @@ simple and Pythonic domain language.") (license license:x11))) (define-public python2-sqlalchemy - (package-with-python2 python-sqlalchemy)) + (let ((base (package-with-python2 python-sqlalchemy))) + (package + (inherit base) + (arguments + (substitute-keyword-arguments (package-arguments base) + ((#:phases phases) + #~(modify-phases #$phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" + ;; The memory usage tests are very expensive and run in + ;; sequence; skip them. + "-k" "not test_memusage.py")))))))) + ;; Do not use pytest-xdist, which is broken for Python 2. + (native-inputs (modify-inputs (package-native-inputs base) + (delete "python-pytest-xdist")))))) (define-public python-sqlalchemy-stubs (package -- cgit v1.2.3 From df95872d103f6649c81630b3f73391e741409ad7 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 00:48:19 -0400 Subject: gnu: python-sqlalchemy: Update to 1.4.35. * gnu/packages/databases.scm (python-sqlalchemy): Update to 1.4.35. --- gnu/packages/databases.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index ce0e035f76..40741a9bd2 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -3357,13 +3357,13 @@ Database API 2.0T.") (define-public python-sqlalchemy (package (name "python-sqlalchemy") - (version "1.4.31") + (version "1.4.35") (source (origin (method url-fetch) (uri (pypi-uri "SQLAlchemy" version)) (sha256 - (base32 "06448s883bb8fgca33bn0pfaj15la0g4cax2mmx482kqwp8mjasq")))) + (base32 "1ddab00d5mpzg25r1qxccma2zb551hhmymsy1ycp6r6w04xq3z1g")))) (build-system python-build-system) (native-inputs (list python-cython ; for C extensions -- cgit v1.2.3 From 0d585039704e9c6848d92f4f85a90dec49049a97 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 01:35:21 -0400 Subject: gnu: Add python-pecan. * gnu/packages/python-web.scm (python-pecan): New variable. --- gnu/packages/python-web.scm | 47 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 0e837c8180..9e8ae40382 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -5901,6 +5901,53 @@ Swagger.") "Manuel lets you mix and match traditional doctests with custom test syntax.") (license license:asl2.0))) +(define-public python-pecan + (package + (name "python-pecan") + (version "1.4.1") + (source + (origin + (method git-fetch) ;no tests in pypi release + (uri (git-reference + (url "https://github.com/pecan/pecan") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "10lz0cqafx3j24m52vv9ph0bxrzyx6wv2dgz7g9kfm60lhaskqkh")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'relax-requirements + (lambda _ + (substitute* "test-requirements.txt" + ;; Drop extraneous virtualenv requirement. + ((".*virtualenv.*") "")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "pecan"))))))) + (native-inputs + (list gunicorn + python-genshi + python-jinja2 + python-pytest + python-sqlalchemy + uwsgi)) + (propagated-inputs + (list python-logutils + python-mako + python-six + python-webob + python-webtest)) + (home-page "http://github.com/pecan/pecan") + (synopsis "WSGI object-dispatching web framework") + (description "This package provides a WSGI object-dispatching web +framework, designed to be lean and fast, with few dependencies.") + (license license:bsd-3))) + (define-public python-persistent (package (name "python-persistent") -- cgit v1.2.3 From eba07849372b978f65815b825955b799ccbb2866 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 09:17:07 -0400 Subject: gnu: Add python-aioredis. * gnu/packages/databases.scm (python-aioredis): New variable. --- gnu/packages/databases.scm | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 40741a9bd2..8a6ace3ed9 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -3963,6 +3963,41 @@ parsing code in hiredis. It primarily speeds up parsing of multi bulk replies." (define-public python2-hiredis (package-with-python2 python-hiredis)) +(define-public python-aioredis + (package + (name "python-aioredis") + (version "2.0.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "aioredis" version)) + (sha256 + (base32 "13nrkk45az6qdiwfpbw80ls6bfip0i27qlkh9gsp2b9zk6pim9ga")))) + (build-system python-build-system) + (arguments + (list #:phases #~(modify-phases %standard-phases + (add-before 'check 'start-redis + (lambda _ + (invoke "redis-server" "--daemonize" "yes"))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs + (list python-pytest + python-pytest-asyncio + python-uvloop + redis)) + (propagated-inputs + (list python-async-timeout + python-hiredis + python-typing-extensions)) + (home-page "https://github.com/aio-libs/aioredis-py") + (synopsis "Redis support for Python's @code{asyncio} module") + (description "This package provides Redis support for the Python +@code{asyncio} (PEP 3156) module.") + (license license:expat))) + (define-public python-fakeredis (package (name "python-fakeredis") -- cgit v1.2.3 From a64ea1f2d3cdc3292c870aa1bdee1202a0a4b12b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 01:46:37 -0400 Subject: gnu: python-fakeredis: Update to 1.7.1. * gnu/packages/databases.scm (python-fakeredis): Update to 1.7.1. [propagated-inputs]: Add python-aioredis. --- gnu/packages/databases.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 8a6ace3ed9..0595c6b6c3 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -4001,20 +4001,20 @@ parsing code in hiredis. It primarily speeds up parsing of multi bulk replies." (define-public python-fakeredis (package (name "python-fakeredis") - (version "1.7.0") + (version "1.7.1") (source (origin (method url-fetch) (uri (pypi-uri "fakeredis" version)) (sha256 (base32 - "0wacd3f558vzsrpdvgvdwy9pp6crxf8hxblz30zbsv1k63j15gf9")))) + "1v68my2v7fg44zwky3k5d52nn1bi0szpgdslghrpa2ifnjhlnb3w")))) (build-system python-build-system) (arguments ;; no tests `(#:tests? #f)) (propagated-inputs - (list python-packaging python-redis python-sortedcontainers)) + (list python-aioredis python-packaging python-redis python-sortedcontainers)) (home-page "https://github.com/jamesls/fakeredis") (synopsis "Fake implementation of redis API for testing purposes") (description -- cgit v1.2.3 From e5d34080229393b4f19fe312fbb667b9e3430afa Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 09:48:12 -0400 Subject: gnu: python-falcon: Update to 3.1.0. * gnu/packages/python-web.scm (python-falcon): Update to 3.1.0. [source]: Use git. Adjust snippet. [phases]{check}: Set HOME and invoke pytests with "-vv". [native-inputs]: Add python-aiofiles, python-cbor2, python-fakeredis, python-httpx, python-pecan, python-pillow, python-pytest-asyncio and python-websockets. [synopsis, description]: Fix indentation. --- gnu/packages/python-web.scm | 50 +++++++++++++++++++++++++++------------------ 1 file changed, 30 insertions(+), 20 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 9e8ae40382..e97630fc14 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -668,14 +668,16 @@ for resource properties and best practices.") (define-public python-falcon (package (name "python-falcon") - (version "2.0.0") + (version "3.1.0") (source (origin - (method url-fetch) - (uri (pypi-uri "falcon" version)) - (sha256 - (base32 - "1z6mqfv574x6jiawf67ib52g4kk20c2x7xk7wrn1573b8v7r79gf")) + ;; Use git, as there are some test files missing from the PyPI release, + ;; such as 'examples' directory. + (method git-fetch) + (uri (git-reference + (url "https://github.com/falconry/falcon") + (commit version))) + (file-name (git-file-name name version)) (modules '((guix build utils))) (snippet '(begin @@ -683,11 +685,13 @@ for resource properties and best practices.") (substitute* "setup.py" ((".*falcon\\.vendor\\.mimeparse.*") "")) (substitute* '("falcon/media/handlers.py" - "falcon/request.py") - (("from falcon\\.vendor ") "")) - (substitute* "falcon.egg-info/SOURCES.txt" - (("falcon/vendor.*") "")) - #t)))) + "falcon/request.py" + "tests/test_deps.py") + (("from falcon\\.vendor ") "") + (("mimeparse.mimeparse") "mimeparse")))) + (sha256 + (base32 + "17k31d8avl63xsr6fzvmkxcsm7gnz5dqpgsz65psm1lpc38c79k3")))) (build-system python-build-system) (arguments `(#:phases @@ -697,27 +701,33 @@ for resource properties and best practices.") ;; Skip orjson, which requires rust to build. (substitute* "tests/test_media_handlers.py" (("== 'CPython") "!= 'CPython")) - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "--ignore" "falcon")))))) + (setenv "HOME" "/tmp") + (invoke "pytest" "-vv" "tests")))))) (propagated-inputs (list python-mimeparse)) (native-inputs - (list python-cython ;for faster binaries + (list python-aiofiles + python-cbor2 + python-cython ;for faster binaries + python-fakeredis + python-httpx python-mujson python-msgpack + python-pecan + python-pillow python-pytest + python-pytest-asyncio python-pytest-runner python-pyyaml python-rapidjson python-requests python-testtools - python-ujson)) + python-ujson + python-websockets)) (home-page "https://falconframework.org") - (synopsis - "Web framework for building APIs and application backends") - (description - "Falcon is a web API framework for building microservices, application -backends and higher-level frameworks. Among its features are: + (synopsis "Web framework for building APIs and application backends") + (description "Falcon is a web API framework for building microservices, +application backends and higher-level frameworks. Among its features are: @itemize @item Optimized and extensible code base @item Routing via URI templates and REST-inspired resource -- cgit v1.2.3 From ea754c74d3def755d79c5a50263b3aa185f4346c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 11:04:29 -0400 Subject: gnu: Add python-dictpath. * gnu/packages/python-xyz.scm (python-dictpath): New variable. --- gnu/packages/python-xyz.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index d2245e5605..4cd26d4038 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -27135,6 +27135,25 @@ cryptographically signed ones).") dictionaries.") (license license:expat))) +(define-public python-dictpath + (package + (name "python-dictpath") + (version "0.1.3") + (source + (origin + (method url-fetch) + (uri (pypi-uri "dictpath" version)) + (sha256 + (base32 "1n4hq4wbgaw59bbb16nhkgg5wk8sl4iw940vjrgx4xmifqxxw73m")))) + (build-system python-build-system) + (native-inputs (list python-pytest python-pytest-cov python-pytest-flake8)) + (home-page "https://github.com/p1c2u/pathable") + (synopsis "Object-oriented path library for Python") + (description "This object-oriented dictionary path Python library enables +traversing resources like paths or accessing resources on demand with separate +accessor layer.") + (license license:asl2.0))) + (define-public pyzo (package (name "pyzo") -- cgit v1.2.3 From 3f9eafbedd5a9c833aed1954f8ad18b3a7699222 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 11:57:03 -0400 Subject: gnu: Add python-openapi-core. * gnu/packages/python-web.scm (python-openapi-core): New variable. --- gnu/packages/python-web.scm | 65 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index e97630fc14..9836e81f6c 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -1588,6 +1588,71 @@ OpenAPI specification against the OpenAPI 2.0 (also known as Swagger), OpenAPI compliance with the specification.") (license license:asl2.0))) +(define-public python-openapi-core + (package + (name "python-openapi-core") + (version "0.14.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/p1c2u/openapi-core") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1npsibyf8zx6z230yl19kyap8g25kqvgm7z1w6rm6jxv58yqsp7r")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "tests/unit" + ;; Ignore Pytest configuration in setup.cfg that adds + ;; unwanted flake8 and coverage options. + "-c" "/dev/null" + ;; This tests fails due to changes in Pytest; fixed + ;; but not yet released upstream + ;; (https://github.com/p1c2u/openapi-core/issues/158). + "-k" "not test_string_format_invalid_value"))))))) + (native-inputs (list python-django + python-falcon + python-flask + python-poetry-core + python-pypa-build + python-pytest + python-responses)) + (propagated-inputs + (list python-attrs + python-dictpath + python-isodate + python-jsonschema + python-lazy-object-proxy + python-more-itertools + python-openapi-schema-validator + python-openapi-spec-validator + python-parse + python-six + python-werkzeug)) + (home-page "https://github.com/p1c2u/openapi-core") + (synopsis "OpenAPI core library") + (description "Openapi-core is a Python library that adds client-side and +server-side support for the OpenAPI Specification v3. It has features such +as: +@itemize +@item Validation of requests and responses +@item Schema casting and unmarshalling +@item Media type and parameters deserialization +@item Security providers (API keys, Cookie, Basic and Bearer HTTP +authentications) +@item Custom deserializers and formats +@item Integration with libraries and frameworks. +@end itemize") + (license license:bsd-3))) + (define-public python-openid (package (name "python-openid") -- cgit v1.2.3 From 1a564cf1471267894c3360e3a5bf0296be01b75d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 12:57:35 -0400 Subject: gnu: Add python-jupyterlab-server. * gnu/packages/jupyter.scm (python-jupyterlab-server): New variable. --- gnu/packages/jupyter.scm | 50 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index 9bda6e23bd..82e7be6792 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -215,6 +215,56 @@ alternative Python kernel for Jupyter.") the JupyterLab CSS variables.") (license license:bsd-3))) +(define-public python-jupyterlab-server + (package + (name "python-jupyterlab-server") + (version "2.12.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "jupyterlab_server" version)) + (sha256 + (base32 "1gxbfa5s0v4z0v8kagkm2bz8hlli5pwhr89y68w5kxcrqfsg9q00")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "-c" "/dev/null" "tests" + ;; XXX: These tests appear to fail due to the lack of + ;; locales. + "-k" "not locale and not language"))))))) + (propagated-inputs + (list python-babel + python-entrypoints + python-importlib-metadata ;TODO: remove after Python >= 3.10 + python-jinja2 + python-json5 + python-jsonschema + python-jupyter-server + python-packaging + python-requests)) + (native-inputs + (list python-ipykernel + python-jupyter-server + python-openapi-core + python-openapi-spec-validator + python-pytest + python-pytest-console-scripts + python-pytest-tornasync + python-ruamel.yaml + python-strict-rfc3339)) + (home-page "https://jupyter.org") + (synopsis "Server components for JupyterLab applications") + (description "JupyterLab Server sits between JupyterLab and Jupyter +Server, and provides a set of REST API handlers and utilities that are used by +JupyterLab. It is a separate project in order to accommodate creating +JupyterLab-like applications from a more limited scope.") + (license license:bsd-3))) + (define-public python-jupyter-packaging (package (name "python-jupyter-packaging") -- cgit v1.2.3 From bfe7f4065095fde94a44b511ae74186a2dbe880f Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 13:40:35 -0400 Subject: gnu: python-hypothesis-6.23: Update to 6.43.3. * gnu/packages/check.scm (python-hypothesis-6.23): Update to 6.43.3 and rename to... (python-hypothesis-next): ... this. [propagated-inputs]: Add python-pytest. * gnu/packages/matrix.scm (python-matrix-nio): Adjust accordingly. * gnu/packages/python-web.scm (python-h2): Likewise. * gnu/packages/check.scm (python-hypothesis)[home-page]: Update URL. --- gnu/packages/check.scm | 12 ++++++++---- gnu/packages/matrix.scm | 2 +- gnu/packages/python-web.scm | 2 +- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 957d7a4262..8e6576208c 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -2174,20 +2174,24 @@ instantly.") much larger range of examples than you would ever want to write by hand. It’s based on the Haskell library, Quickcheck, and is designed to integrate seamlessly into your existing Python unit testing work flow.") - (home-page "https://github.com/HypothesisWorks/hypothesis-python") + (home-page "https://github.com/HypothesisWorks/hypothesis") (license license:mpl2.0) (properties `((python2-variant . ,(delay python2-hypothesis)))))) -(define-public python-hypothesis-6.23 +;;; TODO: Make the default python-hypothesis in the next rebuild cycle. +(define-public python-hypothesis-next (package (inherit python-hypothesis) - (version "6.23.4") + (version "6.43.3") (source (origin (method url-fetch) (uri (pypi-uri "hypothesis" version)) (sha256 (base32 - "0wp8i9qmd5wl1sq1l2b97fgliyk5fyphssl6j7q5qn5zjlfgi4qs")))))) + "0d67dlc5a47i48fxzmji2mnybzby0h1wdscmj54555fghcyp1045")))) + (propagated-inputs + (modify-inputs (package-propagated-inputs python-hypothesis) + (append python-pytest))))) ;to satisfy the sanity-check phase ;; This is the last version of Hypothesis that supports Python 2. (define-public python2-hypothesis diff --git a/gnu/packages/matrix.scm b/gnu/packages/matrix.scm index 5f94eb2075..9ac999b5fd 100644 --- a/gnu/packages/matrix.scm +++ b/gnu/packages/matrix.scm @@ -187,7 +187,7 @@ homeserver and generally help bootstrap the ecosystem.") (native-inputs `(("python-pytest" ,python-pytest-6) ("python-hyperframe" ,python-hyperframe) - ("python-hypothesis" ,python-hypothesis-6.23) + ("python-hypothesis" ,python-hypothesis-next) ("python-hpack" ,python-hpack) ("python-faker" ,python-faker) ("python-pytest-aiohttp" ,python-pytest-aiohttp) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 9836e81f6c..89b688da32 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -1114,7 +1114,7 @@ and that could be anything you want.") (add-installed-pythonpath inputs outputs) (invoke "python" "-m" "pytest" "-vv" "test"))))))) (native-inputs - (list python-hypothesis-6.23 python-pytest)) + (list python-hypothesis-next python-pytest)) (propagated-inputs (list python-hpack python-hyperframe)) (home-page "https://github.com/python-hyper/h2") -- cgit v1.2.3 From 411cd4345f858d038b8761b9c8bbe902aedc3e23 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 14:28:31 -0400 Subject: gnu: python-numpy: Update to 1.21.6 and parallelize build/tests. * gnu/packages/python-xyz.scm (python-numpy): Update to 1.21.6. Move inputs and native-inputs fields after arguments. Use gexps. [modules]: New argument. [phases]{parallelize-build}: New phase. {configure-blas}: Format via (ice-9 format). {fix-executable-paths}: Use search-file-input. Remove obsolete system_info.py substitution. {check}: Remove extraneous add-installed-pythonpath and setenv calls. Provide the '-n' pytest-xdist option. [native-inputs]: Use python-hypothesis-next. (python-numpy-next): Inherit from python-numpy. (python2-numpy): Adjust for gexps. [phases]{delete-failing-test}: Rename to... {delete-failing-tests}: ... this. (python2-numpy-1.8): Likewise, and delete 'delete-failing-tests' phase. Disable tests. [native-inputs]: Define as the empty list. --- gnu/packages/python-xyz.scm | 194 +++++++++++++++++++++----------------------- 1 file changed, 93 insertions(+), 101 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 4cd26d4038..7840ccfcd1 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -5703,10 +5703,13 @@ writing C extensions for Python as easy as Python itself.") "17fqacrpis05w1rpi7d7sbimrk20xf8h6d3vrz5nf6ix3899abil")))) (properties '()))) -(define-public python-numpy-next +;; NOTE: when upgrading numpy please make sure that python-numba, +;; python-pandas and python-scipy still build, as these three packages are +;; often used together. +(define-public python-numpy (package - (name "python-numpy-next") - (version "1.22.3") + (name "python-numpy") + (version "1.21.6") (source (origin (method url-fetch) @@ -5715,50 +5718,57 @@ writing C extensions for Python as easy as Python itself.") version "/numpy-" version ".tar.gz")) (sha256 (base32 - "19dw91pqbqcniw2z57kiyqs1qp56g7kqy1bdyv664g8s62sc01m9")))) + "0b0c5y35rd3mvwfk5is1d5ppfw9nl4d2rgx9xkwh1p0w394wdvyl")))) (build-system python-build-system) - (inputs - (list openblas)) - (native-inputs - (list python-cython python-hypothesis-6.23 python-pytest - python-pytest-xdist gfortran)) (arguments - `(#:phases - (modify-phases %standard-phases - (add-before 'build 'configure-blas - (lambda* (#:key inputs #:allow-other-keys) - (call-with-output-file "site.cfg" - (lambda (port) - (format port - "\ + (list + #:modules '((guix build utils) + (guix build python-build-system) + (ice-9 format)) + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'parallelize-build + (lambda _ + (setenv "NPY_NUM_BUILD_JOBS" + (number->string (parallel-job-count))))) + (add-before 'build 'configure-blas + (lambda* (#:key inputs #:allow-other-keys) + (call-with-output-file "site.cfg" + (lambda (port) + (format port + "\ [openblas] libraries = openblas library_dirs = ~a/lib -include_dirs = ~a/include -" - (assoc-ref inputs "openblas") - (assoc-ref inputs "openblas")))))) - (add-before 'build 'fix-executable-paths - (lambda* (#:key inputs #:allow-other-keys) - ;; Make /gnu/store/...-bash-.../bin/sh the default shell, - ;; instead of /bin/sh. - (substitute* "numpy/distutils/exec_command.py" - (("(os.environ.get\\('SHELL', ')(/bin/sh'\\))" match match-start match-end) - (string-append match-start (assoc-ref inputs "bash") match-end))) - ;; Use "gcc" executable, not "cc". - (substitute* "numpy/distutils/system_info.py" - (("c = distutils\\.ccompiler\\.new_compiler\\(\\)") - "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')")))) - (replace 'check - (lambda* (#:key tests? outputs inputs #:allow-other-keys) - (when tests? - ;; Make installed package available for running the tests. - (add-installed-pythonpath inputs outputs) - ;; Make sure "f2py" etc is found. - (setenv "PATH" (string-append (assoc-ref outputs "out") "/bin" - ":" (getenv "PATH"))) - (invoke "./runtests.py" - "-j" (number->string (parallel-job-count))))))))) +include_dirs = ~:*~a/include~%" #$(this-package-input "openblas")))))) + (add-before 'build 'fix-executable-paths + (lambda* (#:key inputs #:allow-other-keys) + ;; Make /gnu/store/...-bash-.../bin/sh the default shell, + ;; instead of /bin/sh. + (substitute* "numpy/distutils/exec_command.py" + (("'/bin/sh'") + (format #f "~s" (search-input-file inputs "bin/bash")))))) + (replace 'check + (lambda* (#:key tests? outputs inputs #:allow-other-keys) + (when tests? + (invoke "./runtests.py" "-vv" "--no-build" "--mode=fast" + "-j" (number->string (parallel-job-count)) + ;; Contrary to scipy, the runtests.py script of numpy + ;; does *not* automatically provide -n when -j is used + ;; (see: https://github.com/numpy/numpy/issues/21359). + "--" "-n" (number->string (parallel-job-count)) + "-k" (string-append + ;; These tests may fail on 32-bit systems (see: + ;; https://github.com/numpy/numpy/issues/18387). + "not test_float_remainder_overflow " + "and not test_pareto")))))))) + (native-inputs + (list python-cython + python-hypothesis-next + python-pytest + python-pytest-xdist + gfortran)) + (inputs (list bash openblas)) (home-page "https://numpy.org") (synopsis "Fundamental package for scientific computing with Python") (description "NumPy is the fundamental package for scientific computing @@ -5769,10 +5779,26 @@ capabilities.") (properties `((python2-variant . ,(delay python2-numpy)))) (license license:bsd-3))) +(define-public python-numpy-next + (package + (inherit python-numpy) + (name "python-numpy-next") + (version "1.22.3") + (source + (origin + (inherit (package-source python-numpy)) + (method url-fetch) + (uri (string-append + "https://github.com/numpy/numpy/releases/download/v" + version "/numpy-" version ".tar.gz")) + (sha256 + (base32 + "19dw91pqbqcniw2z57kiyqs1qp56g7kqy1bdyv664g8s62sc01m9")))))) + ;; Numpy 1.16.x are the last versions that support Python 2. (define-public python2-numpy (let ((numpy (package-with-python2 - (strip-python2-variant python-numpy-next)))) + (strip-python2-variant python-numpy)))) (package (inherit numpy) (name "python2-numpy") @@ -5788,80 +5814,46 @@ capabilities.") (arguments (substitute-keyword-arguments (package-arguments numpy) ((#:phases phases) - `(modify-phases ,phases - (add-after 'unpack 'delete-failing-test - (lambda _ - ;; There's just one failing test here. - (delete-file "numpy/linalg/tests/test_linalg.py") - ;; ...and this one depends on the previous one. - (delete-file "numpy/matrixlib/tests/test_matrix_linalg.py"))))))) + #~(modify-phases #$phases + (add-after 'unpack 'delete-failing-tests + (lambda _ + ;; There's just one failing test here. + (delete-file "numpy/linalg/tests/test_linalg.py") + ;; ...and this one depends on the previous one. + (delete-file "numpy/matrixlib/tests/test_matrix_linalg.py"))) + (replace 'check + ;; Older versions don't cope well with the extra Pytest + ;; options, so remove them. + (lambda* (#:key tests? outputs inputs #:allow-other-keys) + (when tests? + (invoke "./runtests.py" "-vv" "--no-build" "--mode=fast" + "-j" (number->string (parallel-job-count)))))))))) (native-inputs (list python2-cython python2-pytest gfortran))))) -;; Needed by python-numba, see https://github.com/numba/numba/issues/7176 -(define-public python-numpy-1.20 - (package - (inherit python-numpy-next) - (name "python-numpy") - (version "1.20.3") - (source (origin - (method url-fetch) - (uri (string-append - "https://github.com/numpy/numpy/releases/download/v" - version "/numpy-" version ".tar.gz")) - (sha256 - (base32 - "140zq9snx0di4id4g97vaw9zz8x2rfla5lp3a70j666f5030yd5p")))) - ;; python-numpy-next replaced python-hypothesis with - ;; python-hypothesis-6.23. We switch it back here, to prevent - ;; python-numpy-1.20 and its numerous dependents from being rebuilt. - (native-inputs - (list python-cython python-hypothesis python-pytest - python-pytest-xdist gfortran)) - ;; 92 tests fail, many of them because parts of the temp file name - ;; accidentally ends up in a comparison. - (arguments - (substitute-keyword-arguments (package-arguments python-numpy-next) - ((#:tests? _ #t) #f))))) - -;; NOTE: when upgrading numpy please make sure that python-pandas and -;; python-scipy still build, as these three packages are often used together. -(define-public python-numpy python-numpy-1.20) - ;; NOTE: NumPy 1.8 is packaged only for Python 2 because it is of ;; interest only for legacy code going back to NumPy's predecessor ;; Numeric. (define-public python2-numpy-1.8 - (package (inherit python2-numpy) + (package + (inherit python2-numpy) (version "1.8.2") (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/numpy/numpy") - (commit (string-append "v" version)))) + (url "https://github.com/numpy/numpy") + (commit (string-append "v" version)))) (file-name (git-file-name "numpy" version)) (sha256 (base32 "0ikgi15rsqwbkfsjjxrwh40lqyal2wvyp3923y6w6ch3dcr82sfk")))) - (arguments - (substitute-keyword-arguments (package-arguments python2-numpy) - ((#:phases phases) - `(modify-phases ,phases - (replace 'configure-blas - (lambda* (#:key inputs #:allow-other-keys) - (call-with-output-file "site.cfg" - (lambda (port) - (format port - "[openblas] -libraries = openblas -library_dirs = ~a/lib -include_dirs = ~a/include -" - (assoc-ref inputs "openblas") - (assoc-ref inputs "openblas")))))))))) - (native-inputs - (list python2-nose)) + (arguments (substitute-keyword-arguments (package-arguments python2-numpy) + ((#:tests? _ #f) #f) ;disable tests + ((#:phases phases) + #~(modify-phases #$phases + (delete 'delete-failing-tests))))) + (native-inputs '()) (description "NumPy is the fundamental package for scientific computing with Python. It contains among other things: a powerful N-dimensional array object, sophisticated (broadcasting) functions, tools for integrating C/C++ -- cgit v1.2.3 From 152e45ef4db65dd4776c9d8544862d7952085935 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 14:56:43 -0400 Subject: gnu: python-llvmlite: Update to 0.38.0. * gnu/packages/llvm.scm (python-llvmlite): Update to 0.38.0. --- gnu/packages/llvm.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm index 0fc2a8e380..b84d987dbb 100644 --- a/gnu/packages/llvm.scm +++ b/gnu/packages/llvm.scm @@ -17,7 +17,7 @@ ;;; Copyright © 2020 Giacomo Leidi ;;; Copyright © 2020 Jakub Kądziołka ;;; Copyright © 2021, 2022 Maxime Devos -;;; Copyright © 2020, 2021 Maxim Cournoyer +;;; Copyright © 2020, 2021, 2022 Maxim Cournoyer ;;; Copyright © 2021 Julien Lepiller ;;; Copyright © 2021 Lars-Dominik Braun ;;; Copyright © 2021, 2022 Guillaume Le Vaillant @@ -1503,14 +1503,14 @@ with that of libgomp, the GNU Offloading and Multi Processing Library.") (define-public python-llvmlite (package (name "python-llvmlite") - (version "0.37.0") + (version "0.38.0") (source (origin (method url-fetch) (uri (pypi-uri "llvmlite" version)) (sha256 (base32 - "05avhsvdcqh8wfpblx16qslfq3masqcbkfyn8p3c13h1rmqbi4k3")))) + "0p4nyic9rm7s2fm3m3wpkh568594p9q9nfyjkqxny49vrxn1d7d9")))) (build-system python-build-system) (arguments `(#:phases -- cgit v1.2.3 From feee911366d3da00c0872f46944c36a7d12859b3 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 14:58:29 -0400 Subject: gnu: python-numba: Update to 0.55.1. * gnu/packages/python-xyz.scm (python-numba): Update to 0.55.1. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 7840ccfcd1..8a9c3ae1a4 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -23692,14 +23692,14 @@ validation testing and application logic.") (define-public python-numba (package (name "python-numba") - (version "0.54.1") + (version "0.55.1") (source (origin (method url-fetch) (uri (pypi-uri "numba" version)) (sha256 (base32 - "0gzl2hz9azav9mny4mga19096rrnpw5816r1h4iwrvb4r01wipzr")))) + "18rf8i32m1045zxglvicpgldvzmqdxqvs3dhjd7wilb64sd0ds83")))) (build-system python-build-system) (arguments `(#:phases -- cgit v1.2.3 From 8b390a8750b9d47924cdb49d3459668f0703fcea Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 15:27:38 -0400 Subject: gnu: python-pandas: Build and run tests in parallel. * gnu/packages/python-science.scm (python-pandas) [phases]{enable-parallel-build}: New phase. {check}: Add xdist -n option. Skip test_memory_usage test. [native-inputs]: Add python-pytest-xdist. --- gnu/packages/python-science.scm | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index 2cabdb490c..21ed2c7694 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -413,6 +413,12 @@ library.") (srfi srfi-26)) #:phases (modify-phases %standard-phases + (add-after 'unpack 'enable-parallel-build + (lambda _ + (substitute* "setup.py" + (("\"-j\", type=int, default=1") + (format #f "\"-j\", type=int, default=~a" + (parallel-job-count)))))) (add-after 'unpack 'patch-which (lambda* (#:key inputs #:allow-other-keys) (let ((which (assoc-ref inputs "which"))) @@ -439,6 +445,7 @@ library.") (when tests? (invoke "pytest" "-vv" "pandas" "--skip-slow" "--skip-network" + "-n" (number->string (parallel-job-count)) "-k" (string-append ;; These test access the internet (see: @@ -448,7 +455,11 @@ library.") "not test_wrong_url" ;; TODO: Missing input " and not TestS3" - " and not s3")))))))))) + " and not s3" + ;; This test fails when run with pytest-xdist + ;; (see: + ;; https://github.com/pandas-dev/pandas/issues/39096). + " and not test_memory_usage")))))))))) (propagated-inputs (list python-jinja2 python-numpy @@ -466,6 +477,7 @@ library.") python-html5lib python-pytest python-pytest-mock + python-pytest-xdist ;; Needed to test clipboard support. xorg-server-for-tests)) (home-page "https://pandas.pydata.org") -- cgit v1.2.3 From c359a4fabba7c6fab2498d602f5a63d4cebcc5e4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 15:55:35 -0400 Subject: gnu: python-pandas: Update to 1.4.2. * gnu/packages/python-science.scm (python-pandas): Update to 1.4.2. --- gnu/packages/python-science.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index 21ed2c7694..0ff971e46c 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -397,13 +397,13 @@ library.") (define-public python-pandas (package (name "python-pandas") - (version "1.3.5") + (version "1.4.2") (source (origin (method url-fetch) (uri (pypi-uri "pandas" version)) (sha256 - (base32 "1wd92ra8xcjgigbypid53gvby89myg68ica6r8hdw4hhvvsqahhy")))) + (base32 "04lsak3j5hq2hk0vfjf532rdxdqmg2akamdl4yl3qipihp2izg4j")))) (build-system python-build-system) (arguments `(#:modules ((guix build utils) -- cgit v1.2.3 From 1d1f44b7099a745028a4d99d623c709ab004524b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 17:23:40 -0400 Subject: gnu: python-scikit-learn: Parallelize build and test suite. * gnu/packages/machine-learning.scm (python-scikit-learn) [phases]{configure}: New phase. {build-ext}: Add '-j' option. {check}: Add '-n' option. [native-inputs]: Add python-pytest-xdist. --- gnu/packages/machine-learning.scm | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index 7f082ee677..b765257d98 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -16,7 +16,7 @@ ;;; Copyright © 2020 Konrad Hinsen ;;; Copyright © 2020 Edouard Klein ;;; Copyright © 2020, 2021, 2022 Vinicius Monego -;;; Copyright © 2020, 2021 Maxim Cournoyer +;;; Copyright © 2020, 2021, 2022 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -1095,8 +1095,13 @@ computing environments.") (arguments `(#:phases (modify-phases %standard-phases + (add-before 'build 'configure + (lambda _ + (setenv "SKLEARN_BUILD_PARALLEL" + (number->string (parallel-job-count))))) (add-after 'build 'build-ext - (lambda _ (invoke "python" "setup.py" "build_ext" "--inplace"))) + (lambda _ (invoke "python" "setup.py" "build_ext" "--inplace" + "-j" (number->string (parallel-job-count))))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? @@ -1107,13 +1112,15 @@ computing environments.") (setenv "HOME" "/tmp") (invoke "pytest" "sklearn" "-m" "not network" + "-n" (number->string (parallel-job-count)) ;; This test tries to access the internet. "-k" "not test_load_boston_alternative"))))))) - (inputs - (list openblas)) + (inputs (list openblas)) (native-inputs - (list python-pytest python-pandas ;for tests - python-cython)) + (list python-cython + python-pandas + python-pytest + python-pytest-xdist)) (propagated-inputs (list python-numpy python-threadpoolctl python-scipy python-joblib)) (home-page "https://scikit-learn.org/") -- cgit v1.2.3 From 06b0512260b366513c7f3c3e8f9a6b298da968b7 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 17:43:43 -0400 Subject: gnu: python-pynndescent: Update to 0.5.6. * gnu/packages/machine-learning.scm (python-pynndescent): Update to 0.5.6. [phases]{check}: Skip the test_weighted_minkowski test. [native-inputs, propagated-inputs]: Re-indent. --- gnu/packages/machine-learning.scm | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index b765257d98..5f14453f01 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -1210,13 +1210,13 @@ for scientific computing and data science (e.g. BLAS and OpenMP).") (define-public python-pynndescent (package (name "python-pynndescent") - (version "0.5.5") + (version "0.5.6") (source (origin (method url-fetch) (uri (pypi-uri "pynndescent" version)) (sha256 - (base32 "10pqqqc3jkpw03cyzy04slxmpgyhqnlgbyk0c1cv7kqr5d0zhzbs")))) + (base32 "0p3jsdcprjfzz7qf5674dsqfpvdn6p4wgqikg7b6ki5abf433yv1")))) (build-system python-build-system) (arguments `(#:phases @@ -1224,12 +1224,16 @@ for scientific computing and data science (e.g. BLAS and OpenMP).") (replace 'check (lambda* (#:key inputs outputs tests? #:allow-other-keys) (when tests? - (add-installed-pythonpath inputs outputs) - (invoke "python" "-m" "pytest" "--pyargs" "pynndescent"))))))) - (native-inputs - (list python-pytest)) + (invoke "python" "-m" "pytest" "--pyargs" "pynndescent" + ;; wminkowski no longer exists in scipy 1.8.0 (see: + ;; https://github.com/lmcinnes/pynndescent/issues/177) + "-k" "not test_weighted_minkowski"))))))) + (native-inputs (list python-pytest)) (propagated-inputs - (list python-joblib python-llvmlite python-numba python-scikit-learn + (list python-joblib + python-llvmlite + python-numba + python-scikit-learn python-scipy)) (home-page "https://github.com/lmcinnes/pynndescent") (synopsis "Nearest neighbor descent for approximate nearest neighbors") -- cgit v1.2.3 From 34106c85d8a95c92d110bb657f09ada36401ff29 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 20:09:37 -0400 Subject: gnu: python-umap-learn: Update to 0.5.3. * gnu/packages/machine-learning.scm (python-umap-learn): Update to 0.5.3. [source]: Use git. [arguments]: New field. [native-inputs]: Delete python-joblib and python-nose. Add python-pytest. [propagated-inputs]: Add python-pynndescent and python-tqdm. [synopsis]: Fix indentation. [description]: Fix typo and re-indent. --- gnu/packages/machine-learning.scm | 40 ++++++++++++++++++++++++++------------- 1 file changed, 27 insertions(+), 13 deletions(-) diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index 5f14453f01..3897342345 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -2796,26 +2796,40 @@ These include a barrier, broadcast, and allreduce.") (define-public python-umap-learn (package (name "python-umap-learn") - (version "0.3.10") + (version "0.5.3") (source (origin - (method url-fetch) - (uri (pypi-uri "umap-learn" version)) + (method git-fetch) ;no tests in pypi release + (uri (git-reference + (url "https://github.com/lmcinnes/umap") + (commit version))) + (file-name (git-file-name name version)) (sha256 (base32 - "02ada2yy6km6zgk2836kg1c97yrcpalvan34p8c57446finnpki1")))) + "1315jkb0h1b579y9m59632f0nnpksilm01nxx46in0rq8zna8vsb")))) (build-system python-build-system) - (native-inputs - (list python-joblib python-nose)) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "HOME" "/tmp") + (invoke "pytest" "-vv" "umap"))))))) + (native-inputs (list python-pytest)) (propagated-inputs - (list python-numba python-numpy python-scikit-learn python-scipy)) + (list python-numba + python-numpy + python-pynndescent + python-scikit-learn + python-scipy + python-tqdm)) (home-page "https://github.com/lmcinnes/umap") - (synopsis - "Uniform Manifold Approximation and Projection") - (description - "Uniform Manifold Approximation and Projection is a dimension reduction -technique that can be used for visualisation similarly to t-SNE, but also for -general non-linear dimension reduction.") + (synopsis "Uniform Manifold Approximation and Projection") + (description "Uniform Manifold Approximation and Projection is a dimension +reduction technique that can be used for visualization similarly to t-SNE, but +also for general non-linear dimension reduction.") (license license:bsd-3))) (define-public nnpack -- cgit v1.2.3 From 5f3457ccbb0bf34391f58ec2e96bd482a3dc9b9c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 20:25:53 -0400 Subject: gnu: python-jupyter-server: Update to 1.16.0. * gnu/packages/jupyter.scm (python-jupyter-server): Update to 1.16.0. [propagated-inputs]: Remove python-ipython-genutils and python-requests-unixsocket. --- gnu/packages/jupyter.scm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index 82e7be6792..aaf69af5c6 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -307,14 +307,14 @@ JavaScript build steps.") (define-public python-jupyter-server (package (name "python-jupyter-server") - (version "1.10.2") + (version "1.16.0") (source (origin (method url-fetch) (uri (pypi-uri "jupyter_server" version)) (sha256 (base32 - "1gvjbsw5nl94hz02rnkr4g4kkvh9fz7i45vz17hzwyvdpj7bd8yk")))) + "0fj6l34m6vk3yic87isz9bzgg4qsbr285x1faamf512bsrxghmn7")))) (build-system python-build-system) (arguments `(#:phases @@ -341,7 +341,6 @@ JavaScript build steps.") (propagated-inputs (list python-anyio python-argon2-cffi - python-ipython-genutils python-jinja2 python-jupyter-client python-jupyter-core @@ -349,7 +348,6 @@ JavaScript build steps.") python-nbformat python-prometheus-client python-pyzmq - python-requests-unixsocket python-send2trash python-terminado python-tornado-6 -- cgit v1.2.3 From 5fcd6aefe9ff972145401bcc927b597b182a2294 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 21:13:50 -0400 Subject: gnu: python-voila: Update to 0.3.5. * gnu/packages/jupyter.scm (python-voila): Update to 0.3.5. [source]: Use git. [arguments]: New field. [propagated-inputs]: Add python-jupyterlab-server, python-traitlets and python-websockets. [native-inputs]: Remove python-jupyter-packaging and python-setuptools. Add python-numpy and python-pandas. --- gnu/packages/jupyter.scm | 42 ++++++++++++++++++++++++++++++++++-------- 1 file changed, 34 insertions(+), 8 deletions(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index aaf69af5c6..109241771a 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -713,26 +713,52 @@ datasets across widgets.") (define-public python-voila (package (name "python-voila") - (version "0.2.10") + (version "0.3.5") (source (origin - (method url-fetch) - (uri (pypi-uri "voila" version)) + (method git-fetch) ;no tests in pypi archive + (uri (git-reference + (url "https://github.com/voila-dashboards/voila") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) (sha256 (base32 - "0krfc95yjlhjdmrsladhy6lpf4xs1zw49nmkyl4pkykndglvwa1m")))) + "10qn34ddmcwcl9zxa0gwxarxr64k8hx4yysdwrf0iqvmzmkwmbbj")))) (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'relax-requirements + (lambda _ + (substitute* "setup.cfg" + (("nbclient>=0.4.0,<0.6") + "nbclient")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "HOME" "/tmp") + (invoke "pytest" "-vv" + ;; Many tests depend on Node JavaScript dependencies + ;; and a running HTTP server; ignore them. + "--ignore" "tests/app" + "--ignore" "tests/server"))))))) (propagated-inputs - (list python-jupyter-client python-jupyter-server python-nbclient - python-nbconvert)) + (list python-jupyter-client + python-jupyter-server + python-jupyterlab-server + python-nbclient + python-nbconvert + python-traitlets + python-websockets)) (native-inputs (list python-ipywidgets - python-jupyter-packaging python-matplotlib python-mock + python-numpy + python-pandas python-pytest python-pytest-tornasync - python-setuptools python-tornado-6)) (home-page "https://github.com/voila-dashboards/voila") (synopsis "Render live Jupyter notebooks with interactive widgets") -- cgit v1.2.3 From 2c30237809f975dbdf40d503fc9604de0013b870 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 21:23:14 -0400 Subject: gnu: python-sparqlwrapper: Update to 2.0.0. * gnu/packages/rdf.scm (python-sparqlwrapper): Update to 2.0.0. [source]: Adjust Git URI. --- gnu/packages/rdf.scm | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/gnu/packages/rdf.scm b/gnu/packages/rdf.scm index e3a26cf734..826330585d 100644 --- a/gnu/packages/rdf.scm +++ b/gnu/packages/rdf.scm @@ -8,6 +8,7 @@ ;;; Copyright © 2020 Efraim Flashner ;;; Copyright © 2020 pukkamustard ;;; Copyright © 2022 Marius Bakke +;;; Copyright © 2022 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -473,24 +474,20 @@ C++ library as well as various command-line tools to to work with HDT.") (define-public python-sparqlwrapper (package (name "python-sparqlwrapper") - (version "1.8.5") + (version "2.0.0") (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/RDFLib/sparqlwrapper.git") + (url "https://github.com/RDFLib/sparqlwrapper") (commit version))) (file-name (git-file-name name version)) (sha256 (base32 - "1ia5h06zf6kpw6gdi7f80pzx10m79brj08zrbffb5wn9hzz8x528")))) + "1b4vg754kcxvinwdv7pjfmwbnmgm50w8mb2naf2lwp27bpyllvkb")))) (build-system python-build-system) (arguments '(#:tests? #f)) ; The test suite simply queries external HTTP endpoints. - (native-inputs - ;; Build with setuptools <58 to get lib2to3 support. - (list python-nose python-setuptools)) - (propagated-inputs - (list python-rdflib)) + (propagated-inputs (list python-rdflib)) (home-page "https://rdflib.dev/sparqlwrapper/") (synopsis "SPARQL Endpoint interface to Python") (description "Python wrapper around a SPARQL service. It helps in creating -- cgit v1.2.3 From 7fc8e9ea90f0254d675ec93c08abe8d172033894 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 21:31:37 -0400 Subject: gnu: python-sparqlkernel: Use gexps and fix inputs. [arguments]: Use gexps. [tests?]: Add comment. [phases]: Delete trailing #t. {no-custom-css}: Use a regular lambda. {install-kernelspec}: Move after the add-installed-pythonpath phase. Remove now extraneous add-installed-pythonpath call. Adjust for gexps. [native-inputs]: Delete field. [propagated-inputs]: Add python-ipykernel, python-notebook, python-rdflib and pythopython-traitlets. [description]: Avoid '&' in description. --- gnu/packages/jupyter.scm | 43 +++++++++++++++++++++---------------------- 1 file changed, 21 insertions(+), 22 deletions(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index 109241771a..dbb96b890b 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -620,33 +620,32 @@ Docker registry.") "004v22nyi5cnpxq4fiws89p7i5wcnzv45n3n70axdd6prh6rkapx")))) (build-system python-build-system) (arguments - `(#:tests? #f - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'no-custom-css - (lambda* (#:key inputs #:allow-other-keys) + (list + #:tests? #f ;no test suite + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'no-custom-css + (lambda _ (substitute* "sparqlkernel/install.py" - (("install_custom_css\\( destd, PKGNAME \\)") "")) - #t)) - (add-after 'install 'install-kernelspec - (lambda* (#:key inputs outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - (setenv "HOME" "/tmp") - (add-installed-pythonpath inputs outputs) - (invoke - (string-append out "/bin/jupyter-sparqlkernel") - "install" - (string-append "--InstallKernelSpec.prefix=" out)) - #t)))))) - (native-inputs - (list python-traitlets python-jupyter-client python-notebook - python-ipykernel python-html5lib-0.9)) + (("install_custom_css\\( destd, PKGNAME \\)") "")))) + (add-after 'add-install-to-pythonpath 'install-kernelspec + (lambda _ + (setenv "HOME" "/tmp") + (invoke + (string-append #$output "/bin/jupyter-sparqlkernel") + "install" + (string-append "--InstallKernelSpec.prefix=" #$output))))))) (propagated-inputs - (list python-sparqlwrapper python-pygments)) + (list python-ipykernel + python-notebook + python-pygments + python-rdflib + python-sparqlwrapper + python-traitlets)) (home-page "https://github.com/paulovn/sparql-kernel") (synopsis "Jupyter kernel for SPARQL") (description "This module installs a Jupyter kernel for SPARQL. It allows -sending queries to an SPARQL endpoint and fetching & presenting the results in +sending queries to an SPARQL endpoint, fetching and presenting the results in a notebook.") (license license:bsd-3))) -- cgit v1.2.3 From 1178fdee3bdc6072c080fed37911f949e7fcbc14 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 21:47:03 -0400 Subject: gnu: python-jupyter-protocol: Update to 0.2.0. * gnu/packages/jupyter.scm (python-jupyter-protocol): Update to 0.2.0. [propagated-inputs]: Add python-ipython-genutils. --- gnu/packages/jupyter.scm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index dbb96b890b..9c5ae23f79 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -54,16 +54,19 @@ (define-public python-jupyter-protocol (package (name "python-jupyter-protocol") - (version "0.1.1") + (version "0.2.0") (source (origin (method url-fetch) (uri (pypi-uri "jupyter_protocol" version)) (sha256 (base32 - "1bk3as5yw9y5nmq6l15nr46aby34phmvsx9kxgqnm5pd5q2b5h57")))) + "075vbaak6hlk9606lw61ldv72p6694k938jd1kvkm6spd0pczpmn")))) (build-system python-build-system) (propagated-inputs - (list python-dateutil python-jupyter-core python-pyzmq + (list python-dateutil + python-ipython-genutils + python-jupyter-core + python-pyzmq python-traitlets)) (native-inputs (list python-ipykernel python-ipython python-mock python-pytest)) -- cgit v1.2.3 From bf17d082566f6c912bc0bd75e3e1791ad2cc7901 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 22:12:50 -0400 Subject: gnu: python-jupyter-kernel-mgmt: Update to 0.5.1 and disable tests. * gnu/packages/jupyter.scm (python-jupyter-kernel-mgmt): Update to 0.5.1. [arguments]: New field. [propagated-inputs]: Add python-tornado. [native-inputs]: Remove python-mock. Add python-async-generator and python-pytest-asyncio. --- gnu/packages/jupyter.scm | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index 9c5ae23f79..336af2e24a 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -82,23 +82,40 @@ protocol} to be used by both clients and kernels.") (define-public python-jupyter-kernel-mgmt (package (name "python-jupyter-kernel-mgmt") - (version "0.4.0") + (version "0.5.1") (source (origin (method url-fetch) (uri (pypi-uri "jupyter_kernel_mgmt" version)) (sha256 (base32 - "0i7a78dn89ca8h0a42giyxwcmk6y4wrdr7q8h2ax9vybb84c795q")))) + "0977ixfi1pzjgy84hl0zycg4wpllmid98fhzcpy0lxd322w4sl7x")))) (build-system python-build-system) + (arguments + (list + ;; There are 8 test failures, most of them in 'test_client_loop.py' + ;; (see: https://github.com/takluyver/jupyter_kernel_mgmt/issues/48). + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "HOME" "/tmp") + (invoke "pytest" "-vv" "jupyter_kernel_mgmt"))))))) (propagated-inputs (list python-dateutil python-entrypoints python-jupyter-core python-jupyter-protocol python-pyzmq + python-tornado python-traitlets)) (native-inputs - (list python-ipykernel python-ipython python-mock python-pytest)) + (list python-async-generator + python-ipykernel + python-ipython + python-pytest + python-pytest-asyncio)) (home-page "https://jupyter.org") (synopsis "Discover, launch, and communicate with Jupyter kernels") (description -- cgit v1.2.3 From d9bb301460b77ff2633a8be2fd8a9e600b8371d0 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 22:17:49 -0400 Subject: gnu: xeus: Update to 2.4.1. * gnu/packages/jupyter.scm (xeus): Update to 2.4.1. [source]: Update Git URI. --- gnu/packages/jupyter.scm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gnu/packages/jupyter.scm b/gnu/packages/jupyter.scm index 336af2e24a..5bcbd99c24 100644 --- a/gnu/packages/jupyter.scm +++ b/gnu/packages/jupyter.scm @@ -170,15 +170,15 @@ Messaging Protocol}.") (define-public xeus (package (name "xeus") - (version "0.23.2") + (version "2.4.1") (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/QuantStack/xeus") + (url "https://github.com/jupyter-xeus/xeus") (commit version))) (sha256 (base32 - "1m1b6z1538r7mv2ggn7bdbd9570ja7cadplq64zl8rgl2c8vdi2a")) + "1k1h416qkw3yra6ayfa61nv0v4ify2wvp5x27slgbcw6c88w7fb1")) (file-name (git-file-name name version)))) (build-system cmake-build-system) (arguments @@ -190,7 +190,7 @@ Messaging Protocol}.") ;; The following inputs are used by the test suite. googletest python-pytest - python-3 + python-wrapper python-jupyter-kernel-test python-jupyter-client)) (inputs @@ -199,7 +199,7 @@ Messaging Protocol}.") cppzmq zeromq openssl - `(,util-linux "lib"))) ;libuuid + `(,util-linux "lib"))) ;libuuid (home-page "https://quantstack.net/xeus") (synopsis "C++ implementation of the Jupyter Kernel protocol") (description -- cgit v1.2.3 From f2dfeef93139efdc4e64a2003ec7ed9711db96ae Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 18 Apr 2022 23:16:08 -0400 Subject: gnu: python-types-dataclasses: Fix typo. * gnu/packages/python-xyz.scm (python-types-dataclasses): Fix typo in description. --- gnu/packages/python-xyz.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 8a9c3ae1a4..d3f9109ec7 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -30317,7 +30317,7 @@ multipurpose analysis in Python.") (home-page "https://github.com/python/typeshed") (synopsis "Typing stubs for dataclasses") (description - "This packages provides a collection of library stubs for Python, with + "This package provides a collection of library stubs for Python, with static types.") (license license:asl2.0))) -- cgit v1.2.3 From fa3f7073a98d7c37036712becda3167f4db6a2aa Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 01:20:05 -0400 Subject: gnu: python-cmarkgfm: Update to 0.8.0. * gnu/packages/markup.scm (python-cmarkgfm): Update to 0.8.0. --- gnu/packages/markup.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/markup.scm b/gnu/packages/markup.scm index 0292c02a7f..791035deb3 100644 --- a/gnu/packages/markup.scm +++ b/gnu/packages/markup.scm @@ -252,13 +252,13 @@ implementation. (define-public python-cmarkgfm (package (name "python-cmarkgfm") - (version "0.7.0") + (version "0.8.0") (source (origin (method url-fetch) (uri (pypi-uri "cmarkgfm" version)) (sha256 (base32 - "06cw49bzxl3k7m8993cyi5zqxvk817z8ghhr9xqq5gx8klpiap56")) + "1jxk9cdir4q1bpjla7b7y1qfjmr7mkd0f802b2sb88njk079p1gy")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From ef4473051e82d94560b38ca76e9a0ad4b7f410ae Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 01:26:59 -0400 Subject: gnu: python-readme-renderer: Update to 34.0. * gnu/packages/python-xyz.scm (python-readme-renderer): Update to 34.0. [phases]{check}: Skip GFM tests for now. --- gnu/packages/python-xyz.scm | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index d3f9109ec7..a2713caa0f 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -27441,14 +27441,14 @@ positioning, and keyboard input.") (define-public python-readme-renderer (package (name "python-readme-renderer") - (version "32.0") + (version "34.0") (source (origin (method url-fetch) (uri (pypi-uri "readme_renderer" version)) (sha256 (base32 - "11av194kgq6mvp2afpapkb6vyn3y14gingmgsp3n10krlspvw4mm")))) + "1c75h9znffc2lh4j56yg23l5ifj5l8fbdq3kfigi8vbh45zx3d6z")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases @@ -27460,7 +27460,12 @@ positioning, and keyboard input.") "cmarkgfm>=0.5.0")))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) - (when tests? (invoke "pytest" "-vv"))))))) + (when tests? + ;; The GFM tests fail due to slight differences in the + ;; generated vs expected HTML due to using a more + ;; recent bleach version (see: + ;; https://github.com/pypa/readme_renderer/issues/234). + (invoke "pytest" "-vv" "-k" "not GFM"))))))) (propagated-inputs (list python-bleach python-docutils python-pygments -- cgit v1.2.3 From d95db23cb1d657bf017681afc1a674e41c1aa7d8 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 11:10:41 -0400 Subject: gnu: mbed-tools: Update to 7.53.0 and relax click version requirement. * gnu/packages/embedded.scm (mbed-tools): Update to 7.53.0. [phases]{relax-requirements}: New phase. --- gnu/packages/embedded.scm | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/gnu/packages/embedded.scm b/gnu/packages/embedded.scm index de8d2944bc..9257eea3b0 100644 --- a/gnu/packages/embedded.scm +++ b/gnu/packages/embedded.scm @@ -11,6 +11,7 @@ ;;; Copyright © 2020, 2021, 2022 Simon South ;;; Copyright © 2021 Morgan Smith ;;; Copyright © 2022 Mathieu Othacehe +;;; Copyright © 2022 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -1647,17 +1648,22 @@ whereas kdmx creates pseudo-ttys.") (define-public mbed-tools (package (name "mbed-tools") - (version "7.49.1") + (version "7.53.0") (source (origin (method url-fetch) (uri (pypi-uri "mbed-tools" version)) (sha256 (base32 - "07w1h1093xzpg8agw9hjhki5856mam2c6f3q7jb2866n82cihkg9")))) + "0gdmyxy97bqr9bmkg90v3axmrr2db734nwzq2l05z84x9qiarc9i")))) (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'relax-requirements + (lambda _ + (substitute* "setup.py" + (("\"Click>=7.1,<8\"") + "\"Click>=7.1\"")))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? -- cgit v1.2.3 From 046e5f0d041c9122c0881e8e5d1b5927aa44e9e5 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 11:28:07 -0400 Subject: gnu: conan: Update to 1.47.0 and relax PyYAML requirement. * gnu/packages/package-management.scm (conan): Update to 1.47.0. [phases]{check}: Skip the test_apt_check test. {relax-requirements}: Drop upper bound on PyYAML. --- gnu/packages/package-management.scm | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index e8d182a3bf..10b0e010de 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -18,7 +18,7 @@ ;;; Copyright © 2020 Martin Becze ;;; Copyright © 2020 Vincent Legoll ;;; Copyright © 2021 Ivan Gankevich -;;; Copyright © 2021 Maxim Cournoyer +;;; Copyright © 2021, 2022 Maxim Cournoyer ;;; Copyright © 2021 John Kehayias ;;; Copyright © 2022 Zhu Zihao ;;; @@ -1112,7 +1112,7 @@ written entirely in Python.") (define-public conan (package (name "conan") - (version "1.42.0") + (version "1.47.0") (source (origin (method git-fetch) ;no tests in PyPI archive @@ -1122,7 +1122,7 @@ written entirely in Python.") (file-name (git-file-name name version)) (sha256 (base32 - "153npvj81m1c33gfcv2nry7xhyikxnhjns7lvs525f1x20ck6asg")))) + "1zs2xb22rsy5fsc0fd7c95vrx1mfz7vasyg1lqkzyfimvn5zah6n")))) (build-system python-build-system) (arguments `(#:phases @@ -1133,7 +1133,9 @@ written entirely in Python.") (("node-semver==0.6.1") "node-semver>=0.6.1") (("Jinja2>=2.9, <3") - "Jinja2>=2.9")))) + "Jinja2>=2.9") + (("PyYAML>=3.11, <6.0") + "PyYAML")))) (add-after 'unpack 'patch-paths (lambda* (#:key inputs #:allow-other-keys) (let ((coreutils (assoc-ref inputs "coreutils"))) @@ -1189,6 +1191,8 @@ written entirely in Python.") ;; This one fails for unknown reasons (see: ;; https://github.com/conan-io/conan/issues/9671). "and not test_build " + ;; This test expects the 'apt' command to be available. + "and not test_apt_check " (if (not (string-prefix? "x86_64" system)) ;; These tests either assume the machine is ;; x86_64, or require a cross-compiler to target -- cgit v1.2.3 From 1f88242992346d4e09d959abebb3fc34933bc6b5 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 12:52:55 -0400 Subject: gnu: python-parse-type: Update to 0.6.0, fixing build. * gnu/packages/python-xyz.scm (python-parse-type): Update to 0.6.0. [arguments]: New field. [native-inputs]: Remove python-pytest-runner and python-setuptools. --- gnu/packages/python-xyz.scm | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index a2713caa0f..d47d9507ba 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -2968,21 +2968,24 @@ backported for previous versions of Python from 2.4 to 3.3.") (define-public python-parse-type (package (name "python-parse-type") - (version "0.5.2") + (version "0.6.0") (source (origin - (method url-fetch) - (uri (pypi-uri "parse_type" version)) - (sha256 - (base32 - "02wclgiqky06y36b3q07b7ngpks5j0gmgl6n71ac2j2hscc0nsbz")))) + (method url-fetch) + (uri (pypi-uri "parse_type" version)) + (sha256 + (base32 + "07smqnzc9km7sbvxfyx4gdm9njrx58x8grdw6gs4gva81rk3rd10")))) (build-system python-build-system) - (propagated-inputs - (list python-six python-parse)) - (native-inputs - ;; Use setuptools < 58 to work around - ;; https://github.com/jenisys/parse_type/issues/17 - (list python-pytest python-pytest-runner python-setuptools)) + (arguments + '(#:phases + (modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "-c" "/dev/null"))))))) + (propagated-inputs (list python-six python-parse)) + (native-inputs (list python-pytest)) (home-page "https://github.com/jenisys/parse_type") (synopsis "Extended parse module") (description -- cgit v1.2.3 From d153caabac440073d2123e9ed56151f3da6b3370 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 14:00:47 -0400 Subject: gnu: Add python-bson. * gnu/packages/python-xyz.scm (python-bson): New variable. --- gnu/packages/python-xyz.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index d47d9507ba..21b4ac3131 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -18400,6 +18400,35 @@ multitouch applications.") (define-public python-binwalk (deprecated-package "python-binwalk" binwalk)) +(define-public python-bson + (package + (name "python-bson") + (version "0.5.10") + (source + (origin + (method git-fetch) ;for tests + (uri (git-reference + (url "https://github.com/py-bson/bson") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1vpy4rsvm3hhawvbg9rbw4j36ck8qylkhm8cjy0q6imvinkd2als")))) + (build-system python-build-system) + (arguments + '(#:phases + (modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "./test.py"))))))) + (propagated-inputs (list python-dateutil python-six)) + (home-page "https://github.com/py-bson/bson") + (synopsis "BSON (Binary JSON) codec for Python") + (description "@code{bson} is a Python library implementing a BSON (Binary +JSON) codec.") + (license license:asl2.0))) + (define-public python-nltk (package (name "python-nltk") -- cgit v1.2.3 From 8f3eb93cb0d2e1c506995050496e32e30911dd34 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 14:38:56 -0400 Subject: gnu: python-can: Update to 4.0.0. * gnu/packages/python-xyz.scm (python-can): Update to 4.0.0. [phases]: Strip trailing #t. {relax-version-requirements}: Relax pytest-cov requirement. {check}: Override phase. [propagated-inputs]: Remove python-aenum. Add python-msgpack and python-typing-extensions. [native-inputs]: Add python-parameterized. --- gnu/packages/python-xyz.scm | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 21b4ac3131..86365a04c2 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -2119,14 +2119,14 @@ class.") (define-public python-can (package (name "python-can") - (version "3.3.4") + (version "4.0.0") (source (origin (method url-fetch) (uri (pypi-uri "python-can" version)) (sha256 (base32 - "0jclrvyxasaaxr0albq0kqrnrfqdgqxs7m2qw9nd8kfwg8xj4g1d")))) + "0pcbdgdw94lc2sxd56w6wdsshrs9dd5d3wp0x4sfd0drzx32inar")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases @@ -2137,8 +2137,8 @@ class.") (("coverage<5") "coverage") (("pytest~=4\\.6") "pytest") (("pytest-timeout~=1\\.3") "pytest-timeout") - (("hypothesis~=4\\.56") "hypothesis")) - #t)) + (("pytest-cov.*") "pytest-cov\n") + (("hypothesis~=4\\.56") "hypothesis")))) (add-after 'unpack 'fix-broken-tests ;; The tests try to run two scripts it expects should be ;; in PATH, but they aren't at this time (see: @@ -2146,16 +2146,26 @@ class.") (lambda _ (substitute* "test/test_scripts.py" (("\"can_logger\\.py --help\"") "") - (("\"can_player\\.py --help\"") "")) - #t))))) + (("\"can_player\\.py --help\"") "")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "test" + ;; Disable tests which require specific CAN + ;; drivers we have no package for in Guix. + "--ignore" "test/test_interface_canalystii.py" + ;; These tests fail with "OSError: [Errno 19] + ;; No such device". + "-k" "not BasicTestUdpMulticastBusIPv"))))))) (propagated-inputs - (list python-aenum python-wrapt)) + (list python-msgpack python-typing-extensions python-wrapt)) (native-inputs (list python-codecov python-coverage python-future python-hypothesis python-mock + python-parameterized python-pyserial python-pytest python-pytest-cov -- cgit v1.2.3 From e8dc6ec5d8084efef4341ef90ec5e66ce31c1f03 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 15:01:13 -0400 Subject: gnu: python-amqp: Update to 5.1.1 and enable tests. * gnu/packages/python-xyz.scm (python-amqp): Update to 5.1.1. [arguments]: New field. [native-inputs]: Add python-pytest. --- gnu/packages/python-xyz.scm | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 86365a04c2..4831cebaa0 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -15673,18 +15673,27 @@ and provides a uniform API regardless of which JSON implementation is used.") (define-public python-amqp (package (name "python-amqp") - (version "5.0.7") + (version "5.1.1") (source (origin (method url-fetch) (uri (pypi-uri "amqp" version)) (sha256 - (base32 "0p9alyinl24z699w4gpd8wvn90sm2il1p0gfwdhbpinksy7vfmyp")))) + (base32 "1qmmffiy48nady7is8529vxcyqbq88v5zgawqr3fk4q8rkz166rc")))) (build-system python-build-system) (arguments - `(#:tests? #f)) ; not compatible with pytest>=6 as of 5.0.7 - (propagated-inputs - (list python-vine)) + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" + "-c" "/dev/null" ;take control over pytest options + ;; Integration tests require network connectivity. + "--ignore" "t/integration"))))))) + (native-inputs (list python-pytest)) + (propagated-inputs (list python-vine)) (home-page "https://github.com/celery/py-amqp") (synopsis "Low-level AMQP client for Python (fork of amqplib)") (description -- cgit v1.2.3 From daf2b257555b1f8a21020369eb77189a66abd96d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 14:52:36 -0400 Subject: gnu: python-kombu: Update to 5.2.4. * gnu/packages/python-xyz.scm (python-kombu): Update to 5.2.4. [phases]{delete-transport-tests}: Delete phase. {check}: New phase. [native-inputs]: Remove python-mock. --- gnu/packages/python-xyz.scm | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 4831cebaa0..bfae08fa7c 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -15751,23 +15751,28 @@ applications.") (define-public python-kombu (package (name "python-kombu") - (version "5.2.2") + (version "5.2.4") (source (origin (method url-fetch) (uri (pypi-uri "kombu" version)) (sha256 - (base32 "0256915q3z4pjrkqxw16a31np3p25dxnk1mq2zv0hs4izdihfp8g")))) + (base32 "044ng79gj04668kf5fmy7fjkw8302xyapskkn65ym52zfbpf7kip")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'delete-transport-tests - (lambda _ ; this tests message passing to many different databases - (delete-file-recursively "t/unit/transport")))))) + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" + ;; The transport tests attempt to pass messages to + ;; many different databases. + "--ignore" "t/unit/transport"))))))) (native-inputs - (list python-case python-mock python-pyro4 python-pytest-sugar - python-pytz)) + (list python-case python-pyro4 python-pytest-sugar + python-pytest python-pytz)) (propagated-inputs (list python-amqp python-cached-property python-vine)) (home-page "https://kombu.readthedocs.io") -- cgit v1.2.3 From f35d65707cb15f62f8924b245baca4ad929d309b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 15:22:49 -0400 Subject: gnu: python-celery: Update to 5.2.6 and enable tests. * gnu/packages/python-xyz.scm (python-celery): Update to 5.2.6. [tests?]: Delete argument. [phases]{delete-integration-tests}: Delete phase. {relax-requirements}: New phase. {check}: Ignore the "t/integration" directory and the t/unit/backends/test_mongodb.py file. Remove skip directive for test_all_reqs_enabled_in_tests. [native-inputs]: Add python-dnspython. [propagated-inputs]: Delete python-boto3 and python-cryptography. --- gnu/packages/python-xyz.scm | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index bfae08fa7c..cd44113352 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -15821,31 +15821,37 @@ Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.") (define-public python-celery (package (name "python-celery") - (version "5.1.2") ;newer versions require python-click>=8 + (version "5.2.6") (source (origin (method url-fetch) (uri (pypi-uri "celery" version)) (sha256 - (base32 "1c6lw31i3v81fyj4yn37lbvv70xdgb389iccirzyjr992vlkv6ld")))) + (base32 "109lcqarrbmh95sk1dm4yxayq1h3i27f4w23ndk64mqgyfnqqffi")))) (build-system python-build-system) (arguments - '(#:tests? #f - #:phases + '(#:phases (modify-phases %standard-phases - (add-after 'unpack 'delete-integration-tests + (add-after 'unpack 'relax-requirements (lambda _ - (delete-file-recursively "t/integration"))) ;hangs tests + (substitute* "requirements/default.txt" + (("pytz.*") + "pytz\n")))) (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - (add-installed-pythonpath inputs outputs) - (invoke "python" "-m" "pytest" "t" "-k" - (string-append ; AssertionErrors - "not test_check_privileges_no_fchown" - " and not test_all_reqs_enabled_in_tests")))))))) + (invoke "python" "-m" "pytest" "t" + "--ignore" "t/integration" ;hangs tests + ;; The MongoDB backend test appears to expect an older + ;; version of MongoDB which provided its own bson + ;; module, fails with " AttributeError: module 'bson' + ;; has no attribute 'encode'". + "--ignore" "t/unit/backends/test_mongodb.py" + ;; AssertionErrors + "-k" "not test_check_privileges_no_fchown "))))))) (native-inputs (list python-case + python-dnspython python-flaky python-iniconfig python-moto @@ -15857,12 +15863,10 @@ Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.") python-toml)) (propagated-inputs (list python-billiard - python-boto3 python-click python-click-didyoumean python-click-plugins python-click-repl - python-cryptography python-kombu python-pytz python-vine)) -- cgit v1.2.3 From 2380d68227fbd87a0222f0de51fdd81904b8ddf4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 15:34:45 -0400 Subject: gnu: Add python-argparse-addons. * gnu/packages/python-xyz.scm (python-argparse-addons): New variable. --- gnu/packages/python-xyz.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index cd44113352..e52178debb 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -2235,6 +2235,23 @@ a library.") (description "DiskCache is a disk and file backed persistent cache.") (license license:asl2.0))) +(define-public python-argparse-addons + (package + (name "python-argparse-addons") + (version "0.7.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "argparse_addons" version)) + (sha256 + (base32 "1yx54dmnr3xggjcjk6bbdafvzp6cynrakl56wyz3jglmfvk0znpm")))) + (build-system python-build-system) + (home-page "https://github.com/eerimoq/argparse_addons") + (synopsis "Extensions for Python's @code{argparse} library") + (description "This Python library provides additional types and actions +for the standard @code{argparse} library.") + (license license:expat))) + (define-public python-bitstruct (package (name "python-bitstruct") -- cgit v1.2.3 From 54f67e382e1ed21c6efb9541fe7dadc5c46e5f09 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 15:37:03 -0400 Subject: gnu: python-bitstruct: Update to 8.14.0. * gnu/packages/python-xyz.scm (python-bitstruct): Update to 8.14.0. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index e52178debb..a0642bdfab 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -2255,14 +2255,14 @@ for the standard @code{argparse} library.") (define-public python-bitstruct (package (name "python-bitstruct") - (version "8.9.0") + (version "8.14.0") (source (origin (method url-fetch) (uri (pypi-uri "bitstruct" version)) (sha256 (base32 - "1fpc1qh1vss05ap29xvhjp200fm0q4pvgcjl0qpryh7ay6xgr5vx")))) + "149c73yrqbph71bbyf925r2mbh2jdymqxc6d49lnylpiflf1j313")))) (build-system python-build-system) (home-page "https://github.com/eerimoq/bitstruct") (synopsis "Python values to and C bit field structs converter") -- cgit v1.2.3 From 10ea06342a2e57ba6db39dd2e51e8d4e37cae5bb Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 15:52:31 -0400 Subject: gnu: Add python-toolrack. * gnu/packages/python-xyz.scm (python-toolrack): New variable. --- gnu/packages/python-xyz.scm | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index a0642bdfab..97eb3651a5 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -24067,6 +24067,49 @@ which supports the spawning of processes using the API of the standard library's @code{threading} module.") (license license:bsd-3))) +(define-public python-toolrack + (package + (name "python-toolrack") + (version "3.0.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/albertodonato/toolrack") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0ych11b7nchnkhqgf7dgivbvn2lzafjsi7nhb1an5zjjyns39gpx")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-/bin/sh + (lambda _ + (substitute* "toolrack/aio/tests/test_process.py" + (("/bin/sh") + (which "sh"))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "--pyargs" "toolrack" + "-k" + (string-append + ;; These tests fail for unknown reason comparing the + ;; expected output of shell scripts. + "not test_parse_stderr " + "and not test_parse_no_ending_newline " + "and not test_parse_stdout")))))))) + (native-inputs (list python-pytest python-pytest-asyncio + python-pytest-mock)) + (home-page "https://github.com/albertodonato/toolrack") + (synopsis "Collection of Python utility functions and classes") + (description "This package provides a collection of miscellaneous utility +functions and classes.") + (license license:lgpl3+))) + (define-public python-toolz (package (name "python-toolz") -- cgit v1.2.3 From d45727f4e4be401cbed6c49614e242ffc0a5c581 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 16:03:09 -0400 Subject: gnu: sshoot: Update to 1.5.1. * gnu/packages/vpn.scm (sshoot): Update to 1.5.1. [phases]: Delete trailing #t. {check}: Override phase. [inputs]: Add python-pyxdg and python-toolrack. [native-inputs]: Delete python-fixtures, python-pbr and python-testtools. Add python-pytest and python-pytest-mock. --- gnu/packages/vpn.scm | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/gnu/packages/vpn.scm b/gnu/packages/vpn.scm index 5bf5a62481..f3da89675e 100644 --- a/gnu/packages/vpn.scm +++ b/gnu/packages/vpn.scm @@ -20,6 +20,7 @@ ;;; Copyright © 2021 jgart ;;; Copyright © 2022 Josselin Poiret ;;; Copyright © 2022 Lu hui +;;; Copyright © 2022 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -907,14 +908,14 @@ DNS domain name queries.") (define-public sshoot (package (name "sshoot") - (version "1.2.6") + (version "1.5.1") (source (origin (method url-fetch) (uri (pypi-uri name version)) (sha256 (base32 - "1ccgh0hjyxrwkgy3hnxz3hgbjbs0lmfs25d5l5jam0xbpcpj63h0")))) + "05i54nga4vy660yy9yf6dl376yj0jc51303yr295qk3k9w0k96yd")))) (build-system python-build-system) (arguments '(#:phases @@ -922,13 +923,20 @@ DNS domain name queries.") (add-after 'unpack 'patch-paths (lambda _ (substitute* "sshoot/tests/test_manager.py" - (("/bin/sh") (which "sh"))) - #t))))) + (("/bin/sh") (which "sh"))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "--pyargs" "sshoot"))))))) (inputs - (list python-argcomplete python-prettytable python-pyyaml)) + (list python-argcomplete + python-prettytable + python-pyyaml + python-pyxdg + python-toolrack)) ;; For tests only. (native-inputs - (list python-fixtures python-pbr python-testtools)) + (list python-pytest python-pytest-mock)) (home-page "https://github.com/albertodonato/sshoot") (synopsis "sshuttle VPN session manager") (description "sshoot provides a command-line interface to manage multiple -- cgit v1.2.3 From abca2b804740ec28d56f4ef291b07dfe913b5361 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 16:17:49 -0400 Subject: gnu: python-multipart: Fix build with PyYAML 6. * gnu/packages/python-xyz.scm (python-multipart) [phases]{patch-test-suite}: Substitute yaml.load for yaml.safe_load. --- gnu/packages/python-xyz.scm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 97eb3651a5..e86be67ddb 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -30677,6 +30677,10 @@ writing STL files. It supports both the text and binary forms of STL.") ;; There is a bug in the test_suit specification. (add-after 'unpack 'patch-test-suite (lambda _ + ;; Make compatible with PyYAML 6. + (substitute* "multipart/tests/test_multipart.py" + (("yaml.load") + "yaml.safe_load")) (substitute* "setup.py" (("test_suite = 'multipart.tests.suite'") "test_suite = 'multipart.tests.test_multipart.suite'")) -- cgit v1.2.3 From 91525740096b07b278fcc18803c70f73402d59f8 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 16:32:47 -0400 Subject: gnu: Add python-mergedeep. * gnu/packages/python-xyz.scm (python-mergedeep): New variable. --- gnu/packages/python-xyz.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index e86be67ddb..2246df9da1 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -17428,6 +17428,28 @@ daemon. It is the client side software which allows storing values in one or more, possibly remote, memcached servers.") (license license:psfl))) +(define-public python-mergedeep + (package + (name "python-mergedeep") + (version "1.3.4") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/clarketm/mergedeep") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1msvvdzk33sxzgyvs4fs8dlsrsi7fjj038z83s0yw5h8m8d78469")))) + (build-system python-build-system) + (native-inputs (list python-pytest)) + (home-page "https://github.com/clarketm/mergedeep") + (synopsis "Deep merge function for Python") + (description "This package provides a deep merge function for Python, +useful to combine multiple data objects as one.") + (license license:expat))) + (define-public python-clikit (package (name "python-clikit") -- cgit v1.2.3 From e051e00fef153c240f64fb256c816d73f656614a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 16:38:10 -0400 Subject: gnu: Add python-pyyaml-env-tag. * gnu/packages/python-xyz.scm (python-pyyaml-env-tag): New variable. --- gnu/packages/python-xyz.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 2246df9da1..a9ee1da742 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -17912,6 +17912,24 @@ YAML-serialized data.") (define-public python2-pyaml (package-with-python2 python-pyaml)) +(define-public python-pyyaml-env-tag + (package + (name "python-pyyaml-env-tag") + (version "0.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pyyaml_env_tag" version)) + (sha256 + (base32 "1nsva88jsmwn0cb9jnrfiz4dvs9xakkpgfii7g1xwkx1pmsjc2bh")))) + (build-system python-build-system) + (propagated-inputs (list python-pyyaml)) + (home-page "https://github.com/waylan/pyyaml-env-tag") + (synopsis "Custom YAML tag for environment variables") + (description "This package provides a custom YAML tag for referencing +environment variables in YAML files.") + (license license:expat))) + (define-public python-backpack (package (name "python-backpack") -- cgit v1.2.3 From 03f26438e05d1c724417adb2e7481819c5bd5b75 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 16:42:23 -0400 Subject: gnu: python-ghp-import: Update to 2.0.2. * gnu/packages/version-control.scm (python-ghp-import): Update to 2.0.2. [propagated-inputs]: Add python-dateutil. (python2-ghp-import): Delete variable. --- gnu/packages/version-control.scm | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index d528a08e63..3e275b3287 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -33,7 +33,7 @@ ;;; Copyright © 2020 Tanguy Le Carrour ;;; Copyright © 2020, 2021 Michael Rohleder ;;; Copyright © 2021 Greg Hogan -;;; Copyright © 2021 Maxim Cournoyer +;;; Copyright © 2021, 2022 Maxim Cournoyer ;;; Copyright © 2021 Chris Marusich ;;; Copyright © 2021 Léo Le Bouter ;;; Copyright © 2021 LibreMiami @@ -1139,7 +1139,7 @@ repository") (define-public python-ghp-import (package (name "python-ghp-import") - (version "0.5.5") + (version "2.0.2") (source (origin (method git-fetch) @@ -1148,7 +1148,7 @@ repository") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "12pmw3zz3i57ljnm0rxdyjqdyhisbvy18mjwkb3bzp5pgzs2f45c")))) + (base32 "0i4lxsgqri1y8sw4k44bkwbzmdmk4vpmdi882mw148j8gk4i7vvj")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases @@ -1159,6 +1159,7 @@ repository") (licenses (string-append out "/share/licenses"))) (install-file "README.md" doc) (install-file "LICENSE" licenses))))))) + (propagated-inputs (list python-dateutil)) (home-page "https://github.com/davisp/ghp-import") (synopsis "Copy directory to the gh-pages branch") (description "Script that copies a directory to the gh-pages branch (by @@ -1169,10 +1170,6 @@ default) of the repository.") "https://raw.githubusercontent.com/davisp/ghp-import/master/LICENSE" "Tumbolia Public License")))) -(define-public python2-ghp-import - (package-with-python2 - (strip-python2-variant python-ghp-import))) - (define-public python-gitdb (package (name "python-gitdb") -- cgit v1.2.3 From c5078029031350bb22a91db8c3be7c08461d264a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 16:52:35 -0400 Subject: gnu: Add python-mdx-gh-links. * gnu/packages/python-xyz.scm (python-mdx-gh-links): New variable. --- gnu/packages/python-xyz.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index a9ee1da742..4258b06600 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -706,6 +706,26 @@ configured with a single YAML configuration file.") Markdown. All extensions are found under the module namespace of pymdownx.") (license license:expat))) +(define-public python-mdx-gh-links + (package + (name "python-mdx-gh-links") + (version "0.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "mdx_gh_links" version)) + (sha256 + (base32 "167k1jbp3jifxbnlpi6wy0z1skam7gqv2sixb5bhggb2vypqvysr")))) + (build-system python-build-system) + (arguments (list #:tests? #f)) ;tests connect github + (propagated-inputs (list python-markdown)) + (home-page "https://github.com/Python-Markdown/github-links/") + (synopsis "Python-Markdown extension adding support for shorthand links") + (description "This package is an extension to Python-Markdown which adds +support for shorthand links to GitHub users, repositories, issues and +commits.") + (license license:bsd-3))) + (define-public python-mkdocs-material (package (name "python-mkdocs-material") -- cgit v1.2.3 From 4fe4943ba66bd4c9ed5f3c0e30f4ae639bcea105 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 17:14:06 -0400 Subject: gnu: python-mkdocs: Update to 1.3.0. * gnu/packages/python-xyz.scm (python-mkdocs): Update to 1.3.0. [source]: Use git. [phases]{check}: New override. [propagated-inputs]: Remove python-livereload, python-lunr and python-tornado. Add python-babel, python-ghp-import, python-importlib-metadata, python-markupsafe, python-mdx-gh-links, python-mergedeep, python-packaging, python-pyyaml-env-tag and python-watchdog. --- gnu/packages/python-xyz.scm | 36 ++++++++++++++++++++++++++---------- 1 file changed, 26 insertions(+), 10 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 4258b06600..09b55e7362 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -650,14 +650,18 @@ HTML") (define-public python-mkdocs (package (name "python-mkdocs") - (version "1.1.2") + (version "1.3.0") (source (origin - (method url-fetch) - (uri - (pypi-uri "mkdocs" version)) + ;; The tests suite appears to be incomplete in the PyPI archive. + (method git-fetch) + (uri (git-reference + (url "https://github.com/mkdocs/mkdocs") + (commit version))) + (file-name (git-file-name name version)) (sha256 - (base32 "0fgv5zawpyyv0vd4j5y8m4h058lh9jkwfcm0xy4pg7dr09a1xdph")))) + (base32 + "1n5rdllrxvhnxmdrddf55p3s86dakx0rq2gg6bj6pr6jg2pn932b")))) (build-system python-build-system) (arguments `(#:phases @@ -667,15 +671,27 @@ HTML") (add-after 'unpack 'patch-requirements (lambda _ (substitute* "setup.py" - (("==") ">="))))))) + (("==") ">=")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "-m" "unittest" + "discover" "-p" "*tests.py" "mkdocs" + "--top-level-directory" "."))))))) (propagated-inputs - (list python-click + (list python-babel + python-click + python-ghp-import + python-importlib-metadata python-jinja2 - python-livereload - python-lunr python-markdown + python-markupsafe + python-mdx-gh-links + python-mergedeep + python-packaging python-pyyaml - python-tornado)) + python-pyyaml-env-tag + python-watchdog)) (home-page "https://www.mkdocs.org") (synopsis "Project documentation with Markdown") (description "MkDocs is a static site generator geared towards building -- cgit v1.2.3 From 1341779f8489c207c9683e0c88bc8c99815da57a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 17:26:02 -0400 Subject: gnu: Add python-crccheck. * gnu/packages/python-xyz.scm (python-crccheck): New variable. --- gnu/packages/python-xyz.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 09b55e7362..d46b129329 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -11488,6 +11488,32 @@ output.") (define-public python2-cram (package-with-python2 python-cram)) +(define-public python-crccheck + (package + (name "python-crccheck") + (version "1.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "crccheck" version)) + (sha256 + (base32 "15psg7wjfbpmmry54ffwg6pg63mnv7mkwmb0a7884axnr8qj55j5")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-pytest)) + (home-page "https://sourceforge.net/projects/crccheck/") + (synopsis "Calculation library for CRCs and checksums") + (description "@code{crccheck} is a calculation library for CRCs and +checksums. It implement more than a hundred checksum routines.") + (license license:gpl3+))) + (define-public python-crashtest (package (name "python-crashtest") -- cgit v1.2.3 From bb22c1ba5d37773639a3a6d3eb7f83f5504f91af Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 15:39:31 -0400 Subject: gnu: python-cantools: Update to 37.0.7. * gnu/packages/python-xyz.scm (python-cantools): Update to 37.0.7. [arguments]: Use gexps. [phases]: Strip trailing #t. {build-doc}: Use make -C instead of with-directory-excursion. {install-doc}: Adjust for gexp. [native-inputs]: Use new style. [propagated-inputs]: Add python-argparse-addons, python-crccheck, python-matplotlib and python-parameterized. --- gnu/packages/python-xyz.scm | 54 +++++++++++++++++++++++---------------------- 1 file changed, 28 insertions(+), 26 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index d46b129329..928e0aac9c 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -2311,7 +2311,7 @@ bits instead of primitive data types like @code{char}, @code{int}, etc.") (define-public python-cantools (package (name "python-cantools") - (version "33.1.1") + (version "37.0.7") (source (origin ;; We take the sources from the Git repository as the documentation is @@ -2323,34 +2323,36 @@ bits instead of primitive data types like @code{char}, @code{int}, etc.") (file-name (git-file-name name version)) (sha256 (base32 - "1aad137yd8b4jkfvlv812qsxmxcgra7g1p4wbxfsjy1cbf8fbq9q")))) + "1qcf1fcwif7w70qmhxw2b8kqh420igbinq60p1chzf98xcb0ansx")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'build 'build-doc - (lambda _ - ;; See: https://github.com/eerimoq/cantools/issues/190. - (substitute* "README.rst" - (("https://github.com/eerimoq/cantools/raw/master\ + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'build 'build-doc + (lambda _ + ;; See: https://github.com/eerimoq/cantools/issues/190. + (substitute* "README.rst" + (("https://github.com/eerimoq/cantools/raw/master\ /docs/monitor.png") - "monitor.png")) - (with-directory-excursion "docs" - (invoke "make" "man" "info")))) - (add-after 'install 'install-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (info (string-append out "/share/info")) - (man1 (string-append out "/share/man/man1"))) - (format #t "CWD: ~s~%" (getcwd)) - (install-file "docs/_build/texinfo/cantools.info" info) - (install-file "docs/_build/man/cantools.1" man1) - #t)))))) - (native-inputs - `(("sphinx" ,python-sphinx) - ("texinfo" ,texinfo))) - (propagated-inputs - (list python-bitstruct python-can python-diskcache python-textparser)) + "monitor.png")) + (invoke "make" "-C" "docs" "man" "info"))) + (add-after 'install 'install-doc + (lambda* (#:key outputs #:allow-other-keys) + (let* ((info (string-append #$output "/share/info")) + (man1 (string-append #$output "/share/man/man1"))) + (install-file "docs/_build/texinfo/cantools.info" info) + (install-file "docs/_build/man/cantools.1" man1))))))) + (native-inputs (list python-sphinx texinfo)) + (propagated-inputs + (list python-argparse-addons + python-bitstruct + python-can + python-crccheck + python-diskcache + python-matplotlib + python-parameterized + python-textparser)) (home-page "https://github.com/eerimoq/cantools") (synopsis "Tools for the Controller Area Network (CAN) bus protocol") (description "This package includes Controller Area Network (CAN) related -- cgit v1.2.3 From ece8e759027ac02602d3ffb5f4ecc41a15a4ecf3 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 17:39:37 -0400 Subject: gnu: python-locust: Update to 2.8.6. * gnu/packages/benchmark.scm (python-locust): Update to 2.8.6. [phases]{relax-requirements}: New phase. {check}: Skip the test_distributed_shape test. [propagated-inputs]: Add python-jinja2. --- gnu/packages/benchmark.scm | 24 +++++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/gnu/packages/benchmark.scm b/gnu/packages/benchmark.scm index 25cdfe1dd2..b167c6de6e 100644 --- a/gnu/packages/benchmark.scm +++ b/gnu/packages/benchmark.scm @@ -266,18 +266,25 @@ file metadata operations that can be performed per second.") (define-public python-locust (package (name "python-locust") - (version "2.5.1") + (version "2.8.6") (source (origin (method url-fetch) (uri (pypi-uri "locust" version)) (sha256 (base32 - "1516z6z5pikybg7pma2cgxgj3wxaaky7z6d30mxf81wd4krbq16s")))) + "1gn13j758j36knlcdyyyggn60rpw98iqdkvl3kjsz34brysic6q1")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases + (add-after 'unpack 'relax-requirements + (lambda _ + (substitute* "setup.py" + (("setuptools_scm<=6.0.1") + "setuptools_scm") + (("Jinja2<3.1.0") + "Jinja2")))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? @@ -299,7 +306,10 @@ file metadata operations that can be performed per second.") ;; respectively (see: ;; https://github.com/locustio/locust/issues/1708). "not test_custom_exit_code" - "not test_webserver") " and ")))))))) + "not test_webserver" + ;; This test fails with "AssertionError: + ;; 'stopped' != 'stopping'". + "not test_distributed_shape") " and ")))))))) (propagated-inputs (list python-configargparse python-flask @@ -307,6 +317,7 @@ file metadata operations that can be performed per second.") python-flask-cors python-gevent python-geventhttpclient + python-jinja2 python-msgpack python-psutil python-pyzmq @@ -315,8 +326,11 @@ file metadata operations that can be performed per second.") python-typing-extensions python-werkzeug)) (native-inputs - (list python-mock python-pyquery python-pytest - python-retry python-setuptools-scm)) + (list python-mock + python-pyquery + python-pytest + python-retry + python-setuptools-scm)) (home-page "https://locust.io/") (synopsis "Distributed load testing framework") (description "Locust is a performance testing tool that aims to be easy to -- cgit v1.2.3 From 571713526c51d4ccc9711c5a6e77a00e134fde6d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 21:15:23 -0400 Subject: gnu: Remove python2-jmespath. * gnu/packages/python-xyz.scm (python2-jmespath): Delete variable. --- gnu/packages/python-xyz.scm | 3 --- 1 file changed, 3 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 928e0aac9c..20187ac66d 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -15279,9 +15279,6 @@ document.") (home-page "https://github.com/jmespath/jmespath.py") (license license:expat))) -(define-public python2-jmespath - (package-with-python2 python-jmespath)) - (define-public python-symengine (package (name "python-symengine") -- cgit v1.2.3 From 3ddeaf90a69a4392a3638649ef25025db01a9271 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 21:51:12 -0400 Subject: gnu: python-croniter: Update to 1.3.4. * gnu/packages/python-xyz.scm (python-croniter): Update to 1.3.4. --- gnu/packages/python-xyz.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 20187ac66d..8d12f28850 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -25162,16 +25162,15 @@ processes may share the same data.") (define-public python-croniter (package (name "python-croniter") - (version "0.3.34") + (version "1.3.4") (source (origin (method url-fetch) (uri (pypi-uri "croniter" version)) (sha256 (base32 - "0r79cx4v2dw4hzr0annkkxxis46c8hivq61sr39z6p7lcjsbk1ki")))) + "1whbm26m9kpn0klgr9dqiqpp83ki9nhpxifaq9afcjw32rckcs9i")))) (build-system python-build-system) - (propagated-inputs - (list python-dateutil python-natsort)) + (propagated-inputs (list python-dateutil)) (home-page "https://github.com/kiorky/croniter") (synopsis "Iterate datetime objects with cron-like syntax") (description -- cgit v1.2.3 From fa84f9bce9e1ddd7c513268962bd4779a0b1dc3d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 21:52:21 -0400 Subject: gnu: python-miio: Update to 0.5.11. * gnu/packages/android.scm (python-miio): Update to 0.5.11. [phases]{relax-requirements}: New phase. {adjust-for-click-8}: Likewise. {check}: Remove extraneous add-installed-pythonpath call, INPUTS and OUTPUTS arguments. Invoke pytest with -vv. --- gnu/packages/android.scm | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/gnu/packages/android.scm b/gnu/packages/android.scm index 9f00303811..04dc4b6499 100644 --- a/gnu/packages/android.scm +++ b/gnu/packages/android.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2016, 2020 Marius Bakke ;;; Copyright © 2017 Julien Lepiller ;;; Copyright © 2017 Hartmut Goebel -;;; Copyright © 2017, 2020, 2021 Maxim Cournoyer +;;; Copyright © 2017, 2020, 2021, 2022 Maxim Cournoyer ;;; Copyright © 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Efraim Flashner ;;; Copyright © 2019, 2020 Andreas Enge @@ -1078,23 +1078,33 @@ backups. It supports encrypted archives.") (define-public python-miio (package (name "python-miio") - (version "0.5.8") + (version "0.5.11") (source (origin (method url-fetch) (uri (pypi-uri "python-miio" version)) (sha256 (base32 - "0a4f5ybjvibawwxcjm3r9nnrzf1yff6wwgy05yzyk0bb3rmc99fp")))) + "1dyzzywfa5h6q8clmzxsqmszlby8757ajmvkhdyvq6719z4bn46n")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'relax-requirements + (lambda _ + (substitute* "setup.py" + (("cryptography>=35") + "cryptography")))) + (add-after 'unpack 'adjust-for-click-8 + (lambda _ + (substitute* '("miio/integrations/vacuum/roborock/vacuum.py" + "miio/integrations/vacuum/roborock/vacuum_cli.py") + (("resultcallback") + "result_callback")))) (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "miio"))))))) + (invoke "pytest" "-vv" "miio"))))))) (native-inputs (list python-pytest python-pytest-mock -- cgit v1.2.3 From 213696b061de51f076e7ad2ab01fc76310a81be5 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 19 Apr 2022 23:10:18 -0400 Subject: gnu: Remove python-orator due to being broken and unmaintained. * gnu/packages/databases.scm (python-orator): Delete variable. --- gnu/packages/databases.scm | 35 ----------------------------------- 1 file changed, 35 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 0595c6b6c3..ac3ecbfef1 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -3226,41 +3226,6 @@ Memory-Mapped Database} (LMDB), a high-performance key-value store.") ;; but not actually needed on platforms currently supported by Guix. license:bsd-3)))) -(define-public python-orator - (package - (name "python-orator") - (version "0.9.9") - (source (origin - (method url-fetch) - (uri (pypi-uri "orator" version)) - (sha256 - (base32 - "0mbgybz63ryhr9p1f4glnls5c57jp6il3dw0kf97f3pj80687rvg")))) - (build-system python-build-system) - ;; FIXME: Tests are not distributed with PyPI, and the repository - ;; does not contain setup.py. How to test? - (arguments '(#:tests? #f)) - (propagated-inputs - (list python-backpack - python-blinker - python-cleo - python-faker - python-inflection - python-lazy-object-proxy - python-pendulum - python-pyaml - python-pygments - python-pyyaml - python-simplejson - python-six - python-wrapt)) - (home-page "https://orator-orm.com/") - (synopsis "ActiveRecord ORM for Python") - (description - "Orator provides a simple ActiveRecord-like Object Relational Mapping -implementation for Python.") - (license license:expat))) - (define-public virtuoso-ose (package (name "virtuoso-ose") -- cgit v1.2.3 From e7b0d63e32407cdcaf405cb69c2e8e5e3e3fd5e2 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 00:26:32 -0400 Subject: gnu: Add python-pydyf. * gnu/packages/pdf.scm (python-pydyf): New variable. --- gnu/packages/pdf.scm | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/gnu/packages/pdf.scm b/gnu/packages/pdf.scm index 5963401975..b791a2fc8b 100644 --- a/gnu/packages/pdf.scm +++ b/gnu/packages/pdf.scm @@ -20,7 +20,7 @@ ;;; Copyright © 2020-2022 Nicolas Goaziou ;;; Copyright © 2020 Michael Rohleder ;;; Copyright © 2020 Timotej Lazar -;;; Copyright © 2020 Maxim Cournoyer +;;; Copyright © 2020, 2022 Maxim Cournoyer ;;; Copyright © 2021 Maxime Devos ;;; ;;; This file is part of GNU Guix. @@ -701,6 +701,33 @@ for applications that wish to do lower level manipulation of PDF, such as extracting content or merging files.") (license license:lgpl2.0+))) +(define-public python-pydyf + (package + (name "python-pydyf") + (version "0.1.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pydyf" version)) + (sha256 + (base32 "0b30g3hhxw1bg18r9ax85i1dkg8vy1y1wzas0bg0bxblh7j5sbqy")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "-c" "/dev/null"))))))) + (propagated-inputs (list python-pillow)) + (native-inputs (list ghostscript python-pytest)) + (home-page "https://github.com/CourtBouillon/pydyf") + (synopsis "Low-level PDF generator") + (description "@code{pydyf} is a low-level PDF generator written in Python +and based on PDF specification 1.7.") + (license license:bsd-3))) + (define-public mupdf (package (name "mupdf") -- cgit v1.2.3 From 84943a4e0ed49510c0f6ea49ed6bcff9e195b088 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 00:46:18 -0400 Subject: gnu: weasyprint: Update to 54.3. * gnu/packages/pdf.scm (weasyprint): Update to 54.3. [source]: Update git URL. [phases]: Use gexps. {disable-linters}: Delete phase. {register-dejavu-font}: Remove obsolete phase. {patch-library-paths}: Adjust for code changes. Use search-input-file. {check}: Streamline and use xdist. {build, install}: Override to o a PEP 517 build. [inputs]: Add harfbuzz. [propagated-inputs]: Add python-fonttools-full, python-pillow and python-pydyf. [native-inputs]: Remove python-pytest-cov and python-pytest-runner. Add ghostscript, python-flit-core, python-pypa-build, python-pytest and python-pytest-xdist. --- gnu/packages/pdf.scm | 101 +++++++++++++++++++++++++-------------------------- 1 file changed, 50 insertions(+), 51 deletions(-) diff --git a/gnu/packages/pdf.scm b/gnu/packages/pdf.scm index b791a2fc8b..db04f21242 100644 --- a/gnu/packages/pdf.scm +++ b/gnu/packages/pdf.scm @@ -88,6 +88,7 @@ #:use-module (gnu packages pkg-config) #:use-module (gnu packages pulseaudio) #:use-module (gnu packages python) + #:use-module (gnu packages python-build) #:use-module (gnu packages python-check) #:use-module (gnu packages python-web) #:use-module (gnu packages python-xyz) @@ -1480,77 +1481,75 @@ manipulating PDF documents from the command line. It supports (define-public weasyprint (package (name "weasyprint") - (version "52.1") + (version "54.3") (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/FelixSchwarz/WeasyPrint") + (url "https://github.com/Kozea/WeasyPrint") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 - "0rcj9yah3bp6bbvkmny3w4csx4l5v49lc7mrk29g0x77qnwswjy7")))) + "0cn8gpgyic6pmrnhp0540nbgplpsd5aybi7k89anz6m1sshgjzgs")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-library-paths - (lambda* (#:key inputs #:allow-other-keys) - (let ((fontconfig (assoc-ref inputs "fontconfig")) - (glib (assoc-ref inputs "glib")) - (pango (assoc-ref inputs "pango")) - (pangoft2 (assoc-ref inputs "pangoft2"))) - (substitute* "weasyprint/fonts.py" - (("'fontconfig'") - (format #f "'~a/lib/libfontconfig.so'" fontconfig)) - (("'pangoft2-1.0'") - (format #f "'~a/lib/libpangoft2-1.0.so'" pango))) - (substitute* "weasyprint/text.py" - (("'gobject-2.0'") - (format #f "'~a/lib/libgobject-2.0.so'" glib)) - (("'pango-1.0'") - (format #f "'~a/lib/libpango-1.0.so'" pango)) - (("'pangocairo-1.0'") - (format #f "'~a/lib/libpangocairo-1.0.so'" pango))) - #t))) - (add-after 'unpack 'disable-linters - ;; Their check fails; none of our business. - (lambda _ - (substitute* "setup.cfg" - ((".*pytest-flake8.*") "") - ((".*pytest-isort.*") "") - (("--flake8") "") - (("--isort") "")) - #t)) - (add-before 'check 'register-dejavu-font - (lambda* (#:key inputs #:allow-other-keys) - ;; TODO: fix FreeType so that fonts found in XDG_DATA_DIRS are - ;; honored. - (let* ((HOME "/tmp") - (dejavu (assoc-ref inputs "font-dejavu")) - (fonts-dir (string-append HOME "/.fonts"))) - (setenv "HOME" HOME) - (mkdir-p fonts-dir) - (symlink (string-append dejavu "/share/fonts/truetype") - (string-append fonts-dir "/truetype")) - (invoke "fc-cache" "-rv"))))))) - (inputs - `(("fontconfig" ,fontconfig) - ("glib" ,glib) - ("pango" ,pango))) + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-library-paths + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "weasyprint/text/ffi.py" + (("'gobject-2.0-0'") + (format #f "~s" + (search-input-file inputs "lib/libgobject-2.0.so"))) + (("'pango-1.0-0'") + (format #f "~s" + (search-input-file inputs "lib/libpango-1.0.so"))) + (("'harfbuzz'") + (format #f "~s" + (search-input-file inputs "lib/libharfbuzz.so"))) + (("'fontconfig-1'") + (format #f "~s" + (search-input-file inputs "lib/libfontconfig.so"))) + (("'pangoft2-1.0-0'") + (format #f "~s" + (search-input-file inputs + "lib/libpangoft2-1.0.so")))))) + ;; XXX: PEP 517 manual build copied from python-isort. + (replace 'build + (lambda _ + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "-c" "/dev/null" + "-n" (number->string (parallel-job-count)))))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (inputs (list fontconfig glib harfbuzz pango)) (propagated-inputs (list gdk-pixbuf python-cairocffi python-cairosvg python-cffi python-cssselect2 + python-fonttools-full python-html5lib + python-pillow + python-pydyf python-pyphen python-tinycss2)) (native-inputs - (list font-dejavu ;tests depend on it - python-pytest-cov python-pytest-runner)) + (list font-dejavu ;tests depend on it + ghostscript + python-flit-core + python-pypa-build + python-pytest + python-pytest-xdist)) (home-page "https://weasyprint.org/") (synopsis "Document factory for creating PDF files from HTML") (description "WeasyPrint helps web developers to create PDF documents. It -- cgit v1.2.3 From 1dc1da973cc32f59c5d6beb5048e4523f70b70ef Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 00:57:01 -0400 Subject: gnu: seed: Use webkitgtk-with-libsoup2. * gnu/packages/gnome.scm (seed)[propagated-inputs]: Use webkitgtk-with-libsoup2. --- gnu/packages/gnome.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index dae6692109..d1067408ae 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -557,7 +557,7 @@ bindings.") ("xscrnsaver" ,libxscrnsaver))) (propagated-inputs `(("glib" ,glib) - ("webkit" ,webkitgtk))) + ("webkit" ,webkitgtk-with-libsoup2))) (synopsis "GObject JavaScriptCore bridge") (description "Seed is a library and interpreter, dynamically bridging (through GObjectIntrospection) the WebKit JavaScriptCore engine, with the -- cgit v1.2.3 From 9ca7d9f82d49f7e09d5a2d2b786960c2a747c807 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 00:58:18 -0400 Subject: gnu: markets: Add python-wrapper to fix build. * gnu/packages/gnome-xyz.scm (markets)[native-inputs]: Add python-wrapper. --- gnu/packages/gnome-xyz.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index e193c5b962..daec119012 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -57,6 +57,7 @@ #:use-module (gnu packages inkscape) #:use-module (gnu packages image) #:use-module (gnu packages pkg-config) + #:use-module (gnu packages python) #:use-module (gnu packages python-xyz) #:use-module (gnu packages ssh) #:use-module (gnu packages tls) @@ -1207,6 +1208,7 @@ extended file attributes. It also functions as a standalone command.") vala)) (native-inputs (list pkg-config + python-wrapper `(,glib "bin"))) ; for 'glib-compile-resources' (home-page "https://github.com/bitstower/markets") (synopsis "Stock, currency and cryptocurrency tracker") -- cgit v1.2.3 From e96c89b2c67fa643dc19140417e316e19d837a82 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 00:59:38 -0400 Subject: gnu: libgrss: Use libsoup-minimal-2 to fix build. * gnu/packages/gnome.scm (libgrss)[propagated-inputs]: Use libsoup-minimal-2. --- gnu/packages/gnome.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index d1067408ae..1bd8f82478 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -446,7 +446,7 @@ services.") (list docbook-xml-4.1.2 gobject-introspection gtk-doc/stable pkg-config)) (propagated-inputs - (list glib libsoup libxml2)) + (list glib libsoup-minimal-2 libxml2)) (synopsis "Glib library for feeds") (description "LibGRSS is a Glib abstraction to handle feeds in RSS, Atom, and other formats.") -- cgit v1.2.3 From cc9feb754b044af8ef5c595a5b76711ffed3687f Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 01:02:07 -0400 Subject: gnu: setzer: Add python-wrapper to fix build. * gnu/packages/gnome.scm (setzer)[native-inputs]: Add python-wrapper. --- gnu/packages/gnome.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 1bd8f82478..654facdbff 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -11951,7 +11951,8 @@ and toolbars.") ("gettext" ,gettext-minimal) ("glib:bin" ,glib "bin") ("gobject-introspection" ,gobject-introspection) - ("gtk+:bin" ,gtk+ "bin"))) + ("gtk+:bin" ,gtk+ "bin") + ("python-wrapper" ,python-wrapper))) (inputs `(("gsettings-desktop-schemas" ,gsettings-desktop-schemas) ("gspell" ,gspell) -- cgit v1.2.3 From faa49ec88de38fc37548cc63746542dd21591ebb Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 01:05:13 -0400 Subject: gnu: emacsy: Use webkitgtk-with-libsoup2. * gnu/packages/guile-xyz.scm (emacsy)[inputs]: Use webkitgtk-with-libsoup2. [phases]: Delete trailing #t. --- gnu/packages/guile-xyz.scm | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index ebecdfaa1e..d177cb3aa2 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -16,7 +16,7 @@ ;;; Copyright © 2017 Theodoros Foradis ;;; Copyright © 2017 Nikita ;;; Copyright © 2017, 2018, 2021 Tobias Geerinckx-Rice -;;; Copyright © 2018, 2021 Maxim Cournoyer +;;; Copyright © 2018, 2021, 2022 Maxim Cournoyer ;;; Copyright © 2018, 2019, 2020, 2021, 2022 Arun Isaac ;;; Copyright © 2018 Pierre-Antoine Rouby ;;; Copyright © 2018 Eric Bavier @@ -3343,7 +3343,7 @@ or errors (Left).") guile-lib guile-readline freeglut - webkitgtk)) + webkitgtk-with-libsoup2)) (propagated-inputs `(("glib-networking" ,glib-networking) ("gssettings-desktop-schemas" ,gsettings-desktop-schemas))) @@ -3359,8 +3359,7 @@ or errors (Left).") (modify-phases %standard-phases (add-before 'configure 'setenv (lambda _ - (setenv "GUILE_AUTO_COMPILE" "0") - #t)) + (setenv "GUILE_AUTO_COMPILE" "0"))) (add-after 'install 'wrap-binaries (lambda* (#:key inputs outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) @@ -3381,8 +3380,7 @@ or errors (Left).") (map (cut wrap-program <> `("GUILE_LOAD_PATH" ":" prefix ,scm-path) `("GUILE_LOAD_COMPILED_PATH" ":" prefix ,go-path)) - progs) - #t)))))) + progs))))))) (home-page "https://savannah.nongnu.org/projects/emacsy") (synopsis "Embeddable GNU Emacs-like library using Guile") (description -- cgit v1.2.3 From 075dbc8734dcfc5843330f7efddc733afb746ace Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 01:14:57 -0400 Subject: gnu: python-keyring: Fix test suite. [phases]{check}: Provide the tests directory argument to pytest. Ignore project pytest configs and make it verbose. [native-inputs]: Delete python-pytest-checkdocs, python-pytest-cov and python-pytest-flake8. --- gnu/packages/python-crypto.scm | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/gnu/packages/python-crypto.scm b/gnu/packages/python-crypto.scm index 08b86335c0..60879f1c52 100644 --- a/gnu/packages/python-crypto.scm +++ b/gnu/packages/python-crypto.scm @@ -24,7 +24,7 @@ ;;; Copyright © 2020 Alexandros Theodotou ;;; Copyright © 2020 Justus Winter ;;; Copyright © 2020, 2021 Vinicius Monego -;;; Copyright © 2021 Maxim Cournoyer +;;; Copyright © 2021, 2022 Maxim Cournoyer ;;; Copyright © 2021 Maxime Devos ;;; ;;; This file is part of GNU Guix. @@ -351,14 +351,10 @@ do what is needed for client/server Kerberos authentication based on (replace 'check (lambda* (#:key tests? #:allow-other-keys) (when tests? - (invoke "pytest")) - #t))))) + (invoke "pytest" "-vv" "-c" "/dev/null" "tests"))))))) (native-inputs (list python-toml python-pytest - python-pytest-checkdocs - python-pytest-cov - python-pytest-flake8 python-setuptools python-setuptools-scm)) (propagated-inputs -- cgit v1.2.3 From 70bb54c8a2565df6e14cc8f453b4c3daeaf07214 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 01:16:53 -0400 Subject: gnu: Remove python2-keyring. * gnu/packages/python-crypto.scm (python2-keyring): Delete variable. (python-keyring)[properties]: Delete field. --- gnu/packages/python-crypto.scm | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/gnu/packages/python-crypto.scm b/gnu/packages/python-crypto.scm index 60879f1c52..7f358659f0 100644 --- a/gnu/packages/python-crypto.scm +++ b/gnu/packages/python-crypto.scm @@ -366,30 +366,8 @@ do what is needed for client/server Kerberos authentication based on service from python. It can be used in any application that needs safe password storage.") ;; "MIT" and PSF dual license - (properties `((python2-variant . ,(delay python2-keyring)))) (license license:x11))) -(define-public python2-keyring - (let ((keyring (package-with-python2 - (strip-python2-variant python-keyring)))) - (package - (inherit keyring) - (name "python2-keyring") - (version "8.7") - (source - (origin - (method url-fetch) - (uri (pypi-uri "keyring" version)) - (sha256 - (base32 - "0482rmi2x6p78wl2kz8qzyq21xz1sbbfwnv5x7dggar4vkwxhzfx")))) - (arguments - `(#:python ,python-2)) - (native-inputs - (list python2-pytest python2-pytest-runner python2-setuptools-scm)) - (propagated-inputs - (list python2-pycrypto))))) - (define-public python-keyrings.alt (package (name "python-keyrings.alt") -- cgit v1.2.3 From cecf1953475719b36716630f6765ae6b12631bb4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 01:20:37 -0400 Subject: gnu: python-pingouin: Update to 0.5.1. * gnu/packages/python-science.scm (python-pingouin): Update to 0.5.1. --- gnu/packages/python-science.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index 0ff971e46c..bf7c7ce45f 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -945,7 +945,7 @@ of Pandas (define-public python-pingouin (package (name "python-pingouin") - (version "0.5.0") + (version "0.5.1") (source ;; The PyPI tarball does not contain the tests. (origin @@ -956,7 +956,7 @@ of Pandas (file-name (git-file-name name version)) (sha256 (base32 - "01aaq023q4bymffrc2wm56af87da32wcvy5d5156i4g7qgvh346r")))) + "10v3mwcmyc7rd2957cbmfcw66yw2y0fz7zcfyx46q8slbmd1d8d4")))) (build-system python-build-system) (arguments `(#:phases -- cgit v1.2.3 From dff469209e14b867b1f3f6e946526b4654cc4d08 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 01:26:34 -0400 Subject: gnu: python-flask-wtf: Update to 1.0.1. * gnu/packages/python-web.scm (python-flask-wtf): Update to 1.0.1. [propagated-inputs]: Remove python-flask-babel and python-babel. Add python-flask and python-itsdangerous. --- gnu/packages/python-web.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 89b688da32..f98f824daa 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -3249,14 +3249,14 @@ presume or force a developer to use a particular tool or library.") (define-public python-flask-wtf (package (name "python-flask-wtf") - (version "0.14.3") + (version "1.0.1") (source (origin (method url-fetch) (uri (pypi-uri "Flask-WTF" version)) (sha256 (base32 - "086pvg2x69n0nczcq7frknfjd8am1zdy8qqpva1sanwb02hf65yl")))) + "1jd614662r6ifh4svs8zfwm4k8bal5z3n6pq607bas8gxrpmrzil")))) (build-system python-build-system) (arguments '(#:phases @@ -3265,7 +3265,7 @@ presume or force a developer to use a particular tool or library.") (lambda _ (invoke "pytest" "-vv")))))) (propagated-inputs - (list python-flask-babel python-babel python-wtforms)) + (list python-flask python-itsdangerous python-wtforms)) (native-inputs (list python-pytest)) (home-page "https://github.com/lepture/flask-wtf") -- cgit v1.2.3 From 7d882da0ebdb64b7d0dbdfe964bc75d3274a3265 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 01:47:20 -0400 Subject: gnu: python-flask-login: Update to 0.6.0. * gnu/packages/python-web.scm (python-flask-login): Update to 0.6.0. [arguments]: New field. [native-inputs]: Remove python-coverage, python-pycodestyle and python-pyflakes. --- gnu/packages/python-web.scm | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index f98f824daa..094ec10e4b 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -3837,7 +3837,7 @@ on the command line.") (define-public python-flask-login (package (name "python-flask-login") - (version "0.5.0") + (version "0.6.0") (source (origin (method git-fetch) @@ -3846,17 +3846,21 @@ on the command line.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "11ac924w0y4m0kf3mxnxdlidy88jfa7njw5yyrq16dvnx4iwd8gg")))) + (base32 "12yw01ccgjn9c88cbkrd6k1ykjxd8fxip2b1isvxjirphnlqhn9g")))) (build-system python-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "-c" "/dev/null"))))))) (propagated-inputs (list python-flask)) (native-inputs ;; For tests. (list python-blinker - python-coverage python-mock - python-pycodestyle - python-pyflakes python-pytest python-semantic-version python-werkzeug)) -- cgit v1.2.3 From e56ff456000155d8ecaf61b1a9af8ac93bda7eb4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 01:53:31 -0400 Subject: snippets: Add a 'remove' snippet. * etc/snippets/text-mode/guix-commit-message-remove-package: New file. --- etc/snippets/text-mode/guix-commit-message-remove-package | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 etc/snippets/text-mode/guix-commit-message-remove-package diff --git a/etc/snippets/text-mode/guix-commit-message-remove-package b/etc/snippets/text-mode/guix-commit-message-remove-package new file mode 100644 index 0000000000..0c1050f4fe --- /dev/null +++ b/etc/snippets/text-mode/guix-commit-message-remove-package @@ -0,0 +1,13 @@ +# -*- mode: snippet -*- +# name: guix-commit-message-remove-package +# key: remove +# condition: git-commit-mode +# -- +gnu: Remove ${1:`(with-temp-buffer + (magit-git-wash #'magit-diff-wash-diffs + "diff" "--staged") + (goto-char (point-min)) + (when (re-search-forward "\\-(define-public \\(\\S-+\\)" nil 'noerror) + (match-string-no-properties 1)))`}. + +* `(car (magit-staged-files))` ($1): Delete variable. -- cgit v1.2.3 From ab36b88b1a67059a9ea5a3c1c6b5db6563c962cc Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 08:51:49 -0400 Subject: gnu: python2-sqlalchemy: Skip a failing test. * gnu/packages/databases.scm (python2-sqlalchemy)[phases]{check}: Skip the test_fixture_five test. --- gnu/packages/databases.scm | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index ac3ecbfef1..feedfe68e7 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -3371,7 +3371,12 @@ simple and Pythonic domain language.") (invoke "pytest" "-vv" ;; The memory usage tests are very expensive and run in ;; sequence; skip them. - "-k" "not test_memusage.py")))))))) + "-k" + (string-append + "not test_memusage.py" + ;; This test fails with "AssertionError: Warnings + ;; were not seen [...]". + " and not test_fixture_five"))))))))) ;; Do not use pytest-xdist, which is broken for Python 2. (native-inputs (modify-inputs (package-native-inputs base) (delete "python-pytest-xdist")))))) -- cgit v1.2.3 From 418630a63c26bf683bb215fe2f655485f07020ea Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 20 Apr 2022 14:03:34 -0400 Subject: gnu: dynaconf: Fix build following python-click upgrade. * gnu/packages/python-xyz.scm (dynaconf) [phases]{patch-for-click-8}: New phase. {check}: Remove extraneous setenv call. [native-inputs]: Use the regular python-pytest variable. --- gnu/packages/python-xyz.scm | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 8d12f28850..8b55e67ca9 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -30183,12 +30183,14 @@ Python @code{set} interface.") (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'patch-for-click-8 + (lambda _ + (substitute* "dynaconf/cli.py" + (("click.get_os_args\\()") ;deprecated from Click 8.1+ + "sys.argv[1:]")))) (replace 'check (lambda* (#:key tests? outputs #:allow-other-keys) (when tests? - (setenv "PATH" - (string-append (assoc-ref outputs "out") "/bin:" - (getenv "PATH"))) ;; These tests depend on hvac and a live Vault process. (delete-file "tests/test_vault.py") (invoke "make" "test_only"))))))) @@ -30196,7 +30198,7 @@ Python @code{set} interface.") (list python-click python-configobj python-dotenv-0.13.0 python-ruamel.yaml python-toml)) (native-inputs - (list python-django python-flask python-pytest-6 python-pytest-cov + (list python-django python-flask python-pytest python-pytest-cov python-pytest-mock)) (home-page "https://www.dynaconf.com/") (synopsis "The dynamic configurator for your Python project") -- cgit v1.2.3 From a7e5a116fd9088bbcac0af71546966d8352491b1 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 15:53:03 -0400 Subject: gnu: python-numpydoc: Update to 1.2.1. * gnu/packages/python-xyz.scm (python-numpydoc): Update to 1.2.1. Fix indentation. [phases]{relax-requirements}: New phase. [propagated-inputs]: Add python-jinja2. --- gnu/packages/python-xyz.scm | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 8b55e67ca9..ea1fb174c4 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -6438,34 +6438,34 @@ parse and apply unified diffs. It has features such as: (define-public python-numpydoc (package (name "python-numpydoc") - (version "1.1.0") + (version "1.2.1") (source (origin (method url-fetch) (uri (pypi-uri "numpydoc" version)) (sha256 (base32 - "13j4fvy2p7lc8sn00sxvs0jb19vicaznfgx4cphv9jgxgz5xcvy3")))) + "1xjsli2fqks4iv3524v1d329siad7bbsi4kr174zvhsl1pnjds3w")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'relax-requirements + (lambda _ + (substitute* "setup.py" + (("'Jinja2>=2.10,<3.1'") + "'Jinja2>=2.10'")))) (replace 'check - (lambda* (#:key tests? inputs outputs #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - (add-installed-pythonpath inputs outputs) (invoke "pytest" "-v" "numpydoc/tests" ;; TODO: unclear why these fail. "-k" "not test_MyClass and not test_my_function"))))))) - (propagated-inputs - (list python-sphinx)) - (native-inputs - (list python-matplotlib python-pytest python-pytest-cov)) + (propagated-inputs (list python-jinja2 python-sphinx)) + (native-inputs (list python-matplotlib python-pytest python-pytest-cov)) (home-page "https://pypi.org/project/numpydoc/") - (synopsis - "Numpy's Sphinx extensions") - (description - "Sphinx extension to support docstrings in Numpy format.") + (synopsis "Numpy's Sphinx extensions") + (description "Sphinx extension to support docstrings in Numpy format.") (license license:bsd-2) (properties `((python2-variant . ,(delay python2-numpydoc)))))) -- cgit v1.2.3 From bb7b6ac13ed5bd6d8432563839253ca651bdeef6 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 16:10:00 -0400 Subject: gnu: python-sphinx: Update to 4.5.0. * gnu/packages/sphinx.scm (python-sphinx): Update to 4.5.0. [phases]{check}: Set HOME to /tmp. [propagated-inputs]: Add python-importlib-metadata. [native-inputs]: Add python-cython. --- gnu/packages/sphinx.scm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index cb1897041b..ac8aa39420 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -60,14 +60,14 @@ (define-public python-sphinx (package (name "python-sphinx") - (version "4.2.0") + (version "4.5.0") (source (origin (method url-fetch) (uri (pypi-uri "Sphinx" version)) (sha256 (base32 - "19jq21py7m061v8142y2dbqrbv0adqcdjmharrdy34a432wqs1wl")))) + "1rp28jryxwy24y8vpacclqihbizyi6b1s6id86pibvm46ybcmy3v")))) (build-system python-build-system) (arguments `(#:phases @@ -80,12 +80,14 @@ (substitute* "tests/test_build_latex.py" (("@pytest.mark.sphinx\\('latex', testroot='images'\\)") "@pytest.mark.skip()")) + (setenv "HOME" "/tmp") ;for test_cython (invoke "make" "test"))))))) (propagated-inputs (list python-babel python-docutils python-jinja2 python-imagesize + python-importlib-metadata python-packaging python-pygments python-requests @@ -134,6 +136,7 @@ texlive-xcolor)) (native-inputs (list imagemagick ;for "convert" + python-cython python-html5lib python-pytest)) (home-page "https://www.sphinx-doc.org") -- cgit v1.2.3 From c2a77beb1ab43fb549cb0f8524e8a1efc7924e2b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 22 Apr 2022 14:29:27 -0400 Subject: gnu: python-pydata-sphinx-theme: Update to 0.7.2. * gnu/packages/sphinx.scm (python-pydata-sphinx-theme): Update to 0.7.2. Add TODO comment. [arguments]: New field. [native-inputs]: Delete python-jupyter-sphinx, python-numpy, python-numpydoc, python-pandas, python-recommonmark and python-xarray. Move python-docutils and python-sphinx to... [propagated-inputs]: ... here. Add python-jinja2 --- gnu/packages/sphinx.scm | 33 +++++++++++++++++++-------------- 1 file changed, 19 insertions(+), 14 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index ac8aa39420..497b301bc8 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -1077,29 +1077,34 @@ Sphinx documentation.") (define-public python-pydata-sphinx-theme (package (name "python-pydata-sphinx-theme") - (version "0.6.3") + ;; TODO: This is not the latest release, but the 0.8.x series introduced a + ;; new Sphinx theme build system that complicate things (see: + ;; https://github.com/pydata/pydata-sphinx-theme/issues/628 and + ;; https://src.fedoraproject.org/rpms/python-pydata-sphinx-theme + ;; /blob/rawhide/f/prepare_vendor.sh). + (version "0.7.2") (source (origin (method url-fetch) (uri (pypi-uri "pydata-sphinx-theme" version)) (sha256 (base32 - "055bh3hyh72pafiylvgpsjlk18wm15gg4azc5rjlsww5z475iq1j")))) + "0ph69bnnw9w8vksc7rk45q5yknsrsgk9a19xsbxym46jrmgz67b7")))) (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) (propagated-inputs - (list python-beautifulsoup4)) - (native-inputs (list python-beautifulsoup4 - python-docutils-0.15 - python-jupyter-sphinx - python-numpy - python-numpydoc - python-pandas - python-pytest - python-pytest-regressions - python-recommonmark - python-sphinx - python-xarray)) + python-docutils + python-jinja2 + python-sphinx)) + (native-inputs (list python-pytest python-pytest-regressions)) (home-page "https://github.com/pydata/pydata-sphinx-theme") (synopsis "Bootstrap-based Sphinx theme") (description -- cgit v1.2.3 From 9812a44f8654176c51ba1af18b0b38d91f812443 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 21:43:12 -0400 Subject: gnu: python-sphinx-copybutton: Update to 0.5.0. * gnu/packages/sphinx.scm (python-sphinx-copybutton): Update to 0.5.0. [propagated-inputs]: Delete python-flit, python-setuptools and python-wheel. --- gnu/packages/sphinx.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 497b301bc8..5788bb7870 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -268,19 +268,18 @@ documents click applications.") (define-public python-sphinx-copybutton (package (name "python-sphinx-copybutton") - (version "0.2.6") + (version "0.5.0") (source (origin (method url-fetch) (uri (pypi-uri "sphinx-copybutton" version)) (sha256 (base32 - "0ny9jpygj93z8jyjpi4v6jjz90pmns74s389wq16igzzq2mpgfjm")))) + "1xl7jwcldqvfya2gdp1nfxma7rv35alk998dfnx2fg6hmpd5kh50")))) (build-system python-build-system) (arguments `(#:tests? #f)) ; XXX: Check requires network access. - (propagated-inputs - (list python-flit python-setuptools python-sphinx python-wheel)) + (propagated-inputs (list python-sphinx)) (home-page "https://github.com/choldgraf/sphinx-copybutton") (synopsis "Sphinx extension to add \"copy\" buttons to code blocks") (description -- cgit v1.2.3 From 80ec843bf4e5a3d458e5aa4147f732353a8d2e23 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 21:49:02 -0400 Subject: gnu: python-sphinx-click: Update to 4.0.3 and enable tests. * gnu/packages/sphinx.scm (python-sphinx-click): Update to 4.0.3. [arguments]: Delete field. [native-inputs]: Delete python-coverage. Add python-pytest and python-wheel. Move python-click, python-docutils and python-sphinx to... [propagated-inputs]: ... here. --- gnu/packages/sphinx.scm | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 5788bb7870..739d32398c 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -242,23 +242,23 @@ Apple help books.") (define-public python-sphinx-click (package (name "python-sphinx-click") - (version "3.0.1") + (version "4.0.3") (source (origin (method url-fetch) (uri (pypi-uri "sphinx-click" version)) (sha256 (base32 - "118ppsymp1p2gn8v7mifika817qx6v07mja7kxizq9cg7dpw894v")))) + "1nqy3b7wr64rbmdp7kpi723az53a89y6250h46i505g1rw0czam1")))) (build-system python-build-system) (arguments - `(#:tests? #f)) ;requires python-coverage<5.0 - (native-inputs - (list python-click - python-coverage - python-docutils - python-pbr - python-sphinx)) + (list #:phases #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "tests"))))))) + (native-inputs (list python-pbr python-pytest python-wheel)) + (propagated-inputs (list python-click python-docutils python-sphinx)) (home-page "https://github.com/click-contrib/sphinx-click") (synopsis "Sphinx extension that documents click applications") (description "This package provide sphinx extension that automatically -- cgit v1.2.3 From 936e335ac21fcb84ca34962b8cfd7b2f9a8abe41 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 21:54:25 -0400 Subject: gnu: python-sphinxcontrib-websupport: Update to 1.2.4. * gnu/packages/sphinx.scm (python-sphinxcontrib-websupport): Update to 1.2.4. --- gnu/packages/sphinx.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 739d32398c..90568f855f 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -506,13 +506,13 @@ builder does not support SVG images natively (e.g. LaTeX).") (define-public python-sphinxcontrib-websupport (package (name "python-sphinxcontrib-websupport") - (version "1.2.0") + (version "1.2.4") (source (origin (method url-fetch) (uri (pypi-uri "sphinxcontrib-websupport" version)) (sha256 (base32 - "1smma7r0rhwcmbfvvkfs5djfz1qm8wbpcvp084ca6dmw2b9zplxs")))) + "0ck2jphvs82vjcbphhd1h7j1xfi9ynv5d8g5b947qnk8l0ih5psf")))) (build-system python-build-system) (arguments ;; FIXME: Tests depend on Sphinx, which depends on this. -- cgit v1.2.3 From ab26bfd4d92212daece91d7d523af7a8195da4b4 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 21:55:28 -0400 Subject: gnu: python-sphinxcontrib-programoutput: Update to 0.17 and enable tests. * gnu/packages/sphinx.scm (python-sphinxcontrib-programoutput): Update to 0.17. [arguments]: Delete field. --- gnu/packages/sphinx.scm | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 90568f855f..f9c588c8cb 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -423,19 +423,15 @@ Blog, News or Announcements section to a Sphinx website.") (define-public python-sphinxcontrib-programoutput (package (name "python-sphinxcontrib-programoutput") - (version "0.15") + (version "0.17") (source (origin (method url-fetch) (uri (pypi-uri "sphinxcontrib-programoutput" version)) (sha256 (base32 - "155bz0z2cz544pphkd3nk7ph83mz7nn0ql135kzi62kqmd75ppc0")))) + "0zrb2ny6y7nk84qmw5mds84fc4pxgqf4sjy7bk95b0zfrawfj3ih")))) (build-system python-build-system) - (arguments - ;; FIXME: Many tests are failing. - '(#:tests? #f)) - (propagated-inputs - (list python-sphinx)) + (propagated-inputs (list python-sphinx)) (synopsis "Sphinx extension to include program output") (description "A Sphinx extension to literally insert the output of arbitrary commands into documents, helping you to keep your command examples up to date.") -- cgit v1.2.3 From badd61bed29dadb148f64f9d21654b513441d057 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 21:57:15 -0400 Subject: gnu: python-sphinx-argparse: Update to 0.3.1. * gnu/packages/sphinx.scm (python-sphinx-argparse): Update to 0.3.1. --- gnu/packages/sphinx.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index f9c588c8cb..25dcff01be 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -682,13 +682,13 @@ theme for the Sphinx documentation system. It's the default theme of Sphinx.") (define-public python-sphinx-argparse (package (name "python-sphinx-argparse") - (version "0.2.5") + (version "0.3.1") (source (origin (method url-fetch) (uri (pypi-uri "sphinx-argparse" version)) (sha256 - (base32 "05wc8f5hb3jsg2vh2jf7jsyan8d4i09ifrz2c8fp6f7x1zw9iav0")))) + (base32 "07nw68nrbpzsswb5bz8gdb5allgj6jnz8m81afhr9v6c8fyiq5c2")))) (build-system python-build-system) (propagated-inputs (list python-sphinx)) -- cgit v1.2.3 From ea20078ccb098ee0e5a27cfed7efdf4fe9c7d799 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 22:29:41 -0400 Subject: gnu: python-sphinx-cloud-sptheme: Update to 1.10.1 [still broken]. * gnu/packages/sphinx.scm (python-sphinx-cloud-sptheme): Update to 1.10.1. [source]: Update source to point to new Mercurial repository. [arguments]: Delete field, enabling tests (which fail due to Jinja2 >= 3.1). [native-inputs]: Move python-sphinx to... [propagated-inputs]: ... here. [description]: Do not use raw quotes to decorate text. --- gnu/packages/sphinx.scm | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 25dcff01be..4b485d53c0 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -38,6 +38,7 @@ #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) + #:use-module (guix hg-download) #:use-module (guix gexp) #:use-module (guix utils) #:use-module (guix build-system python) @@ -701,25 +702,28 @@ theme for the Sphinx documentation system. It's the default theme of Sphinx.") argparse commands and options") (license license:expat))) +;;; FIXME: Currently broken by Jinja >= 3.10 (see: +;;; https://foss.heptapod.net/doc-utils/cloud_sptheme/-/issues/47). (define-public python-sphinx-cloud-sptheme (package (name "python-sphinx-cloud-sptheme") - (version "1.8.0") + (version "1.10.1") (source (origin - (method url-fetch) - (uri (pypi-uri "cloud_sptheme" version)) + (method hg-fetch) + (uri (hg-reference + (url "https://foss.heptapod.net/doc-utils/cloud_sptheme") + (changeset version))) + (file-name (hg-file-name name version)) (sha256 (base32 - "1dniqb6a39yh786f86c4jn666rwnyi1jvzn4616zhcchb7sfdshd")))) + "0k0pgi0vcn8vdy3k6x11fpp4mqp7p3l6n6pjfi3mir3vwjhdfz7l")))) (build-system python-build-system) - ;; FIXME: The 'pypi' release archive does not contain tests. - (arguments '(#:tests? #f)) - (native-inputs - (list python-sphinx)) - (home-page "https://bitbucket.org/ecollins/cloud_sptheme") - (synopsis "'Cloud' theme for Sphinx documenter") - (description "This package contains the \"Cloud\" theme for Sphinx and some -related extensions.") + (native-inputs (list python-mock)) + (propagated-inputs (list python-sphinx)) + (home-page "https://foss.heptapod.net/doc-utils/cloud_sptheme") + (synopsis "Cloud theme for Sphinx") + (description "This package contains the @emph{Cloud} theme for Sphinx and +some related extensions.") (license license:bsd-3))) (define-public python-guzzle-sphinx-theme -- cgit v1.2.3 From 50b620f119e3aea2876f4b8580a49de059fc038b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 23:14:29 -0400 Subject: gnu: Add python-beartype. * gnu/packages/python-check.scm (python-beartype): New variable. --- gnu/packages/python-check.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 41b73172b0..8cabd05dd5 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -70,6 +70,38 @@ Protocol (TAP) in Python. TAP is a line based test protocol for recording test data in a standard way.") (license license:bsd-3))) +(define-public python-beartype + (package + (name "python-beartype") + (version "0.10.4") + (source + (origin + (method url-fetch) + (uri (pypi-uri "beartype" version)) + (sha256 + (base32 "0amzckgw9c93bl4jf0q6322j9wyyf3i8vl03yixfkrpllzv6kv14")))) + (build-system python-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "beartype_test" + ;; These tests rely on git through the + ;; "get_main_readme_file" helper. + "-k" + (string-append "not test_doc_readme " + "and not test_sphinx " + "and not test_pep561_mypy")))))))) + (native-inputs + (list python-pytest)) + (home-page "https://github.com/beartype/beartype") + (synopsis "Fast runtime type checking for Python") + (description "Beartype aims to be a very fast runtime type checking tool +written in pure Python.") + (license license:expat))) + (define-public python-pytest-click (package (name "python-pytest-click") -- cgit v1.2.3 From 4d62953573ecf8a1e5616a4a7c1577d91ad9f57a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 23:20:23 -0400 Subject: gnu: Add python-nptyping. * gnu/packages/python-check.scm (python-nptyping): New variable. --- gnu/packages/python-check.scm | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 8cabd05dd5..a1601d6656 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -1811,6 +1811,40 @@ them using any Python VM with basically no runtime overhead.") (delete 'ensure-no-mtimes-pre-1980)))) (native-inputs '())))) +(define-public python-nptyping + (package + (name "python-nptyping") + (version "2.0.0") + (source (origin + (method git-fetch) ;pypi only contains a binary wheel + (uri (git-reference + (url "https://github.com/ramonhagenaars/nptyping") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0839mcrv5jljq9k9124ssnl1hc1inbxwlwjk72imabsbqssjy9rb")))) + (build-system python-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-before 'build 'set-source-date-epoch + (lambda _ + ;; Otherwise the wheel building test would fail with "ZIP does + ;; not support timestamps before 1980". + (setenv "SOURCE_DATE_EPOCH" "315532800")))))) + (native-inputs + (list python-beartype + python-mypy + python-typeguard + python-wheel)) + (propagated-inputs (list python-numpy python-typing-extensions)) + (home-page "https://github.com/ramonhagenaars/nptyping") + (synopsis "Type hints for Numpy") + (description "This package provides extensive dynamic type checks for +dtypes and shapes of arrays for NumPy, extending @code{numpy.typing}.") + (license license:expat))) + (define-public python-pylama (package (name "python-pylama") -- cgit v1.2.3 From 0efccc8f1881f8272a2eafb5b948047cf8912dec Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 23:31:24 -0400 Subject: gnu: python-sphinx-autodoc-typehints: Update to 1.18.1. * gnu/packages/sphinx.scm (python-sphinx-autodoc-typehints): Update to 1.18.1. [source]: Use git. [argument]: New field. [propagated-inputs]: Add python-sphinx. [native-inputs]: Remove python-dataclasses and python-sphinx. Add python-nptyping and python-setuptools-scm. --- gnu/packages/sphinx.scm | 39 +++++++++++++++++++++++++++++++-------- 1 file changed, 31 insertions(+), 8 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 4b485d53c0..5e0ac96ab6 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -50,6 +50,7 @@ #:use-module (gnu packages imagemagick) #:use-module (gnu packages python) #:use-module (gnu packages python-build) + #:use-module (gnu packages python-check) #:use-module (gnu packages python-crypto) #:use-module (gnu packages python-web) #:use-module (gnu packages python-xyz) @@ -872,20 +873,42 @@ enabled web server.") (define-public python-sphinx-autodoc-typehints (package (name "python-sphinx-autodoc-typehints") - (version "1.11.1") + (version "1.18.1") (source (origin - (method url-fetch) - (uri (pypi-uri "sphinx-autodoc-typehints" version)) + (method git-fetch) ;no tests in pypi archive + (uri (git-reference + (url "https://github.com/tox-dev/sphinx-autodoc-typehints") + (commit version))) + (file-name (git-file-name name version)) (sha256 (base32 - "086v9mg21pvfx0lfqjx2xf36hnzrsripfg345xi59f7xwb9scjr4")))) + "16yhpwfdmybir80a6892cnr98m58p19rklmjdlzhk3njx7di8jzp")))) (build-system python-build-system) - (propagated-inputs - (list python-setuptools-scm python-sphinx)) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'pretend-version + ;; The version string is usually derived via setuptools-scm, but + ;; without the git metadata available, the version string is set to + ;; '0.0.0'. + (lambda _ + (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" #$version))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "tests" + ;; This test requires to download an objects.inv file + ;; from the Sphinx website. + "-k" "not test_format_annotation"))))))) + (propagated-inputs (list python-sphinx)) (native-inputs - (list python-dataclasses python-pytest python-sphinx - python-sphobjinv python-typing-extensions)) + (list python-nptyping + python-pytest + python-setuptools-scm + python-sphobjinv + python-typing-extensions)) (home-page "https://pypi.org/project/sphinx-autodoc-typehints/") (synopsis "Type hints for the Sphinx autodoc extension") (description "This extension allows you to use Python 3 annotations for -- cgit v1.2.3 From 01360c8b02f259f7b3890fc0b6dcd37f33ae4d38 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 23:34:24 -0400 Subject: gnu: python-sphinxext-opengraph: Update to 0.6.3. * gnu/packages/sphinx.scm (python-sphinxext-opengraph): Update to 0.6.3. [phases]{check}: Streamline and invoke pytest verbosely. [native-inputs]: Indent on a single line. --- gnu/packages/sphinx.scm | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 5e0ac96ab6..42eb34810a 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -812,7 +812,7 @@ translate and to apply translation to Sphinx generated document.") (define-public python-sphinxext-opengraph (package (name "python-sphinxext-opengraph") - (version "0.4.2") + (version "0.6.3") (source (origin (method git-fetch) ; no tests in PyPI release @@ -821,18 +821,16 @@ translate and to apply translation to Sphinx generated document.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0dka44wri7agcr1jd641hq6j7qlbycligp80ngf32l5asqz1mgzp")))) + (base32 "1wrgpan9z65fv4hbvisz4sypc4w5ammnxkyn5lhr43wdr6b967k1")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) + (lambda* (#:key tests? #:allow-other-keys) (when tests? - (add-installed-pythonpath inputs outputs) - (invoke "python" "-m" "pytest"))))))) - (native-inputs - (list python-beautifulsoup4 python-pytest python-sphinx)) + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-beautifulsoup4 python-pytest python-sphinx)) (home-page "https://github.com/wpilibsuite/sphinxext-opengraph") (synopsis "Sphinx Extension to enable OpenGraph support") (description -- cgit v1.2.3 From c16f282d560675af51e6bd5dd65b36baaf7850e8 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 23:36:55 -0400 Subject: gnu: python-sphinx-rtd-theme: Update to 1.0.0. * gnu/packages/sphinx.scm (python-sphinx-rtd-theme): Update to 1.0.0. --- gnu/packages/sphinx.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index 42eb34810a..ae0080b308 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -751,18 +751,17 @@ and several other projects.") (define-public python-sphinx-rtd-theme (package (name "python-sphinx-rtd-theme") - (version "0.2.4") + (version "1.0.0") (source (origin (method url-fetch) (uri (pypi-uri "sphinx_rtd_theme" version)) (sha256 (base32 - "05rlhjzdyapr2w74jjs7mrm8hi69qskcr5vya9f9drpsys7lpxrd")))) + "0p3abj91c3l72ajj5jwblscsdf1jflrnn0djx2h5y6f2wjbx9ipf")))) (build-system python-build-system) (arguments '(#:tests? #f)) ; No tests. - (propagated-inputs - (list python-sphinx)) + (propagated-inputs (list python-docutils python-sphinx)) (home-page "https://github.com/snide/sphinx_rtd_theme/") (synopsis "ReadTheDocs.org theme for Sphinx") (description "A theme for Sphinx used by ReadTheDocs.org.") -- cgit v1.2.3 From b60ca1f3b83ae62194cd8ea7317f4aef3b2bc2e7 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 21 Apr 2022 12:06:41 -0400 Subject: gnu: python-numpy-documentation: Overhaul package definition. * gnu/packages/python-xyz.scm (python-numpy-documentation): Relocate next to the python-numpy package in the module. Inherit from python-numpy. [version, source, build-system, home-page, license]: Remove fields, now inherited. [phases]{add-gnu-freefont-to-texmf}: New phase. {install}: Patch conf.py to allow building the info manual. Set HOME. Copy the whole generated HTML directory. Parallelize documentation build. [native-inputs]: Use new style. Add font-gnu-freefont, fontconfig, python-breathe, python-ipython, python-pandas, python-pydata-sphinx-theme, python-scipy, python-sphinx-panels, texlive-bin, texlive-cbfonts, texlive-cm-super, texlive-greek-fontenc, texlive-latex-expdlist, texlive-polyglossia and texlive-xindy. Remove pkg-config, the previous "texlive" updmap.cfg package, scipy-sphinx-theme, and do not inherit the native inputs of python-numpy. [synopsis]: Refine. [description]: Expound a bit. --- gnu/packages/python-xyz.scm | 206 ++++++++++++++++++++------------------------ 1 file changed, 93 insertions(+), 113 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index ea1fb174c4..1140e29790 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -5863,6 +5863,99 @@ capabilities.") (base32 "19dw91pqbqcniw2z57kiyqs1qp56g7kqy1bdyv664g8s62sc01m9")))))) +(define-public python-numpy-documentation + (package + (inherit python-numpy) + (name "python-numpy-documentation") + (arguments + (list + #:tests? #f ;we're only generating the documentation + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'add-gnu-freefont-to-texmf + (lambda _ + ;; XXX: The Sphinx-generated tex output specifies the GNU + ;; FreeFont font to be searched via its extension, which uses + ;; kpathsea instead of fontconfig and fail (see: + ;; https://github.com/sphinx-doc/sphinx/issues/10347). Create a + ;; symlink to GNU FreeFont and add it to the TEXMF tree via + ;; GUIX_TEXMF. + (mkdir-p "texmf-dist/fonts/opentype/public") + (symlink (string-append + #$(this-package-native-input "font-gnu-freefont") + "/share/fonts/opentype") + (string-append + (getcwd) "/" + "texmf-dist/fonts/opentype/public/gnu-freefont")) + (setenv "GUIX_TEXMF" (string-append (getenv "GUIX_TEXMF") ":" + (getcwd) "/texmf-dist")))) + (delete 'build) + (replace 'install + (lambda _ + (let* ((data (string-append #$output "/share")) + (doc (string-append data "/doc/numpy")) + (html (string-append doc "/html")) + (info (string-append data "/info")) + (sphinxopts (string-append + "SPHINXOPTS=-j" + (number->string (parallel-job-count))))) + (with-directory-excursion "doc" + ;; Do not treat warnings as errors. + (substitute* "Makefile" + ((" -WT ") " -T ")) + (setenv "HOME" "/tmp") + ;; Build the PDF documentation. + (invoke "make" "latex-build" sphinxopts) + (invoke "make" "-C" "build/latex" "all-pdf" sphinxopts) + ;; Build the HTML documentation + (invoke "make" "html" sphinxopts) + ;; Build the Info documentation. The issues worked around + ;; below can be tracked at + ;; https://github.com/numpy/numpy/issues/12278. + (substitute* "source/conf.py" + ;; The root document should be "index", not "contents". + (("\"contents\"") "'index'") + ;; Disable Sphinx extensions that produce broken Texinfo. + ((".*'numpydoc'.*") "") + ((".*'sphinx.ext.autosummary'.*") "")) + (invoke "make" "info" sphinxopts) + ;; Install the HTML documentation. + (mkdir-p html) + (copy-recursively "build/html" html) + ;; Install the PDF reference and user manuals. + (install-file "build/latex/numpy-ref.pdf" doc) + (install-file "build/latex/numpy-user.pdf" doc) + ;; Install the info manual. + (install-file "build/texinfo/numpy.info" info) + (symlink (string-append html "/_images") + (string-append info "/numpy-figures"))))))))) + (native-inputs + (list font-gnu-freefont + perl + python-breathe + python-ipython + python-matplotlib + python-numpy + python-numpydoc + python-pandas + python-pydata-sphinx-theme + python-scipy ;used by matplotlib + python-sphinx + python-sphinx-panels + texinfo + texlive-bin + texlive-cbfonts + texlive-cm-super + texlive-greek-fontenc + texlive-latex-expdlist + texlive-polyglossia + texlive-xindy)) + (inputs '()) + (propagated-inputs '()) + (synopsis "Documentation for the @code{python-numpy} package") + (description "This package provides the complete NumPy documentation in +the Texinfo, HTML, and PDF formats."))) + ;; Numpy 1.16.x are the last versions that support Python 2. (define-public python2-numpy (let ((numpy (package-with-python2 @@ -6083,119 +6176,6 @@ parser that can be used to decode raw NTLM/SPNEGO/Kerberos tokens into a human readable format.") (license license:expat))) -(define-public python-numpy-documentation - (package - (name "python-numpy-documentation") - (version (package-version python-numpy)) - (source (package-source python-numpy)) - (build-system python-build-system) - (native-inputs - `(("python-matplotlib" ,python-matplotlib) - ("python-numpy" ,python-numpy) - ("pkg-config" ,pkg-config) - ("python-sphinx" ,python-sphinx) - ("python-numpydoc" ,python-numpydoc) - ("texlive" ,(texlive-updmap.cfg (list - texlive-capt-of - texlive-cm-super - texlive-fonts-ec - texlive-generic-iftex - texlive-pdftex - texlive-amsfonts - texlive-latex-cmap - texlive-latex-environ - texlive-latex-eqparbox - texlive-etoolbox - texlive-latex-expdlist - texlive-latex-fancyhdr - texlive-latex-fancyvrb - texlive-latex-fncychap - texlive-latex-float - texlive-latex-framed - texlive-latex-geometry - texlive-latex-graphics - texlive-hyperref - texlive-latex-mdwtools - texlive-latex-multirow - texlive-latex-needspace - texlive-oberdiek - texlive-latex-parskip - texlive-latex-preview - texlive-latex-tabulary - texlive-latex-threeparttable - texlive-latex-titlesec - texlive-latex-trimspaces - texlive-latex-ucs - texlive-latex-upquote - texlive-url - texlive-latex-varwidth - texlive-wrapfig))) - ("texinfo" ,texinfo) - ("perl" ,perl) - ("scipy-sphinx-theme" - ,(let ((commit "c466764e2231ba132c09826b5b138fffa1cfcec3")) - (origin ;the build script expects scipy-sphinx-theme as a git submodule - (method git-fetch) - (uri (git-reference - (url "https://github.com/scipy/scipy-sphinx-theme") - (commit commit))) - (file-name (git-file-name "python-scipy-sphinx-theme" - (string-take commit 7))) - (sha256 - (base32 - "0q2y87clwlsgc7wvlsn9pzyssybcq10plwhq2w1ydykfsyyqbmkl"))))) - ,@(package-native-inputs python-numpy))) - (arguments - `(#:tests? #f ; we're only generating the documentation - #:phases - (modify-phases %standard-phases - (delete 'build) - (replace 'install - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((data (string-append (assoc-ref outputs "out") "/share")) - (doc (string-append - data "/doc/" ,name "-" - ,(package-version python-numpy))) - (info-reader (string-append data "/info")) - (html (string-append doc "/html")) - (scipy-sphinx-theme "scipy-sphinx-theme") - (sphinx-theme-checkout (assoc-ref inputs scipy-sphinx-theme)) - (pyver ,(string-append "PYVER="))) - - ;; FIXME: this is needed to for texlive-updmap.cfg to generate - ;; fonts, which are not found. - (setenv "HOME" "/tmp") - - (with-directory-excursion "doc" - (copy-recursively sphinx-theme-checkout scipy-sphinx-theme) - (mkdir-p html) - (invoke "make" "html" pyver) - (invoke "make" "latex" "PAPER=a4" pyver) - (invoke "make" "-C" "build/latex" - "all-pdf" "PAPER=a4" pyver) - ;; FIXME: Generation of the info file fails. - ;; (invoke "make" "info" pyver) - ;; (mkdir-p info) - ;; (copy-file "build/texinfo/numpy.info" - ;; (string-append info "/numpy.info")) - (for-each (lambda (file) - (copy-file (string-append "build/latex" file) - (string-append doc file))) - '("/numpy-ref.pdf" "/numpy-user.pdf")) - (with-directory-excursion "build/html" - (for-each (lambda (file) - (let* ((dir (dirname file)) - (tgt-dir (string-append html "/" dir))) - (unless (equal? "." dir) - (mkdir-p tgt-dir)) - (install-file file html))) - (find-files "." ".*"))))) - #t))))) - (home-page (package-home-page python-numpy)) - (synopsis "Documentation for the python-numpy package") - (description (package-description python-numpy)) - (license (package-license python-numpy)))) - (define-public python-pygit2 (package (name "python-pygit2") -- cgit v1.2.3 From dfe81d0f812e012cb0cb7d6c89f8aea03b733038 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 22 Apr 2022 21:41:39 -0400 Subject: gnu: Add python-ipdb. * gnu/packages/python-xyz.scm (python-ipdb): New variable. --- gnu/packages/python-xyz.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 1140e29790..e99587cf67 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -6278,6 +6278,32 @@ to the interactive prompt. It is an extension of the @code{rlcompleter} module from the standard Python library.") (license license:bsd-3))) +(define-public python-ipdb + (package + (name "python-ipdb") + (version "0.13.9") + (source + (origin + (method url-fetch) + (uri (pypi-uri "ipdb" version)) + (sha256 + (base32 "1ibql99agjf2gj7y0svzd5m0h81hailf4p3sj3yl9i1i8ykdj6wm")))) + (build-system python-build-system) + (arguments + (list #:phases #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "-m" "unittest" "discover"))))))) + (propagated-inputs (list python-ipython python-toml python-decorator)) + (home-page "https://github.com/gotcha/ipdb") + (synopsis "IPython-enhanced Python debugger (pdb)") + (description "@code{ipdb} exports functions to access the IPython +debugger, which features tab completion, syntax highlighting, better +tracebacks and better introspection than Python's standard @command{pdb} +debugger, with which it shares the same interface.") + (license license:bsd-3))) + (define-public python-pdbpp (package (name "python-pdbpp") -- cgit v1.2.3 From 09fccde9c04769ecf01bc5c6a22aadc9704369e5 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 22 Apr 2022 21:55:47 -0400 Subject: gnu: python-pudb: Update to 2022.1.1 and rename from pudb. Renaming rationale: pudb can also be used as a Python library (like pdb). * gnu/packages/python-xyz.scm (python-pudb): Update to 2022.1.1. [phases]{check}: Remove obsolete 'add-installed-pythonpath' call. Invoke pytest verbosely. [native-inputs]: Remove python-numpy. [propagated-inputs]: Apply guix style. (pudb): Define as a deprecated alias to python-pudb. --- gnu/packages/python-xyz.scm | 46 ++++++++++++++++++++++----------------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index e99587cf67..771b00e047 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -30228,32 +30228,29 @@ development, testing, production]}; @end itemize") (license license:expat))) -(define-public pudb +(define-public python-pudb (package - (name "pudb") - (version "2021.2") - (source - (origin - (method url-fetch) - (uri (pypi-uri "pudb" version)) - (sha256 - (base32 "0p16pvzfa3w02ybg3n0iy5rs23z4rz4a42lb8wh3mcq62y9ik2w7")))) + (name "python-pudb") + (version "2022.1.1") + (source (origin + (method url-fetch) + (uri (pypi-uri "pudb" version)) + (sha256 + (base32 + "0gq82hwnibby9qdyv7ri11phvg94nby4jb0w9h3jk79w89kdsfyv")))) (build-system python-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (add-before 'check 'fix-read-only-home - (lambda _ - (setenv "HOME" "/tmp"))) - (replace 'check - (lambda* (#:key inputs outputs tests? #:allow-other-keys) - (when tests? - (add-installed-pythonpath inputs outputs) - (invoke "pytest"))))))) - (native-inputs - (list python-numpy python-pytest python-pytest-mock)) - (propagated-inputs - (list python-jedi python-pygments python-urwid python-urwid-readline)) + `(#:phases (modify-phases %standard-phases + (add-before 'check 'fix-read-only-home + (lambda _ + (setenv "HOME" "/tmp"))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv"))))))) + (native-inputs (list python-pytest python-pytest-mock)) + (propagated-inputs (list python-jedi python-pygments python-urwid + python-urwid-readline)) (home-page "https://documen.tician.de/pudb/") (synopsis "Console-based Python debugger") (description @@ -30262,6 +30259,9 @@ all the niceties of modern GUI-based debuggers in a more lightweight and keyboard-friendly package.") (license license:expat))) +(define-public pudb + (deprecated-package "pudb" python-pudb)) + (define-public python-iwlib (package (name "python-iwlib") -- cgit v1.2.3 From 9fd911eb9b6e55e5586314605f0074f95f190466 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sat, 23 Apr 2022 01:14:22 -0400 Subject: gnu: Add python-mpl-sphinx-theme. * gnu/packages/sphinx.scm (python-mpl-sphinx-theme): New variable. --- gnu/packages/sphinx.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index ae0080b308..93f174217a 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -748,6 +748,23 @@ Sphinx documentation system, used by @uref{http://docs.guzzlephp.org, Guzzle} and several other projects.") (license license:expat))) +(define-public python-mpl-sphinx-theme + (package + (name "python-mpl-sphinx-theme") + (version "3.5.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "mpl_sphinx_theme" version)) + (sha256 + (base32 "0ilsw6s5hfvjzqs3258c8gmg5v3dwa6k69mwmkxsyh1qmv15krpw")))) + (build-system python-build-system) + (propagated-inputs (list python-pydata-sphinx-theme)) + (home-page "https://github.com/matplotlib/mpl-sphinx-theme") + (synopsis "Matplotlib theme for Sphinx") + (description "This package provides a Matplotlib theme for Sphinx.") + (license license:bsd-3))) + (define-public python-sphinx-rtd-theme (package (name "python-sphinx-rtd-theme") -- cgit v1.2.3 From b3a77978c91e04c8486ceb85e11315de721da8a8 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 24 Apr 2022 00:30:19 -0400 Subject: gnu: Add texlive-underscore. * gnu/packages/tex.scm (texlive-underscore): New variable. --- gnu/packages/tex.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 9f8fdbafdc..818316a4e5 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -664,6 +664,26 @@ executables. It is maintained as a part of TeX Live."))) documentation from TeX files. It is part of the LaTeX base.") (license license:lppl1.3+))) +(define-public texlive-underscore + (package + (inherit (simple-texlive-package + "texlive-underscore" + (list "/doc/latex/underscore/" + "/tex/latex/underscore/") + (base32 + "0slxsxc9azmv3gsm55jkhkv8a06wafankp55hhsdd6k4prp8szrb") + #:trivial? #t)) + (home-page "https://www.ctan.org/pkg/underscore") + (synopsis "Control the behaviour of @samp{_} in text") + (description "This package causes @code{\\_} in text mode (i.e., +@code{\\textunderscore}) to print an underscore so that hyphenation of words +either side of it is not affected; a package option controls whether an actual +hyphenation point appears after the underscore, or merely a break point. The +package also arranges that, while in text, @samp{_} itself behaves as +@code{\\textunderscore} (the behaviour of @samp{_} in maths mode is not +affected).") + (license license:lppl1.2+))) + (define-public texlive-unicode-data (package (inherit (simple-texlive-package -- cgit v1.2.3 From 44256e57cc0bf83ff86bf54722c4757852aadd9d Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sat, 23 Apr 2022 23:48:31 -0400 Subject: gnu: python-matplotlib-documentation: Fix build. * gnu/packages/python-xyz.scm (python-matplotlib-documentation): Inherit from python-matplotlib. [version, source, build-system, home-page, description, license]: Delete fields, now inherited. [phases]: Streamline build and install phases and enable parallel build. [native-inputs]: Use new style. Remove python-matplotlib, python-ipykernel, python-mock, texlive-enumitem, texlive-latex-geometry, texlive-latex-preview, texlive-latex-ucs, texlive-pdftex, texlive-fonts-ec, texlive-txfonts and inherited python-matplotlib packages. Add inkscape, python-mpl-sphinx-theme, python-scipy, python-ipywidgets, texlive-babel, texlive-fontspec, texlive-unicode-math, texlive-etoolbox, and texlive-underscore. --- gnu/packages/python-xyz.scm | 138 +++++++++++++++++++------------------------- 1 file changed, 58 insertions(+), 80 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 771b00e047..12ee339a80 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -6800,87 +6800,65 @@ toolkits.") (define-public python-matplotlib-documentation (package + (inherit python-matplotlib) (name "python-matplotlib-documentation") - (version (package-version python-matplotlib)) - (source (package-source python-matplotlib)) - (build-system python-build-system) - (native-inputs - `(("python-matplotlib" ,python-matplotlib) - ("python-colorspacious" ,python-colorspacious) - ("python-sphinx" ,python-sphinx) - ("python-sphinx-copybutton" ,python-sphinx-copybutton) - ("python-sphinx-gallery" ,python-sphinx-gallery) - ("python-numpydoc" ,python-numpydoc) - ("python-ipython" ,python-ipython) - ("python-ipykernel" ,python-ipykernel) - ("python-mock" ,python-mock) - ("graphviz" ,graphviz) - ("texlive" ,(texlive-updmap.cfg (list texlive-amsfonts - texlive-enumitem - texlive-latex-amsmath - texlive-latex-expdlist - texlive-latex-geometry - texlive-latex-preview - texlive-latex-type1cm - texlive-latex-ucs - - texlive-pdftex - - texlive-fonts-ec - texlive-times - texlive-txfonts))) - ("texinfo" ,texinfo) - ,@(package-native-inputs python-matplotlib))) - (arguments - `(#:tests? #f ; we're only generating documentation - #:phases - (modify-phases %standard-phases - ;; The tests in python-matplotlib are run after the install phase, so - ;; we need to delete the extra phase here. - (delete 'check) - (replace 'build - (lambda _ - (chdir "doc") - (setenv "PYTHONPATH" "../examples/units") - (substitute* "conf.py" - ;; Don't use git. - (("^SHA = check_output.*") - (string-append "SHA = \"" ,version "\"\n")) - ;; Don't fetch intersphinx files from the Internet - (("^explicit_order_folders" m) - (string-append "intersphinx_mapping = {}\n" m)) - (("'sphinx.ext.intersphinx',") "") - ;; Disable URL embedding which requires internet access. - (("'https://docs.scipy.org/doc/numpy'") "None") - (("'https://docs.scipy.org/doc/scipy/reference'") "None")) - (invoke "make" - "SPHINXBUILD=sphinx-build" - "SPHINXOPTS=" ; don't abort on warnings - "html" "texinfo"))) - (replace 'install - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((data (string-append (assoc-ref outputs "out") "/share")) - (doc (string-append data "/doc/python-matplotlib-" ,version)) - (info (string-append data "/info")) - (html (string-append doc "/html"))) - (mkdir-p html) - (mkdir-p info) - (copy-recursively "build/html" html) - (symlink (string-append html "/_images") - (string-append info "/matplotlib-figures")) - (with-directory-excursion "build/texinfo" - (substitute* "matplotlib.texi" - (("@image\\{([^,]*)" all file) - (string-append "@image{matplotlib-figures/" file))) - (symlink (string-append html "/_images") - "./matplotlib-figures") - (invoke "makeinfo" "--no-split" - "-o" "matplotlib.info" "matplotlib.texi")) - (install-file "build/texinfo/matplotlib.info" info))))))) - (home-page (package-home-page python-matplotlib)) - (synopsis "Documentation for the python-matplotlib package") - (description (package-description python-matplotlib)) - (license (package-license python-matplotlib)))) + (arguments + (list + #:tests? #f ;we're only generating documentation + #:phases + #~(modify-phases %standard-phases + (replace 'build + (lambda _ + (setenv "HOME" "/tmp") + (chdir "doc") + (substitute* "conf.py" + ;; The sphinx_panels extension causes a "TypeError: first + ;; argument must be callable" to be raised when generating the + ;; info target; remove it (see: + ;; https://github.com/executablebooks/sphinx-panels/issues/74). + ((".*'sphinx_panels',.*") "")) + (invoke "make" "html" "info" + ;; Don't abort on warnings; build in parallel. + (format #f "SPHINXOPTS=-j~a" (parallel-job-count))))) + (replace 'install + (lambda _ + (let* ((data (string-append #$output "/share")) + (doc (string-append data "/doc/matplotlib")) + (info (string-append data "/info")) + (html (string-append doc "/html"))) + (mkdir-p html) + (copy-recursively "build/html" html) + (install-file "build/texinfo/matplotlib.info" info) + ;; The "matplotlib-figures" directory contains are a subset of + ;; the images produced for the html target; simply create a + ;; symlink to it, saving about 11 MiB. + (symlink (string-append html "/_images") + (string-append info "/matplotlib-figures")))))))) + (native-inputs + (list graphviz + inkscape + python-colorspacious + python-mpl-sphinx-theme + python-scipy + python-sphinx + python-sphinx-copybutton + python-sphinx-gallery + python-sphinxcontrib-svg2pdfconverter + python-numpydoc + python-ipython + python-ipywidgets + texlive-amsfonts + texlive-amsmath + texlive-babel + texlive-fontspec + texlive-unicode-math + texlive-etoolbox + texlive-latex-expdlist + texlive-underscore + texlive-latex-type1cm + texlive-times + texinfo)) + (synopsis "Documentation for the @code{python-matplotlib} package"))) (define-public python-matplotlib-inline (package -- cgit v1.2.3 From e3bb211c23cdd09a2f088baad2e68a4c7bbc2b82 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Mon, 25 Apr 2022 11:36:20 +0200 Subject: gnu: python-qtpy: Update to 2.0.1. * gnu/packages/qt.scm (python-qtpy): Update to 2.0.1. [propagated-inputs]: Remove python-pyside-2, add python-packaging. Signed-off-by: Maxim Cournoyer --- gnu/packages/qt.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 0163d02bc0..bf2a3e88c2 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -2269,17 +2269,16 @@ top of the PyQt bindings for Qt. PyQt-builder is used to build PyQt itself.") (define-public python-qtpy (package (name "python-qtpy") - (version "1.9.0") + (version "2.0.1") (source (origin (method url-fetch) (uri (pypi-uri "QtPy" version)) (sha256 (base32 - "13cw8l7zrhbdi03k1wl1pg9xdl4ahdfa7yz8gd0f23sxnm22rdrd")))) + "13zbhnl2rm30xafwrzfwdb4mjp7gk4s9h2xagbf83pnjzczhgzdd")))) (build-system python-build-system) - (propagated-inputs - `(("python-pyside2" ,python-pyside-2))) + (propagated-inputs (list python-packaging)) (arguments `(;; Not all supported bindings are packaged. Especially PyQt4. #:tests? #f)) -- cgit v1.2.3 From dd50817dd661755c72e1a321e69e116c8044656e Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Mon, 25 Apr 2022 11:38:04 +0200 Subject: gnu: python-qtconsole: Update to 5.3.0. * gnu/packages/python-xyz.scm (python-qtconsole): Update to 5.3.0. [native-inputs]: Add python-pytest-qt. Signed-off-by: Maxim Cournoyer --- gnu/packages/python-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 12ee339a80..fd0f51120e 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -14011,13 +14011,13 @@ Jupyter kernels such as IJulia and IRKernel.") (define-public python-qtconsole (package (name "python-qtconsole") - (version "4.7.7") + (version "5.3.0") (source (origin (method url-fetch) (uri (pypi-uri "qtconsole" version)) (sha256 - (base32 "013qgpsm8jzcz3prhq7sxs36l8f7fgagmn3xa010gfhxf7cfldpj")))) + (base32 "09anp8g7vqi8z8wyi2lv21a2frd2dyhyrzvcrk2anijyqzyj0dcf")))) (build-system python-build-system) (arguments `(#:phases @@ -14034,7 +14034,7 @@ Jupyter kernels such as IJulia and IRKernel.") python-jupyter-core python-pygments python-pyqt python-pyzmq python-qtpy python-traitlets)) (native-inputs - (list python-flaky python-pytest)) + (list python-flaky python-pytest python-pytest-qt)) (home-page "https://jupyter.org") (synopsis "Jupyter Qt console") (description "This package provides a Qt-based console for Jupyter with -- cgit v1.2.3 From f2ab6b04a464f07389d9b8196379ab84118e258b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 5 May 2022 08:29:10 -0400 Subject: gnu: python-pygments: Update to 2.12.0. * gnu/packages/python-xyz.scm (python-pygments): Update to 2.12.0. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index fd0f51120e..69c16411d8 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -4661,14 +4661,14 @@ text styles of documentation.") (define-public python-pygments (package (name "python-pygments") - (version "2.8.1") + (version "2.12.0") (source (origin (method url-fetch) (uri (pypi-uri "Pygments" version)) (sha256 (base32 - "153zyxigm879sk2n71lfv03y2pgxb7dl0dlsbwkz9aydxnkf2mi6")))) + "1sr6iqh21xi6p8aba4wa9pqfhjbbpcvn9jcsx0ggy4lniw8idcay")))) (build-system python-build-system) (arguments ;; FIXME: Tests require sphinx, which depends on this. -- cgit v1.2.3 From 1fd6bcfba7442f7b4fa2f610a8a84be7c5274a3b Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 9 May 2022 22:57:54 -0400 Subject: gnu: python-matplotlib: Update to 3.5.2. * gnu/packages/python-xyz.scm (python-matplotlib): Update to 3.5.2. [propagated-inputs]: Move after 'arguments' field. Use new style and re-order. [inputs]: Order lexicographically. [native-inputs]: Use new style. [phases]{fix-and-disable-failing-tests}: Fix indentation. Delete the 'lib/matplotlib/tests/test_animation.py' test. {check}: Skip the test_lazy_auto_backend_selection test. --- gnu/packages/python-xyz.scm | 95 ++++++++++++++++++++++++--------------------- 1 file changed, 51 insertions(+), 44 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 69c16411d8..1fe9a969aa 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -6625,51 +6625,14 @@ comparison. (define-public python-matplotlib (package (name "python-matplotlib") - (version "3.5.1") + (version "3.5.2") (source (origin (method url-fetch) (uri (pypi-uri "matplotlib" version)) (sha256 - (base32 "076f8qi265x8jy89c03r3vv5h4is4ir5mawwrrrpp96314783sdj")))) - (build-system python-build-system) - (propagated-inputs ; the following packages are all needed at run time - `(("python-cycler" ,python-cycler) - ("python-fonttools" ,python-fonttools) - ("python-kiwisolver" ,python-kiwisolver) - ("python-packaging" ,python-packaging) - ("python-pyparsing" ,python-pyparsing) - ("python-pygobject" ,python-pygobject) - ("python-certifi" ,python-certifi) - ("gobject-introspection" ,gobject-introspection) - ("python-tkinter" ,python "tk") - ("python-dateutil" ,python-dateutil) - ("python-numpy" ,python-numpy) - ("python-pillow" ,python-pillow) - ("python-pytz" ,python-pytz) - ("python-six" ,python-six) - ("python-wxpython" ,python-wxpython) - ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of - ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context' - ;; object. For this reason we need to import both libraries. - ;; https://cairocffi.readthedocs.io/en/stable/cffi_api.html#converting-pycairo-wrappers-to-cairocffi - ("python-pycairo" ,python-pycairo) - ("python-cairocffi" ,python-cairocffi))) - (inputs - (list libpng - freetype - qhull - cairo - glib - tcl - tk)) - (native-inputs - `(("pkg-config" ,pkg-config) - ("python-pytest" ,python-pytest) - ("python-pytest-timeout" ,python-pytest-timeout) - ("python-pytest-xdist" ,python-pytest-xdist) - ("python-setuptools-scm" ,python-setuptools-scm) - ("python-setuptools-scm-git-archive" ,python-setuptools-scm-git-archive))) + (base32 "18h78s5ld1i6mz00w258hy29909nfr3ddq6ry9kq18agw468bks8")))) + (build-system python-build-system) (arguments (list #:phases @@ -6687,8 +6650,8 @@ comparison. (lambda _ (substitute* (append (find-files "lib/matplotlib/tests/" "test_.*\\.py$") - (find-files "lib/mpl_toolkits/tests" - "test_.*\\.py$")) + (find-files "lib/mpl_toolkits/tests" + "test_.*\\.py$")) (("^from matplotlib" match) (string-append "import pytest\n" match)) (("( *)@([^_]+_)*(image_comparison|check_figures_equal)" match @@ -6711,7 +6674,11 @@ reason=\"unknown minor image differences\")\n" match))) ;; different version of FreeType. "lib/matplotlib/tests/test_constrainedlayout.py" ;; Fontconfig returns no fonts. - "lib/matplotlib/tests/test_font_manager.py")))) + "lib/matplotlib/tests/test_font_manager.py" + ;; The images comparison test fails + ;; non-deterministically when run in parallel (see: + ;; https://github.com/matplotlib/matplotlib/issues/22992). + "lib/matplotlib/tests/test_compare_images.py")))) (add-before 'build 'configure-environment (lambda* (#:key inputs #:allow-other-keys) ;; Fix rounding errors when using the x87 FPU. @@ -6741,7 +6708,47 @@ tests = True~%" (assoc-ref inputs "tcl") (assoc-ref inputs "tk")))))) ;; everything gets built in the source directory. (invoke "pytest" "-n" (number->string (parallel-job-count)) - "-m" "not network" "--pyargs" "matplotlib")))))))) + "-m" "not network" "--pyargs" "matplotlib" + ;; The 'test_lazy_auto_backend_selection' fails + ;; because it would require an X server; skip it. + "-k" "not test_lazy_auto_backend_selection")))))))) + (propagated-inputs + (list gobject-introspection + python-cairocffi + python-certifi + python-cycler + python-dateutil + python-fonttools + python-kiwisolver + python-numpy + python-packaging + python-pillow + ;; ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context' + ;; ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of + ;; ;; https://cairocffi.readthedocs.io/en/stable/cffi_api.html#converting-pycairo-wrappers-to-cairocffi + ;; ;; object. For this reason we need to import both libraries. + ;; python-pycairo + python-pygobject + python-pyparsing + python-pytz + python-six + `(,python "tk") + python-wxpython)) + (inputs + (list cairo + freetype + glib + libpng + qhull + tcl + tk)) + (native-inputs + (list pkg-config + python-pytest + python-pytest-timeout + python-pytest-xdist + python-setuptools-scm + python-setuptools-scm-git-archive)) (home-page "https://matplotlib.org/") (synopsis "2D plotting library for Python") (description -- cgit v1.2.3 From ba4ed74f9e9f1365cf70b6784571a75885020cae Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Wed, 27 Apr 2022 09:44:34 +0200 Subject: gnu: python-pytest-sanic: Update to 1.9.1. * gnu/packages/python-check.scm (python-pytest-sanic): Update to 1.9.1. Signed-off-by: Maxim Cournoyer --- gnu/packages/python-check.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index a1601d6656..b86f75dc1b 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -1985,13 +1985,13 @@ help in debugging failures and optimizing the scheduler to improve speed.") (define-public python-pytest-sanic (package (name "python-pytest-sanic") - (version "1.7.0") + (version "1.9.1") (source (origin (method url-fetch) (uri (pypi-uri "pytest-sanic" version)) (sha256 (base32 - "0hm7im77dgqfk8k34qbbfhimg8hifl4zwpa2s3mgbknrjvyw5qpx")))) + "0shq1bqnydj0l3ipb73j1qh5kqcjvzkps30zk8grq3dwmh3wmnkr")))) (build-system python-build-system) (arguments ;; Tests depend on python-sanic. -- cgit v1.2.3 From 1a0c253b937bbb54f44f7d3c5e7d52a7eacb8a14 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 27 Apr 2022 09:45:48 +0200 Subject: gnu: python-multidict: Update to 5.2.0. * gnu/packages/python-xyz.scm (python-multidict): Update to 5.2.0. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 1fe9a969aa..fdfdd3fef3 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -7105,14 +7105,14 @@ Python code against some of the style conventions in (define-public python-multidict (package (name "python-multidict") - (version "4.7.5") + (version "5.2.0") (source (origin (method url-fetch) (uri (pypi-uri "multidict" version)) (sha256 (base32 - "07ikq2c72kd263hpldw55y0px2l3g34hjk66ml9lryh1jv287qmf")))) + "1kjrxav572j45xvr1iy60zb2g8zqvrinzdkl4ax36js4vczckl8d")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases -- cgit v1.2.3 From f6b001be16ab7f35bcdb2e5bfac5cbcb11e09ffb Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Wed, 27 Apr 2022 09:48:24 +0200 Subject: gnu: Add python-sanic-routing. * gnu/packages/python-web.scm (python-sanic-routing): New variable. Signed-off-by: Maxim Cournoyer --- gnu/packages/python-web.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 094ec10e4b..ff0f961849 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -6341,6 +6341,27 @@ parsing and rewriting of remote git URLs from various hosting providers.") as a Python package.") (license license:bsd-3))) +(define-public python-sanic-routing + (package + (name "python-sanic-routing") + (version "0.7.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "sanic-routing" version)) + (sha256 + (base32 "0k9paln0jd4sc2bklp977c82n29pk12wiv726siplkh57y5yi70k")))) + (build-system python-build-system) + (arguments + ;; PyPi sources does not contain tests, recursive dependency on + ;; python-sanic. + (list #:tests? #f)) + (home-page "https://github.com/sanic-org/sanic-routing/") + (synopsis "Routing component for Sanic") + (description "Internal package for @code{python-sanic}, which provides +the @code{BasicRouter}.") + (license license:expat))) + (define-public python-sanic (package (name "python-sanic") -- cgit v1.2.3 From 207065aa6e2eedbbded0f69743b25f61d9b0ca4a Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Wed, 27 Apr 2022 09:49:13 +0200 Subject: gnu: Add python-sanic-bootstrap. * gnu/packages/python-web.scm (python-sanic-bootstrap): New variable. Signed-off-by: Maxim Cournoyer --- gnu/packages/python-web.scm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index ff0f961849..574b7958cb 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -6424,6 +6424,13 @@ that's written to go fast. It allows the usage of the your code non-blocking and speedy.") (license license:expat))) +(define-public python-sanic-bootstrap + (package + (inherit python-sanic) + (name "python-sanic-bootstrap") + (arguments (list #:tests? #f)) + (native-inputs '()))) + (define-public python-socketio (package (name "python-socketio") -- cgit v1.2.3 From 7acd0122307016477293df878d775d0b79eaeb34 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Wed, 27 Apr 2022 09:50:22 +0200 Subject: gnu: Add python-sanic-testing. * gnu/packages/python-web.scm (python-sanic-testing): New variable. Signed-off-by: Maxim Cournoyer --- gnu/packages/python-web.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 574b7958cb..8b6d454780 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -6362,6 +6362,30 @@ as a Python package.") the @code{BasicRouter}.") (license license:expat))) +(define-public python-sanic-testing + (package + (name "python-sanic-testing") + (version "22.3.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "sanic-testing" version)) + (sha256 + (base32 "1vkgi9d3xyik507j4jy9s74mkl81hgx3c2d5y3aa1av9h6wjjivp")))) + (build-system python-build-system) + (arguments + ;; PyPi sources does not contain tests, recursive dependency on + ;; python-sanic. + (list #:tests? #f)) + (propagated-inputs (list python-httpx python-sanic-bootstrap + python-websockets)) + (home-page "https://github.com/sanic-org/sanic-testing/") + (synopsis "Test clients for Sanic") + (description "Internal package for @code{python-sanic}, which is +meant to be the core testing utility and clients for testing Sanic +applications.") + (license license:expat))) + (define-public python-sanic (package (name "python-sanic") -- cgit v1.2.3 From 93baba64753d4f8543b38a3a6092b7a71b79b246 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Wed, 27 Apr 2022 09:51:09 +0200 Subject: gnu: python-sanic: Update to 21.12.1. * gnu/packages/python-web.scm (python-sanic): Update to 21.12.1. [arguments]<#:phases>: Remove 'use-recent-pytest, update skipped tests in 'check. [propagated-inputs]: Remove python-httpx, replace python-multidict with python-multidict-5, add python-sanic-routing. [native-inputs]: Add python-bandit, python-chardet, python-isort and python-sanic-testing. Remove python-hstspreload, python-httpcore, python-pytest-cov and python-urllib3. Signed-off-by: Maxim Cournoyer --- gnu/packages/python-web.scm | 51 ++++++++++++++++++++++++--------------------- 1 file changed, 27 insertions(+), 24 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 8b6d454780..7636931091 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -86,6 +86,7 @@ #:use-module (gnu packages libevent) #:use-module (gnu packages libffi) #:use-module (gnu packages node) + #:use-module (gnu packages openstack) #:use-module (gnu packages pcre) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) @@ -6389,53 +6390,55 @@ applications.") (define-public python-sanic (package (name "python-sanic") - (version "20.12.4") + ;; We provide the latest LTS version of python-sanic. + (version "21.12.1") (source (origin (method url-fetch) (uri (pypi-uri "sanic" version)) (sha256 (base32 - "0axfc151s7nrykzypzciyvkxxrs5ayx8kxv4r620hjb9w3jjhfnp")))) + "0b8mcd1q9qkwcv2qz8nlyaacs0bp7a1l31sdq2m8hhkxykzfq5bg")))) (build-system python-build-system) (arguments - '(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'use-recent-pytest - ;; Allow using recent dependencies. - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "setup.py" - (("pytest==5.2.1") "pytest") - (("multidict>=5.0,<6.0") "multidict") - (("httpx==0\\.15\\.4") "httpx")) - #t)) - (replace 'check - (lambda* (#:key inputs outputs #:allow-other-keys) - (add-installed-pythonpath inputs outputs) - (invoke "pytest" "-vv" "./tests" "-k" - (string-append "not test_zero_downtime " - "and not test_gunicorn_worker " - "and not test_logo_"))))))) + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "./tests" "-k" + (string-append + ;; PyPi sources lack examples module. + "not test_gunicorn_" + ;; Does not expect brotli and reordered headers. + " and not test_raw_headers" + ;; These look like buggy testcases. + " and not test_zero_downtime" + " and not test_non_default_uvloop_config_raises_warning" + " and not test_listeners_triggered" + " and not test_keep_alive_connection_context" + " and not test_keep_alive_client_timeout")))))))) (propagated-inputs (list python-aiofiles python-httptools - python-httpx python-multidict + python-sanic-routing python-ujson python-uvloop python-websockets)) (native-inputs (list gunicorn + python-bandit python-beautifulsoup4 - python-hstspreload - python-httpcore + python-chardet + python-isort python-pytest - python-pytest-cov python-pytest-benchmark python-pytest-sanic python-pytest-sugar python-pytest-asyncio - python-urllib3 + python-sanic-testing python-uvicorn)) (home-page "https://github.com/sanic-org/sanic/") -- cgit v1.2.3 From 84f24711366b173c3d0aa427be64501809b1d060 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Thu, 12 May 2022 16:24:49 -0400 Subject: gnu: python-scikit-build: Fix build. * gnu/packages/python-xyz.scm (python-scikit-build) [phases]{check}: Add forgotten trailing spaces. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index fdfdd3fef3..020f078dee 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -28870,8 +28870,8 @@ and frame grabber interface.") ;; These are not parallel safe and fail ;; nondeterministically (see: ;; https://github.com/scikit-build/scikit-build/issues/711). - "and not test_generator_cleanup" - "and not test_generator_selection"))))) + "and not test_generator_cleanup " + "and not test_generator_selection "))))) (replace 'install (lambda _ (let ((whl (car (find-files "dist" "\\.whl$")))) -- cgit v1.2.3 From 7f7cc042083a759f9b136761f8f9f95ed87563ed Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Thu, 12 May 2022 14:38:18 +0200 Subject: gnu: ungoogled-chromium: Update to 101.0.4951.64-1. * gnu/packages/chromium.scm (%chromium-version): Set to 101.0.4951.64. (%ungoogled-origin, ungoogled-chromium): Update hashes. --- gnu/packages/chromium.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/chromium.scm b/gnu/packages/chromium.scm index 25a4ef9dc2..f9fbf6b700 100644 --- a/gnu/packages/chromium.scm +++ b/gnu/packages/chromium.scm @@ -313,7 +313,7 @@ ;; run the Blink performance tests, just remove everything to save ~70MiB. '("third_party/blink/perf_tests")) -(define %chromium-version "101.0.4951.54") +(define %chromium-version "101.0.4951.64") (define %ungoogled-revision (string-append %chromium-version "-1")) (define %debian-revision "debian/101.0.4951.41-2") @@ -325,7 +325,7 @@ (file-name (git-file-name "ungoogled-chromium" %ungoogled-revision)) (sha256 (base32 - "0zhzy7llqddvym992pwhkgqh2f6ywjqqg0bhahl6c0np95gzhpbs")))) + "0k7w6xvjf1yzyak9ywvcdw762d8zbx6d8haz35q87jz0mxfn2mr3")))) (define* (debian-patch name hash #:optional (revision %debian-revision)) (origin @@ -454,7 +454,7 @@ %chromium-version ".tar.xz")) (sha256 (base32 - "1d808a7mvg0nd0mm20c1ny5kdvb2xvrs8vz4nnk456ix8pywcv62")) + "1xyqm32y9v1hn8ji6qfw6maynqgg3266j58dq4x4aqsm2gj9cn4w")) (modules '((guix build utils))) (snippet (force ungoogled-chromium-snippet)))) (build-system gnu-build-system) -- cgit v1.2.3 From c99c3d11cdb05a2efc0950f0a50bfcb3fbbba2c7 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Tue, 10 May 2022 16:39:18 +0200 Subject: doc: Add "Writing Manifests" node. * doc/guix.texi (Invoking guix package): Remove explanation of 'specifications->manifest' and 'package->development-manifest'. Link to "Writing Manifests". (Inferiors): Likewise. (Invoking guix shell): Add anchor and link to 'package->development-manifest'. (Invoking guix pack): Likewise. (Writing Manifests): New section. (Using TeX and LaTeX): Link to "Writing Manifests". --- doc/guix.texi | 347 +++++++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 320 insertions(+), 27 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index c168a66072..30cd56fcf3 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -279,6 +279,7 @@ Programming Interface * Package Modules:: Packages from the programmer's viewpoint. * Defining Packages:: Defining new packages. * Defining Package Variants:: Customizing packages. +* Writing Manifests:: The bill of materials of your environment. * Build Systems:: Specifying how packages are built. * Build Phases:: Phases of the build process of a package. * Build Utilities:: Helpers for your package definitions and more. @@ -3378,7 +3379,6 @@ commands. The advantage is that @var{file} can be put under version control, copied to different machines to reproduce the same profile, and so on. -@c FIXME: Add reference to (guix profile) documentation when available. @var{file} must return a @dfn{manifest} object, which is roughly a list of packages: @@ -3393,30 +3393,7 @@ of packages: (list guile-2.0 "debug"))) @end lisp -@findex specifications->manifest -In this example we have to know which modules define the @code{emacs} -and @code{guile-2.0} variables to provide the right -@code{use-package-modules} line, which can be cumbersome. We can -instead provide regular package specifications and let -@code{specifications->manifest} look up the corresponding package -objects, like this: - -@lisp -(specifications->manifest - '("emacs" "guile@@2.2" "guile@@2.2:debug")) -@end lisp - -@findex package->development-manifest -You might also want to create a manifest for all the dependencies of a -package, rather than the package itself: - -@lisp -(package->development-manifest (specification->package "emacs")) -@end lisp - -The example above gives you all the software required to develop Emacs, -similar to what @command{guix environment emacs} provides. - +@xref{Writing Manifests}, for information on how to write a manifest. @xref{export-manifest, @option{--export-manifest}}, to learn how to obtain a manifest file from an existing profile. @@ -4711,7 +4688,7 @@ want to install in your profile the current @code{guile} package, along with the @code{guile-json} as it existed in an older revision of Guix---perhaps because the newer @code{guile-json} has an incompatible API and you want to run your code against the old API@. To do that, you could write a manifest for -use by @code{guix package --manifest} (@pxref{Invoking guix package}); in that +use by @code{guix package --manifest} (@pxref{Writing Manifests}); in that manifest, you would create an inferior for that old Guix revision you care about, and you would look up the @code{guile-json} package in the inferior: @@ -5783,6 +5760,7 @@ former is sourced only by log-in shells. @xref{Bash Startup Files,,, bash, The GNU Bash Reference Manual}, for details on Bash start-up files. +@anchor{shell-development-option} @item --development @itemx -D Cause @command{guix shell} to include in the environment the @@ -5824,6 +5802,10 @@ To select other outputs, two element tuples can be specified: guix shell -e '(list (@@ (gnu packages bash) bash) "include")' @end example +@xref{package-development-manifest, +@code{package->development-manifest}}, for information on how to write a +manifest for the development environment of a package. + @item --file=@var{file} @itemx -f @var{file} Create an environment containing the package or list of packages that @@ -5843,6 +5825,7 @@ running: guix shell -D -f gdb-devel.scm @end example +@anchor{shell-manifest} @item --manifest=@var{file} @itemx -m @var{file} Create an environment for the packages contained in the manifest object @@ -5853,6 +5836,7 @@ This is similar to the same-named option in @command{guix package} (@pxref{profile-manifest, @option{--manifest}}) and uses the same manifest files. +@xref{Writing Manifests}, for information on how to write a manifest. See @option{--export-manifest} below on how to obtain a first manifest. @cindex manifest, exporting @@ -6737,6 +6721,7 @@ This has the same purpose as the same-named option in @command{guix build} (@pxref{Additional Build Options, @option{--expression} in @command{guix build}}). +@anchor{pack-manifest} @item --manifest=@var{file} @itemx -m @var{file} Use the packages contained in the manifest object returned by the Scheme @@ -6751,6 +6736,7 @@ for use on machines that do not have Guix installed. Note that you can specify @emph{either} a manifest file @emph{or} a list of packages, but not both. +@xref{Writing Manifests}, for information on how to write a manifest. @xref{shell-export-manifest, @command{guix shell --export-manifest}}, for information on how to ``convert'' command-line options into a manifest. @@ -6957,6 +6943,7 @@ package definitions. * Package Modules:: Packages from the programmer's viewpoint. * Defining Packages:: Defining new packages. * Defining Package Variants:: Customizing packages. +* Writing Manifests:: The bill of materials of your environment. * Build Systems:: Specifying how packages are built. * Build Phases:: Phases of the build process of a package. * Build Utilities:: Helpers for your package definitions and more. @@ -7962,6 +7949,312 @@ when @var{cut?} returns true for a given package. When @var{deep?} is true, @va applied to implicit inputs as well. @end deffn +@node Writing Manifests +@section Writing Manifests + +@cindex manifest +@cindex bill of materials (manifests) +@command{guix} commands let you specify package lists on the command +line. This is convenient, but as the command line becomes longer and +less trivial, it quickly becomes more convenient to have that package +list in what we call a @dfn{manifest}. A manifest is some sort of a +``bill of materials'' that defines a package set. You would typically +come up with a code snippet that builds the manifest, store it in a +file, say @file{manifest.scm}, and then pass that file to the +@option{-m} (or @option{--manifest}) option that many @command{guix} +commands support. For example, here's what a manifest for a simple +package set might look like: + +@lisp +;; Manifest for three packages. +(specifications->manifest '("gcc-toolchain" "make" "git")) +@end lisp + +Once you have that manifest, you can pass it, for example, to +@command{guix package} to install just those three packages to your +profile (@pxref{profile-manifest, @option{-m} option of @command{guix +package}}): + +@example +guix package -m manifest.scm +@end example + +@noindent +... or you can pass it to @command{guix shell} (@pxref{shell-manifest, +@command{-m} option of @command{guix shell}}) to spawn an ephemeral +environment: + +@example +guix shell -m manifest.scm +@end example + +@noindent +... or you can pass it to @command{guix pack} in pretty much the same +way (@pxref{pack-manifest, @option{-m} option of @command{guix pack}}). +You can store the manifest under version control, share it with others +so they can easily get set up, etc. + +But how do you write your first manifest? To get started, maybe you'll +want to write a manifest that mirrors what you already have in a +profile. Rather than start from a blank page, @command{guix package} +can generate a manifest for you (@pxref{export-manifest, @command{guix +package --export-manifest}}): + +@example +# Write to 'manifest.scm' a manifest corresponding to the +# default profile, ~/.guix-profile. +guix package --export-manifest > manifest.scm +@end example + +Or maybe you'll want to ``translate'' command-line arguments into a +manifest. In that case, @command{guix shell} can help +(@pxref{shell-export-manifest, @command{guix shell --export-manifest}}): + +@example +# Write a manifest for the packages specified on the command line. +guix shell --export-manifest gcc-toolchain make git > manifest.scm +@end example + +In both cases, the @option{--export-manifest} option tries hard to +generate a faithful manifest; in particular, it takes package +transformation options into account (@pxref{Package Transformation +Options}). + +@quotation Note +Manifests are @emph{symbolic}: they refer to packages of the channels +@emph{currently in use} (@pxref{Channels}). In the example above, +@code{gcc-toolchain} might refer to version 11 today, but it might refer +to version 13 two years from now. + +If you want to ``pin'' your software environment to specific package +versions and variants, you need an additional piece of information: the +list of channel revisions in use, as returned by @command{guix +describe}. @xref{Replicating Guix}, for more information. +@end quotation + +Once you've obtained your first manifest, perhaps you'll want to +customize it. Since your manifest is code, you now have access to all +the Guix programming interfaces! + +Let's assume you want a manifest to deploy a custom variant of GDB, the +GNU Debugger, that does not depend on Guile, together with another +package. Building on the example seen in the previous section +(@pxref{Defining Package Variants}), you can write a manifest along +these lines: + +@lisp +(use-modules (guix packages) + (gnu packages gdb) ;for 'gdb' + (gnu packages version-control)) ;for 'git' + +;; Define a variant of GDB without a dependency on Guile. +(define gdb-sans-guile + (package + (inherit gdb) + (inputs (modify-inputs (package-inputs gdb) + (delete "guile"))))) + +;; Return a manifest containing that one package plus Git. +(packages->manifest (list gdb-sans-guile git)) +@end lisp + +Note that in this example, the manifest directly refers to the +@code{gdb} and @code{git} variables, which are bound to a @code{package} +object (@pxref{package Reference}), instead of calling +@code{specifications->manifest} to look up packages by name as we did +before. The @code{use-modules} form at the top lets us access the core +package interface (@pxref{Defining Packages}) and the modules that +define @code{gdb} and @code{git} (@pxref{Package Modules}). Seamlessly, +we're weaving all this together---the possibilities are endless, unleash +your creativity! + +The data type for manifests as well as supporting procedures are defined +in the @code{(guix profiles)} module, which is automatically available +to code passed to @option{-m}. The reference follows. + +@deftp {Data Type} manifest +Data type representing a manifest. + +It currently has one field: + +@table @code +@item entries +This must be a list of @code{manifest-entry} records---see below. +@end table +@end deftp + +@deftp {Data Type} manifest-entry +Data type representing a manifest entry. A manifest entry contains +essential metadata: a name and version string, the object (usually a +package) for that entry, the desired output (@pxref{Packages with +Multiple Outputs}), and a number of optional pieces of information +detailed below. + +Most of the time, you won't build a manifest entry directly; instead, +you will pass a package to @code{package->manifest-entry}, described +below. In some unusual cases though, you might want to create manifest +entries for things that are @emph{not} packages, as in this example: + +@lisp +;; Manually build a single manifest entry for a non-package object. +(let ((hello (program-file "hello" #~(display "Hi!")))) + (manifest-entry + (name "foo") + (version "42") + (item + (computed-file "hello-directory" + #~(let ((bin (string-append #$output "/bin"))) + (mkdir #$output) (mkdir bin) + (symlink #$hello + (string-append bin "/hello"))))))) +@end lisp + +The available fields are the following: + +@table @asis +@item @code{name} +@itemx @code{version} +Name and version string for this entry. + +@item @code{item} +A package or other file-like object (@pxref{G-Expressions, file-like +objects}). + +@item @code{output} (default: @code{"out"}) +Output of @code{item} to use, in case @code{item} has multiple outputs +(@pxref{Packages with Multiple Outputs}). + +@item @code{dependencies} (default: @code{'()}) +List of manifest entries this entry depends on. When building a +profile, dependencies are added to the profile. + +Typically, the propagated inputs of a package (@pxref{package Reference, +@code{propagated-inputs}}) end up having a corresponding manifest entry +in among the dependencies of the package's own manifest entry. + +@item @code{search-paths} (default: @code{'()}) +The list of search path specifications honored by this entry +(@pxref{Search Paths}). + +@item @code{properties} (default: @code{'()}) +List of symbol/value pairs. When building a profile, those properties +get serialized. + +This can be used to piggyback additional metadata---e.g., the +transformations applied to a package (@pxref{Package Transformation +Options}). + +@item @code{parent} (default: @code{(delay #f)}) +A promise pointing to the ``parent'' manifest entry. + +This is used as a hint to provide context when reporting an error +related to a manifest entry coming from a @code{dependencies} field. +@end table +@end deftp + +@deffn {Scheme Procedure} concatenate-manifests @var{lst} +Concatenate the manifests listed in @var{lst} and return the resulting +manifest. +@end deffn + +@c TODO: , manifest-lookup, manifest-remove, etc. + +@deffn {Scheme Procedure} package->manifest-entry @var{package} @ + [@var{output}] [#:properties] +Return a manifest entry for the @var{output} of package @var{package}, +where @var{output} defaults to @code{"out"}, and with the given +@var{properties}. By default @var{properties} is the empty list or, if +one or more package transformations were applied to @var{package}, it is +an association list representing those transformations, suitable as an +argument to @code{options->transformation} (@pxref{Defining Package +Variants, @code{options->transformation}}). + +The code snippet below builds a manifest with an entry for the default +output and the @code{send-email} output of the @code{git} package: + +@lisp +(use-modules (gnu packages version-control)) + +(manifest (list (package->manifest-entry git) + (package->manifest-entry git "send-email"))) +@end lisp +@end deffn + +@deffn {Scheme Procedure} packages->manifest @var{packages} +Return a list of manifest entries, one for each item listed in +@var{packages}. Elements of @var{packages} can be either package +objects or package/string tuples denoting a specific output of a +package. + +Using this procedure, the manifest above may be rewritten more +concisely: + +@lisp +(use-modules (gnu packages version-control)) + +(packages->manifest (list git `(,git "send-email"))) +@end lisp +@end deffn + +@anchor{package-development-manifest} +@deffn {Scheme Procedure} package->development-manifest @var{package} @ + [@var{system}] [#:target] +Return a manifest for the @dfn{development inputs} of @var{package} for +@var{system}, optionally when cross-compiling to @var{target}. +Development inputs include both explicit and implicit inputs of +@var{package}. + +Like the @option{-D} option of @command{guix shell} +(@pxref{shell-development-option, @command{guix shell -D}}), the +resulting manifest describes the environment in which one can develop +@var{package}. For example, suppose you're willing to set up a +development environment for Inkscape, with the addition of Git for +version control; you can describe that ``bill of materials'' with the +following manifest: + +@lisp +(use-modules (gnu packages inkscape) ;for 'inkscape' + (gnu packages version-control)) ;for 'git' + +(concatenate-manifests + (list (package->development-manifest inkscape) + (packages->manifest (list git)))) +@end lisp + +In this example, the development manifest that +@code{package->development-manifest} returns includes the compiler +(GCC), the many supporting libraries (Boost, GLib, GTK, etc.), and a +couple of additional development tools---these are the dependencies +@command{guix show inkscape} lists. +@end deffn + +@c TODO: Move (gnu packages) interface to a section of its own. + +Last, the @code{(gnu packages)} module provides higher-level facilities +to build manifests. In particular, it lets you look up packages by +name---see below. + +@deffn {Scheme Procedure} specifications->manifest @var{specs} +Given @var{specs}, a list of specifications such as @code{"emacs@@25.2"} +or @code{"guile:debug"}, return a manifest. Specs have the format that +command-line tools such as @command{guix install} and @command{guix +package} understand (@pxref{Invoking guix package}). + +As an example, it lets you rewrite the Git manifest that we saw earlier +like this: + +@lisp +(specifications->manifest '("git" "git:send-email")) +@end lisp + +Notice that we do not need to worry about @code{use-modules}, importing +the right set of modules, and referring to the right variables. +Instead, we directly refer to packages in the same way as on the command +line, which can often be more convenient. +@end deffn + +@c TODO: specifications->package, etc. + @node Build Systems @section Build Systems @@ -39388,7 +39681,7 @@ You can then pass it to any command with the @option{-m} option: guix shell -m manifest.scm -- pdflatex doc.tex @end example -@xref{Invoking guix package, @option{--manifest}}, for more on +@xref{Writing Manifests}, for more on manifests. In the future, we plan to provide packages for @TeX{} Live @dfn{collections}---``meta-packages'' such as @code{fontsrecommended}, @code{humanities}, or @code{langarabic} that provide the set of packages -- cgit v1.2.3 From c0e712931bd9aca5541f8c67eda39731e82c6dfe Mon Sep 17 00:00:00 2001 From: "Artyom V. Poptsov" Date: Tue, 10 May 2022 16:49:18 +0300 Subject: gnu: guile-ics: Update to 0.2.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/guile-xyz.scm (guile-ics): Update to 0.2.1. Signed-off-by: Ludovic Courtès --- gnu/packages/guile-xyz.scm | 29 ++++++++++------------------- 1 file changed, 10 insertions(+), 19 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index d177cb3aa2..0863174924 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -1772,7 +1772,7 @@ provides tight coupling to Guix.") (define-public guile-ics (package (name "guile-ics") - (version "0.2.0") + (version "0.2.1") (source (origin (method git-fetch) (uri (git-reference @@ -1781,26 +1781,17 @@ provides tight coupling to Guix.") (file-name (string-append name "-" version "-checkout")) (sha256 (base32 - "0qjjvadr7gibdq9jvwkmlkb4afsw9n2shfj9phpiadinxk3p4m2g")) - (modules '((guix build utils))) - (snippet - '(begin - ;; Allow builds with Guile 3.0. - (substitute* "configure.ac" - (("^GUILE_PKG.*") - "GUILE_PKG([3.0 2.2 2.0])\n")) - #t)))) + "11wv6qk8xd4sd8s97mnw383p098ffivk0na4jii76r5wbmg1wd7q")) + (modules '((guix build utils))))) (build-system gnu-build-system) - ;; XXX: Tests expect 'test-runner-current' to not return #f after - ;; 'test-end', which is no longer the case in Guile 3.0.7. - (arguments '(#:tests? #f)) (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("texinfo" ,texinfo) - ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'. - ("gettext" ,gettext-minimal) - ("pkg-config" ,pkg-config))) + (list autoconf + automake + texinfo + ;; Gettext brings 'AC_LIB_LINKFLAGS_FROM_LIBS'. + gettext-minimal + help2man + pkg-config)) (inputs (list guile-3.0 which)) (propagated-inputs (list guile-lib)) (home-page "https://github.com/artyom-poptsov/guile-ics") -- cgit v1.2.3 From 944f2c81ffbfa705c9738129797e524352c08279 Mon Sep 17 00:00:00 2001 From: "Wamm K. D" Date: Mon, 9 May 2022 21:47:35 -0500 Subject: gnu: artanis: Update to 0.5.1. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/guile-xyz.scm (artanis): Update to 0.5.1. [source]: Substitute "artanis/tpl/parser.scm". Signed-off-by: Ludovic Courtès --- gnu/packages/guile-xyz.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 0863174924..2794825d91 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -135,14 +135,14 @@ (define-public artanis (package (name "artanis") - (version "0.5") + (version "0.5.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/artanis/artanis-" version ".tar.gz")) (sha256 (base32 - "1vk1kp2xhz35xa5n27cxlq9c88wk6qm7fqaac8rb0pb6k9pvsv7v")) + "1zfg49s7wp37px7k22qcr06rxfwyn3gv1c3jmma346xw0m8jr63w")) (modules '((guix build utils))) (snippet '(begin @@ -153,7 +153,8 @@ (delete-file-recursively "artanis/third-party/redis") (substitute* '("artanis/artanis.scm" "artanis/lpc.scm" - "artanis/oht.scm") + "artanis/oht.scm" + "artanis/tpl/parser.scm") (("(#:use-module \\()artanis third-party (json\\))" _ use-module json) (string-append use-module json))) -- cgit v1.2.3 From b0246953e9cfce401f1eff6a204eaaa52dbaa197 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Fri, 13 May 2022 17:11:05 +0200 Subject: gnu: artanis: Remove input labels. * gnu/packages/guile-xyz.scm (artanis)[native-inputs]: Remove input labels. Use BASH-MINIMAL instead of BASH. --- gnu/packages/guile-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 2794825d91..f6488e74a5 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -183,9 +183,9 @@ (propagated-inputs (list guile-json-3 guile-readline guile-redis)) (native-inputs - `(("bash" ,bash) ;for the `source' builtin - ("pkgconfig" ,pkg-config) - ("util-linux" ,util-linux))) ;for the `script' command + (list bash-minimal ;for the `source' builtin + pkg-config + util-linux)) ;for the `script' command (arguments `(#:modules (((guix build guile-build-system) #:select (target-guile-effective-version)) -- cgit v1.2.3 From 2f812bfa38bd9cf595ce2496618feb84513b3353 Mon Sep 17 00:00:00 2001 From: ykonai Date: Sun, 8 May 2022 12:40:40 +0200 Subject: gnu: pipe-viewer: Update to 0.2.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/video.scm (pipe-viewer): Update to 0.2.0 Signed-off-by: Ludovic Courtès --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index e42a696ddd..78d6b26c99 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -1077,7 +1077,7 @@ H.264 (MPEG-4 AVC) video streams.") (define-public pipe-viewer (package (name "pipe-viewer") - (version "0.1.7") + (version "0.2.0") (source (origin (method git-fetch) @@ -1087,7 +1087,7 @@ H.264 (MPEG-4 AVC) video streams.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1fh8b77vchpsar88dszsz5h1gzd4jz0v902igp2880vnpvacmfi9")))) + (base32 "19qfs0nv7l01468f14a5zbvaiff5hrsk3a4zqknh15014xnvw08s")))) (build-system perl-build-system) (arguments `(#:imported-modules -- cgit v1.2.3 From 89a2eb25c3e9809eb58ce48d4f36bf06bad338dc Mon Sep 17 00:00:00 2001 From: Maxime Devos Date: Sat, 7 May 2022 08:37:31 +0000 Subject: search-paths: Define $SSL_CERT_DIR and $SSL_CERT_FILE. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit For the ‘why’, see the docstring next to $SSL_CERT_DIR. In later commits, packages will be changed to use these variables and the variables will be added to more packages. * guix/search-paths.scm ($SSL_CERT_DIR, $SSL_CERT_FILE): New variables. * doc/guix.texi (Search Paths): Document them. Signed-off-by: Ludovic Courtès --- doc/guix.texi | 21 ++++++++++++++++++++- guix/search-paths.scm | 26 ++++++++++++++++++++++++++ 2 files changed, 46 insertions(+), 1 deletion(-) diff --git a/doc/guix.texi b/doc/guix.texi index 30cd56fcf3..e1fb50a634 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -88,7 +88,7 @@ Copyright @copyright{} 2020 Daniel Brooks@* Copyright @copyright{} 2020 John Soo@* Copyright @copyright{} 2020 Jonathan Brielmaier@* Copyright @copyright{} 2020 Edgar Vincent@* -Copyright @copyright{} 2021 Maxime Devos@* +Copyright @copyright{} 2021, 2022 Maxime Devos@* Copyright @copyright{} 2021 B. Wilson@* Copyright @copyright{} 2021 Xinglu Chen@* Copyright @copyright{} 2021 Raghav Gururajan@* @@ -10127,6 +10127,25 @@ Again, the libxml2 example shows a situation where this is needed. @end table @end deftp +Some search paths are not tied by a single package but to many packages. +To reduce duplications, some of them are pre-defined in @code{(guix +search-paths)}. + +@defvr {Scheme Variable} $SSL_CERT_DIR +@defvrx {Scheme Variable} $SSL_CERT_FILE +These two search paths indicate where X.509 certificates can be found +(@pxref{X.509 Certificates}). +@end defvr + +These pre-defined search paths can be used as in the following example: + +@lisp +(package + (name "curl") + ;; some fields omitted ... + (native-search-paths (list $SSL_CERT_DIR $SSL_CERT_FILE))) +@end lisp + How do you turn search path specifications on one hand and a bunch of directories on the other hand in a set of environment variable definitions? That's the job of @code{evaluate-search-paths}. diff --git a/guix/search-paths.scm b/guix/search-paths.scm index 002e6342bb..6b13a98946 100644 --- a/guix/search-paths.scm +++ b/guix/search-paths.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013, 2014, 2015, 2017, 2018 Ludovic Courtès +;;; Copyright © 2022 Maxime Devos ;;; ;;; This file is part of GNU Guix. ;;; @@ -32,6 +33,8 @@ search-path-specification-file-pattern $PATH + $SSL_CERT_DIR + $SSL_CERT_FILE search-path-specification->sexp sexp->search-path-specification @@ -70,6 +73,29 @@ (variable "PATH") (files '("bin" "sbin")))) +;; Two variables for certificates (see (guix)X.509 Certificates), +;; respected by 'openssl', possibly GnuTLS in the future +;; (https://gitlab.com/gnutls/gnutls/-/merge_requests/1541) +;; and many of their dependents -- even some GnuTLS depepdents +;; like Guile. As they are not tied to a single package, define +;; them here to avoid duplication. +;; +;; Additionally, the 'native-search-paths' field is not thunked, +;; so doing (package-native-search-paths openssl) +;; could cause import cycle issues. +(define-public $SSL_CERT_DIR + (search-path-specification + (variable "SSL_CERT_DIR") + (separator #f) ;single entry + (files '("etc/ssl/certs")))) + +(define-public $SSL_CERT_FILE + (search-path-specification + (variable "SSL_CERT_FILE") + (file-type 'regular) + (separator #f) ;single entry + (files '("etc/ssl/certs/ca-certificates.crt")))) + (define (search-path-specification->sexp spec) "Return an sexp representing SPEC, a . The sexp corresponds to the arguments expected by `set-path-environment-variable'." -- cgit v1.2.3 From 2200530bf6850c381f455b3b0d349a9afb2aa2e9 Mon Sep 17 00:00:00 2001 From: Maxime Devos Date: Sat, 7 May 2022 08:37:32 +0000 Subject: gnu: openssl: Use $SSL_CERT_DIR/$SSL_CERT_FILE. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/tls.scm (openssl)[native-search-paths]: Use the $SSL_CERT_DIR/$SSL_CERT_FILE from (guix search-paths) instead of a local copy. Signed-off-by: Ludovic Courtès --- gnu/packages/tls.scm | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm index 84ed0caa5d..e413f3c24f 100644 --- a/gnu/packages/tls.scm +++ b/gnu/packages/tls.scm @@ -51,6 +51,7 @@ #:use-module (guix build-system python) #:use-module (guix build-system cmake) #:use-module (guix build-system trivial) + #:use-module ((guix search-paths) #:select ($SSL_CERT_DIR $SSL_CERT_FILE)) #:use-module (gnu packages compression) #:use-module (gnu packages) #:use-module (gnu packages autotools) @@ -495,15 +496,7 @@ OpenSSL for TARGET." #$(package-version this-package) "/misc"))))))) (native-search-paths - (list (search-path-specification - (variable "SSL_CERT_DIR") - (separator #f) ;single entry - (files '("etc/ssl/certs"))) - (search-path-specification - (variable "SSL_CERT_FILE") - (file-type 'regular) - (separator #f) ;single entry - (files '("etc/ssl/certs/ca-certificates.crt"))))) + (list $SSL_CERT_DIR $SSL_CERT_FILE)) (synopsis "SSL/TLS implementation") (description "OpenSSL is an implementation of SSL/TLS.") -- cgit v1.2.3 From 39420f27eee3a0aa18f8129b7db956a9196bf048 Mon Sep 17 00:00:00 2001 From: Maxime Devos Date: Sat, 7 May 2022 08:37:33 +0000 Subject: gnu: cuirass: Use $SSL_CERT_DIR. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/ci.scm (cuirass)[native-search-paths]: Use the $SSL_CERT_DIR from (guix search-paths) instead of a local copy. Signed-off-by: Ludovic Courtès --- gnu/packages/ci.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gnu/packages/ci.scm b/gnu/packages/ci.scm index a2dce71d40..ab421fe870 100644 --- a/gnu/packages/ci.scm +++ b/gnu/packages/ci.scm @@ -28,6 +28,7 @@ #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix download) + #:use-module ((guix search-paths) #:select ($SSL_CERT_DIR)) #:use-module (gnu packages autotools) #:use-module (gnu packages base) #:use-module (gnu packages boost) @@ -52,7 +53,8 @@ #:use-module (gnu packages web) #:use-module (gnu packages xml) #:use-module (guix build-system cmake) - #:use-module (guix build-system gnu)) + #:use-module (guix build-system gnu) + #:use-module ((guix search-paths) #:select ($SSL_CERT_DIR))) (define-public cuirass (let ((commit "9f08035f942a1e78f92e2db886d7837b0ab98b2f") @@ -173,9 +175,7 @@ (file-type 'regular) (separator #f) ;single entry (files '("etc/ssl/certs/ca-certificates.crt"))) - (search-path-specification - (variable "SSL_CERT_DIR") - (files '("etc/ssl/certs"))))) + $SSL_CERT_DIR)) (synopsis "Continuous integration system") (description "Cuirass is a continuous integration tool using GNU Guix. It is -- cgit v1.2.3 From 579270c6bf1ec5662efc1e166f3a430b59edf3c9 Mon Sep 17 00:00:00 2001 From: Maxime Devos Date: Sat, 7 May 2022 08:37:34 +0000 Subject: gnu: cmake-bootstrap: Use $SSL_CERT_DIR/$SSL_CERT_FILE. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/cmake.scm (cmake-bootstrap)[native-search-paths]: Use the $SSL_CERT_DIR/$SSL_CERT_FILE from (guix search-paths) instead of a local copy. Signed-off-by: Ludovic Courtès --- gnu/packages/cmake.scm | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/gnu/packages/cmake.scm b/gnu/packages/cmake.scm index 4207f14310..cf930c57fc 100644 --- a/gnu/packages/cmake.scm +++ b/gnu/packages/cmake.scm @@ -38,6 +38,7 @@ #:use-module (guix build-system gnu) #:use-module (guix build-system cmake) #:use-module (guix build-system emacs) + #:use-module ((guix search-paths) #:select ($SSL_CERT_DIR $SSL_CERT_FILE)) #:use-module (gnu packages) #:use-module (gnu packages backup) #:use-module (gnu packages compression) @@ -229,15 +230,8 @@ using the CMake build system.") (files '(""))) ;; "cmake-curl-certificates.patch" changes CMake to honor 'SSL_CERT_DIR' ;; and 'SSL_CERT_FILE', hence these search path entries. - (search-path-specification - (variable "SSL_CERT_DIR") - (separator #f) ;single entry - (files '("etc/ssl/certs"))) - (search-path-specification - (variable "SSL_CERT_FILE") - (file-type 'regular) - (separator #f) ;single entry - (files '("etc/ssl/certs/ca-certificates.crt"))))) + $SSL_CERT_DIR + $SSL_CERT_FILE)) (home-page "https://cmake.org/") (synopsis "Cross-platform build system") (description -- cgit v1.2.3 From eebcfc65d89419d046f6f0789cf3c79676cecec5 Mon Sep 17 00:00:00 2001 From: Maxime Devos Date: Sat, 7 May 2022 08:37:35 +0000 Subject: gnu: curl: Use $SSL_CERT_DIR/$SSL_CERT_FILE. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/curl.scm (curl)[native-search-paths]: Use the $SSL_CERT_DIR/$SSL_CERT_FILE from (guix search-paths) instead of a local copy. Signed-off-by: Ludovic Courtès --- gnu/packages/curl.scm | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/gnu/packages/curl.scm b/gnu/packages/curl.scm index a83ecbaa09..7fa0261147 100644 --- a/gnu/packages/curl.scm +++ b/gnu/packages/curl.scm @@ -41,6 +41,7 @@ #:use-module (guix build-system gnu) #:use-module (guix build-system go) #:use-module (guix build-system meson) + #:use-module ((guix search-paths) #:select ($SSL_CERT_DIR $SSL_CERT_FILE)) #:use-module (gnu packages) #:use-module (gnu packages check) #:use-module (gnu packages compression) @@ -82,15 +83,8 @@ ("python" ,python-minimal-wrapper))) (native-search-paths ;; These variables are introduced by curl-use-ssl-cert-env.patch. - (list (search-path-specification - (variable "SSL_CERT_DIR") - (separator #f) ;single entry - (files '("etc/ssl/certs"))) - (search-path-specification - (variable "SSL_CERT_FILE") - (file-type 'regular) - (separator #f) ;single entry - (files '("etc/ssl/certs/ca-certificates.crt"))) + (list $SSL_CERT_DIR + $SSL_CERT_FILE ;; Note: This search path is respected by the `curl` command-line ;; tool only. Patching libcurl to read it too would bring no ;; advantages and require maintaining a more complex patch. -- cgit v1.2.3 From d4a0dcb7379e92d1adc8e846eb5ca5c513389763 Mon Sep 17 00:00:00 2001 From: Maxime Devos Date: Sat, 7 May 2022 08:37:36 +0000 Subject: gnu: guix: Use $SSL_CERT_DIR. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/package-management.scm (guix)[native-search-paths]: Use the $SSL_CERT_DIR from (guix search-paths) instead of a local copy. Signed-off-by: Ludovic Courtès --- gnu/packages/package-management.scm | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 10b0e010de..908efee821 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -121,6 +121,7 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix utils) + #:use-module ((guix search-paths) #:select ($SSL_CERT_DIR $SSL_CERT_FILE)) #:use-module (ice-9 match) #:use-module (srfi srfi-1)) @@ -473,14 +474,9 @@ $(prefix)/etc/openrc\n"))) (list (search-path-specification (variable "GUIX_EXTENSIONS_PATH") (files '("share/guix/extensions"))) - ;; (guix git) and (guix build download) honor this variable whose ;; name comes from OpenSSL. - (search-path-specification - (variable "SSL_CERT_DIR") - (separator #f) ;single entry - (files '("etc/ssl/certs"))))) - + $SSL_CERT_DIR)) (home-page "https://www.gnu.org/software/guix/") (synopsis "Functional package manager for installed software packages and versions") (description -- cgit v1.2.3 From 0932e97637c785010bc69411a261655a2f38ba72 Mon Sep 17 00:00:00 2001 From: Greg Hogan Date: Tue, 3 May 2022 16:31:25 +0000 Subject: gnu: poke: Update to 2.3. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/engineering.scm (poke): Update to 2.3. Signed-off-by: Ludovic Courtès --- gnu/packages/engineering.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm index 95313daa63..fe9e06e05a 100644 --- a/gnu/packages/engineering.scm +++ b/gnu/packages/engineering.scm @@ -32,6 +32,7 @@ ;;; Copyright © 2022 Peter Polidoro ;;; Copyright © 2022 Malte Frank Gerdes ;;; Copyright © 2022 Konstantinos Agiannis +;;; Copyright © 2022 Greg Hogan ;;; ;;; This file is part of GNU Guix. ;;; @@ -2803,13 +2804,13 @@ GUI.") (define-public poke (package (name "poke") - (version "2.1") + (version "2.3") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/poke/poke-" version ".tar.gz")) (sha256 - (base32 "0w168jcjahl3jawkhnh0dc10mcw4nwv4yawwc8xhqm5w3dn8wlnd")) + (base32 "0rn7ph7fvbwasf7jhai122sniqjkw81p0kvbxjlv6z6s2q8wz41n")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From 2e6f4220cffc72f55f5390a57499e95fc9a03796 Mon Sep 17 00:00:00 2001 From: arkhan Date: Wed, 11 May 2022 16:04:40 -0500 Subject: gnu: xonsh: Update to 0.12.4. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/shells.scm (xonsh): Update to 0.12.4. [source](snippet): Substitute "xonsh/parsers/completion_context.py". [arguments]: Rewrite #:phases as a gexp. Signed-off-by: Ludovic Courtès --- gnu/packages/shells.scm | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm index 00a0ef363d..9fe0ed8e27 100644 --- a/gnu/packages/shells.scm +++ b/gnu/packages/shells.scm @@ -545,13 +545,13 @@ ksh, and tcsh.") (define-public xonsh (package (name "xonsh") - (version "0.9.27") + (version "0.12.4") (source (origin (method url-fetch) (uri (pypi-uri "xonsh" version)) (sha256 - (base32 "1maz7yvb5py91n699yqsna81x2i25mvrqkrcn7h7870nxd87ral2")) + (base32 "0xlac84nsgs0052n2pw8np1smlgghrbd7p6yrcp7d5qh8zdr9lx3")) (modules '((guix build utils))) (snippet `(begin @@ -565,6 +565,7 @@ ksh, and tcsh.") "xonsh/__amalgam__.py" "xonsh/lexer.py" "xonsh/parsers/base.py" + "xonsh/parsers/completion_context.py" "xonsh/xonfig.py") (("from xonsh\\.ply\\.(.*) import" _ module) (format #f "from ~a import" module)) @@ -572,10 +573,19 @@ ksh, and tcsh.") #t)))) (build-system python-build-system) (arguments - '(;; TODO Try running run the test suite. - ;; See 'requirements-tests.txt' in the source distribution for more - ;; information. - #:tests? #f)) + (list ;; TODO Try running run the test suite. + ;; See 'requirements-tests.txt' in the source distribution for more + ;; information. + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out"))) + (invoke "python" "-m" "compileall" + "--invalidation-mode=unchecked-hash" out) + (invoke "python" "setup.py" "install" "--root=/" + (string-append "--prefix=" out)))))))) (inputs (list python-ply)) (home-page "https://xon.sh/") -- cgit v1.2.3 From c61746b8aa85bc7d69225f47fc56b1f3821b2d00 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 13 May 2022 01:03:31 -0400 Subject: gnu: rpm: Update to 4.17.0. * gnu/packages/package-management.scm (rpm): Update to 4.17.0. [configure-flags]: Remove '--without-lua', no longer supported. [phases]: Delete trailing #t. {fix-lua-check}: New phase. [inputs]: Use new style, sort inputs and add lua. --- gnu/packages/package-management.scm | 40 +++++++++++++++++++++---------------- 1 file changed, 23 insertions(+), 17 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 908efee821..579abb063f 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -80,6 +80,7 @@ #:use-module (gnu packages libedit) #:use-module (gnu packages linux) #:use-module (gnu packages lisp) + #:use-module (gnu packages lua) #:use-module (gnu packages man) #:use-module (gnu packages markup) #:use-module (gnu packages nettle) @@ -825,7 +826,7 @@ features of Stow with some extensions.") (define-public rpm (package (name "rpm") - (version "4.16.1.3") + (version "4.17.0") (source (origin (method url-fetch) (uri (string-append "http://ftp.rpm.org/releases/rpm-" @@ -833,35 +834,40 @@ features of Stow with some extensions.") version ".tar.bz2")) (sha256 (base32 - "07g2g0adgjm29wqy94iqhpp5dk0hacfw1yf7kzycrrxnfbwwfgai")))) + "0sjyqs6hc57k46f45b68dfxnp985s0gar0fi1s0ig6vl4h5j439f")))) (build-system gnu-build-system) (arguments - '(#:configure-flags '("--with-external-db" ;use the system's bdb - "--enable-python" - "--without-lua") + '(#:configure-flags '("--with-external-db" ;use the system's bdb + "--enable-python") #:phases (modify-phases %standard-phases + (add-after 'unpack 'fix-lua-check + (lambda _ + (substitute* "configure" + (("lua >= 5.3") + "lua-5.3 >= 5.3")))) (add-before 'configure 'set-nss-library-path (lambda* (#:key inputs #:allow-other-keys) (let ((nss (assoc-ref inputs "nss"))) (setenv "LIBRARY_PATH" (string-append (getenv "LIBRARY_PATH") ":" - nss "/lib/nss")) - #t)))))) + nss "/lib/nss")))))))) (native-inputs (list pkg-config)) (inputs - (list python - xz - bdb - popt - nss - nspr + (list bdb + bzip2 + cpio + file libarchive libgcrypt - file - bzip2 - zlib - cpio)) + lua + nspr + nss + popt + python + sqlite + xz + zlib)) (home-page "https://rpm.org/") (synopsis "The RPM Package Manager") (description -- cgit v1.2.3 From b65a1e4a2144f1e7a1b58444f4bf2695783c0166 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 10 Apr 2022 13:23:43 +0200 Subject: gnu: emacs: Update to 28.1. * gnu/packages/emacs.scm (emacs): Update to 28.1 * gnu/packages/patches/emacs-exec-path.patch: Adjust accordingly. * gnu/packages/patches/emacs-ignore-empty-xim-styles.patch: Delete file. * gnu/local.mk: Remove it here. --- gnu/local.mk | 1 - gnu/packages/emacs.scm | 5 ++--- gnu/packages/patches/emacs-exec-path.patch | 12 +++++------ .../patches/emacs-ignore-empty-xim-styles.patch | 24 ---------------------- 4 files changed, 8 insertions(+), 34 deletions(-) delete mode 100644 gnu/packages/patches/emacs-ignore-empty-xim-styles.patch diff --git a/gnu/local.mk b/gnu/local.mk index a5cf82ab28..4ef12fd68e 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1030,7 +1030,6 @@ dist_patch_DATA = \ %D%/packages/patches/emacs-exec-path.patch \ %D%/packages/patches/emacs-git-email-missing-parens.patch \ %D%/packages/patches/emacs-fix-scheme-indent-function.patch \ - %D%/packages/patches/emacs-ignore-empty-xim-styles.patch \ %D%/packages/patches/emacs-json-reformat-fix-tests.patch \ %D%/packages/patches/emacs-highlight-stages-add-gexp.patch \ %D%/packages/patches/emacs-hyperbole-toggle-messaging.patch \ diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index bfb3f9790e..7d791250d2 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -79,17 +79,16 @@ (define-public emacs (package (name "emacs") - (version "27.2") + (version "28.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/emacs/emacs-" version ".tar.xz")) (sha256 (base32 - "1ff182gjw9wqsbx1kj5gl2r5pbqhp4ar54g04j33fgz6g17cr9xl")) + "1qbmmmhnjhn4lvzsnyk7l5ganbi6wzbm38jc1a7hhyh3k78b7c98")) (patches (search-patches "emacs-exec-path.patch" "emacs-fix-scheme-indent-function.patch" - "emacs-ignore-empty-xim-styles.patch" "emacs-source-date-epoch.patch")) (modules '((guix build utils))) (snippet diff --git a/gnu/packages/patches/emacs-exec-path.patch b/gnu/packages/patches/emacs-exec-path.patch index 7303599df1..9a76b0237d 100644 --- a/gnu/packages/patches/emacs-exec-path.patch +++ b/gnu/packages/patches/emacs-exec-path.patch @@ -4,13 +4,13 @@ with things like GCC being referenced. --- a/lisp/loadup.el +++ b/lisp/loadup.el -@@ -481,7 +481,8 @@ lost after dumping"))) +@@ -530,7 +530,8 @@ lost after dumping"))) ((equal dump-mode "dump") "emacs") ((equal dump-mode "bootstrap") "emacs") ((equal dump-mode "pbootstrap") "bootstrap-emacs.pdmp") -- (t (error "unrecognized dump mode %s" dump-mode))))) -+ (t (error "unrecognized dump mode %s" dump-mode)))) +- (t (error "Unrecognized dump mode %s" dump-mode))))) ++ (t (error "Unrecognized dump mode %s" dump-mode)))) + (exec-path nil)) - (message "Dumping under the name %s" output) - (condition-case () - (delete-file output) + (when (and (featurep 'native-compile) + (equal dump-mode "pdump")) + ;; Don't enable this before bootstrap is completed, as the diff --git a/gnu/packages/patches/emacs-ignore-empty-xim-styles.patch b/gnu/packages/patches/emacs-ignore-empty-xim-styles.patch deleted file mode 100644 index 398e65bdc8..0000000000 --- a/gnu/packages/patches/emacs-ignore-empty-xim-styles.patch +++ /dev/null @@ -1,24 +0,0 @@ -Fix contributed upstream here: -https://debbugs.gnu.org/cgi/bugreport.cgi?bug=42694. - -Index: emacs-26.3/src/xfns.c -=================================================================== ---- emacs-26.3.orig/src/xfns.c -+++ emacs-26.3/src/xfns.c -@@ -2628,6 +2628,8 @@ xic_free_xfontset (struct frame *f) - static XIMStyle - best_xim_style (XIMStyles *xim) - { -+ if (xim == NULL) goto out; -+ - int i, j; - int nr_supported = ARRAYELTS (supported_xim_styles); - -@@ -2636,6 +2638,7 @@ best_xim_style (XIMStyles *xim) - if (supported_xim_styles[i] == xim->supported_styles[j]) - return supported_xim_styles[i]; - -+ out: - /* Return the default style. */ - return XIMPreeditNothing | XIMStatusNothing; - } -- cgit v1.2.3 From 64557bc695f074af3fcf1eeed8f6696921ef18c5 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 10 Apr 2022 13:28:05 +0200 Subject: gnu: emacs: Use new package style. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/emacs.scm (emacs)[source]: Drop trailing ‘#t’. [arguments]: Convert to list of G-Expressions. Use ‘search-input-file’ where possible. Inline references to auxiliary files. Drop trailing ‘#t’s. [inputs, native-inputs]: Drop labels. --- gnu/packages/emacs.scm | 327 ++++++++++++++++++++++++------------------------- 1 file changed, 161 insertions(+), 166 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 7d791250d2..a32fe624dd 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -41,6 +41,7 @@ (define-module (gnu packages emacs) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) + #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix build-system gnu) @@ -51,6 +52,7 @@ #:use-module (gnu packages base) #:use-module (gnu packages compression) #:use-module (gnu packages fontutils) + #:use-module (gnu packages freedesktop) #:use-module (gnu packages fribidi) #:use-module (gnu packages gd) #:use-module (gnu packages gettext) @@ -119,183 +121,176 @@ (list line "\"~/.guix-profile/include\"" "\"/var/guix/profiles/system/profile/include\"") - " "))) - #t)))) + " "))))))) (build-system glib-or-gtk-build-system) (arguments - `(#:tests? #f ; no check target - #:configure-flags (list "--with-modules" - "--with-cairo" - "--disable-build-details") - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'patch-program-file-names - (lambda* (#:key inputs #:allow-other-keys) - (substitute* '("src/callproc.c" - "lisp/term.el" - "lisp/htmlfontify.el" - "lisp/textmodes/artist.el" - "lisp/progmodes/sh-script.el") - (("\"/bin/sh\"") - (format #f "~s" (which "sh")))) - (substitute* "lisp/doc-view.el" - (("\"(gs|dvipdf|ps2pdf)\"" all what) - (let ((ghostscript (assoc-ref inputs "ghostscript"))) - (if ghostscript - (string-append "\"" ghostscript "/bin/" what "\"") - all))) - (("\"(pdftotext)\"" all what) - (let ((poppler (assoc-ref inputs "poppler"))) - (if poppler - (string-append "\"" poppler "/bin/" what "\"") - all)))) - ;; match ".gvfs-fuse-daemon-real" and ".gvfsd-fuse-real" - ;; respectively when looking for GVFS processes. - (substitute* "lisp/net/tramp-gvfs.el" - (("\\(tramp-compat-process-running-p \"(.*)\"\\)" all process) - (format #f "(or ~a (tramp-compat-process-running-p ~s))" - all (string-append "." process "-real")))) - #t)) - (add-before 'configure 'fix-/bin/pwd - (lambda _ - ;; Use `pwd', not `/bin/pwd'. - (substitute* (find-files "." "^Makefile\\.in$") - (("/bin/pwd") - "pwd")) - #t)) - (add-after 'install 'install-site-start - ;; Use 'guix-emacs' in "site-start.el", which is used autoload the - ;; Elisp packages found in EMACSLOADPATH. - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (lisp-dir (string-append out "/share/emacs/site-lisp")) - (emacs (string-append out "/bin/emacs"))) + (list + #:tests? #f ; no check target + #:configure-flags #~(list "--with-modules" + "--with-cairo" + "--disable-build-details") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-program-file-names + (lambda* (#:key inputs #:allow-other-keys) + (substitute* '("src/callproc.c" + "lisp/term.el" + "lisp/htmlfontify.el" + "lisp/textmodes/artist.el" + "lisp/progmodes/sh-script.el") + (("\"/bin/sh\"") + (format #f "~s" (search-input-file inputs "/bin/sh")))) + (substitute* "lisp/doc-view.el" + (("\"(gs|dvipdf|ps2pdf|pdftotext)\"" all what) + (let ((replacement (search-input-file + inputs + (string-append "/bin/" what)))) + (if replacement + (string-append "\"" replacement "\"") + all)))) + ;; match ".gvfs-fuse-daemon-real" and ".gvfsd-fuse-real" + ;; respectively when looking for GVFS processes. + (substitute* "lisp/net/tramp-gvfs.el" + (("\\(tramp-compat-process-running-p \"(.*)\"\\)" all process) + (format #f "(or ~a (tramp-compat-process-running-p ~s))" + all (string-append "." process "-real")))))) + (add-before 'configure 'fix-/bin/pwd + (lambda _ + ;; Use `pwd', not `/bin/pwd'. + (substitute* (find-files "." "^Makefile\\.in$") + (("/bin/pwd") + "pwd")))) + (add-after 'install 'install-site-start + ;; Use 'guix-emacs' in "site-start.el", which is used autoload the + ;; Elisp packages found in EMACSLOADPATH. + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (lisp-dir (string-append out "/share/emacs/site-lisp")) + (emacs (string-append out "/bin/emacs"))) - ;; This is duplicated from emacs-utils to prevent coupling. - (define* (emacs-byte-compile-directory dir) - (let ((expr `(progn - (setq byte-compile-debug t) - (byte-recompile-directory - (file-name-as-directory ,dir) 0 1)))) - (invoke emacs "--quick" "--batch" - (format #f "--eval=~s" expr)))) + ;; This is duplicated from emacs-utils to prevent coupling. + (define* (emacs-byte-compile-directory dir) + (let ((expr `(progn + (setq byte-compile-debug t) + (byte-recompile-directory + (file-name-as-directory ,dir) 0 1)))) + (invoke emacs "--quick" "--batch" + (format #f "--eval=~s" expr)))) - (copy-file (assoc-ref inputs "guix-emacs.el") - (string-append lisp-dir "/guix-emacs.el")) - (with-output-to-file (string-append lisp-dir "/site-start.el") - (lambda () - (display - (string-append - "(when (require 'guix-emacs nil t)\n" - " (guix-emacs-autoload-packages)\n" - " (advice-add 'package-load-all-descriptors" - " :after #'guix-emacs-load-package-descriptors))")))) - ;; Remove the extraneous subdirs.el file, as it causes Emacs to - ;; add recursively all the the sub-directories of a profile's - ;; share/emacs/site-lisp union when added to EMACSLOADPATH, - ;; which leads to conflicts. - (delete-file (string-append lisp-dir "/subdirs.el")) - ;; Byte compile the site-start files. - (emacs-byte-compile-directory lisp-dir)) - #t)) - (add-after 'glib-or-gtk-wrap 'restore-emacs-pdmp - ;; restore the dump file that Emacs installs somewhere in - ;; libexec/ to its original state - (lambda* (#:key outputs target #:allow-other-keys) - (let* ((libexec (string-append (assoc-ref outputs "out") - "/libexec")) - ;; each of these ought to only match a single file, - ;; but even if not (find-files) sorts by string<, - ;; so the Nth element in one maps to the Nth element of - ;; the other - (pdmp (find-files libexec "\\.pdmp$")) - (pdmp-real (find-files libexec "\\.pdmp-real$"))) - (for-each rename-file pdmp-real pdmp)))) - (add-after 'glib-or-gtk-wrap 'strip-double-wrap - (lambda* (#:key outputs #:allow-other-keys) - ;; Directly copy emacs-X.Y to emacs, so that it is not wrapped - ;; twice. This also fixes a minor issue, where WMs would not be - ;; able to track emacs back to emacs.desktop. - (with-directory-excursion (assoc-ref outputs "out") - (copy-file - (car (find-files "bin" "^emacs-([0-9]+\\.)+[0-9]+$")) - "bin/emacs") - #t))) - (add-after 'strip-double-wrap 'wrap-emacs-paths - (lambda* (#:key inputs outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (lisp-dirs (find-files (string-append out "/share/emacs") - "^lisp$" - #:directories? #t))) - (for-each - (lambda (prog) - (wrap-program prog - ;; emacs-next and variants rely on uname being in PATH for - ;; Tramp. Tramp paths can't be hardcoded, because they - ;; need to be portable. - `("PATH" suffix - ,(map (lambda (in) (string-append in "/bin")) - (list (assoc-ref inputs "gzip") - (assoc-ref inputs "coreutils")))) - `("EMACSLOADPATH" suffix ,lisp-dirs))) - (find-files (string-append out "/bin") - ;; Matches versioned and unversioned emacs binaries. - ;; We don't patch emacsclient, because it takes its - ;; environment variables from emacs. - ;; Likewise, we don't need to patch helper binaries - ;; like etags, ctags or ebrowse. - "^emacs(-[0-9]+(\\.[0-9]+)*)?$")))))))) + (copy-file #$(local-file + (search-auxiliary-file "emacs/guix-emacs.el")) + (string-append lisp-dir "/guix-emacs.el")) + (with-output-to-file (string-append lisp-dir "/site-start.el") + (lambda () + (display + (string-append + "(when (require 'guix-emacs nil t)\n" + " (guix-emacs-autoload-packages)\n" + " (advice-add 'package-load-all-descriptors" + " :after #'guix-emacs-load-package-descriptors))")))) + ;; Remove the extraneous subdirs.el file, as it causes Emacs to + ;; add recursively all the the sub-directories of a profile's + ;; share/emacs/site-lisp union when added to EMACSLOADPATH, + ;; which leads to conflicts. + (delete-file (string-append lisp-dir "/subdirs.el")) + ;; Byte compile the site-start files. + (emacs-byte-compile-directory lisp-dir)))) + (add-after 'glib-or-gtk-wrap 'restore-emacs-pdmp + ;; restore the dump file that Emacs installs somewhere in + ;; libexec/ to its original state + (lambda* (#:key outputs target #:allow-other-keys) + (let* ((libexec (string-append (assoc-ref outputs "out") + "/libexec")) + ;; each of these ought to only match a single file, + ;; but even if not (find-files) sorts by string<, + ;; so the Nth element in one maps to the Nth element of + ;; the other + (pdmp (find-files libexec "\\.pdmp$")) + (pdmp-real (find-files libexec "\\.pdmp-real$"))) + (for-each rename-file pdmp-real pdmp)))) + (add-after 'glib-or-gtk-wrap 'strip-double-wrap + (lambda* (#:key outputs #:allow-other-keys) + ;; Directly copy emacs-X.Y to emacs, so that it is not wrapped + ;; twice. This also fixes a minor issue, where WMs would not be + ;; able to track emacs back to emacs.desktop. + (with-directory-excursion (assoc-ref outputs "out") + (copy-file + (car (find-files "bin" "^emacs-([0-9]+\\.)+[0-9]+$")) + "bin/emacs")))) + (add-after 'strip-double-wrap 'wrap-emacs-paths + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (lisp-dirs (find-files (string-append out "/share/emacs") + "^lisp$" + #:directories? #t))) + (for-each + (lambda (prog) + (wrap-program prog + ;; emacs-next and variants rely on uname being in PATH for + ;; Tramp. Tramp paths can't be hardcoded, because they + ;; need to be portable. + `("PATH" suffix + ,(map dirname + (list (search-input-file inputs "/bin/gzip") + ;; for coreutils + (search-input-file inputs "/bin/yes")))) + `("EMACSLOADPATH" suffix ,lisp-dirs))) + (find-files (string-append out "/bin") + ;; Matches versioned and unversioned emacs binaries. + ;; We don't patch emacsclient, because it takes its + ;; environment variables from emacs. + ;; Likewise, we don't need to patch helper binaries + ;; like etags, ctags or ebrowse. + "^emacs(-[0-9]+(\\.[0-9]+)*)?$")))))))) (inputs - `(("gnutls" ,gnutls) - ("ncurses" ,ncurses) + (list gnutls + ncurses - ;; Required for "core" functionality, such as dired and compression. - ("coreutils" ,coreutils) - ("gzip" ,gzip) + ;; Required for "core" functionality, such as dired and compression. + coreutils + gzip - ;; Avoid Emacs's limited movemail substitute that retrieves POP3 email - ;; only via insecure channels. This is not needed for (modern) IMAP. - ("mailutils" ,mailutils) + ;; Avoid Emacs's limited movemail substitute that retrieves POP3 + ;; email only via insecure channels. + ;; This is not needed for (modern) IMAP. + mailutils - ;; TODO: Add the optional dependencies. - ("gpm" ,gpm) - ("libx11" ,libx11) - ("gtk+" ,gtk+) - ("cairo" ,cairo) - ("pango" ,pango) - ("harfbuzz" ,harfbuzz) - ("libxft" ,libxft) - ("libtiff" ,libtiff) - ("giflib" ,giflib) - ("libjpeg" ,libjpeg-turbo) - ("acl" ,acl) - ("jansson" ,jansson) - ("gmp" ,gmp) - ("ghostscript" ,ghostscript) - ("poppler" ,poppler) + ;; TODO: Add the optional dependencies. + gpm + libx11 + gtk+ + cairo + pango + harfbuzz + libxft + libtiff + giflib + libjpeg-turbo + acl + jansson + gmp + ghostscript + poppler - ;; When looking for libpng `configure' links with `-lpng -lz', so we - ;; must also provide zlib as an input. - ("libpng" ,libpng) - ("zlib" ,zlib) - ("librsvg" ,@(if (target-x86-64?) - (list librsvg-bootstrap) - (list librsvg-2.40))) - ("libxpm" ,libxpm) - ("libxml2" ,libxml2) - ("libice" ,libice) - ("libsm" ,libsm) - ("alsa-lib" ,alsa-lib) - ("dbus" ,dbus) + ;; When looking for libpng `configure' links with `-lpng -lz', so we + ;; must also provide zlib as an input. + libpng + zlib + (if (target-x86-64?) + librsvg-bootstrap + librsvg-2.40) + libxpm + libxml2 + libice + libsm + alsa-lib + dbus - ;; multilingualization support - ("libotf" ,libotf) - ("m17n-lib" ,m17n-lib))) + ;; multilingualization support + libotf + m17n-lib)) (native-inputs - `(("guix-emacs.el" ,(search-auxiliary-file "emacs/guix-emacs.el")) - ("pkg-config" ,pkg-config) - ("texinfo" ,texinfo))) - + (list pkg-config texinfo)) (native-search-paths (list (search-path-specification (variable "EMACSLOADPATH") -- cgit v1.2.3 From 5f315e1d5f46721c757f5259835d84d6a037f9b9 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 10 Apr 2022 13:32:27 +0200 Subject: gnu: emacs: Add support for socket activation. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/emacs.scm (emacs)[#:phases]: Add ‘enable-elogind’. [inputs]: Add elogind. [native-inputs]: Add autoconf. --- gnu/packages/emacs.scm | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index a32fe624dd..a070def7cb 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -131,6 +131,12 @@ "--disable-build-details") #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'enable-elogind + (lambda _ + (substitute* "configure.ac" + (("libsystemd") "libelogind")) + (when (file-exists? "configure") + (delete-file "configure")))) (add-after 'unpack 'patch-program-file-names (lambda* (#:key inputs #:allow-other-keys) (substitute* '("src/callproc.c" @@ -271,6 +277,7 @@ gmp ghostscript poppler + elogind ;; When looking for libpng `configure' links with `-lpng -lz', so we ;; must also provide zlib as an input. @@ -290,7 +297,7 @@ libotf m17n-lib)) (native-inputs - (list pkg-config texinfo)) + (list autoconf pkg-config texinfo)) (native-search-paths (list (search-path-specification (variable "EMACSLOADPATH") -- cgit v1.2.3 From eb02e086e934e9330d361e93469839f86e73ece2 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Thu, 28 Apr 2022 18:39:36 +0200 Subject: gnu: emacs-next: Update to 38d87c43c2ad727406dcfe316aac5e24e202c251. * gnu/packages/emacs.scm (emacs-next): Update to 38d87c43c2ad727406dcfe316aac5e24e202c251. --- gnu/packages/emacs.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index a070def7cb..0e2c3d2c38 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -320,12 +320,12 @@ languages.") (license license:gpl3+))) (define-public emacs-next - (let ((commit "2ea34662c20f71d35dd52a5ed996542c7386b9cb") + (let ((commit "38d87c43c2ad727406dcfe316aac5e24e202c251") (revision "0")) (package (inherit emacs) (name "emacs-next") - (version (git-version "28.0.50" revision commit)) + (version (git-version "29.0.50" revision commit)) (source (origin (inherit (package-source emacs)) @@ -336,7 +336,7 @@ languages.") (file-name (git-file-name name version)) (sha256 (base32 - "0igjm9kwiswn2dpiy2k9xikbdfc7njs07ry48fqz70anljj8y7y3")))) + "0h206asgaqfzhz36p78n23yj4p7kbr6a1f0j0njzxf0ypqrmw9yr")))) (native-inputs (modify-inputs (package-native-inputs emacs) (prepend autoconf)))))) -- cgit v1.2.3 From 527952945c59f69665e40b6b416141554084e057 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Thu, 28 Apr 2022 18:40:27 +0200 Subject: gnu: emacs-next-pgtk: Define in terms of emacs-next. * gnu/packages/emacs.scm (emacs-next-pgtk)[version,source]: Drop fields, inheriting from emacs-next instead. --- gnu/packages/emacs.scm | 46 ++++++++++++++++------------------------------ 1 file changed, 16 insertions(+), 30 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 0e2c3d2c38..0e03455282 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -342,36 +342,22 @@ languages.") (prepend autoconf)))))) (define-public emacs-next-pgtk - (let ((commit "ae18c8ec4f0ef37c8c9cda473770ff47e41291e2") - (revision "1")) - (package - (inherit emacs-next) - (name "emacs-next-pgtk") - (version (git-version "28.0.50" revision commit)) - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://git.savannah.gnu.org/git/emacs.git/") - (commit commit))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "07hgfqh965zmra0rbmnf63p3lsinpv5hn5payqcrjx25pl75xnaf")))) - (arguments - (substitute-keyword-arguments (package-arguments emacs-next) - ((#:configure-flags flags ''()) - `(cons* "--with-pgtk" "--with-xwidgets" ,flags)))) - (propagated-inputs - (list gsettings-desktop-schemas glib-networking)) - (inputs - `(("webkitgtk" ,webkitgtk-with-libsoup2) - ,@(package-inputs emacs-next))) - (home-page "https://github.com/masm11/emacs") - (synopsis "Emacs text editor with @code{pgtk} and @code{xwidgets} support") - (description "This is an unofficial Emacs fork build with a pure-GTK -graphical toolkit to work natively on Wayland. In addition to that, xwidgets -also enabled and works without glitches even on X server.")))) + (package + (inherit emacs-next) + (name "emacs-next-pgtk") + (arguments + (substitute-keyword-arguments (package-arguments emacs-next) + ((#:configure-flags flags ''()) + `(cons* "--with-pgtk" "--with-xwidgets" ,flags)))) + (propagated-inputs + (list gsettings-desktop-schemas glib-networking)) + (inputs + `(("webkitgtk" ,webkitgtk-with-libsoup2) + ,@(package-inputs emacs-next))) + (home-page "https://github.com/masm11/emacs") + (synopsis "Emacs text editor with @code{pgtk} and @code{xwidgets} support") + (description "This Emacs build implements graphical UI purely in terms of +GTK and also enables xwidgets."))) (define-public emacs-minimal ;; This is the version that you should use as an input to packages that just -- cgit v1.2.3 From b41cb7ff535017489b70ea6889882a3285245475 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 13 May 2022 19:06:51 -0400 Subject: gnu: linux-libre: Update to 5.17.7. * gnu/packages/linux.scm (linux-libre-5.17-version): Update to 5.17.7. (linux-libre-5.17-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index b3723c513d..dd6e1a31aa 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -361,7 +361,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The current "stable" kernels. That is, the most recently released major ;; versions that are still supported upstream. -(define-public linux-libre-5.17-version "5.17.6") +(define-public linux-libre-5.17-version "5.17.7") (define-public linux-libre-5.17-gnu-revision "gnu") (define deblob-scripts-5.17 (linux-libre-deblob-scripts @@ -371,7 +371,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1zd4ds6ha4a2acqnalp234r2m9rz9p30qmy1aqri78i06aw7flwn"))) (define-public linux-libre-5.17-pristine-source (let ((version linux-libre-5.17-version) - (hash (base32 "035i9i0gg3fxi5ighjrya97592sk0i4xagra6a8m8nxyh21z3k34"))) + (hash (base32 "16ccf7n6fns9z93c65lchn5v3fgl9c5vkr1v6p0c1xifn7v7xxi2"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.17))) -- cgit v1.2.3 From 776e61308525b233af4c89c9fee3d30ebf5c0afe Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 13 May 2022 19:07:11 -0400 Subject: gnu: linux-libre 5.15: Update to 5.15.39. * gnu/packages/linux.scm (linux-libre-5.15-version): Update to 5.15.39. (linux-libre-5.15-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index dd6e1a31aa..b1bcecc97f 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -379,7 +379,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The "longterm" kernels — the older releases with long-term upstream support. ;; Here are the support timelines: ;; -(define-public linux-libre-5.15-version "5.15.38") +(define-public linux-libre-5.15-version "5.15.39") (define-public linux-libre-5.15-gnu-revision "gnu") (define deblob-scripts-5.15 (linux-libre-deblob-scripts @@ -389,7 +389,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "0gs92qbpvirwd02rpwwnja7771z2azbiy9ppy9ynpr14lxmzxnnh"))) (define-public linux-libre-5.15-pristine-source (let ((version linux-libre-5.15-version) - (hash (base32 "0lhhl766mrl2mbbvn7gkajfzja4v1f96xm9qq3z8pf4h1515shby"))) + (hash (base32 "1bfpiyccjggysd04flaana0x69n1lcpckzpw1v6kh3ly9xil31l8"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.15))) -- cgit v1.2.3 From 05b4fb639109b122fa88d7d193893d08cec2e412 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 13 May 2022 19:07:34 -0400 Subject: gnu: linux-libre 5.10: Update to 5.10.115. * gnu/packages/linux.scm (linux-libre-5.10-version): Update to 5.10.115. (linux-libre-5.10-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index b1bcecc97f..6aec804698 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -394,7 +394,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-5.15))) -(define-public linux-libre-5.10-version "5.10.114") +(define-public linux-libre-5.10-version "5.10.115") (define-public linux-libre-5.10-gnu-revision "gnu1") (define deblob-scripts-5.10 (linux-libre-deblob-scripts @@ -404,7 +404,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1xyhz0dyrkg2avz382ly3dzpa5v89x49gfzx80c1drpwsk7jg6gp"))) (define-public linux-libre-5.10-pristine-source (let ((version linux-libre-5.10-version) - (hash (base32 "09h5ngcl8clsvsv11q6ksvgcs01whlwbbrlpj1jz8mg3gjsrzl07"))) + (hash (base32 "0w9gwizyqjgsj93dqqvlh6bqkmpzjajhj09319nqncc95yrigr7m"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.10))) -- cgit v1.2.3 From 8758dac7108a32dbf1e7d1cd2f26771b18e5a1c9 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 13 May 2022 19:07:55 -0400 Subject: gnu: linux-libre 5.4: Update to 5.4.193. * gnu/packages/linux.scm (linux-libre-5.4-version): Update to 5.4.193. (linux-libre-5.4-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 6aec804698..355f80a01d 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -409,7 +409,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-5.10))) -(define-public linux-libre-5.4-version "5.4.192") +(define-public linux-libre-5.4-version "5.4.193") (define-public linux-libre-5.4-gnu-revision "gnu1") (define deblob-scripts-5.4 (linux-libre-deblob-scripts @@ -419,7 +419,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "05i286d98fm2pdf9724x1dsmfcm7gsd7yyyvxqlpisyj1kx14hda"))) (define-public linux-libre-5.4-pristine-source (let ((version linux-libre-5.4-version) - (hash (base32 "14wyvacajnj6fnxqrash7b8inq0lgmglydqa30kb21zva88jwj1j"))) + (hash (base32 "187jfk9hf52n5z9yv56vq1knp3kdcbyk5w5k98ziwcbdjm1x65hd"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.4))) -- cgit v1.2.3 From 7a3e461c361404005480df916ea248b5e48460ac Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 13 May 2022 19:08:25 -0400 Subject: gnu: linux-libre 4.19: Update to 4.19.242. * gnu/packages/linux.scm (linux-libre-4.19-version): Update to 4.19.242. (linux-libre-4.19-pristine-source, deblob-scripts-4.19): Update hashes. --- gnu/packages/linux.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 355f80a01d..19129d38c7 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -424,17 +424,17 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-5.4))) -(define-public linux-libre-4.19-version "4.19.241") +(define-public linux-libre-4.19-version "4.19.242") (define-public linux-libre-4.19-gnu-revision "gnu1") (define deblob-scripts-4.19 (linux-libre-deblob-scripts linux-libre-4.19-version linux-libre-4.19-gnu-revision (base32 "06pqv050bkii0hc2v7ymny5264w1bca8db0dp1pw9mfmjg865am5") - (base32 "1mp9d0b7mqw7cl65k0a18265cvn4qwcpnvna8r6n5m3y4pz3rik9"))) + (base32 "1dnjgx1nmawm9gm0yf15nl80nmg7hy7q2vl3jxjbwj6hlrfv5dmx"))) (define-public linux-libre-4.19-pristine-source (let ((version linux-libre-4.19-version) - (hash (base32 "04zyi22c2d91k7v2w0s8v112cqqf24km599mn18k2nafq79njqjc"))) + (hash (base32 "18k5fbzclk7g657bs8idwqjk7hakzx6256b1a3506sy29q4zvg2r"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.19))) -- cgit v1.2.3 From fb42a8d996999da1717cc9366ebfab25cf6a5921 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 13 May 2022 19:08:55 -0400 Subject: gnu: linux-libre 4.14: Update to 4.14.278. * gnu/packages/linux.scm (linux-libre-4.14-version): Update to 4.14.278. (linux-libre-4.14-pristine-source, deblob-scripts-4.14): Update hashes. --- gnu/packages/linux.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 19129d38c7..366abe41db 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -439,17 +439,17 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-4.19))) -(define-public linux-libre-4.14-version "4.14.277") +(define-public linux-libre-4.14-version "4.14.278") (define-public linux-libre-4.14-gnu-revision "gnu1") (define deblob-scripts-4.14 (linux-libre-deblob-scripts linux-libre-4.14-version linux-libre-4.14-gnu-revision (base32 "02rxvr0gmxb3zfsyyzdmzgfq04gkdkv1cc38md0xfl0mxzdzdfyk") - (base32 "1mp9d0b7mqw7cl65k0a18265cvn4qwcpnvna8r6n5m3y4pz3rik9"))) + (base32 "1dnjgx1nmawm9gm0yf15nl80nmg7hy7q2vl3jxjbwj6hlrfv5dmx"))) (define-public linux-libre-4.14-pristine-source (let ((version linux-libre-4.14-version) - (hash (base32 "058vzn1gcsc194hgwrj78afawz2anm7ga8a1x5m5i4cw8p1arp73"))) + (hash (base32 "1glb6z3nicd2lzhvwcqj54642agk0bbg022wnc3ckld5ngpd9miw"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.14))) -- cgit v1.2.3 From 5ee14252b7a1332bf845de2c3f4cf29f4b61d9e0 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 13 May 2022 19:09:23 -0400 Subject: gnu: linux-libre 4.9: Update to 4.9.313. * gnu/packages/linux.scm (linux-libre-4.9-version): Update to 4.9.313. (linux-libre-4.9-pristine-source, deblob-scripts-4.9): Update hashes. --- gnu/packages/linux.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 366abe41db..f8b9a29843 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -454,17 +454,17 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-4.14))) -(define-public linux-libre-4.9-version "4.9.312") +(define-public linux-libre-4.9-version "4.9.313") (define-public linux-libre-4.9-gnu-revision "gnu1") (define deblob-scripts-4.9 (linux-libre-deblob-scripts linux-libre-4.9-version linux-libre-4.9-gnu-revision (base32 "0nai5m4rbh37qaj1xf2qj7656l2gacfh0847q5d07y22b048fq5n") - (base32 "0wdaj40pcq9wg5xnz2zj3jj8bawhfgqxcwp6dnavbf9lq0gca48p"))) + (base32 "14jyn2yrbm6ayp0bszs4f9jy3p1qkrj5p5gf5c42spr67aa2lv2v"))) (define-public linux-libre-4.9-pristine-source (let ((version linux-libre-4.9-version) - (hash (base32 "09y6wl4j3y46fza6kmssibmxspxx0i44fqrhc2cyvrm2bgxv2bzs"))) + (hash (base32 "1p3vr1h01ph6x0pxrr6y6k5c4nrhvq650dfngv5mkrgsc5w7ffz0"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.9))) -- cgit v1.2.3 From 35707e50581f17c68ec38add5cd8d9ebc600b925 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sat, 14 May 2022 21:55:29 +0200 Subject: gnu: emacs-minimal: Use G-Expressions in arguments. This is a follow-up to commit 64557bc695f074af3fcf1eeed8f6696921ef18c5. The use of G-Expressions in emacs' arguments wasn't reflected in emacs-minimal, causing builds to fail as reported in . * gnu/packages/emacs.scm (emacs-minimal)[arguments]: Convert to list of G-Expessions. --- gnu/packages/emacs.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 0e03455282..255c8ee864 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -369,11 +369,11 @@ GTK and also enables xwidgets."))) (arguments (substitute-keyword-arguments (package-arguments emacs) ((#:configure-flags flags ''()) - `(list "--with-gnutls=no" "--disable-build-details")) + #~(list "--with-gnutls=no" "--disable-build-details")) ((#:phases phases) - `(modify-phases ,phases - (delete 'restore-emacs-pdmp) - (delete 'strip-double-wrap))))) + #~(modify-phases #$phases + (delete 'restore-emacs-pdmp) + (delete 'strip-double-wrap))))) (inputs `(("guix-emacs.el" ,(search-auxiliary-file "emacs/guix-emacs.el")) ("ncurses" ,ncurses) -- cgit v1.2.3 From 775817648f00275eb2f63be163e617de4eeefd99 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sat, 14 May 2022 22:06:57 +0200 Subject: gnu: emacs: Don't error on missing commands. This is a follow-up to commit 64557bc695f074af3fcf1eeed8f6696921ef18c5. Inputs lacking from emacs proper may not be present in emacs-minimal, thus throwing an error on lookup. This error is already anticipated in the handling code. * gnu/packages/emacs.scm (emacs)[patch-program-file-names]: Wrap search-input-file in false-if-exception. --- gnu/packages/emacs.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 255c8ee864..441c810ff4 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -148,9 +148,10 @@ (format #f "~s" (search-input-file inputs "/bin/sh")))) (substitute* "lisp/doc-view.el" (("\"(gs|dvipdf|ps2pdf|pdftotext)\"" all what) - (let ((replacement (search-input-file - inputs - (string-append "/bin/" what)))) + (let ((replacement (false-if-exception + (search-input-file + inputs + (string-append "/bin/" what))))) (if replacement (string-append "\"" replacement "\"") all)))) -- cgit v1.2.3 From 3935451f63c078cae9a928d87c6838ec3138abc0 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sat, 14 May 2022 22:11:30 +0200 Subject: gnu: emacs-minimal: Fix inputs. This is a follow-up to 5f315e1d5f46721c757f5259835d84d6a037f9b9. The addition of autoconf wasn't reflected in emacs-minimal, causing builds to break. Also drop labels while we're at it. * gnu/packages/emacs.scm (emacs-minimal)[inputs]: Drop labels. [native-inputs]: Drop labels. Add autoconf. --- gnu/packages/emacs.scm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 441c810ff4..9649334e45 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -376,12 +376,12 @@ GTK and also enables xwidgets."))) (delete 'restore-emacs-pdmp) (delete 'strip-double-wrap))))) (inputs - `(("guix-emacs.el" ,(search-auxiliary-file "emacs/guix-emacs.el")) - ("ncurses" ,ncurses) - ("coreutils" ,coreutils) - ("gzip" ,gzip))) + (list (search-auxiliary-file "emacs/guix-emacs.el") + ncurses + coreutils + gzip)) (native-inputs - `(("pkg-config" ,pkg-config))))) + (list autoconf pkg-config)))) (define-public emacs-xwidgets (package/inherit emacs -- cgit v1.2.3 From bf04c2044bc239faf349da47aed08537a86b2208 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 14 May 2022 16:52:41 -0400 Subject: gnu: MPD: Update to 0.23.7. * gnu/packages/mpd.scm (mpd): Update to 0.23.7. --- gnu/packages/mpd.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mpd.scm b/gnu/packages/mpd.scm index 1ee6806735..dde233b337 100644 --- a/gnu/packages/mpd.scm +++ b/gnu/packages/mpd.scm @@ -107,7 +107,7 @@ interfacing MPD in the C, C++ & Objective C languages.") (define-public mpd (package (name "mpd") - (version "0.23.6") + (version "0.23.7") (source (origin (method url-fetch) (uri @@ -116,7 +116,7 @@ interfacing MPD in the C, C++ & Objective C languages.") "/mpd-" version ".tar.xz")) (sha256 (base32 - "1v969w7h3660ph3h2bdlkrzc05pfz95bmxjqdbzzf7pfwf795ifb")))) + "04c2fr4akiylafb7wdjzn7r7d90rmzilbnagrifqyf3wf6ncn3cn")))) (build-system meson-build-system) (arguments `(#:configure-flags '("-Ddocumentation=enabled"))) -- cgit v1.2.3 From 9d4c7cbead07181cc6ca4375148c883beb0efcc2 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 14 May 2022 16:50:46 -0400 Subject: gnu: Syncthing: Update to 1.20.1. * gnu/packages/syncthing.scm (syncthing): Update to 1.20.1. --- gnu/packages/syncthing.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/syncthing.scm b/gnu/packages/syncthing.scm index 107b97e547..6002c10560 100644 --- a/gnu/packages/syncthing.scm +++ b/gnu/packages/syncthing.scm @@ -46,7 +46,7 @@ (define-public syncthing (package (name "syncthing") - (version "1.19.1") + (version "1.20.1") (source (origin (method url-fetch) (uri (string-append "https://github.com/syncthing/syncthing" @@ -54,7 +54,7 @@ "/syncthing-source-v" version ".tar.gz")) (sha256 (base32 - "09silpbpciqzpr4y4ycpkxrwi9zf90xgd13844m145134cpyrigz")))) + "1g1514y1p8cfvjqszn6k90xv67vzr1yw6xa02g6gb38sl6pap3x8")))) (build-system go-build-system) ;; The primary Syncthing executable goes to "out", while the auxiliary ;; server programs and utility tools go to "utils". This reduces the size -- cgit v1.2.3 From 58cb8c2f68f365cf91b4055d5ef432e4323ccea1 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 00:21:05 +0200 Subject: gnu: emacs-minimal: Drop meaningless input. The search for guix-emacs.el has already been inlined into a phase shared by all emacs variants. * gnu/packages/emacs.scm (emacs-minimal)[inputs]: Remove "emacs/guix-emacs.el". --- gnu/packages/emacs.scm | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 9649334e45..1c261c2c99 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -376,10 +376,7 @@ GTK and also enables xwidgets."))) (delete 'restore-emacs-pdmp) (delete 'strip-double-wrap))))) (inputs - (list (search-auxiliary-file "emacs/guix-emacs.el") - ncurses - coreutils - gzip)) + (list ncurses coreutils gzip)) (native-inputs (list autoconf pkg-config)))) -- cgit v1.2.3 From 3443cbf8ddc3903179bf5c4950bb350872e65c4a Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 00:22:38 +0200 Subject: gnu: emacs-minimal: Tidy up coding style. * gnu/packages/emacs.scm (emacs-minimal)[inputs, native-inputs]: Reduce to a single line. [#:configure-flags]: Use G-Expression rather than double quoting. --- gnu/packages/emacs.scm | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 1c261c2c99..4f90279e78 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -369,16 +369,14 @@ GTK and also enables xwidgets."))) (build-system gnu-build-system) (arguments (substitute-keyword-arguments (package-arguments emacs) - ((#:configure-flags flags ''()) + ((#:configure-flags flags #~'()) #~(list "--with-gnutls=no" "--disable-build-details")) ((#:phases phases) #~(modify-phases #$phases (delete 'restore-emacs-pdmp) (delete 'strip-double-wrap))))) - (inputs - (list ncurses coreutils gzip)) - (native-inputs - (list autoconf pkg-config)))) + (inputs (list ncurses coreutils gzip)) + (native-inputs (list autoconf pkg-config)))) (define-public emacs-xwidgets (package/inherit emacs -- cgit v1.2.3 From be3b73bd88c83413a0cab705ce7543fb6fedce88 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Sat, 14 May 2022 23:39:57 +0200 Subject: gnu: emacs-dash: Fix build with Emacs 28. * gnu/packages/emacs-xyz.scm (emacs-dash)[phase]: Add phase 'disable-byte-compile-error-on-warn. Signed-off-by: Liliana Marie Prikler --- gnu/packages/emacs-xyz.scm | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index c18505a681..928ca1c120 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -3677,7 +3677,14 @@ restore the saved place.") (base32 "0z6f8y1m9amhg427iz1d4xcyr6n0kj5w7kmiz134p320ixsdnzd8")))) (build-system emacs-build-system) - (arguments `(#:tests? #t)) + (arguments `(#:tests? #t + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'disable-byte-compile-error-on-warn + (lambda _ + (substitute* "Makefile" + (("\\(setq byte-compile-error-on-warn t\\)") + "(setq byte-compile-error-on-warn nil)"))))))) (home-page "https://github.com/magnars/dash.el") (synopsis "Modern list library for Emacs") (description "This package provides a modern list API library for Emacs.") -- cgit v1.2.3 From 45bff507344892bfbfb114b88e6d5c6f16485d74 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 01:19:29 +0200 Subject: gnu: emacs-dash: Use new package style. * gnu/packages/emacs-xyz.scm (emacs-dash)[arguments]: Convert to list of G-Expressions. --- gnu/packages/emacs-xyz.scm | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 928ca1c120..787f6fc43e 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -3677,14 +3677,15 @@ restore the saved place.") (base32 "0z6f8y1m9amhg427iz1d4xcyr6n0kj5w7kmiz134p320ixsdnzd8")))) (build-system emacs-build-system) - (arguments `(#:tests? #t - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'disable-byte-compile-error-on-warn - (lambda _ - (substitute* "Makefile" - (("\\(setq byte-compile-error-on-warn t\\)") - "(setq byte-compile-error-on-warn nil)"))))))) + (arguments + (list #:tests? #t + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-byte-compile-error-on-warn + (lambda _ + (substitute* "Makefile" + (("\\(setq byte-compile-error-on-warn t\\)") + "(setq byte-compile-error-on-warn nil)"))))))) (home-page "https://github.com/magnars/dash.el") (synopsis "Modern list library for Emacs") (description "This package provides a modern list API library for Emacs.") -- cgit v1.2.3 From ce1c88a29b56ac7abe8413997464508b46d4f970 Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Sat, 14 May 2022 15:14:49 -0700 Subject: gnu: diffoscope: Update to 212. * gnu/packages/diffoscope.scm (diffoscope): Update to 212. --- gnu/packages/diffoscope.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/diffoscope.scm b/gnu/packages/diffoscope.scm index 89cf3cebc8..da4de83373 100644 --- a/gnu/packages/diffoscope.scm +++ b/gnu/packages/diffoscope.scm @@ -74,7 +74,7 @@ (define-public diffoscope (package (name "diffoscope") - (version "209") + (version "212") (source (origin (method git-fetch) @@ -83,7 +83,7 @@ (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "18avlxra2jrqg5xklb86ikafyqad58m8c906s3l8lwxwpjqkx794")) + (base32 "1yzxqynrbr9kj7f5qxfzcxr8vb86xygm2yzgq8rqqc1khzsl7q90")) (patches (search-patches "diffoscope-fix-llvm-test.patch")))) (build-system python-build-system) -- cgit v1.2.3 From de68877a517ba058f67086d444d7265c9c803679 Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Sat, 14 May 2022 17:06:48 -0700 Subject: gnu: libxmlb: Install xb-tool in bin dir. * gnu/packages/patches/libxmlb-install-xb-tool-into-bindir.patch: New file. * gnu/packages/xml.scm (libxmlb)[source]: Add patch. * gnu/local.mk (dist_patch_DATA): Add patch. * gnu/packages/diffoscope.scm (diffoscope)[arguments]: Add 'xb-tool-external-tool phase. --- gnu/local.mk | 1 + gnu/packages/diffoscope.scm | 7 ++ .../libxmlb-install-xb-tool-into-bindir.patch | 100 +++++++++++++++++++++ gnu/packages/xml.scm | 4 +- 4 files changed, 111 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/libxmlb-install-xb-tool-into-bindir.patch diff --git a/gnu/local.mk b/gnu/local.mk index 4ef12fd68e..d5b60bdba3 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1426,6 +1426,7 @@ dist_patch_DATA = \ %D%/packages/patches/libxml2-terminating-newline.patch \ %D%/packages/patches/libxml2-xpath-recursion-limit.patch \ %D%/packages/patches/libxml2-xpath0-Add-option-xpath0.patch \ + %D%/packages/patches/libxmlb-install-xb-tool-into-bindir.patch \ %D%/packages/patches/libxslt-generated-ids.patch \ %D%/packages/patches/libxt-guix-search-paths.patch \ %D%/packages/patches/lierolibre-check-unaligned-access.patch \ diff --git a/gnu/packages/diffoscope.scm b/gnu/packages/diffoscope.scm index da4de83373..b4279a3fb5 100644 --- a/gnu/packages/diffoscope.scm +++ b/gnu/packages/diffoscope.scm @@ -111,6 +111,13 @@ (string-append "['" (which "stat") "',")) (("\\['getfacl',") (string-append "['" (which "getfacl") "',"))))) + (add-after 'unpack 'xb-tool-external-tool + ;; Fixed upstream, remove this phase when updating to + ;; diffoscope 213 + (lambda _ + (substitute* "diffoscope/external_tools.py" + ((".debian.: .libxmlb-dev.") + "\"debian\": \"libxmlb-dev\", \"guix\": \"libxmlb\"")))) (add-after 'build 'build-man-page (lambda* (#:key (make-flags '()) #:allow-other-keys) (apply invoke "make" "-C" "doc" make-flags))) diff --git a/gnu/packages/patches/libxmlb-install-xb-tool-into-bindir.patch b/gnu/packages/patches/libxmlb-install-xb-tool-into-bindir.patch new file mode 100644 index 0000000000..97f0f5fbd3 --- /dev/null +++ b/gnu/packages/patches/libxmlb-install-xb-tool-into-bindir.patch @@ -0,0 +1,100 @@ +From f91a9cfcd70178404ac2aafdfa124c9a4efe8866 Mon Sep 17 00:00:00 2001 +From: Richard Hughes +Date: Mon, 18 Apr 2022 10:50:42 +0100 +Subject: [PATCH 11/11] Install xb-tool into bindir + +Fixes https://github.com/hughsie/libxmlb/issues/123 +--- + contrib/libxmlb.spec.in | 3 ++- + meson.build | 4 +++- + src/meson.build | 9 ++++++++- + src/xb-tool.1 | 19 +++++++++++++++++++ + 4 files changed, 32 insertions(+), 3 deletions(-) + create mode 100644 src/xb-tool.1 + +diff --git a/contrib/libxmlb.spec.in b/contrib/libxmlb.spec.in +index 6be65d1..24478fe 100644 +--- a/contrib/libxmlb.spec.in ++++ b/contrib/libxmlb.spec.in +@@ -71,7 +71,8 @@ Executable and data files for installed tests. + %files + %doc README.md + %license LICENSE +-%{_libexecdir}/xb-tool ++%{_bindir}/xb-tool ++%{_mandir}/man1/xb-tool.1* + %dir %{_libdir}/girepository-1.0 + %{_libdir}/girepository-1.0/Xmlb-2.0.typelib + %{_libdir}/libxmlb.so.2* +diff --git a/meson.build b/meson.build +index 6870907..53b1324 100644 +--- a/meson.build ++++ b/meson.build +@@ -103,16 +103,18 @@ add_project_link_arguments( + ) + + if host_machine.system() == 'windows' +- libexecdir = get_option('libexecdir') ++ bindir = get_option('bindir') + installed_test_bindir = get_option('libexecdir') + installed_test_datadir = get_option('datadir') + else + prefix = get_option('prefix') + datadir = join_paths(prefix, get_option('datadir')) ++ bindir = join_paths(prefix, get_option('bindir')) + libexecdir = join_paths(prefix, get_option('libexecdir')) + installed_test_bindir = join_paths(libexecdir, 'installed-tests', meson.project_name()) + installed_test_datadir = join_paths(datadir, 'installed-tests', meson.project_name()) + endif ++mandir = join_paths(prefix, get_option('mandir')) + + gio = dependency('gio-2.0', version : '>= 2.45.8') + giounix = dependency('gio-unix-2.0', version : '>= 2.45.8', required: false) +diff --git a/src/meson.build b/src/meson.build +index d7a1401..93fb8ba 100644 +--- a/src/meson.build ++++ b/src/meson.build +@@ -96,7 +96,14 @@ xb_tool = executable( + libxmlb, + ], + install : true, +- install_dir : libexecdir ++ install_dir : bindir ++) ++configure_file( ++ input : 'xb-tool.1', ++ output : 'xb-tool.1', ++ configuration : conf, ++ install: true, ++ install_dir: join_paths(mandir, 'man1'), + ) + endif + +diff --git a/src/xb-tool.1 b/src/xb-tool.1 +new file mode 100644 +index 0000000..348d1b1 +--- /dev/null ++++ b/src/xb-tool.1 +@@ -0,0 +1,19 @@ ++.\" Report problems in https://github.com/hughsie/libxmlb ++.TH man 1 "18 April 2022" @PACKAGE_VERSION@ "xb-tool man page" ++.SH NAME ++xb-tool \- standalone XMLb utility ++.SH SYNOPSIS ++xb-tool [CMD] ++.SH DESCRIPTION ++This tool allows creating, dumping and querying binary XML blobs. ++.PP ++Additionally \fBxb-tool\fR can be used to profile specfic tokenized queries. ++.SH OPTIONS ++The xb-tool command takes various options depending on the action. ++Run \fBxb-tool --help\fR for the full list. ++.SH EXIT STATUS ++Commands that successfully execute will return "0", otherwise "1". ++.SH BUGS ++No known bugs. ++.SH AUTHOR ++Richard Hughes (richard@hughsie.com) +-- +2.35.1 + diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm index a0d8d20102..11b0a4ef54 100644 --- a/gnu/packages/xml.scm +++ b/gnu/packages/xml.scm @@ -99,7 +99,9 @@ (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0znz2y1ig2kvlda44a3kxa8x7f222nbg50rjz6nlngzka0ccsgxx")))) + (base32 "0znz2y1ig2kvlda44a3kxa8x7f222nbg50rjz6nlngzka0ccsgxx")) + ;; Drop xb-tool patch after libxmlb 0.3.8, merged upstream + (patches (search-patches "libxmlb-install-xb-tool-into-bindir.patch")))) (build-system meson-build-system) (arguments `(#:glib-or-gtk? #t)) -- cgit v1.2.3 From 22d6e36005322cd641bc1107f3f04945e03478d5 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 03:05:28 +0200 Subject: gnu: emacs-yasnippet: Fix build. * gnu/packages/patches/emacs-yasnippet-fix-tests.patch: New file. * gnu/packages/emacs-xyz.scm (emacs-yasnippet): Use it here. * gnu/local.mk (dist_patch_DATA): Register it here. --- gnu/local.mk | 1 + gnu/packages/emacs-xyz.scm | 4 +- .../patches/emacs-yasnippet-fix-tests.patch | 95 ++++++++++++++++++++++ 3 files changed, 99 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/emacs-yasnippet-fix-tests.patch diff --git a/gnu/local.mk b/gnu/local.mk index d5b60bdba3..cfb499915a 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1038,6 +1038,7 @@ dist_patch_DATA = \ %D%/packages/patches/emacs-telega-path-placeholder.patch \ %D%/packages/patches/emacs-telega-test-env.patch \ %D%/packages/patches/emacs-wordnut-require-adaptive-wrap.patch \ + %D%/packages/patches/emacs-yasnippet-fix-tests.patch \ %D%/packages/patches/enjarify-setup-py.patch \ %D%/packages/patches/enlightenment-fix-setuid-path.patch \ %D%/packages/patches/eog-update-libportal-usage.patch \ diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 787f6fc43e..8a319fc0ff 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -13490,7 +13490,9 @@ the Emacs Tempo library. You may also write your templates in Lisp.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0via9dzw8m5lzymg1h78xkwjssh39zr3g6ccyamlf1rjzjsyxknv")))) + (base32 "0via9dzw8m5lzymg1h78xkwjssh39zr3g6ccyamlf1rjzjsyxknv")) + (patches + (search-patches "emacs-yasnippet-fix-tests.patch")))) (build-system emacs-build-system) (arguments `(#:tests? #t diff --git a/gnu/packages/patches/emacs-yasnippet-fix-tests.patch b/gnu/packages/patches/emacs-yasnippet-fix-tests.patch new file mode 100644 index 0000000000..475352d8db --- /dev/null +++ b/gnu/packages/patches/emacs-yasnippet-fix-tests.patch @@ -0,0 +1,95 @@ +From 904a058fcf4e1f4985e03f8551eec282ca12ccb5 Mon Sep 17 00:00:00 2001 +From: Philipp Stephani +Date: Mon, 6 Dec 2021 18:50:10 +0100 +Subject: [PATCH] Unbreak unit tests under Emacs 28. +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +- Emacs 28 has a new mode ‘lisp-data-mode’ for Lisp data. +- A test that was temporarily broken passes again. +- The default for ‘org-adapt-indentation’ has changed. +--- + yasnippet-tests.el | 41 ++++++++++++++++++++++++++--------------- + 1 file changed, 26 insertions(+), 15 deletions(-) + +diff --git a/yasnippet-tests.el b/yasnippet-tests.el +index b8a7980f..9fadf00c 100644 +--- a/yasnippet-tests.el ++++ b/yasnippet-tests.el +@@ -1,6 +1,6 @@ + ;;; yasnippet-tests.el --- some yasnippet tests -*- lexical-binding: t -*- + +-;; Copyright (C) 2012-2015, 2017-2018 Free Software Foundation, Inc. ++;; Copyright (C) 2012-2015, 2017-2018, 2021 Free Software Foundation, Inc. + + ;; Author: João Távora + ;; Keywords: emulations, convenience +@@ -556,16 +556,19 @@ XXXXX ------------------------")))) + (yas-mock-insert "foo bar") + (ert-simulate-command '(yas-next-field)) + (goto-char (point-min)) +- (let ((expected (with-temp-buffer +- (insert (format (concat "* Test foo bar\n" +- " " org-property-format "\n" +- " " org-property-format "\n" +- " " org-property-format) +- ":PROPERTIES:" "" +- ":ID:" "foo bar-after" +- ":END:" "")) +- (delete-trailing-whitespace) +- (buffer-string)))) ++ ;; The default value of `org-adapt-indentation' changed between Org-mode 9.4 ++ ;; and 9.5, so force a specific value. ++ (let* ((org-adapt-indentation nil) ++ (expected (with-temp-buffer ++ (insert (format (concat "* Test foo bar\n" ++ org-property-format "\n" ++ org-property-format "\n" ++ org-property-format) ++ ":PROPERTIES:" "" ++ ":ID:" "foo bar-after" ++ ":END:" "")) ++ (delete-trailing-whitespace) ++ (buffer-string)))) + ;; Some org-mode versions leave trailing whitespace, some don't. + (delete-trailing-whitespace) + (should (equal expected (buffer-string)))))) +@@ -1390,7 +1393,9 @@ hello ${1:$(when (stringp yas-text) (funcall func yas-text))} foo${1:$$(concat \ + ,@(if (fboundp 'prog-mode) + '(prog-mode)) + emacs-lisp-mode +- lisp-interaction-mode)) ++ lisp-interaction-mode ++ ;; `lisp-data-mode' doesn't exist prior to Emacs 28. ++ ,@(and (fboundp 'lisp-data-mode) '(lisp-data-mode)))) + (observed (yas--modes-to-activate))) + (should (equal major-mode (car observed))) + (should (equal (sort expected #'string<) (sort observed #'string<)))))))) +@@ -1418,7 +1423,11 @@ hello ${1:$(when (stringp yas-text) (funcall func yas-text))} foo${1:$$(concat \ + '(prog-mode)) + emacs-lisp-mode + and-also-this-one +- lisp-interaction-mode)) ++ lisp-interaction-mode ++ ;; `lisp-data-mode' doesn't exist prior to ++ ;; Emacs 28. ++ ,@(and (fboundp 'lisp-data-mode) ++ '(lisp-data-mode)))) + (observed (yas--modes-to-activate))) + (should (equal expected-first + (cl-subseq observed 0 (length expected-first)))) +@@ -1691,9 +1700,11 @@ TODO: be meaner" + "Test expansion of snippets in org source blocks." + ;; org 9+ no longer runs fontification for text-mode, so our hacks + ;; don't work. Note that old ert doesn't have skipping, so we have +- ;; to expect failure instead. ++ ;; to expect failure instead. Starting with Org-mode 9.5 this seems ++ ;; to work again. + :expected-result (if (and (fboundp 'org-in-src-block-p) +- (version< (org-version) "9")) ++ (or (version< (org-version) "9") ++ (version<= "9.5" (org-version)))) + :passed :failed) + (let ((text-mode-hook #'yas-minor-mode)) + (do-yas-org-native-tab-in-source-block "text"))) -- cgit v1.2.3 From 9a520eb203fefe85cf15ebb978c897f99dc01ccf Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 00:07:43 +0200 Subject: gnu: emacs-next-pgtk: Use new package style. * gnu/packages/emacs.scm (emacs-next-pgtk)[arguments]: Convert to list of G-Expressions. [inputs]: Use modify-inputs. --- gnu/packages/emacs.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 4f90279e78..9f03f0b0db 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -348,13 +348,13 @@ languages.") (name "emacs-next-pgtk") (arguments (substitute-keyword-arguments (package-arguments emacs-next) - ((#:configure-flags flags ''()) - `(cons* "--with-pgtk" "--with-xwidgets" ,flags)))) + ((#:configure-flags flags #~'()) + #~(cons* "--with-pgtk" "--with-xwidgets" #$flags)))) (propagated-inputs (list gsettings-desktop-schemas glib-networking)) (inputs - `(("webkitgtk" ,webkitgtk-with-libsoup2) - ,@(package-inputs emacs-next))) + (modify-inputs (package-inputs emacs-next) + (prepend webkitgtk-with-libsoup2))) (home-page "https://github.com/masm11/emacs") (synopsis "Emacs text editor with @code{pgtk} and @code{xwidgets} support") (description "This Emacs build implements graphical UI purely in terms of -- cgit v1.2.3 From a56a3fa761ab3502e638d92c267bfe781eb176e4 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 00:10:19 +0200 Subject: gnu: emacs-xwidgets: Use new package style. * gnu/packages/emacs.scm (emacs-xwidgets)[arguments]: Convert to list of G-Expressions. [inputs]: Use modify-inputs. --- gnu/packages/emacs.scm | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 9f03f0b0db..6423845013 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -386,16 +386,15 @@ editor (with xwidgets support)") (build-system gnu-build-system) (arguments (substitute-keyword-arguments (package-arguments emacs) - ((#:configure-flags flags ''()) - `(cons "--with-xwidgets" ,flags)) + ((#:configure-flags flags #~'()) + #~(cons "--with-xwidgets" #$flags)) ((#:phases phases) - `(modify-phases ,phases - (delete 'restore-emacs-pdmp) - (delete 'strip-double-wrap))))) + #~(modify-phases #$phases + (delete 'restore-emacs-pdmp) + (delete 'strip-double-wrap))))) (inputs - `(("webkitgtk" ,webkitgtk-with-libsoup2) - ("libxcomposite" ,libxcomposite) - ,@(package-inputs emacs))))) + (modify-inputs (package-inputs emacs) + (prepend webkitgtk-with-libsoup2 libxcomposite))))) (define-public emacs-no-x (package/inherit emacs -- cgit v1.2.3 From 4949188d465dd008c73c54d71baa2def676a445a Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 00:10:59 +0200 Subject: gnu: emacs-no-x: Use new package style. * gnu/packages/emacs.scm (emacs-no-x)[arguments]: Convert to list of G-Expressions. [inputs]: Use modify-inputs. --- gnu/packages/emacs.scm | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 6423845013..d46b194441 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -402,22 +402,20 @@ editor (with xwidgets support)") (synopsis "The extensible, customizable, self-documenting text editor (console only)") (build-system gnu-build-system) - (inputs (fold alist-delete - (package-inputs emacs) - '("libx11" "gtk+" "libxft" "libtiff" "giflib" "libjpeg" - "imagemagick" "libpng" "librsvg" "libxpm" "libice" - "libsm" "cairo" "pango" "harfbuzz" - - ;; These depend on libx11, so remove them as well. - "libotf" "m17n-lib" "dbus"))) + (inputs (modify-inputs (package-inputs emacs) + (delete "libx11" "gtk+" "libxft" "libtiff" "giflib" "libjpeg" + "imagemagick" "libpng" "librsvg" "libxpm" "libice" + "libsm" "cairo" "pango" "harfbuzz" + ;; These depend on libx11, so remove them as well. + "libotf" "m17n-lib" "dbus"))) (arguments (substitute-keyword-arguments (package-arguments emacs) - ((#:configure-flags flags ''()) - `(delete "--with-cairo" ,flags)) + ((#:configure-flags flags #~'()) + #~(delete "--with-cairo" #$flags)) ((#:phases phases) - `(modify-phases ,phases - (delete 'restore-emacs-pdmp) - (delete 'strip-double-wrap))))))) + #~(modify-phases #$phases + (delete 'restore-emacs-pdmp) + (delete 'strip-double-wrap))))))) (define-public emacs-no-x-toolkit (package/inherit emacs -- cgit v1.2.3 From 484dd71a085fb1ef845fde4fa5920b7279883228 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 00:11:22 +0200 Subject: gnu: emacs-no-x-toolkit: Use new package style. * gnu/packages/emacs.scm (emacs-no-x-toolkit)[arguments]: Convert to list of G-Expressions. [inputs]: Use modify-inputs. --- gnu/packages/emacs.scm | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index d46b194441..4c63b4ab5b 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -423,14 +423,15 @@ editor (console only)") (synopsis "The extensible, customizable, self-documenting text editor (without an X toolkit)" ) (build-system gnu-build-system) - (inputs (append `(("inotify-tools" ,inotify-tools)) - (alist-delete "gtk+" (package-inputs emacs)))) + (inputs (modify-inputs (package-inputs emacs) + (delete "gtk+") + (prepend inotify-tools))) (arguments (substitute-keyword-arguments (package-arguments emacs) - ((#:configure-flags flags ''()) - `(cons "--with-x-toolkit=no" ,flags)) + ((#:configure-flags flags #~'()) + #~(cons "--with-x-toolkit=no" #$flags)) ((#:phases phases) - `(modify-phases ,phases + #~(modify-phases #$phases (delete 'restore-emacs-pdmp) (delete 'strip-double-wrap))))))) -- cgit v1.2.3 From 1110479d2d4dc69fc66eadb4a6c24ca2f13afa93 Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sun, 15 May 2022 00:11:41 +0200 Subject: gnu: emacs-wide-int: Use new package style. * gnu/packages/emacs.scm (emacs-wide-int)[arguments]: Convert to list of G-Expressions. [inputs]: Use modify-inputs. --- gnu/packages/emacs.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index 4c63b4ab5b..a5d246f7a5 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -443,7 +443,7 @@ editor (with wide ints)" ) (arguments (substitute-keyword-arguments (package-arguments emacs) ((#:configure-flags flags) - `(cons "--with-wide-int" ,flags)))))) + #~(cons "--with-wide-int" #$flags)))))) (define-public guile-emacs (let ((commit "41120e0f595b16387eebfbf731fff70481de1b4b") -- cgit v1.2.3 From c54087a853f6e7f2f755339db50569835a80dc7e Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 15 May 2022 15:51:14 +0300 Subject: gnu: efivar: Use correct compiler when cross compiling. * gnu/packages/linux.scm (efivar)[arguments]: Adjust make-flags to set CC and not CC_FOR_BUILD. --- gnu/packages/linux.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index f8b9a29843..95f2e96f17 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -6758,7 +6758,7 @@ under OpenGL graphics workloads.") #:make-flags #~(list (string-append "prefix=" #$output) (string-append "libdir=" #$output "/lib") - (string-append "CC_FOR_BUILD=" #$(cc-for-target)) + (string-append "CC=" #$(cc-for-target)) (string-append "LDFLAGS=-Wl,-rpath=" #$output "/lib")) #:phases #~(modify-phases %standard-phases -- cgit v1.2.3 From 00838bd41ce7f1e4bf0d9d65bcf0f96fa781f6f4 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 15 May 2022 15:56:13 +0300 Subject: gnu: efibootmgr: Fix cross compiling. Fixes . * gnu/packages/linux.scm (efibootmgr)[arguments]: When cross-compiling add make-flags to find and use the correct binaries and libraries. --- gnu/packages/linux.scm | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 95f2e96f17..eb92ac3f9f 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -6805,14 +6805,22 @@ interface to the variable facility of UEFI boot firmware.") (arguments (list #:tests? #f ;no tests - #:make-flags #~(list (string-append "prefix=" #$output) - (string-append "libdir=" #$output "/lib") - ;; EFIDIR denotes a subdirectory relative to the - ;; EFI System Partition where the loader will be - ;; installed (known as OS_VENDOR in the code). - ;; GRUB overrides this, as such it's only used if - ;; nothing else is specified on the command line. - "EFIDIR=gnu") + #:make-flags + #~(append (list (string-append "prefix=" #$output) + (string-append "libdir=" #$output "/lib") + ;; EFIDIR denotes a subdirectory relative to the + ;; EFI System Partition where the loader will be + ;; installed (known as OS_VENDOR in the code). + ;; GRUB overrides this, as such it's only used if + ;; nothing else is specified on the command line. + "EFIDIR=gnu") + #$(if (%current-target-system) + #~(list + (string-append "CC=" #$(cc-for-target)) + (string-append "PKG_CONFIG=" #$(pkg-config-for-target)) + (string-append "EXTRAINCDIRS=" + #$(this-package-input "efivar") "/include")) + #~'())) #:phases #~(modify-phases %standard-phases (delete 'configure)))) (native-inputs (list pkg-config)) -- cgit v1.2.3 From 9860c90e8e5362e0e843efbd45f4563b9746a196 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 15 May 2022 15:59:07 +0300 Subject: gnu: efibootmgr: Update to new upstream location. * gnu/packages/linux.scm (efibootmgr)[source, home-page]: Update to new upstream URI. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index eb92ac3f9f..0b30108d7c 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -6787,7 +6787,7 @@ interface to the variable facility of UEFI boot firmware.") (origin (method git-fetch) (uri (git-reference - (url "https://github.com/rhinstaller/efibootmgr") + (url "https://github.com/rhboot/efibootmgr") (commit version))) (file-name (git-file-name name version)) (sha256 @@ -6826,7 +6826,7 @@ interface to the variable facility of UEFI boot firmware.") (list pkg-config)) (inputs (list efivar popt)) - (home-page "https://github.com/rhinstaller/efibootmgr") + (home-page "https://github.com/rhboot/efibootmgr") (synopsis "Modify the Extensible Firmware Interface (EFI) boot manager") (description "@code{efibootmgr} is a user-space application to modify the Intel -- cgit v1.2.3 From ebb43029506d994bee0c2b890881fd61a0b0c202 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 15 May 2022 20:08:51 +0300 Subject: gnu: openssl-3.0: Update to 3.0.3. * gnu/packages/tls.scm (openssl-3.0): Update to 3.0.3. --- gnu/packages/tls.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm index e413f3c24f..cf50a88410 100644 --- a/gnu/packages/tls.scm +++ b/gnu/packages/tls.scm @@ -525,7 +525,7 @@ OpenSSL for TARGET." (define-public openssl-3.0 (package (inherit openssl) - (version "3.0.2") + (version "3.0.3") (source (origin (method url-fetch) (uri (list (string-append "https://www.openssl.org/source/openssl-" @@ -538,7 +538,7 @@ OpenSSL for TARGET." (patches (search-patches "openssl-3.0-c-rehash-in.patch")) (sha256 (base32 - "0qyvvw8n97f0gs786l2dkxnmi3hs344mxplw7jp5cisdmp71rscq")))) + "02wcan5izwsxg6vl5fzkqq4icwi7cp4hrj327h05zppirsnph07f")))) (arguments (substitute-keyword-arguments (package-arguments openssl) ((#:phases phases '%standard-phases) -- cgit v1.2.3 From 40a729a0e6f1d660b942241416c1e2c567616d4d Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sun, 15 May 2022 20:20:08 -0400 Subject: gnu: Fix the build of wicd. Fixes . * gnu/packages/check.scm (python2-pytest-cov, python2-freezegun): Define without package-with-python2. * gnu/packages/python-xyz.scm (python2-babel): Likewise. * gnu/packages/time.scm (python2-dateutil): Likwise. --- gnu/packages/check.scm | 62 ++++++++++++++++++++++++++++++++++++++++++++- gnu/packages/python-xyz.scm | 32 ++++++++++++++++++++++- gnu/packages/time.scm | 39 +++++++++++++++++++++++++++- 3 files changed, 130 insertions(+), 3 deletions(-) diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index 8e6576208c..8c161a4a4f 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -1178,6 +1178,38 @@ distributed testing in both @code{load} and @code{each} modes. It also supports coverage of subprocesses.") (license license:expat))) +(define-public python2-pytest-cov + (package + (name "python2-pytest-cov") + (version "2.8.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pytest-cov" version)) + (sha256 + (base32 "0avzlk9p4nc44k7lpx9109dybq71xqnggxb9f4hp0l64pbc44ryc")))) + (build-system python-build-system) + (arguments + `(#:python ,python-2 + #:phases + (modify-phases %standard-phases + (replace 'check + (lambda _ + ;; Options taken from tox.ini. + ;; TODO: make "--restructuredtext" tests pass. They currently fail + ;; with "Duplicate implicit target name". + (invoke "python" "./setup.py" "check" + "--strict" "--metadata")))))) + (propagated-inputs + (list python2-coverage python2-pytest)) + (home-page "https://github.com/pytest-dev/pytest-cov") + (synopsis "Pytest plugin for measuring coverage") + (description + "Pytest-cov produces coverage reports. It supports centralised testing and +distributed testing in both @code{load} and @code{each} modes. It also +supports coverage of subprocesses.") + (license license:expat))) + (define-public python-pytest-httpserver (package (name "python-pytest-httpserver") @@ -2935,7 +2967,35 @@ time by mocking the datetime module.") (license license:asl2.0))) (define-public python2-freezegun - (package-with-python2 python-freezegun)) + (package + (name "python2-freezegun") + (version "0.3.14") + (source + (origin + (method url-fetch) + (uri (pypi-uri "freezegun" version)) + (sha256 + (base32 "0al75mk829j1izxi760b7yjnknjihyfhp2mvi5qiyrxb9cpxwqk2")))) + (build-system python-build-system) + (native-inputs + (list python2-mock python2-pytest)) + (propagated-inputs + (list python2-six python2-dateutil)) + (arguments + `(#:python ,python-2 + #:phases + (modify-phases %standard-phases + ;; The tests are normally executed via `make test`, but the PyPi + ;; package does not include the Makefile. + (replace 'check + (lambda _ + (invoke "pytest" "-vv")))))) + (home-page "https://github.com/spulec/freezegun") + (synopsis "Test utility for mocking the datetime module") + (description + "FreezeGun is a library that allows your python tests to travel through +time by mocking the datetime module.") + (license license:asl2.0))) (define-public python-flexmock (package diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 020f078dee..199fcf5fb8 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -1283,7 +1283,37 @@ etc.") (license license:bsd-3))) (define-public python2-babel - (package-with-python2 python-babel)) + (package + (name "python2-babel") + (version "2.9.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "Babel" version)) + (sha256 + (base32 + "018yg7g2pa6vjixx1nx41cfispgfi0azzp0a1chlycbj8jsil0ys")))) + (build-system python-build-system) + (native-inputs + (list python2-freezegun python2-pytest tzdata-for-tests)) + (propagated-inputs + (list python2-pytz)) + (arguments + `(#:python ,python-2 + #:phases (modify-phases %standard-phases + (replace 'check + (lambda _ + (invoke "pytest" "-vv")))))) + (home-page "https://babel.pocoo.org/") + (synopsis + "Tools for internationalizing Python applications") + (description + "Babel is composed of two major parts: +- tools to build and work with gettext message catalogs +- a Python interface to the CLDR (Common Locale Data Repository), providing +access to various locale display names, localized number and date formatting, +etc.") + (license license:bsd-3))) (define-public python2-backport-ssl-match-hostname (package diff --git a/gnu/packages/time.scm b/gnu/packages/time.scm index 9b57fe41fb..ca5e462680 100644 --- a/gnu/packages/time.scm +++ b/gnu/packages/time.scm @@ -233,7 +233,44 @@ datetime module, available in Python 2.3+.") (license (list bsd-3 asl2.0)))) (define-public python2-dateutil - (package-with-python2 python-dateutil)) + (package + (name "python2-dateutil") + (version "2.8.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "python-dateutil" version)) + (sha256 + (base32 + "11iy7m4bp2lgfkcl0r6xzf34bvk7ppjmsyn2ygfikbi72v6cl8q1")))) + (build-system python-build-system) + (arguments + `(#:python ,python-2 + #:phases (modify-phases %standard-phases + (replace 'check + (lambda _ + ;; Delete tests that depend on "freezegun" to avoid a + ;; circular dependency. + (delete-file "dateutil/test/test_utils.py") + (delete-file "dateutil/test/test_rrule.py") + + ;; XXX: Fails to get timezone from /etc/localtime. + (delete-file "dateutil/test/test_tz.py") + + (invoke "pytest" "-vv")))))) + (native-inputs + (list python2-pytest python2-pytest-cov python2-setuptools-scm)) + (propagated-inputs + (list python2-six)) + (home-page "https://dateutil.readthedocs.io/en/stable/") + (synopsis "Extensions to the standard datetime module") + (description + "The dateutil module provides powerful extensions to the standard +datetime module, available in Python 2.3+.") + ;; The license was changed from the three-clause BSD license to a dual + ;; Apache 2.0/BSD-3 variant at 2017-12-01. Some code is only available as + ;; BSD-3 still; but all new code is dual licensed (the user can choose). + (license (list bsd-3 asl2.0)))) (define-public python-parsedatetime (package -- cgit v1.2.3