diff options
author | Sharlatan Hellseher <sharlatanus@gmail.com> | 2025-07-05 22:51:36 +0100 |
---|---|---|
committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2025-07-06 00:44:34 +0100 |
commit | 502b3d9dd682e03b8acfdc809ce8fc77ee5d8ca0 (patch) | |
tree | 849c1af4422be0960d0e05000655936fb5ef1354 | |
parent | 265541b912cf2cb22ca225a6407d47a33b0841e9 (diff) |
gnu: python-plotly: Improve package.
* gnu/packages/graph.scm (python-plotly): Simplify and improve package.
[build-system]: Use pyproject.
[arguments] <test-flags>: Utilize it and skip only problematic tests
which miss some packages, requiring networking or fail abnormaly.
<phases>: Use default 'check.
[propagated-inputs]: Remove python-six; add python-scikit-image and
python-vaex-core.
[native-inputs]: Add python-setuptools and python-wheel.
Change-Id: I4fefedbbf3e9180b07b40252fb8fb89f49983dbd
-rw-r--r-- | gnu/packages/graph.scm | 68 |
1 files changed, 53 insertions, 15 deletions
diff --git a/gnu/packages/graph.scm b/gnu/packages/graph.scm index ceeed8e219..91698213f3 100644 --- a/gnu/packages/graph.scm +++ b/gnu/packages/graph.scm @@ -310,15 +310,55 @@ lines.") (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/plotly/plotly.py") - (commit (string-append "v" version)))) + (url "https://github.com/plotly/plotly.py") + (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 "0i22sv8p3kl84nkldbv1253kld85rbwp2pdxivxn64wwflfpqvx6")))) - (build-system python-build-system) + (build-system pyproject-build-system) (arguments (list + #:test-flags + ;; 2658 passed, 18 skipped, 38 deselected, 574 warnings + #~(list "-k" (string-join + ;; python-polars is not packaged yet. + (list "not test_build_df_from_vaex_and_polars" + "test_build_df_with_hover_data_from_vaex_and_polars" + ;; ValueError + "test_bytesio" + "test_ensure_orca_ping_and_proc" + "test_kaleido_engine_to_image_returns_bytes" + "test_kaleido_fulljson" + "test_latex_fig_to_image[eps]" + "test_mimetype_combination" + "test_orca_version_number" + "test_pdf_renderer_show_override" + "test_png_renderer_mimetype" + "test_problematic_environment_variables[eps]" + "test_server_timeout_shutdown" + "test_simple_to_image[eps]" + "test_svg_renderer_show" + "test_to_image_default[eps]" + "test_topojson_fig_to_image[eps]" + "test_validate_orca" + "test_write_image_string[eps]" + "test_write_image_string_bad_extension_override" + "test_write_image_string_format_inference[eps]" + "test_write_image_writeable[eps]" + ;; XXX: check why these tests fail + "test_dependencies_not_imported" + "test_external_server_url" + "test_invalid_figure_json" + "test_lazy_imports" + "test_legend_dots" + "test_linestyle" + "test_orca_executable_path" + "test_sanitize_json[auto]" + "test_sanitize_json[json]" + "test_scraper" + "test_write_image_string_bad_extension_failure") + " and not ")) #:phases #~(modify-phases %standard-phases (add-before 'build 'skip-npm @@ -338,26 +378,24 @@ lines.") (format #f "__version__ = ~s" #$version))))) (add-after 'fix-version 'chdir (lambda _ - (chdir "packages/python/plotly"))) - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "pytest" "-x" "plotly/tests/test_core") - (invoke "pytest" "-x" "plotly/tests/test_io") - ;; FIXME: Add optional dependencies and enable their tests. - ;; (invoke "pytest" "-x" "plotly/tests/test_optional") - (invoke "pytest" "_plotly_utils/tests"))))))) + (chdir "packages/python/plotly")))))) (native-inputs - (list python-ipywidgets python-pytest python-xarray)) + (list python-ipywidgets + python-pytest + python-setuptools + python-wheel + python-xarray)) (propagated-inputs (list python-ipython python-pandas python-pillow + ;; python-polars python-requests python-retrying - python-six + python-scikit-image + python-statsmodels python-tenacity - python-statsmodels)) + python-vaex-core)) (home-page "https://plotly.com/python/") (synopsis "Interactive plotting library for Python") (description "Plotly's Python graphing library makes interactive, |