From 84a07b5e5eaf17e83b2326a20142cec3f579d4bf Mon Sep 17 00:00:00 2001 From: Nicolas Graves Date: Fri, 17 Oct 2025 16:13:02 +0200 Subject: [PATCH] gnu: python-ipython-sql: Update to 0.5.0-0.e21bc64. * gnu/packages/python-xyz.scm (python-ipython-sql): Update to 0.5.0-0.e21bc64. [build-system]: Switch to pyproject-build-system. [arguments]<#:tests?>: Disable them, update comment. <#:phases>: Replace 'check phase, remove phase 'permit-newer-prettytable. [native-inputs]: Add python-setuptools. [propagated-inputs]: Remove python-six. Replace python-sqlalchemy by python-sqlalchemy-2. Change-Id: I88ded8e0427f7b0c3d7a6b7a59ce38079836d508 Signed-off-by: Sharlatan Hellseher --- gnu/packages/python-xyz.scm | 37 +++++++++++++++++++++++-------------- 1 file changed, 23 insertions(+), 14 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index f834920d4a70e2ce0a76cc5b603fc3f8c8ba2034..b78a3cc8f01833e32552a2d4a81f2a623d3be2c1 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -14544,33 +14544,42 @@ profile, launches a cluster and returns a view. On program exit it shuts the cluster down and deletes the throwaway profile.") (license license:expat))) +;; TODO: Package python-jupysql which is the maintained fork of this one. (define-public python-ipython-sql (package (name "python-ipython-sql") - (version "0.4.1") + (properties '((commit . "e21bc64e172270311d9103602e1c2ec1bcdd5aa8") + (revision . "0"))) + (version (git-version "0.5.0" + (assoc-ref properties 'revision) + (assoc-ref properties 'commit))) (source (origin - (method url-fetch) - (uri (pypi-uri "ipython-sql" version)) + (method git-fetch) + (uri (git-reference + (url "https://github.com/catherinedevlin/ipython-sql") + (commit (assoc-ref properties 'commit)))) + (file-name (git-file-name name version)) (sha256 - (base32 "1r6rz8jgrqzhkf2flwjw75d96g8l7kykmx5wli3q1988w96391ip")))) - (build-system python-build-system) + (base32 "0palwgr7lnar8ykifzhf1qach206bf1xa1zkji2adk9pr9ajsiix")))) + (build-system pyproject-build-system) (arguments - (list #:tests? #f ;must run under IPython + (list #:tests? #f ;Fail because of prettytable. #:phases #~(modify-phases %standard-phases - (add-after 'unpack 'permit-newer-prettytable - ;; See https://github.com/catherinedevlin/ipython-sql/issues/202 - (lambda _ - (substitute* "setup.py" - (("prettytable<1") - "prettytable"))))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (setenv "HOME" (getcwd)) + (if tests? + (invoke "ipython" "-c" + "import pytest; pytest.main(['.'])") + (format #t "test suite not run.~%"))))))) + (native-inputs (list python-pytest python-setuptools)) (propagated-inputs (list python-ipython python-ipython-genutils python-prettytable - python-six - python-sqlalchemy + python-sqlalchemy-2 python-sqlparse)) (home-page "https://github.com/catherinedevlin/ipython-sql") (synopsis "RDBMS access via IPython")