If we can get back to the original topic of this thread, I would like to 
report on the experiment I just finished.  That experiment was to update 
the python3 spkg to Python-3.13.3 (the latest python release) and then 
build Sage 10.7.b0 using the updated spkg and the usual build script that I 
always use for the Sage_macOS app.  (That script uses Sage's python3 spkg 
and Sages gfortran spkg and installs 42 optional packages without using 
anything from homebrew or conda.)

Updating the python3 spkg required changing a grand total of 4 lines of 
text: 
* the version number was changed in package-version.txt
* 2 SHA hashes were updated in checksums.in
* 1 line was changed in spkg-build.in to stop testing whether the crypt 
module can be imported.  (The crypt module was removed from Python 3.13..)

With those 4 changes, Sage 10.7.b0 built without any issues whatsoever, 
python 3.13 included.

Starting from the resulting sage build I was then able to assemble a Sage 
10.7 macOS app using our standard script for that job.  Once I finish 
getting Apple to notarize the app I will post it as a pre-release on our 
github site.

The obvious questions which this raises and which have still not been 
answered here are:  What is so wrong with this process?  Why do we have to 
break it?  Why can't we at least leave the Sage spkg in place until there 
is an actual, tested, working replacement for it?  (I am ignoring the other 
obvious question: what is so difficult about changing 4 lines of text in an 
spkg directory?)

I will attach the full patch file for updating the python3 spkg to version 
3.13.3, in case someone wants to convert it to a PR.

- Marc



On Friday, April 11, 2025 at 3:13:31 PM UTC-5 dim...@gmail.com wrote:

>
>
> On 11 April 2025 11:28:17 GMT-05:00, Marc Culler <marc....@gmail.com> 
> wrote:
> >
> >
> >On Thursday, April 10, 2025 at 9:53:04 PM UTC-5 Tobias wrote:
> >
> >
> >With all non-python pre-reqs in place, 
> >just run./bootstrap and pip to build sagelib, that's all. 
> >No need to worry about a dodgy custom venv, 
> >unhappy ./configure, etc.
> >
> >
> >> Interesting, where can I find a list of the non-python pre-reqs? 
> >
> >
> https://github.com/sagemath/sage/blob/871ba9daed15374d6b2ff1c533970f44b70f21e9/pyproject.toml#L101-L162
> >
> >
> >That pyproject.toml file contains these lines:
> >
> ># Python 3.11 is the minimum supported version
> >target-version = "py311"
> >
> >It would be extremely helpful to know how the mesonpy backend uses that 
> >target-version value. Specifically, if I have compiled a python 
> >distribution and installed it somewhere on my system, and if I am using 
> the 
> >pip from my installation to build a wheel, would pymeson build the wheel 
> >for my version of python, or might it (as Dima suggests) build for some 
> >other version that it finds somewhere else on the system which happens to 
> >meet the minimum version requirement?
>
> I tried running "meson setup", which is probably meant for setting up new 
> projects rather than getting info on the setup and dependencies.
>
> I think the use of meson for building via pip or "uv pip" in a venv works 
> correctly, as expected, it uses the python of the venv, and not something 
> it finds somewhere...
>
> Dima
>
> >
> >- Marc
> >
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion visit 
https://groups.google.com/d/msgid/sage-devel/15523de1-226e-4b3e-bd6d-a91ece173cabn%40googlegroups.com.
diff --git a/build/pkgs/python3/checksums.ini b/build/pkgs/python3/checksums.ini
index 3bac47d26a6..e6fa77b9643 100644
--- a/build/pkgs/python3/checksums.ini
+++ b/build/pkgs/python3/checksums.ini
@@ -1,4 +1,4 @@
 tarball=Python-VERSION.tar.xz
-sha1=d9b83c17a717e1cbd3ab6bd14cfe3e508e6d87b2
-sha256=fa8a2e12c5e620b09f53e65bcd87550d2e5a1e2e04bf8ba991dcc55113876397
+sha1=f26085cf12daef7b60b8a6fe93ef988b9a094aea
+sha256=40f868bcbdeb8149a3149580bb9bfd407b3321cd48f0be631af955ac92c0e041
 upstream_url=https://www.python.org/ftp/python/VERSION/Python-VERSION.tar.xz
diff --git a/build/pkgs/python3/package-version.txt b/build/pkgs/python3/package-version.txt
index d9506ceba51..2c20ac9bea3 100644
--- a/build/pkgs/python3/package-version.txt
+++ b/build/pkgs/python3/package-version.txt
@@ -1 +1 @@
-3.12.5
+3.13.3
diff --git a/build/pkgs/python3/spkg-build.in b/build/pkgs/python3/spkg-build.in
index f2a8b4311db..64ae52f43dd 100644
--- a/build/pkgs/python3/spkg-build.in
+++ b/build/pkgs/python3/spkg-build.in
@@ -108,7 +108,7 @@ fi
 echo "Testing importing of various modules..."
 import_errors=false
 # Issue #31160: We no longer check for readline here.
-test_modules="ctypes math hashlib crypt socket zlib sqlite3 ssl"
+test_modules="ctypes math hashlib socket zlib sqlite3 ssl"
 if [ "$UNAME" = "Darwin" ]; then
     test_modules="$test_modules _scproxy"
 fi

Reply via email to