diff options
| author | Liguros - Gitlab CI/CD [develop] <gitlab@liguros.net> | 2024-12-01 18:50:22 +0000 |
|---|---|---|
| committer | Liguros - Gitlab CI/CD [develop] <gitlab@liguros.net> | 2024-12-01 18:50:22 +0000 |
| commit | 672d9ecbb4f1f9c0928f12ef89a0c284234bf0b2 (patch) | |
| tree | 0a54a5207e6754b67749b06e24ff73b162e111aa /dev-python | |
| parent | f4abe2e58f5ad33fa63953deb34376ad5a696be4 (diff) | |
| download | baldeagleos-repo-672d9ecbb4f1f9c0928f12ef89a0c284234bf0b2.tar.gz baldeagleos-repo-672d9ecbb4f1f9c0928f12ef89a0c284234bf0b2.tar.xz baldeagleos-repo-672d9ecbb4f1f9c0928f12ef89a0c284234bf0b2.zip | |
Adding metadata
Diffstat (limited to 'dev-python')
21 files changed, 1212 insertions, 22 deletions
diff --git a/dev-python/langdetect/Manifest b/dev-python/langdetect/Manifest index a11d7c268c91..37a64204a00a 100644 --- a/dev-python/langdetect/Manifest +++ b/dev-python/langdetect/Manifest @@ -1 +1,3 @@ DIST langdetect-1.0.9.tar.gz 981474 BLAKE2B ea8a9c3f16a2987c080742473bff4f2c1503f53fb3c2b40b0b1d6212bb6133ea22dce7864ffcfb8968c3a46b157d45cb3e2cf6f84bdbed0266cc716a853b032c SHA512 7558d674c47b080c79e43a00a25d2c7f77188cf60bea2cecb3bebb803d75e1aa42b43c74bd26ea1b541f4cb927421908882cbec01a91f0913984217e71ccc8db +EBUILD langdetect-1.0.9.ebuild 494 BLAKE2B 9b3521c5721afa49a58e0c35267f7d82bb56bd7e1d6d3152be0d36cd220180a526cb20b90b1113fbf0fff4a512137570f0b3bcf864498b7b7cc00403cb61ca27 SHA512 16d311400bf84a5f04e15f3da4b68b2810e4b005009f4d03dc8a487176dfc294403c976c412c83dcfa8084a49ef7b7d5389b43fb2ba446ce107ce4595e3558c6 +MISC metadata.xml 457 BLAKE2B 630128a3e982b6d60cc7b9f74c79fcb5ee47a71a02c73a50af9da8cedb6fad8e20a7f74b881e5b25c6483b92c9edbd56552cd38b2d9cbfa8b3eb4530facea969 SHA512 674f4f5cd809c6c77bc14e0f5687fa972bef14bdfa0b3343c5d66b7163eef1906eb87d060c8288732f825de71dce291ad0b841a5f2f0dd230f957b5687e45d45 diff --git a/dev-python/langdetect/files/langdetect-1.0.9-explicit-config.patch b/dev-python/langdetect/files/langdetect-1.0.9-explicit-config.patch deleted file mode 100644 index 637368d2f237..000000000000 --- a/dev-python/langdetect/files/langdetect-1.0.9-explicit-config.patch +++ /dev/null @@ -1,13 +0,0 @@ -Fix "Package 'langdetect.profiles' is absent from the `packages` configuration." - ---- a/setup.py -+++ b/setup.py -@@ -18,7 +18,7 @@ setup( - author_email='michal.danilak@gmail.com', - url='https://github.com/Mimino666/langdetect', - keywords='language detection library', -- packages=['langdetect', 'langdetect.utils', 'langdetect.tests'], -+ packages=['langdetect', 'langdetect.utils', 'langdetect.tests', 'langdetect.profiles'], - include_package_data=True, - install_requires=['six'], - license='MIT', diff --git a/dev-python/langdetect/langdetect-1.0.9.ebuild b/dev-python/langdetect/langdetect-1.0.9.ebuild index eb2586280d80..56733bbffc48 100644 --- a/dev-python/langdetect/langdetect-1.0.9.ebuild +++ b/dev-python/langdetect/langdetect-1.0.9.ebuild @@ -1,4 +1,4 @@ -# Copyright 2022-2024 Gentoo Authors +# Copyright 2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -19,6 +19,4 @@ KEYWORDS="~amd64" RDEPEND="dev-python/six[${PYTHON_USEDEP}]" -PATCHES=( "${FILESDIR}/${P}-explicit-config.patch" ) - distutils_enable_tests unittest diff --git a/dev-python/langdetect/metadata.xml b/dev-python/langdetect/metadata.xml index c0f74ac187e2..020e07f2a3dd 100644 --- a/dev-python/langdetect/metadata.xml +++ b/dev-python/langdetect/metadata.xml @@ -2,9 +2,11 @@ <!DOCTYPE pkgmetadata SYSTEM "https://liguros.gitlab.io/dtd/metadata.dtd"> <pkgmetadata> <maintainer type="person"> - <email>pastalian46@gmail.com</email> - <name>Takuya Wakazono</name> + <email>marcin.deranek@slonko.net</email> + <name>Marcin Deranek</name> </maintainer> - - <origin>gentoo-guru-overlay</origin> + <upstream> + <bugs-to>https://github.com/Mimino666/langdetect/issues</bugs-to> + </upstream> + <origin>slonko-overlay</origin> </pkgmetadata>
\ No newline at end of file diff --git a/dev-python/matplotlib/Manifest b/dev-python/matplotlib/Manifest index ecf6bcb4c140..670abb3c3530 100644 --- a/dev-python/matplotlib/Manifest +++ b/dev-python/matplotlib/Manifest @@ -3,3 +3,4 @@ DIST matplotlib-3.10.0rc1.tar.gz 36682106 BLAKE2B c6948deb4749a08fa84e0a72d4c687 DIST matplotlib-3.9.0.tar.gz 36069890 BLAKE2B 02ddb25901b5a93a8daf6f26c98b92d5e35abe2e98783b039928338abb1d628adbf3fd4786c08cb1610bf405cb558ca31fc12dbde77ec5f2a633143c7ea659a1 SHA512 135ee2f97c26cb60479cc10bf8a833384c393993d8a905ab869f4c73b91a50ffa596f84ce349af7f1a0b08a21e1906394cf6a702bb567a9c3999d40f54974326 DIST matplotlib-3.9.1.tar.gz 36084124 BLAKE2B b7cc9e219664849411cc3133afbdb676f956c943f92d447ba5cca0467da56d1575796fe1046e7503e6d7c4dfdfad6e5181404f331ed7ac1397c8c61f4a30bd23 SHA512 a1d48c42a5f4f04b57e34d25df842917e6380b8d6b6d1018c9b630cbbea4619b1d75729a218a6f52b63d4a61c2204bb26ad8f741566f84e41ca73190e419f672 DIST matplotlib-3.9.2.tar.gz 36088381 BLAKE2B c84d08b7afa1f0460b5b57447481ef90f22380c02d20227c3a45b6f603032a11359b223397f18c8dc9111ad36fbd7510e2d5496502b3202e3074ddf8e8258bb7 SHA512 4b7437eeb085915a90db64600d0e6c59501ea1513d07b8298a159a763461ef6947a0cb332dcde1a5f0996840320ca7dd1d972d7514ff6f87b036fc631e79885f +DIST matplotlib-3.9.3.tar.gz 36113438 BLAKE2B 6d51d11e04a71e2a01eaa9b76c072633cbbcb393b91be069f0db2f8a523711d244c93f7a4a9e0f8bc50b14928567d22865f5091a39000c7d7160fc258e21cab5 SHA512 f42a1bc8febf88369b5164879f32bc7967fe0930e42d12395722ac3d2c10a8c59ac9419b68c4bcb499c7df26dfc429dafb672b61f85aee971dd270b0e29742ed diff --git a/dev-python/matplotlib/files/matplotlib-3.9.3-test.patch b/dev-python/matplotlib/files/matplotlib-3.9.3-test.patch new file mode 100644 index 000000000000..62461c655d88 --- /dev/null +++ b/dev-python/matplotlib/files/matplotlib-3.9.3-test.patch @@ -0,0 +1,249 @@ +diff --git a/lib/matplotlib/tests/test_arrow_patches.py b/lib/matplotlib/tests/test_arrow_patches.py +index 254b86cb54..1f93b1a476 100644 +--- a/lib/matplotlib/tests/test_arrow_patches.py ++++ b/lib/matplotlib/tests/test_arrow_patches.py +@@ -68,7 +68,7 @@ def __prepare_fancyarrow_dpi_cor_test(): + + + @image_comparison(['fancyarrow_dpi_cor_100dpi.png'], remove_text=True, +- tol=0 if platform.machine() == 'x86_64' else 0.02, ++ tol=0.015 if platform.machine() == 'x86_64' else 0.02, + savefig_kwarg=dict(dpi=100)) + def test_fancyarrow_dpi_cor_100dpi(): + """ +@@ -83,7 +83,7 @@ def test_fancyarrow_dpi_cor_100dpi(): + + + @image_comparison(['fancyarrow_dpi_cor_200dpi.png'], remove_text=True, +- tol=0 if platform.machine() == 'x86_64' else 0.02, ++ tol=0.018 if platform.machine() == 'x86_64' else 0.02, + savefig_kwarg=dict(dpi=200)) + def test_fancyarrow_dpi_cor_200dpi(): + """ +@@ -116,7 +116,7 @@ def test_fancyarrow_dash(): + + + @image_comparison(['arrow_styles.png'], style='mpl20', remove_text=True, +- tol=0 if platform.machine() == 'x86_64' else 0.02) ++ tol=0.005 if platform.machine() == 'x86_64' else 0.02) + def test_arrow_styles(): + styles = mpatches.ArrowStyle.get_styles() + +diff --git a/lib/matplotlib/tests/test_axes.py b/lib/matplotlib/tests/test_axes.py +index e99ef129eb..73ed9bd974 100644 +--- a/lib/matplotlib/tests/test_axes.py ++++ b/lib/matplotlib/tests/test_axes.py +@@ -1186,7 +1186,7 @@ def test_imshow(): + + @image_comparison( + ['imshow_clip'], style='mpl20', +- tol=1.24 if platform.machine() in ('aarch64', 'arm64', 'ppc64le', 's390x') else 0) ++ tol=1.24) + def test_imshow_clip(): + # As originally reported by Gellule Xg <gellule.xg@free.fr> + # use former defaults to match existing baseline image +@@ -2570,7 +2570,7 @@ def test_contour_hatching(): + + @image_comparison( + ['contour_colorbar'], style='mpl20', +- tol=0.54 if platform.machine() in ('aarch64', 'arm64', 'ppc64le', 's390x') else 0) ++ tol=0.54) + def test_contour_colorbar(): + x, y, z = contour_dat() + +@@ -4931,7 +4931,7 @@ def test_vertex_markers(): + + + @image_comparison(['vline_hline_zorder', 'errorbar_zorder'], +- tol=0 if platform.machine() == 'x86_64' else 0.026) ++ tol=0.015 if platform.machine() == 'x86_64' else 0.026) + def test_eb_line_zorder(): + x = list(range(10)) + +@@ -8861,7 +8861,7 @@ def test_zorder_and_explicit_rasterization(): + + + @image_comparison(["preset_clip_paths.png"], remove_text=True, style="mpl20", +- tol=0.027 if platform.machine() == "arm64" else 0) ++ tol=0.027 if platform.machine() == "arm64" else 0.02) + def test_preset_clip_paths(): + fig, ax = plt.subplots() + +diff --git a/lib/matplotlib/tests/test_colorbar.py b/lib/matplotlib/tests/test_colorbar.py +index 35911afc79..852075c78d 100644 +--- a/lib/matplotlib/tests/test_colorbar.py ++++ b/lib/matplotlib/tests/test_colorbar.py +@@ -235,7 +235,7 @@ def test_colorbar_single_ax_panchor_east(constrained): + + + @image_comparison(['contour_colorbar.png'], remove_text=True, +- tol=0 if platform.machine() == 'x86_64' else 0.054) ++ tol=0.01 if platform.machine() == 'x86_64' else 0.054) + def test_contour_colorbar(): + fig, ax = plt.subplots(figsize=(4, 2)) + data = np.arange(1200).reshape(30, 40) - 500 +diff --git a/lib/matplotlib/tests/test_constrainedlayout.py b/lib/matplotlib/tests/test_constrainedlayout.py +index 4dc4d9501e..015e46cbe4 100644 +--- a/lib/matplotlib/tests/test_constrainedlayout.py ++++ b/lib/matplotlib/tests/test_constrainedlayout.py +@@ -655,11 +655,11 @@ def test_compressed1(): + fig.draw_without_rendering() + + pos = axs[0, 0].get_position() +- np.testing.assert_allclose(pos.x0, 0.06195, atol=1e-3) +- np.testing.assert_allclose(pos.y1, 0.8537, atol=1e-3) ++ np.testing.assert_allclose(pos.x0, 0.06195, atol=2e-3) ++ np.testing.assert_allclose(pos.y1, 0.8537, atol=2e-3) + pos = axs[1, 2].get_position() +- np.testing.assert_allclose(pos.x1, 0.8618, atol=1e-3) +- np.testing.assert_allclose(pos.y0, 0.1934, atol=1e-3) ++ np.testing.assert_allclose(pos.x1, 0.8618, atol=2e-3) ++ np.testing.assert_allclose(pos.y0, 0.1934, atol=2e-3) + + + @pytest.mark.parametrize('arg, state', [ +diff --git a/lib/matplotlib/tests/test_contour.py b/lib/matplotlib/tests/test_contour.py +index a3e00c30ce..7366dc8b39 100644 +--- a/lib/matplotlib/tests/test_contour.py ++++ b/lib/matplotlib/tests/test_contour.py +@@ -450,8 +450,7 @@ def test_contourf_log_extension(split_collections): + @pytest.mark.parametrize("split_collections", [False, True]) + @image_comparison( + ['contour_addlines.png'], remove_text=True, style='mpl20', +- tol=0.15 if platform.machine() in ('aarch64', 'arm64', 'ppc64le', 's390x') +- else 0.03) ++ tol=0.15) + # tolerance is because image changed minutely when tick finding on + # colorbars was cleaned up... + def test_contour_addlines(split_collections): +diff --git a/lib/matplotlib/tests/test_figure.py b/lib/matplotlib/tests/test_figure.py +index 6e6daa7706..7492fded94 100644 +--- a/lib/matplotlib/tests/test_figure.py ++++ b/lib/matplotlib/tests/test_figure.py +@@ -26,7 +26,7 @@ import matplotlib.dates as mdates + + + @image_comparison(['figure_align_labels'], extensions=['png', 'svg'], +- tol=0 if platform.machine() == 'x86_64' else 0.01) ++ tol=0.02) + def test_align_labels(): + fig = plt.figure(layout='tight') + gs = gridspec.GridSpec(3, 3) +@@ -68,7 +68,7 @@ def test_align_labels(): + + @image_comparison(['figure_align_titles_tight.png', + 'figure_align_titles_constrained.png'], +- tol=0 if platform.machine() == 'x86_64' else 0.022, ++ tol=0.01 if platform.machine() == 'x86_64' else 0.022, + style='mpl20') + def test_align_titles(): + for layout in ['tight', 'constrained']: +diff --git a/lib/matplotlib/tests/test_image.py b/lib/matplotlib/tests/test_image.py +index 0c032fa536..5e417881e9 100644 +--- a/lib/matplotlib/tests/test_image.py ++++ b/lib/matplotlib/tests/test_image.py +@@ -1417,7 +1417,7 @@ def test_nonuniform_and_pcolor(): + + @image_comparison( + ['rgba_antialias.png'], style='mpl20', remove_text=True, +- tol=0 if platform.machine() == 'x86_64' else 0.007) ++ tol=0.007) + def test_rgba_antialias(): + fig, axs = plt.subplots(2, 2, figsize=(3.5, 3.5), sharex=False, + sharey=False, constrained_layout=True) +diff --git a/lib/matplotlib/tests/test_legend.py b/lib/matplotlib/tests/test_legend.py +index 3c2af27564..c65887b5e4 100644 +--- a/lib/matplotlib/tests/test_legend.py ++++ b/lib/matplotlib/tests/test_legend.py +@@ -177,7 +177,7 @@ def test_multiple_keys(): + + + @image_comparison(['rgba_alpha.png'], remove_text=True, +- tol=0 if platform.machine() == 'x86_64' else 0.03) ++ tol=0.02 if platform.machine() == 'x86_64' else 0.03) + def test_alpha_rgba(): + fig, ax = plt.subplots() + ax.plot(range(10), lw=5) +@@ -186,7 +186,7 @@ def test_alpha_rgba(): + + + @image_comparison(['rcparam_alpha.png'], remove_text=True, +- tol=0 if platform.machine() == 'x86_64' else 0.03) ++ tol=0.02 if platform.machine() == 'x86_64' else 0.03) + def test_alpha_rcparam(): + fig, ax = plt.subplots() + ax.plot(range(10), lw=5) +@@ -214,7 +214,7 @@ def test_fancy(): + + + @image_comparison(['framealpha'], remove_text=True, +- tol=0 if platform.machine() == 'x86_64' else 0.024) ++ tol=0.02 if platform.machine() == 'x86_64' else 0.024) + def test_framealpha(): + x = np.linspace(1, 100, 100) + y = x +diff --git a/lib/matplotlib/tests/test_lines.py b/lib/matplotlib/tests/test_lines.py +index 902b7aa2c0..d5145a38f0 100644 +--- a/lib/matplotlib/tests/test_lines.py ++++ b/lib/matplotlib/tests/test_lines.py +@@ -185,7 +185,7 @@ def test_set_drawstyle(): + + @image_comparison( + ['line_collection_dashes'], remove_text=True, style='mpl20', +- tol=0 if platform.machine() == 'x86_64' else 0.65) ++ tol=0.65) + def test_set_line_coll_dash_image(): + fig, ax = plt.subplots() + np.random.seed(0) +diff --git a/lib/matplotlib/tests/test_units.py b/lib/matplotlib/tests/test_units.py +index ae6372fea1..4f0dc25732 100644 +--- a/lib/matplotlib/tests/test_units.py ++++ b/lib/matplotlib/tests/test_units.py +@@ -79,7 +79,7 @@ def quantity_converter(): + # Tests that the conversion machinery works properly for classes that + # work as a facade over numpy arrays (like pint) + @image_comparison(['plot_pint.png'], style='mpl20', +- tol=0 if platform.machine() == 'x86_64' else 0.03) ++ tol=0.002 if platform.machine() == 'x86_64' else 0.03) + def test_numpy_facade(quantity_converter): + # use former defaults to match existing baseline image + plt.rcParams['axes.formatter.limits'] = -7, 7 +@@ -106,7 +106,7 @@ def test_numpy_facade(quantity_converter): + + # Tests gh-8908 + @image_comparison(['plot_masked_units.png'], remove_text=True, style='mpl20', +- tol=0 if platform.machine() == 'x86_64' else 0.02) ++ tol=0.02) + def test_plot_masked_units(): + data = np.linspace(-5, 5) + data_masked = np.ma.array(data, mask=(data > -2) & (data < 2)) +diff --git a/lib/matplotlib/tests/test_usetex.py b/lib/matplotlib/tests/test_usetex.py +index 342face450..c7256586bc 100644 +--- a/lib/matplotlib/tests/test_usetex.py ++++ b/lib/matplotlib/tests/test_usetex.py +@@ -15,6 +15,7 @@ import matplotlib.pyplot as plt + pytestmark = needs_usetex + + ++@pytest.mark.skip(reason="TODO: broken") + @image_comparison( + baseline_images=['test_usetex'], + extensions=['pdf', 'png'], +@@ -65,7 +66,7 @@ def test_mathdefault(): + fig.canvas.draw() + + +-@image_comparison(['eqnarray.png']) ++@image_comparison(['eqnarray.png'], tol=23) + def test_multiline_eqnarray(): + text = ( + r'\begin{eqnarray*}' +@@ -163,7 +164,7 @@ except mpl.ExecutableNotFoundError: + + + @image_comparison(baseline_images=['rotation'], extensions=['eps', 'pdf', 'png', 'svg'], +- style='mpl20', tol=3.91 if _old_gs_version else 0) ++ style='mpl20', tol=30) + def test_rotation(): + mpl.rcParams['text.usetex'] = True + diff --git a/dev-python/matplotlib/matplotlib-3.9.3.ebuild b/dev-python/matplotlib/matplotlib-3.9.3.ebuild new file mode 100644 index 000000000000..d465b2c54ff5 --- /dev/null +++ b/dev-python/matplotlib/matplotlib-3.9.3.ebuild @@ -0,0 +1,301 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=meson-python +PYTHON_COMPAT=( python3_{9,10,11,12,13} pypy3 ) +PYTHON_REQ_USE='tk?,threads(+)' + +inherit distutils-r1 pypi virtualx + +FT_PV=2.6.1 +DESCRIPTION="Pure python plotting library with matlab like syntax" +HOMEPAGE=" + https://matplotlib.org/ + https://github.com/matplotlib/matplotlib/ + https://pypi.org/project/matplotlib/ +" +SRC_URI+=" + test? ( + https://downloads.sourceforge.net/project/freetype/freetype2/${FT_PV}/freetype-${FT_PV}.tar.gz + ) +" + +# Main license: matplotlib +# Some modules: BSD +# matplotlib/backends/qt4_editor: MIT +# Fonts: BitstreamVera, OFL-1.1 +LICENSE="BitstreamVera BSD matplotlib MIT OFL-1.1" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~arm64-macos ~x64-macos" +IUSE="cairo excel gtk3 latex qt5 tk webagg wxwidgets" + +DEPEND=" + media-libs/freetype:2 + >=media-libs/qhull-2013:= + >=dev-python/numpy-1.25:=[${PYTHON_USEDEP}] +" +# internal copy of pycxx highly patched +# dev-python/pycxx +RDEPEND=" + ${DEPEND} + >=dev-python/contourpy-1.0.1[${PYTHON_USEDEP}] + >=dev-python/cycler-0.10.0-r1[${PYTHON_USEDEP}] + >=dev-python/fonttools-4.22.0[${PYTHON_USEDEP}] + >=dev-python/kiwisolver-1.3.1[${PYTHON_USEDEP}] + >=dev-python/packaging-20.0[${PYTHON_USEDEP}] + >=dev-python/pillow-8[jpeg,webp,${PYTHON_USEDEP}] + >=dev-python/pyparsing-2.3.1[${PYTHON_USEDEP}] + >=dev-python/python-dateutil-2.7[${PYTHON_USEDEP}] + >=dev-python/pytz-2019.3[${PYTHON_USEDEP}] + media-fonts/dejavu + media-fonts/stix-fonts + media-libs/libpng:0 + virtual/imagemagick-tools[jpeg,tiff] + cairo? ( + dev-python/cairocffi[${PYTHON_USEDEP}] + ) + excel? ( + dev-python/xlwt[${PYTHON_USEDEP}] + ) + gtk3? ( + >=dev-python/pygobject-3.40.1-r1:3[cairo?,${PYTHON_USEDEP}] + x11-libs/gtk+:3[introspection] + ) + latex? ( + virtual/latex-base + app-text/dvipng + app-text/ghostscript-gpl + app-text/poppler[utils] + dev-texlive/texlive-fontsrecommended + dev-texlive/texlive-latexextra + dev-texlive/texlive-luatex + dev-texlive/texlive-xetex + ) + qt5? ( + $(python_gen_cond_dep ' + dev-python/pyqt5[gui,widgets,${PYTHON_USEDEP}] + ' 'python3*') + ) + webagg? ( + >=dev-python/tornado-6.0.4[${PYTHON_USEDEP}] + ) + wxwidgets? ( + $(python_gen_cond_dep ' + dev-python/wxpython:*[${PYTHON_USEDEP}] + ' python3_{10..12}) + ) +" + +BDEPEND=" + ${RDEPEND} + dev-python/pybind11[${PYTHON_USEDEP}] + >=dev-python/setuptools-scm-7[${PYTHON_USEDEP}] + virtual/pkgconfig + test? ( + $(python_gen_impl_dep 'tk') + dev-python/psutil[${PYTHON_USEDEP}] + dev-python/pytest-rerunfailures[${PYTHON_USEDEP}] + >=dev-python/tornado-6.0.4[${PYTHON_USEDEP}] + !hppa? ( !s390? ( + || ( + media-video/ffmpeg[openh264] + media-video/ffmpeg[x264] + ) + ) ) + gtk3? ( + >=dev-python/pygobject-3.40.1-r1:3[cairo?,${PYTHON_USEDEP}] + x11-libs/gtk+:3[introspection] + ) + ) +" + +EPYTEST_XDIST=1 +distutils_enable_tests pytest + +src_unpack() { + # do not unpack freetype + unpack "${P}.tar.gz" +} + +python_prepare_all() { + # Affects installed _version.py, bug #854600 + export SETUPTOOLS_SCM_PRETEND_VERSION=${PV} + + local PATCHES=( + "${FILESDIR}"/matplotlib-3.9.3-test.patch + ) + + # increase lock timeout to 30 s + sed -i -e 's:retries = 50:retries = 300:' lib/matplotlib/cbook.py || die + + distutils-r1_python_prepare_all +} + +src_configure() { + unset DISPLAY # bug #278524 + export XDG_RUNTIME_DIR="${T}/runtime-dir" + mkdir "${XDG_RUNTIME_DIR}" || die + chmod 0700 "${XDG_RUNTIME_DIR}" || die + + DISTUTILS_ARGS=( + -Dsystem-freetype=true + -Dsystem-qhull=true + -Dmacosx=false + ) +} + +src_test() { + mkdir subprojects/packagecache || die + cp "${DISTDIR}/freetype-${FT_PV}.tar.gz" subprojects/packagecache/ || die + virtx distutils-r1_src_test +} + +python_test() { + local EPYTEST_DESELECT=( + # broken by -Wdefault + "tests/test_rcparams.py::test_validator_invalid[validate_strlist-arg6-MatplotlibDeprecationWarning]" + "tests/test_rcparams.py::test_validator_invalid[validate_strlist-arg7-MatplotlibDeprecationWarning]" + tests/test_testing.py::test_warn_to_fail + tests/test_legend.py::test_legend_nolabels_warning + # TODO? + tests/test_backend_qt.py::test_fig_sigint_override + tests/test_backend_qt.py::test_ipython + tests/test_backend_nbagg.py::test_ipynb + # leak tests are fragile + tests/test_backends_interactive.py::test_figure_leak_20490 + # major "images not close", new texlive perhaps + tests/test_contour.py::test_all_algorithms + # "no warnings" + tests/test_backend_pdf.py::test_invalid_metadata + tests/test_figure.py::test_too_many_figures + ) + + case ${EPYTHON} in + pypy3) + EPYTEST_DESELECT+=( + # TODO: warning isn't passed through + tests/test_image.py::test_large_image + # TODO + tests/test_pickle.py::test_complete + tests/test_pickle.py::test_no_pyplot + tests/test_pickle.py::test_pickle_load_from_subprocess + tests/test_pickle.py::test_simple + tests/test_texmanager.py::test_openin_any_paranoid + tests/test_widgets.py::test_check_buttons + tests/test_widgets.py::test_check_buttons_lines + tests/test_widgets.py::test_check_radio_buttons_image + tests/test_widgets.py::test_radio_buttons + ) + if has_version "<dev-python/pypy3_10-exe-7.3.13_p2" || + has_version "<dev-python/pypy3_10-exe-bin-7.3.13_p2" + then + EPYTEST_DESELECT+=( + # TypeError is raised when exception is raised in a starred + # expression referencing a generator that uses "yield from" + # and raises -- non-critical, since some exception is raised + # after all + # https://foss.heptapod.net/pypy/pypy/-/issues/4032 + tests/test_axes.py::test_bad_plot_args + tests/test_axes.py::test_plot_errors + tests/test_axes.py::test_plot_format_errors + ) + fi + ;; + python3.11) + EPYTEST_DESELECT+=( + # https://github.com/matplotlib/matplotlib/issues/23384 + "tests/test_backends_interactive.py::test_figure_leak_20490[time_mem1-{'MPLBACKEND': 'qtagg', 'QT_API': 'PyQt5'}]" + "tests/test_backends_interactive.py::test_figure_leak_20490[time_mem1-{'MPLBACKEND': 'qtcairo', 'QT_API': 'PyQt5'}]" + ) + ;; + python3.12) + EPYTEST_DESELECT+=( + tests/test_constrainedlayout.py::test_compressed1 + ) + ;; + esac + + case ${ABI} in + hppa) + EPYTEST_DESELECT+=( + 'tests/test_mathtext.py::test_mathtext_exceptions[hspace without value]' + 'tests/test_mathtext.py::test_mathtext_exceptions[hspace with invalid value]' + 'tests/test_mathtext.py::test_mathtext_exceptions[function without space]' + 'tests/test_mathtext.py::test_mathtext_exceptions[accent without space]' + 'tests/test_mathtext.py::test_mathtext_exceptions[frac without parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[frac with empty parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[binom without parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[binom with empty parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[genfrac without parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[genfrac with empty parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[sqrt without parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[sqrt with invalid value]' + 'tests/test_mathtext.py::test_mathtext_exceptions[overline without parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[overline with empty parameter]' + 'tests/test_mathtext.py::test_mathtext_exceptions[left with invalid delimiter]' + 'tests/test_mathtext.py::test_mathtext_exceptions[right with invalid delimiter]' + 'tests/test_mathtext.py::test_mathtext_exceptions[unclosed parentheses with sizing]' + 'tests/test_mathtext.py::test_mathtext_exceptions[unclosed parentheses without sizing]' + 'tests/test_mathtext.py::test_mathtext_exceptions[dfrac without parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[dfrac with empty parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[overset without parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[underset without parameters]' + 'tests/test_mathtext.py::test_mathtext_exceptions[unknown symbol]' + 'tests/test_mathtext.py::test_mathtext_exceptions[double superscript]' + 'tests/test_mathtext.py::test_mathtext_exceptions[double subscript]' + 'tests/test_mathtext.py::test_mathtext_exceptions[super on sub without braces]' + 'tests/test_quiver.py::test_barbs[png]' + 'tests/test_quiver.py::test_barbs_pivot[png]' + 'tests/test_quiver.py::test_barbs_flip[png]' + 'tests/test_text.py::test_parse_math' + 'tests/test_text.py::test_parse_math_rcparams' + ) + ;& + alpha|arm|m68k|o32|ppc|s390|sh|sparc|x86) + EPYTEST_DESELECT+=( + # too large for 32-bit platforms + 'tests/test_axes.py::test_psd_csd[png]' + ) + ;; + *) + ;; + esac + + # we need to rebuild mpl against bundled freetype, otherwise + # over 1000 tests will fail because of mismatched font rendering + local DISTUTILS_ARGS=( + "${DISTUTILS_ARGS[@]}" + -Dsystem-freetype=false + ) + distutils_pep517_install "${BUILD_DIR}"/test + cp -r "${BUILD_DIR}"/{install,test}"${EPREFIX}/usr/bin" || die + local -x PATH=${BUILD_DIR}/test${EPREFIX}/usr/bin:${PATH} + + pushd lib >/dev/null || die + local path + local sitedir=${BUILD_DIR}/test$(python_get_sitedir) + # sigh, upstream doesn't install these + while IFS= read -d '' path; do + cp -r "${path}" "${sitedir}/${path}" || die + done < <( + find \( \ + -name baseline_images -o \ + -name '*.ipynb' -o \ + -name '*.pfb' -o \ + -name '*.ttf' -o \ + -name tinypages \ + \) -print0 + ) + popd >/dev/null || die + + # speed tests up + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + # pretend we're on CI to increase timeouts + local -x CI=1 + nonfatal epytest --pyargs matplotlib -m "not network" \ + -p rerunfailures --reruns=3 \ + -o tmp_path_retention_policy=all || die +} diff --git a/dev-python/mkdocs-material/Manifest b/dev-python/mkdocs-material/Manifest index 0c01b45fd720..a4177ea8fe59 100644 --- a/dev-python/mkdocs-material/Manifest +++ b/dev-python/mkdocs-material/Manifest @@ -1,3 +1,4 @@ DIST mkdocs-material-9.5.44.gh.tar.gz 14764147 BLAKE2B e0aaed852abd060eee0b9049798a327a4ddc5969a84289b8aa983b0dfbe926b2e0dfd13525593c2783106bca882adfcfad7961c2eb0363a1f4a4131c364c42c8 SHA512 9a0c8d4a52c8b44b9c8e84b57839d5ddc3080eaa136cb6effc3da8eb9d08a2ef0c0898ff875afabc1783ea548653a9b00f00db67ceb48d52f323a93795529465 DIST mkdocs-material-9.5.45.gh.tar.gz 14703865 BLAKE2B a48e2e00bf0c1511e58e3f621656aa23227f0e579b96f83d09666328c815dc67cc8015b5f5400e08dd371e022740f0d46f6f550d1e35880485adf75a9352a8e9 SHA512 1a55d96fbc9872c754570633b094a8e605ef5be2cfe41f5c47d4f1af8ba5bedf9c4e419748716f8c8014a2b661d6ff73e6e98bdb3396568c64534e08f676f11b DIST mkdocs-material-9.5.46.gh.tar.gz 14708818 BLAKE2B 3aed540e20f588f2cb08c94a2323e5311de5edd1467a7bfe1dbabfa81c69ed50875cab5d85aaa874648966bec4acea265a316004683b60b16703a6548aa1464e SHA512 f75bc96590f30c2109fa3ea915b91bd4cad50a4ce3d374fd162ee6178672f3acf812c9e98c348556a212587df935db1126ab2d1fe1f18cfdc3bd1f52efafa859 +DIST mkdocs-material-9.5.47.gh.tar.gz 14708561 BLAKE2B ea3ac2df6f88d3c9b8ebd9bbbe5b6d0bf826fe3ebe733f8a84d532becbbfa66e0c11aa069da9571810593405d91e5d4e45ea0aad158ca1a956cb18c9f7fa9f13 SHA512 3ccce10161552c70276255a25e4467064de4adc92e38ec77e244ae140e9e58fa95144c5667116de89b41807df875ad3bb988685eec37e1285534367a6b4e9d76 diff --git a/dev-python/mkdocs-material/mkdocs-material-9.5.47.ebuild b/dev-python/mkdocs-material/mkdocs-material-9.5.47.ebuild new file mode 100644 index 000000000000..c99fc052adb8 --- /dev/null +++ b/dev-python/mkdocs-material/mkdocs-material-9.5.47.ebuild @@ -0,0 +1,67 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=hatchling +PYTHON_COMPAT=( python3_{9,10,11,12,13} ) + +DOCS_BUILDER="mkdocs" +DOCS_DEPEND=" + dev-python/mkdocs-material-extensions + dev-python/mkdocs-minify-plugin + dev-python/mkdocs-redirects +" + +inherit distutils-r1 docs + +DESCRIPTION="A Material Design theme for MkDocs" +HOMEPAGE=" + https://github.com/squidfunk/mkdocs-material/ + https://pypi.org/project/mkdocs-material/ +" +SRC_URI=" + https://github.com/squidfunk/${PN}/archive/${PV}.tar.gz + -> ${P}.gh.tar.gz +" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~riscv ~x86" +IUSE="social" + +RDEPEND=" + >=dev-python/babel-2.10.3[${PYTHON_USEDEP}] + >=dev-python/colorama-0.4[${PYTHON_USEDEP}] + >=dev-python/jinja2-3.0.2[${PYTHON_USEDEP}] + >=dev-python/lxml-4.6[${PYTHON_USEDEP}] + >=dev-python/markdown-3.2[${PYTHON_USEDEP}] + >=dev-python/mkdocs-1.5.3[${PYTHON_USEDEP}] + >=dev-python/paginate-0.5.6[${PYTHON_USEDEP}] + >=dev-python/pygments-2.16[${PYTHON_USEDEP}] + >=dev-python/pymdown-extensions-10.2[${PYTHON_USEDEP}] + >=dev-python/readtime-2.0[${PYTHON_USEDEP}] + >=dev-python/regex-2022.4.24[${PYTHON_USEDEP}] + >=dev-python/requests-2.26[${PYTHON_USEDEP}] + social? ( + >=dev-python/pillow-10.2[${PYTHON_USEDEP}] + >=media-gfx/cairosvg-2.5[${PYTHON_USEDEP}] + ) +" +BDEPEND=" + >=dev-python/trove-classifiers-2023.10.18[${PYTHON_USEDEP}] +" +# mkdocs-material-extensions depends on mkdocs-material creating a circular dep +PDEPEND=" + >=dev-python/mkdocs-material-extensions-1.2[${PYTHON_USEDEP}] +" + +PATCHES=( + # simplify pyproject to remove extra deps for metadata + "${FILESDIR}/${PN}-8.5.7-simplify-build.patch" +) + +src_prepare() { + echo "__version__ = '${PV}'" > gentoo_version.py || die + distutils-r1_src_prepare +} diff --git a/dev-python/multipart/multipart-1.1.0.ebuild b/dev-python/multipart/multipart-1.1.0.ebuild index e4c37e0c5b65..91286e6a0389 100644 --- a/dev-python/multipart/multipart-1.1.0.ebuild +++ b/dev-python/multipart/multipart-1.1.0.ebuild @@ -16,6 +16,6 @@ HOMEPAGE=" LICENSE="MIT" SLOT="0" -KEYWORDS="~amd64 ~arm64 ~ppc64 ~riscv ~x86" +KEYWORDS="amd64 ~arm64 ~ppc64 ~riscv ~x86" distutils_enable_tests pytest diff --git a/dev-python/pyfakefs/Manifest b/dev-python/pyfakefs/Manifest index f4de887adb8e..903147d06e2d 100644 --- a/dev-python/pyfakefs/Manifest +++ b/dev-python/pyfakefs/Manifest @@ -1 +1,2 @@ DIST pyfakefs-5.7.1.gh.tar.gz 245977 BLAKE2B 8d675ddeecdf2ebde938509da68e76b67773f490c65f99f67c25e781147fd0743e3ccd2f8083d36e29fd293ffb8a77182055abec4f03a10b64a39787b4b4330a SHA512 78a5e754fbc4a47f4816296cd7045cb9001924f3185297ba166d332e2a938eb3109684cd4b63761c7d56e5461a298405f4d20059a8806d059bc940a7e8443d77 +DIST pyfakefs-5.7.2.gh.tar.gz 247345 BLAKE2B 8d7a85b74daf4aeef9628b00916f242b257a8fc9b799ae4a29fc8b56f70320815725490efdda6310350fb3666d67209ca8413e25e1da32c73aa53acf3f2607d2 SHA512 51f4dc345b2222756f40f58caa73e34cfc0fd5dbacd61fb9bfead8f3b1f1bb8afa7178bea4f65f191d0324f5ae507a17dc97c918f80fd39b61678e180af4a22b diff --git a/dev-python/pyfakefs/pyfakefs-5.7.2.ebuild b/dev-python/pyfakefs/pyfakefs-5.7.2.ebuild new file mode 100644 index 000000000000..a323d4442571 --- /dev/null +++ b/dev-python/pyfakefs/pyfakefs-5.7.2.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{9,10,11,12,13} pypy3 ) + +inherit distutils-r1 + +DESCRIPTION="A fake file system that mocks the Python file system modules" +HOMEPAGE=" + https://github.com/pytest-dev/pyfakefs/ + https://pypi.org/project/pyfakefs/ +" +SRC_URI=" + https://github.com/pytest-dev/pyfakefs/archive/v${PV}.tar.gz + -> ${P}.gh.tar.gz +" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" + +distutils_enable_tests pytest + +python_test() { + local EPYTEST_DESELECT=() + local EPYTEST_IGNORE=( + # test for regression with opentimelineio package + pyfakefs/pytest_tests/segfault_test.py + # test for regression with undefined package + pyfakefs/pytest_tests/pytest_fixture_test.py + ) + + if ! has_version "dev-python/pandas[${PYTHON_USEDEP}]"; then + EPYTEST_IGNORE+=( + pyfakefs/pytest_tests/pytest_reload_pandas_test.py + ) + fi + + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + epytest -p pyfakefs.pytest_plugin +} diff --git a/dev-python/pyopengl-accelerate/files/pyopengl-accelerate-3.1.8-gcc-14.patch b/dev-python/pyopengl-accelerate/files/pyopengl-accelerate-3.1.8-gcc-14.patch new file mode 100644 index 000000000000..56f976288316 --- /dev/null +++ b/dev-python/pyopengl-accelerate/files/pyopengl-accelerate-3.1.8-gcc-14.patch @@ -0,0 +1,42 @@ +From fbe0fab7947788039cb4fbc9a5a1ea65a0c0e15b Mon Sep 17 00:00:00 2001 +From: Florian Weimer <fweimer@redhat.com> +Date: Fri, 5 Jan 2024 08:48:12 +0100 +Subject: [PATCH 1/2] accelerate: Fix type of PyArray_FillWithScalar + +The first argument is of type PyArrayObject, not PyObject. +--- a/accelerate/src/numpy_formathandler.pyx ++++ b/accelerate/src/numpy_formathandler.pyx +@@ -22,7 +22,7 @@ cdef extern from "numpy/arrayobject.h": + int PyArray_ISCARRAY_RO( np.ndarray instance ) + cdef np.ndarray PyArray_Zeros(int nd, np.npy_intp* dims, np.dtype, int fortran) + cdef np.ndarray PyArray_EnsureArray(object) +- cdef int PyArray_FillWithScalar(object, object) ++ cdef int PyArray_FillWithScalar(np.ndarray, object) + cdef void import_array() + cdef void* PyArray_DATA( np.ndarray ) + cdef int PyArray_NDIM( np.ndarray ) + +From f62dd58a5437c628d3ff3e626d4507811ef2127b Mon Sep 17 00:00:00 2001 +From: Florian Weimer <fweimer@redhat.com> +Date: Fri, 5 Jan 2024 08:48:43 +0100 +Subject: [PATCH 2/2] accelerate: Use recommended way to integrate NumPy with + Cython + +This approach follows +<https://cython.readthedocs.io/en/latest/src/tutorial/numpy.html#adding-types>. +--- a/accelerate/src/numpy_formathandler.pyx ++++ b/accelerate/src/numpy_formathandler.pyx +@@ -23,7 +23,6 @@ cdef extern from "numpy/arrayobject.h": + cdef np.ndarray PyArray_Zeros(int nd, np.npy_intp* dims, np.dtype, int fortran) + cdef np.ndarray PyArray_EnsureArray(object) + cdef int PyArray_FillWithScalar(np.ndarray, object) +- cdef void import_array() + cdef void* PyArray_DATA( np.ndarray ) + cdef int PyArray_NDIM( np.ndarray ) + cdef int *PyArray_DIMS( np.ndarray ) +@@ -227,4 +226,4 @@ cdef class NumpyHandler(FormatHandler): + + # Cython numpy tutorial neglects to mention this AFAICS + # get segfaults without it +-import_array() ++np.import_array() diff --git a/dev-python/pyopengl-accelerate/files/pyopengl-accelerate-3.1.8-numpy-2.0.patch b/dev-python/pyopengl-accelerate/files/pyopengl-accelerate-3.1.8-numpy-2.0.patch new file mode 100644 index 000000000000..a7d1c50db4ed --- /dev/null +++ b/dev-python/pyopengl-accelerate/files/pyopengl-accelerate-3.1.8-numpy-2.0.patch @@ -0,0 +1,171 @@ +From 20213b913f4a396752c515cafd7ee2ea53ab1fcf Mon Sep 17 00:00:00 2001 +From: Paul Zander <negril.nx+gentoo@gmail.com> +Date: Thu, 20 Jun 2024 17:03:20 +0200 +Subject: [PATCH 1/2] add requirements + +Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> +--- a/requirements.txt ++++ b/requirements.txt +@@ -0,0 +1,4 @@ ++numpy>=2.0.0 ++pytest>=8.2.2 ++setuptools>=70.0.0 ++Cython>=3.0.10 +\ No newline at end of file +-- +2.45.2 + + +From bfb5c7005917fc5b4cb71e17b2ed8cc015828f1b Mon Sep 17 00:00:00 2001 +From: Paul Zander <negril.nx+gentoo@gmail.com> +Date: Thu, 20 Jun 2024 21:40:28 +0200 +Subject: [PATCH 1/5] numpy-2.0 define_macros + +Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> +--- a/setup.py ++++ b/setup.py +@@ -45,7 +45,7 @@ def cython_extension( + # *cython* itself is using the deprecated api, and the + # deprecated APIs are actually providing the attributes + # that we use throughout our code... +- # ('NPY_NO_DEPRECATED_API','NPY_1_7_API_VERSION'), ++ ('NPY_NO_DEPRECATED_API', 'NPY_2_0_API_VERSION'), + ], + compiler_directives={'language_level': "3"} if have_cython else {}, + ) +-- +2.45.2 + + +From b352289a51b2629917b59ee2b35569651436af70 Mon Sep 17 00:00:00 2001 +From: Paul Zander <negril.nx+gentoo@gmail.com> +Date: Thu, 20 Jun 2024 21:42:33 +0200 +Subject: [PATCH 2/5] python-3.11-PyMemoryView_GetContiguous + +Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> +--- a/src/buffers_formathandler.pyx ++++ b/src/buffers_formathandler.pyx +@@ -73,8 +73,8 @@ cdef class MemoryviewHandler(FormatHandler): + # TODO: respect no-copy flag! + instance = PyMemoryView_GetContiguous( + instance, +- PyBUF_STRIDES|PyBUF_FORMAT|PyBUF_C_CONTIGUOUS, + 'C' ++ PyBUF_WRITE, + ) + return instance + cdef c_from_param( self, object instance, object typeCode ): +-- +2.45.2 + + +From 86268a423c994f0808bd745ac4b0dfe69c8682ad Mon Sep 17 00:00:00 2001 +From: Paul Zander <negril.nx+gentoo@gmail.com> +Date: Thu, 20 Jun 2024 21:43:32 +0200 +Subject: [PATCH 3/5] enable conversion to C char + +Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> +--- a/src/buffers_formathandler.pyx ++++ b/src/buffers_formathandler.pyx +@@ -73,8 +73,8 @@ cdef class MemoryviewHandler(FormatHandler): + # TODO: respect no-copy flag! + instance = PyMemoryView_GetContiguous( + instance, +- 'C' + PyBUF_WRITE, ++ b'C' + ) + return instance + cdef c_from_param( self, object instance, object typeCode ): +-- +2.45.2 + + +From 8d8618cd4d318ace3ecabe823da0dcfdae2fb0e5 Mon Sep 17 00:00:00 2001 +From: Paul Zander <negril.nx+gentoo@gmail.com> +Date: Thu, 20 Jun 2024 21:44:53 +0200 +Subject: [PATCH 4/5] set language_level + +Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> +--- a/setup.py ++++ b/setup.py +@@ -47,7 +47,6 @@ def cython_extension( + # that we use throughout our code... + ('NPY_NO_DEPRECATED_API', 'NPY_2_0_API_VERSION'), + ], +- compiler_directives={'language_level': "3"} if have_cython else {}, + ) + + +@@ -116,6 +115,8 @@ if ( # Prevents running of setup during code introspection imports + extraArguments["cmdclass"] = { + "build_ext": build_ext, + } ++ for e in extensions: ++ e.cython_directives = {'language_level': "3"} + setup( + options={ + "sdist": { +--- a/src/numpy_formathandler.pyx ++++ b/src/numpy_formathandler.pyx +@@ -1,5 +1,5 @@ + """Accelerator for numpy format handler operations""" +-#cython: language_level=3 ++# cython: language_level=3 + from ctypes import c_void_p + import numpy as np + cimport numpy as np +-- +2.45.2 + + +From 6cd6e7c053e3268086e90df6d1297941cbce93f2 Mon Sep 17 00:00:00 2001 +From: Paul Zander <negril.nx+gentoo@gmail.com> +Date: Thu, 20 Jun 2024 21:46:46 +0200 +Subject: [PATCH 5/5] drop old cython numpy definitions + +Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> +--- a/src/numpy_formathandler.pyx ++++ b/src/numpy_formathandler.pyx +@@ -3,36 +3,18 @@ + from ctypes import c_void_p + import numpy as np + cimport numpy as np ++from numpy cimport * + from OpenGL_accelerate.formathandler cimport FormatHandler +-import traceback, weakref + from OpenGL.error import CopyError + from OpenGL._bytes import bytes,unicode + +-cdef extern from "Python.h": +- cdef void Py_INCREF( object ) +- + cdef extern from "numpy/arrayobject.h": + cdef np.ndarray PyArray_FromArray( np.ndarray, np.dtype, int ) +- cdef np.ndarray PyArray_ContiguousFromAny( object op, int, int, int max_depth) +- cdef int PyArray_Check( object ) +- cdef int PyArray_CheckScalar( object ) +- int NPY_ARRAY_CARRAY +- int NPY_ARRAY_FORCECAST +- int PyArray_ISCARRAY( np.ndarray instance ) +- int PyArray_ISCARRAY_RO( np.ndarray instance ) + cdef np.ndarray PyArray_Zeros(int nd, np.npy_intp* dims, np.dtype, int fortran) +- cdef np.ndarray PyArray_EnsureArray(object) +- cdef int PyArray_FillWithScalar(np.ndarray, object) +- cdef void* PyArray_DATA( np.ndarray ) +- cdef int PyArray_NDIM( np.ndarray ) +- cdef int *PyArray_DIMS( np.ndarray ) +- cdef int PyArray_DIM( np.ndarray, int dim ) +- cdef np.dtype PyArray_DESCR( np.ndarray ) +- cdef np.npy_intp PyArray_SIZE( np.ndarray ) + + cdef np.dtype array_descr( np.ndarray array ): + """Wrap PyArray_DESCR and incref to deal with the "borrowed" reference""" +- cdef np.dtype desc = PyArray_DESCR( array ) ++ cdef np.dtype desc = array.dtype + Py_INCREF(<object> desc) + return desc + +-- +2.45.2 + diff --git a/dev-python/pyopengl-accelerate/pyopengl-accelerate-3.1.8-r1.ebuild b/dev-python/pyopengl-accelerate/pyopengl-accelerate-3.1.8-r1.ebuild new file mode 100644 index 000000000000..27ba7785a73f --- /dev/null +++ b/dev-python/pyopengl-accelerate/pyopengl-accelerate-3.1.8-r1.ebuild @@ -0,0 +1,81 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{9,10,11,12,13} ) + +inherit distutils-r1 + +DESCRIPTION="Accelerate module for PyOpenGL" +HOMEPAGE=" + https://pyopengl.sourceforge.net/ + https://github.com/mcfletch/pyopengl/ + https://pypi.org/project/PyOpenGL-accelerate/ +" + +if [[ ${PV} = *9999* ]] ; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/mcfletch/pyopengl.git" + S="${S}/accelerate" +else + MY_P=pyopengl-release-${PV} + SRC_URI=" + https://github.com/mcfletch/pyopengl/archive/release-${PV}.tar.gz + -> ${MY_P}.gh.tar.gz + " + KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" + S=${WORKDIR}/${MY_P}/accelerate +fi + +LICENSE="BSD" +SLOT="0" +IUSE="numpy" + +DEPEND=" + numpy? ( + dev-python/numpy:=[${PYTHON_USEDEP}] + ) +" +RDEPEND=" + ${DEPEND} + dev-python/pyopengl[${PYTHON_USEDEP}] +" +BDEPEND=" + dev-python/cython[${PYTHON_USEDEP}] +" + +distutils_enable_tests pytest + +src_prepare() { + default + + touch requirements.txt || die + + eapply -p2 "${FILESDIR}/${PN}-3.1.8-gcc-14.patch" + + eapply -p1 "${FILESDIR}/${PN}-3.1.8-numpy-2.0.patch" +} + +src_configure() { + rm src/*.c || die + + if ! use numpy; then + cat > "${T}"/numpy.py <<-EOF || die + raise ImportError("building numpy extension disabled") + EOF + fi +} + +python_compile() { + local -x PYTHONPATH=${T}:${PYTHONPATH} + distutils-r1_python_compile +} + +python_test() { + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + cd "${T}" || die + epytest "${S}"/tests +} diff --git a/dev-python/pyopengl-accelerate/pyopengl-accelerate-9999.ebuild b/dev-python/pyopengl-accelerate/pyopengl-accelerate-9999.ebuild new file mode 100644 index 000000000000..27ba7785a73f --- /dev/null +++ b/dev-python/pyopengl-accelerate/pyopengl-accelerate-9999.ebuild @@ -0,0 +1,81 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{9,10,11,12,13} ) + +inherit distutils-r1 + +DESCRIPTION="Accelerate module for PyOpenGL" +HOMEPAGE=" + https://pyopengl.sourceforge.net/ + https://github.com/mcfletch/pyopengl/ + https://pypi.org/project/PyOpenGL-accelerate/ +" + +if [[ ${PV} = *9999* ]] ; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/mcfletch/pyopengl.git" + S="${S}/accelerate" +else + MY_P=pyopengl-release-${PV} + SRC_URI=" + https://github.com/mcfletch/pyopengl/archive/release-${PV}.tar.gz + -> ${MY_P}.gh.tar.gz + " + KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" + S=${WORKDIR}/${MY_P}/accelerate +fi + +LICENSE="BSD" +SLOT="0" +IUSE="numpy" + +DEPEND=" + numpy? ( + dev-python/numpy:=[${PYTHON_USEDEP}] + ) +" +RDEPEND=" + ${DEPEND} + dev-python/pyopengl[${PYTHON_USEDEP}] +" +BDEPEND=" + dev-python/cython[${PYTHON_USEDEP}] +" + +distutils_enable_tests pytest + +src_prepare() { + default + + touch requirements.txt || die + + eapply -p2 "${FILESDIR}/${PN}-3.1.8-gcc-14.patch" + + eapply -p1 "${FILESDIR}/${PN}-3.1.8-numpy-2.0.patch" +} + +src_configure() { + rm src/*.c || die + + if ! use numpy; then + cat > "${T}"/numpy.py <<-EOF || die + raise ImportError("building numpy extension disabled") + EOF + fi +} + +python_compile() { + local -x PYTHONPATH=${T}:${PYTHONPATH} + distutils-r1_python_compile +} + +python_test() { + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + cd "${T}" || die + epytest "${S}"/tests +} diff --git a/dev-python/pytest/Manifest b/dev-python/pytest/Manifest index 0cb1cf335838..f426d4267cbd 100644 --- a/dev-python/pytest/Manifest +++ b/dev-python/pytest/Manifest @@ -3,3 +3,4 @@ DIST pytest-8.0.2.tar.gz 1396924 BLAKE2B ad95d246f5592cfe54faea6c96e38cb60d3e271 DIST pytest-8.1.2.tar.gz 1410060 BLAKE2B 1379047c5ba434e98a383756c53a9cf31dc3bd3abcc49820f872b9110ec70906ca14080ce17ed2770b71195fbd79627a0eb16ee00429e165368144b20153a02b SHA512 a6ffae29da98ee4c357ebb03f00c4bc1a33f093ef867ad118841695548468c7f229eaa2c029a2ce3b158bbb0a65be5014e91555a223d04c1c72e614cb1d00546 DIST pytest-8.2.2.tar.gz 1427980 BLAKE2B 7f343e5ff05e4d26f816595ad1c52ee2b79d38029e75e3641ed0bbb7477e0a47e5ae48ebc3058a8e9f374cd1a391d360d9eda73eca2e41d8b533eda7948aedcb SHA512 896192f0d41f3fef49915dfea6ae33dbb939f6bbe54de27861bf1554bf87f910702169293e923af9bc40466e7f806aa19ca54cbe41a848c233f70b52bb86a63c DIST pytest-8.3.3.tar.gz 1442487 BLAKE2B a7b262806ac2ef8700034f9d6239ef1f69c865c100a3d2b00c07adb5957e59b664cf2d39b5d2c1352f28fdd8045e8a2bf193543ba67f67c4853b21f95e4f0a6a SHA512 7cdf76e33f20b1b2323de7341c203caa8d7b5505b5e774c55c6e30876e5b6f1405e12d54e7f1f0a1b15dbc0392bd83c7bb1928d25f06db3a15498c9d4cb4658b +DIST pytest-8.3.4.tar.gz 1445919 BLAKE2B 4114e8621c50f5c02fdf88de59400b2e24663b10354445623a7d6d9255d827eff2b71f009596e6521b9d3e84417a9f39cb46ffcb55833bec08c6327f300e8b0d SHA512 e11034864dc6dcc2d0297658b9e01e5717c7d878aa64d5020474ffc784287046ffa60e5c1ddb814f2a870401ec997c574933144cc0d925360e1e595312179b15 diff --git a/dev-python/pytest/pytest-8.3.4.ebuild b/dev-python/pytest/pytest-8.3.4.ebuild new file mode 100644 index 000000000000..e9fbcff66509 --- /dev/null +++ b/dev-python/pytest/pytest-8.3.4.ebuild @@ -0,0 +1,116 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_TESTED=( python3_{9,10,11,12,13} pypy3 ) +PYTHON_COMPAT=( "${PYTHON_TESTED[@]}" ) + +inherit distutils-r1 pypi + +DESCRIPTION="Simple powerful testing with Python" +HOMEPAGE=" + https://pytest.org/ + https://github.com/pytest-dev/pytest/ + https://pypi.org/project/pytest/ +" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris" +IUSE="test" +RESTRICT="!test? ( test )" + +RDEPEND=" + dev-python/iniconfig[${PYTHON_USEDEP}] + dev-python/packaging[${PYTHON_USEDEP}] + <dev-python/pluggy-2[${PYTHON_USEDEP}] + >=dev-python/pluggy-1.5.0[${PYTHON_USEDEP}] + $(python_gen_cond_dep ' + >=dev-python/exceptiongroup-1.0.0_rc8[${PYTHON_USEDEP}] + >=dev-python/tomli-1[${PYTHON_USEDEP}] + ' 3.10) + !!<=dev-python/flaky-3.7.0-r5 +" +BDEPEND=" + >=dev-python/setuptools-scm-6.2.3[${PYTHON_USEDEP}] + test? ( + ${RDEPEND} + $(python_gen_cond_dep ' + dev-python/argcomplete[${PYTHON_USEDEP}] + >=dev-python/attrs-19.2[${PYTHON_USEDEP}] + >=dev-python/hypothesis-3.56[${PYTHON_USEDEP}] + dev-python/mock[${PYTHON_USEDEP}] + >=dev-python/pygments-2.7.2[${PYTHON_USEDEP}] + dev-python/pytest-xdist[${PYTHON_USEDEP}] + dev-python/requests[${PYTHON_USEDEP}] + dev-python/xmlschema[${PYTHON_USEDEP}] + ' "${PYTHON_TESTED[@]}") + ) +" + +src_test() { + # workaround new readline defaults + echo "set enable-bracketed-paste off" > "${T}"/inputrc || die + local -x INPUTRC="${T}"/inputrc + distutils-r1_src_test +} + +python_test() { + if ! has "${EPYTHON}" "${PYTHON_TESTED[@]/_/.}"; then + einfo "Skipping tests on ${EPYTHON}" + return + fi + + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + local -x COLUMNS=80 + + local EPYTEST_DESELECT=( + # broken by epytest args + testing/test_warnings.py::test_works_with_filterwarnings + + # tend to be broken by random pytest plugins + # (these tests patch PYTEST_DISABLE_PLUGIN_AUTOLOAD out) + testing/test_helpconfig.py::test_version_less_verbose + testing/test_helpconfig.py::test_version_verbose + testing/test_junitxml.py::test_random_report_log_xdist + testing/test_junitxml.py::test_runs_twice_xdist + testing/test_terminal.py::TestProgressOutputStyle::test_xdist_normal + testing/test_terminal.py::TestProgressOutputStyle::test_xdist_normal_count + testing/test_terminal.py::TestProgressOutputStyle::test_xdist_verbose + testing/test_terminal.py::TestProgressWithTeardown::test_xdist_normal + testing/test_terminal.py::TestTerminalFunctional::test_header_trailer_info + testing/test_terminal.py::TestTerminalFunctional::test_no_header_trailer_info + + # unstable with xdist + testing/test_terminal.py::TestTerminalFunctional::test_verbose_reporting_xdist + + # TODO (XPASS) + testing/test_debugging.py::TestDebuggingBreakpoints::test_pdb_not_altered + testing/test_debugging.py::TestPDB::test_pdb_interaction_capturing_simple + testing/test_debugging.py::TestPDB::test_pdb_interaction_capturing_twice + testing/test_debugging.py::TestPDB::test_pdb_with_injected_do_debug + testing/test_debugging.py::test_pdb_suspends_fixture_capturing + + # setuptools warnings + testing/acceptance_test.py::TestInvocationVariants::test_cmdline_python_namespace_package + + # PDB tests seem quite flaky (they time out often) + testing/test_debugging.py::TestPDB + ) + + case ${EPYTHON} in + pypy3) + EPYTEST_DESELECT+=( + # regressions on pypy3.9 + # https://github.com/pytest-dev/pytest/issues/9787 + testing/test_skipping.py::test_errors_in_xfail_skip_expressions + testing/test_unraisableexception.py + ) + ;; + esac + + local EPYTEST_XDIST=1 + epytest +} diff --git a/dev-python/python-multipart/Manifest b/dev-python/python-multipart/Manifest index e561656aa2e1..d2e8d6bf90fb 100644 --- a/dev-python/python-multipart/Manifest +++ b/dev-python/python-multipart/Manifest @@ -1,3 +1,4 @@ DIST python-multipart-0.0.12.gh.tar.gz 92904 BLAKE2B 25076627fdcb3a4bfc9eda74218f9d6d30ea18517da00c312f50c9d3ae156894b29e83bd38d4e11d7d06732999ae9640243e660d2a037253b9f511772a6c737b SHA512 271ed29f3025be5c058a56ec56ce373348dc27b4c8130c17609bd48d73fc975b2ac8387d4989be578e1be01a618aad87c1d3ec3a37dbe73dc45813ec961842d0 DIST python-multipart-0.0.17.gh.tar.gz 94416 BLAKE2B daf9f5e2a94d804216fbf18778295cec3270139d5912ace80ab84d57d32115d7a53563d429f81fd2f0f55b9fe30b58f62ef1d095414f7bfe6bd3951dbb9d9e89 SHA512 52b5d5b154a18a2ae34ce7931076278b5a5edb2cbca5350c6898fd675fb57755cefc97642b2edae7e7d9903d877430da85f73347b9fcaaf1c20fa09dc12799fd DIST python-multipart-0.0.18.gh.tar.gz 95540 BLAKE2B fb68867f6035ee463c69c89df6b792bd8506df03386a1d61f223aa0fb63c2e6604c76377e9c356e55280c39e20052eced7c48869cf9661980626586054379ae9 SHA512 d4b888d95cbbbb70a66a8d756dfa479e96bf9cb7e754f8630a89e63dbdc06a9e237dd257c5924618030bfd03737d202029bbd5b50e483f72680177d3b0775629 +DIST python-multipart-0.0.19.gh.tar.gz 95805 BLAKE2B fcd22b383aab09cc9dd1eaf6b6859d406b3439fbfe3460761f147ab8230f4cae118e44d3f3f067c03d4ff508b655c8f84d120765e233c87ae11b014d2d544051 SHA512 cd4f1dc7b5b2e4b29dbccb62f71143dc5ecfad419c12aca2d780d8ef0f3fcc1ef9f7e129b56daa48caef04c95e2e365157b9d945a2e40a5693ba70b2d1d80686 diff --git a/dev-python/python-multipart/python-multipart-0.0.19.ebuild b/dev-python/python-multipart/python-multipart-0.0.19.ebuild new file mode 100644 index 000000000000..1014160be7d0 --- /dev/null +++ b/dev-python/python-multipart/python-multipart-0.0.19.ebuild @@ -0,0 +1,44 @@ +# Copyright 2022-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=hatchling +PYTHON_COMPAT=( python3_{9,10,11,12,13} pypy3 ) + +inherit distutils-r1 + +DESCRIPTION="A streaming multipart parser for Python" +HOMEPAGE=" + https://github.com/Kludex/python-multipart/ + https://pypi.org/project/python-multipart/ +" +SRC_URI=" + https://github.com/Kludex/python-multipart/archive/${PV}.tar.gz + -> ${P}.gh.tar.gz +" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" + +BDEPEND=" + test? ( + dev-python/pyyaml[${PYTHON_USEDEP}] + ) +" + +distutils_enable_tests pytest + +src_prepare() { + distutils-r1_src_prepare + + # do not install the backwards compatibility package + # we're patching revdeps instead + rm -r multipart || die +} + +python_test() { + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + epytest +} diff --git a/dev-python/treq/treq-24.9.1-r1.ebuild b/dev-python/treq/treq-24.9.1-r1.ebuild index c98d2af11ad5..29b3f9699983 100644 --- a/dev-python/treq/treq-24.9.1-r1.ebuild +++ b/dev-python/treq/treq-24.9.1-r1.ebuild @@ -16,7 +16,7 @@ HOMEPAGE=" LICENSE="MIT" SLOT="0" -KEYWORDS="~amd64 ~arm64 ~ppc64 ~riscv ~x86" +KEYWORDS="amd64 ~arm64 ~ppc64 ~riscv ~x86" IUSE="test" RESTRICT="!test? ( test )" |
