Created attachment 252846 [details] Patch for mpi4py 4.0.0 - Update to 4.0.0 - Move blocks to placate portlint - Take maintainership QA portlint: OK poudriere: OK
1. Sort options: -USES= python pkgconfig -USE_PYTHON= distutils cython autoplist concurrent +USES= pkgconfig python +USE_PYTHON= autoplist concurrent cython distutils 2. If you have USE_PYTHON=cython do you need: BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}cython3>3.0.0:lang/cython3@${PY_FLAVOR} ?
(In reply to Vladimir Druzenko from comment #1) Thanks for the feedback. 1) OK 2) I need the BUILD_DEPENDS, otherwise py39-cython-0.29.37 is installed with only USE_PYTHON=cython, and cython > 3.0.0 is needed by the port. With the BUILD_DEPENDS, I can probably get rid of USE_PYTHON=cython. I'll upload a new patch.
Created attachment 252848 [details] Patch for mpi4py 4.0.0 v2 Update patch according to comments
(In reply to Laurent Chardon from comment #2) > otherwise py39-cython-0.29.37 Default python in ports is 3.11.
(In reply to Laurent Chardon from comment #2) USES=cython => lang/cython Maybe you don't need USES=cython?
(In reply to Vladimir Druzenko from comment #4) Sorry, that was a typo. I meant py311-cython-0.29.37.
(In reply to Vladimir Druzenko from comment #5) I'm not sure what you mean
(In reply to Laurent Chardon from comment #7) Can we remove cython from USES?
(In reply to Vladimir Druzenko from comment #8) That's what I thought you meant. I removed it already from USE_PYTHON. I've tested that it works. It's not in USES. From my second patch: >+USES= pkgconfig python >+USE_PYTHON= autoplist concurrent distutils
$ grep mpi4py /usr/ports/INDEX-14 | wc -l 65 Are you sure 4.0.0 is fully compatible with 3.1.6? And we don't need exp-run?
Created attachment 252888 [details] git patch 3 Two changes: - BSD2CLAUSE -> BSD3CLAUSE, to reflect upstream change - Update CONFLICTS_INSTALLs for current version
(In reply to Vladimir Druzenko from comment #10) I did some simple tests, but I can't be sure that it won't break anything. I'm OK with an exp-run if you are willing to set it up, but I don't know how useful it will really be, because a lot of the dependencies are run-time. That being said, it won't hurt to do an exp-run and have a look.
(In reply to Laurent Chardon from comment #12) What upstream write about back compatibility? Also, why do we need line "SLAVEDIRS=net/py-mpi4py-mpich"? Can't find how and where it used.
(In reply to Vladimir Druzenko from comment #13) I'm not sure what SLAVESDIR is used for. I see that other ports have it. It seems that this line was added recently in Bug 272949. I've cc'd the author. As for the changes, upstream mentions that they are not all backward-compatible. However they have some mitigations in place, and the rest seems fairly edge-case to me, but I could be wrong. See "Backward-incompatible changes" in URL.
(In reply to Laurent Chardon from comment #14) I already found this commit, but I don't see there SLAVEDIRS used. Ports framework don't know this option/variable either. I removed this line and build both ports net/py-mpi4py-mpich and net/py-mpi4py without errors. It looks scary to me, who is not in the know: Backward-incompatible changes: * Python 2 is no longer supported, Python 3.6+ is required, but typing stubs are supported for Python 3.8+. * The Intracomm.Create_group() method is no longer defined in the base Comm class. * Group.Compare() and Comm.Compare() are no longer class methods but instance methods. Existing codes using the former class methods are expected to continue working. * Group.Translate_ranks() is no longer a class method but an instance method. Existing codes using the former class method are expected to continue working. * The LB and UB datatypes are no longer available, use Datatype.Create_resized() instead. * The HOST predefined attribute key is no longer available. * The MPI.memory class has been renamed to MPI.buffer. The old name is still available as an alias to the new name. * The mpi4py.dl module is no longer available. * The mpi4py.get_config function returns an empty dictionary.
(In reply to Laurent Chardon from comment #14) Hello, SLAVESDIR is not a macro, just a warning. It means that this is a MASTER port, and if you modify it, the ports referenced by SLAVESDIR will be affected.
(In reply to Thierry Thomas from comment #16) So this is some kind of comment?
(In reply to Vladimir Druzenko from comment #17) Yes, it is.
(In reply to Thierry Thomas from comment #18) Thanks. But what can we do with compatibility with other ports?… In most cases, exp-run can only handle build failures. On the other hand, it's better than nothing.
If you want an exp-run , assign this PR to portmgr
(In reply to Vladimir Druzenko from comment #19) Usually Python programs set limits if they might fail with a too recent version (resp. too old) of their dependencies, and the ports would stop at the configure stage. If they build, we can only hope that all goes well!
(In reply to Thierry Thomas from comment #21) We are in middle of Q3 - have time to fix consumers till Q4. Even if the exp-run is successful, we commit, and then runtime errors are discovered in consumers, we can always roll back the version update. (In reply to Antoine Brodin from comment #20) Done. Thanks!
Exp-run looks fine
(In reply to Antoine Brodin from comment #23) Thanks, Antoine! yuri, cmt, mr, thierry, sunpoet, stephen, henrik@gulbra.net, teodorsigaev@gmail.com, your ports depends on this port. If you have the opportunity, please check how your ports work with net/py-mpi4py version 4.0. They are build fine, but it's python - many errors can only be seen at runtime. If no one has any objections, I plan to commit within the next 2-3 days. Full list (grep mpi4py INDEX-14 | awk -F'[/|]' '{print $5"/"$6}'): cad/PrusaSlicer cad/appcsxcad cad/csxcad cad/freecad cad/gmsh cad/horizon-eda cad/kicad cad/kicad-devel cad/kicad-doc cad/kicad-library-footprints cad/kicad-library-footprints-devel cad/kicad-library-packages3d cad/kicad-library-packages3d-devel cad/kicad-library-symbols cad/kicad-library-symbols-devel cad/kicad-library-templates cad/kicad-library-templates-devel cad/librepcb cad/opencascade cad/py-gmsh cad/py-pygmsh cad/qcsxcad devel/py-pyina french/aster french/homard graphics/alizams graphics/cloudcompare graphics/elastix graphics/f3d graphics/mirtk graphics/pcl-pointclouds graphics/py-f3d graphics/py-fury graphics/py-mayavi graphics/py-pyvista graphics/simpleitk math/deal.ii math/hyperdeal math/octave-forge math/octave-forge-bim math/octave-forge-msh math/octave-forge-secs1d math/octave-forge-secs3d math/octave-forge-sole math/py-topologic math/topologic math/vtk9 misc/adios2 misc/visp science/InsightToolkit science/code_saturne science/elmerfem science/liggghts science/mmg science/openems science/paraview science/py-PyFR science/py-boutdata science/py-boututils science/py-pyprecice science/py-vedo science/py-xbout science/ttk
(In reply to Vladimir Druzenko from comment #24) Ok. Commiting…
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=907f3f00bc41d3cc836425afc8eba4bc5510da65 commit 907f3f00bc41d3cc836425afc8eba4bc5510da65 Author: Laurent Chardon <laurent.chardon@gmail.com> AuthorDate: 2024-09-01 15:48:07 +0000 Commit: Vladimir Druzenko <vvd@FreeBSD.org> CommitDate: 2024-09-01 15:57:59 +0000 net/py-mpi4py: Update 3.1.6 → 4.0.0 Backward-incompatible changes: * Python 2 is no longer supported, Python 3.6+ is required, but typing stubs are supported for Python 3.8+. * The Intracomm.Create_group() method is no longer defined in the base Comm class. * Group.Compare() and Comm.Compare() are no longer class methods but instance methods. Existing codes using the former class methods are expected to continue working. * Group.Translate_ranks() is no longer a class method but an instance method. Existing codes using the former class method are expected to continue working. * The LB and UB datatypes are no longer available, use Datatype.Create_resized() instead. * The HOST predefined attribute key is no longer available. * The MPI.memory class has been renamed to MPI.buffer. The old name is still available as an alias to the new name. * The mpi4py.dl module is no longer available. * The mpi4py.get_config function returns an empty dictionary. Changelog: https://github.com/mpi4py/mpi4py/releases/tag/4.0.0 Exp-run looks fine. Take maintainership. PR: 280883 net/py-mpi4py/Makefile | 51 +++++++++++++++---------------- net/py-mpi4py/distinfo | 6 ++-- net/py-mpi4py/files/patch-setup.py (gone) | 25 --------------- 3 files changed, 27 insertions(+), 55 deletions(-)
Thanks!
Thank you!