From: tornaria <tornaria@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: [PR PATCH] python3-sympy: update to 1.10.1.
Date: Tue, 29 Mar 2022 00:38:46 +0200 [thread overview]
Message-ID: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-36397@inbox.vuxu.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 687 bytes --]
There is a new pull request by tornaria against master on the void-packages repository
https://github.com/tornaria/void-packages sympy-1.10
https://github.com/void-linux/void-packages/pull/36397
python3-sympy: update to 1.10.1.
Also fix integer_nthroot(2, 10**10) in 32 bit, reported upstream (https://github.com/sympy/sympy/issues/18374#issuecomment-1081196879 and https://github.com/aleaxit/gmpy/issues/257#issuecomment-1073426165)
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
A patch file from https://github.com/void-linux/void-packages/pull/36397.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-sympy-1.10-36397.patch --]
[-- Type: text/x-diff, Size: 2433 bytes --]
From d9339d489a1147447cfacfeb77a790cf2dd9c57e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Sat, 19 Mar 2022 21:55:20 -0300
Subject: [PATCH] python3-sympy: update to 1.10.1.
Also fix integer_nthroot(2, 10**10) in 32 bit, reported upstream.
---
.../patches/fix_integer_nthroot.patch | 26 +++++++++++++++++++
srcpkgs/python3-sympy/template | 4 +--
2 files changed, 28 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/python3-sympy/patches/fix_integer_nthroot.patch
diff --git a/srcpkgs/python3-sympy/patches/fix_integer_nthroot.patch b/srcpkgs/python3-sympy/patches/fix_integer_nthroot.patch
new file mode 100644
index 000000000000..0f4860a6c9e1
--- /dev/null
+++ b/srcpkgs/python3-sympy/patches/fix_integer_nthroot.patch
@@ -0,0 +1,26 @@
+Fix integer_nthroot(2, 10**10) in 32 bit.
+
+See: https://github.com/sympy/sympy/issues/18374#issuecomment-1081196879
+
+diff --git a/sympy/core/power.py b/sympy/core/power.py
+index 59ab7c53a4..ae3ee25c93 100644
+--- a/sympy/core/power.py
++++ b/sympy/core/power.py
+@@ -21,6 +21,8 @@
+
+ from mpmath.libmp import sqrtrem as mpmath_sqrtrem
+
++from ctypes import c_ulong
++ULONG_MAX = c_ulong(-1).value
+
+
+ def isqrt(n):
+@@ -74,7 +76,7 @@ def integer_nthroot(y, n):
+ raise ValueError("y must be nonnegative")
+ if n < 1:
+ raise ValueError("n must be positive")
+- if HAS_GMPY and n < 2**63:
++ if HAS_GMPY and n <= ULONG_MAX:
+ # Currently it works only for n < 2**63, else it produces TypeError
+ # sympy issue: https://github.com/sympy/sympy/issues/18374
+ # gmpy2 issue: https://github.com/aleaxit/gmpy/issues/257
diff --git a/srcpkgs/python3-sympy/template b/srcpkgs/python3-sympy/template
index 807f0db5f1a2..3bb4df3bffdf 100644
--- a/srcpkgs/python3-sympy/template
+++ b/srcpkgs/python3-sympy/template
@@ -1,6 +1,6 @@
# Template file for 'python3-sympy'
pkgname=python3-sympy
-version=1.9
+version=1.10.1
revision=1
wrksrc="sympy-${version}"
build_style=python3-module
@@ -12,7 +12,7 @@ maintainer="Alessio Sergi <al3hex@gmail.com>"
license="BSD-3-Clause"
homepage="https://sympy.org/"
distfiles="${PYPI_SITE}/s/sympy/sympy-${version}.tar.gz"
-checksum=c7a880e229df96759f955d4f3970d4cabce79f60f5b18830c08b90ce77cd5fdc
+checksum=5939eeffdf9e152172601463626c022a2c27e75cf6278de8d401d50c9d58787b
post_install() {
vman doc/man/isympy.1
next reply other threads:[~2022-03-28 22:38 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-28 22:38 tornaria [this message]
2022-03-30 15:49 ` tornaria
2022-03-31 14:37 ` [PR PATCH] [Merged]: " leahneukirchen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-36397@inbox.vuxu.org \
--to=tornaria@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).