forked from pool/python-graphviz
- Add py314.patch to fix tests with Python 3.14
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-graphviz?expand=0&rev=40
This commit is contained in:
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
||||
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
.osc
|
||||
BIN
graphviz-0.21.tar.gz
LFS
Normal file
BIN
graphviz-0.21.tar.gz
LFS
Normal file
Binary file not shown.
13
py314.patch
Normal file
13
py314.patch
Normal file
@@ -0,0 +1,13 @@
|
||||
Index: graphviz-0.21/tests/test_quoting.py
|
||||
===================================================================
|
||||
--- graphviz-0.21.orig/tests/test_quoting.py
|
||||
+++ graphviz-0.21/tests/test_quoting.py
|
||||
@@ -17,7 +17,7 @@ def test_deprecated_escape(recwarn, char
|
||||
assert len(recwarn) == 1
|
||||
w = recwarn.pop(DeprecationWarning if sys.version_info < (3, 12)
|
||||
else SyntaxWarning)
|
||||
- assert str(w.message).startswith('invalid escape sequence')
|
||||
+ assert 'invalid escape sequence' in str(w.message)
|
||||
|
||||
assert escape == f'\\{char}'
|
||||
assert quoting.quote(escape) == f'"\\{char}"'
|
||||
235
python-graphviz.changes
Normal file
235
python-graphviz.changes
Normal file
@@ -0,0 +1,235 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Sep 9 14:31:30 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Add py314.patch to fix tests with Python 3.14
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jul 2 07:55:23 UTC 2025 - John Paul Adrian Glaubitz <adrian.glaubitz@suse.com>
|
||||
|
||||
- Update to 0.21
|
||||
* Drop Python 3.8 support (end of life 7 Oct 2024).
|
||||
* Tag Python 3.13 support.
|
||||
* Add support for ``format='svg_inline'``, available since upstream
|
||||
Graphviz 10.0.1. Produces header-less SVG suitable for inlining
|
||||
into HTML (see https://www.graphviz.org/docs/outputs/svg/).
|
||||
* Switch project to ``pyproject.toml`` and build to ``python -m build``)
|
||||
(https://build.pypa.io). This changes the source distribution formar
|
||||
from ``.zip`` to PEP 625 compliant ``.tar.gz``
|
||||
(https://peps.python.org/pep-0625/).
|
||||
- Remove unzip package from BuildRequires
|
||||
- Switch source archive format to TAR.GZ
|
||||
- Update BuildRequires from pyproject.toml
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jun 6 09:21:15 UTC 2025 - Thomas Renninger <trenn@suse.de>
|
||||
|
||||
- Fix tests with latest graphviz update to 12.x
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu May 23 01:59:56 UTC 2024 - Steve Kowalik <steven.kowalik@suse.com>
|
||||
|
||||
- Update to 0.20.3:
|
||||
* Drop Python 3.7 support (end of life 27 Jun 2023).
|
||||
* Tag Python 3.11 and 3.12 support.
|
||||
* Add caveat about labe escaping/quoting to .node() and .render() API docs.
|
||||
* Document that doctest_skip_exe() lines in doctest should be ignored.
|
||||
- Drop patch python312-syntax-warning.patch, no longer required.
|
||||
- Ignore conftest files during collection, due to pytest issue.
|
||||
- Switch to pyproject macros.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Dec 6 22:22:48 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- add python312-syntax-warning.patch for python 3.12 support
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Apr 21 12:25:49 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- add sle15_python_module_pythons (jsc#PED-68)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Apr 13 22:41:38 UTC 2023 - Matej Cepl <mcepl@suse.com>
|
||||
|
||||
- Make calling of %{sle15modernpython} optional.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Aug 18 18:39:25 UTC 2022 - Ben Greiner <code@bnavigator.de>
|
||||
|
||||
- Update to v0.20.1
|
||||
* Fix documentation building: upgrade to Sphinx 5.0.
|
||||
* Fix broken user guide links in API documentation.
|
||||
- Version 0.20
|
||||
* Add keyword-only neato_no_op argument to .render(), .pipe(),
|
||||
and stand-alone graphviz.render() and graphviz.pipe().
|
||||
* When building a Graph or Digraph, warn about an expected DOT
|
||||
syntax error in rendering when passing a string that ends with
|
||||
an odd number of backslashes (e.g. invalid dot.node('spam',
|
||||
label='\\') instead of correct ..., label=r'\\' for a node
|
||||
labled as a backslash).
|
||||
* Increase visibility of graphviz.escape() in the documentation.
|
||||
- Version 0.19.2
|
||||
* Drop Python 3.6 support (end of life 23 Dec 2021).
|
||||
* Fix ExecutableNotFound and CalledProcessError in
|
||||
graphviz.__all__.
|
||||
* Better document 0.18 change of behaviour for the body
|
||||
argument/attribute (lines need to include their final newline).
|
||||
- drop python-graphviz-pytest.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Mar 23 10:36:42 UTC 2022 - pgajdos@suse.com
|
||||
|
||||
- do not require python-mock for build
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 13 15:16:48 UTC 2021 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
- Add noto-sans-fonts: in order to have a reliable test suite with
|
||||
pango 1.50, we need to have some fonts available.
|
||||
- Add python-graphviz-pytest.patch: Allow to run pytest directly,
|
||||
instead of run-tests.py. Allows us to further use %%pytest
|
||||
without workarounds. Patch will be part of the next version.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 13 09:38:47 UTC 2021 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
- Update to version 0.19.1:
|
||||
+ Fix undecoded CalledProcessError.stdout and .stderr when
|
||||
.pipe() call with an encoding different from self.encoding
|
||||
fails.
|
||||
+ Fix missing project root conftest.py in source distribution.
|
||||
+ Extend examples/graphviz-escapes.ipynb.
|
||||
+ Improve test coverage.
|
||||
+ Increase build scripts verbosity.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Dec 8 11:21:12 UTC 2021 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
- Update to version 0.19:
|
||||
+ Add PendingDeprecationWarning to calls using positional
|
||||
arguments that will be deprecated in a later version.
|
||||
+ Add keyword-only outfile argument to .render() and stand-alone
|
||||
graphviz.render().
|
||||
+ Add graphviz.set_jupyter_format() to set the output format used
|
||||
by the Jupyter visualization of graphviz.Graph,
|
||||
graphviz.Digraph, and graphviz.Source.
|
||||
+ Add keyword-only raise_if_result_exists argument to .render()
|
||||
and stand-alone graphviz.render().
|
||||
- For all intermediate releases between 0.14.1 and 0.19, please see
|
||||
the packaged CHANGES.txt.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Aug 6 08:26:39 UTC 2020 - Dirk Mueller <dmueller@suse.com>
|
||||
|
||||
- update to 0.14.1
|
||||
* Document the colon-separated ``node[:port[:compass]]`` format used for ``tail``
|
||||
and ``head`` points in the ``edge()``- and ``edges()``-methods'
|
||||
* Improve handling of escaped quotes (``\"``). Different from other layout engine
|
||||
escapes sequences such as ``\l`` and ``\N`` (which are passed on as is by
|
||||
default), there is no use case for backslash-escaping a literal quote character
|
||||
because escaping of quotes is done by this library. Therefore, a
|
||||
backslash-escaped quote (e.g. in ``label='\\"'``) is now treated the same as a
|
||||
plain unescaped quote, i.e. both ``label='"'`` and ``label='\\"'`` produce
|
||||
the same DOT source ``[label="\""]`` (a label that renders as a literal quote).
|
||||
Before this change, use of ``'\\"'`` could break the quoting mechanism creating
|
||||
invalid or unintended DOT, possibly leading to syntax errors from the rendering
|
||||
process.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun Nov 24 17:21:08 UTC 2019 - Arun Persaud <arun@gmx.de>
|
||||
|
||||
- update to version 0.13.2:
|
||||
* Fix missing support for four-part versions in
|
||||
"graphviz.version()".
|
||||
|
||||
- changes from version 0.13.1:
|
||||
* Tag Python 3.8 support.
|
||||
* Fix quoting for non-ASCII numerals.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Sep 12 10:11:53 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
||||
|
||||
- Update to 0.13:
|
||||
* Fix missing escaping of backslashes, e.g. in labels
|
||||
* Add basic debug logging via the stdlib ``logging`` module.
|
||||
* Add ``escape()`` function (resembling ``re.escape()``)
|
||||
* Add explicit support for layout engine escape sequences
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Aug 3 14:28:44 UTC 2019 - Arun Persaud <arun@gmx.de>
|
||||
|
||||
- update to version 0.11.1:
|
||||
* Include "stderr" in "str()" of raised
|
||||
"subprocess.CalledProcessError".
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Jun 15 15:48:14 UTC 2019 - Arun Persaud <arun@gmx.de>
|
||||
|
||||
- specfile:
|
||||
* be more specific i %files section
|
||||
|
||||
- update to version 0.11:
|
||||
* Add "quiet" argument to ".render()" and ".pipe()" methods of
|
||||
"Graph", "Digraph", and "Source" objects, allowing to suppress
|
||||
"stderr" of the layout subprocess (parity with stand-alone
|
||||
"render()" and "pipe()" functions).
|
||||
* The rendering process for "render()" methods and stand-alone
|
||||
function is now started from the directory of the rendered dot
|
||||
source file. This allows to render graph descriptions that use
|
||||
relative paths inline (e.g. for referring to image files to be
|
||||
included) by using paths relative to the source file
|
||||
location. Previously, such relative paths would need to be given
|
||||
relative to the directory from which "render()" was started, so
|
||||
this change is backwards incompatible for code that relied on the
|
||||
previous behaviour.
|
||||
* Drop Python 3.4 support.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Apr 23 10:58:51 UTC 2019 - Thomas Bechtold <tbechtold@suse.com>
|
||||
|
||||
- Add minimal needed versions to BuildRequires
|
||||
Build fails with older python-pytest-mock versions so add the
|
||||
needed checks to avoid that
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Dec 4 12:48:43 UTC 2018 - Matej Cepl <mcepl@suse.com>
|
||||
|
||||
- Remove superfluous devel dependency for noarch package
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Nov 14 12:44:07 UTC 2018 - Tomáš Chvátal <tchvatal@suse.com>
|
||||
|
||||
- Update to 0.10.1:
|
||||
* python 3.7 support
|
||||
* Various fixes
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Jan 6 17:29:25 UTC 2018 - arun@gmx.de
|
||||
|
||||
- specfile:
|
||||
* update copyright year
|
||||
|
||||
- update to version 0.8.2:
|
||||
* Add nohtml() to support labels of the form '<...>' (disabling
|
||||
their default treatment as HTML strings).
|
||||
* Make default utf-8 encoding more visible.
|
||||
* Set encoding = locale.getpreferredencoding() when encoding
|
||||
argument/property is set to None explicitly (follow stdlib io.open
|
||||
behaviour).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Nov 15 13:12:25 UTC 2017 - jengelh@inai.de
|
||||
|
||||
- Replace imperatives in description.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Nov 15 12:53:33 UTC 2017 - mimi.vx@gmail.com
|
||||
|
||||
- update to 0.8.1
|
||||
* please see long list of changes in
|
||||
https://github.com/xflr6/graphviz/blob/d7149d507ea6c345ac20f5d6d7e14bc3f162114c/CHANGES
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Apr 14 21:09:02 UTC 2017 - toddrme2178@gmail.com
|
||||
|
||||
- Initial singlespec version
|
||||
|
||||
88
python-graphviz.spec
Normal file
88
python-graphviz.spec
Normal file
@@ -0,0 +1,88 @@
|
||||
#
|
||||
# spec file for package python-graphviz
|
||||
#
|
||||
# Copyright (c) 2025 SUSE LLC and contributors
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
%{?sle15_python_module_pythons}
|
||||
Name: python-graphviz
|
||||
Version: 0.21
|
||||
Release: 0
|
||||
Summary: Python interface for Graphviz
|
||||
License: MIT
|
||||
URL: https://github.com/xflr6/graphviz
|
||||
Source: https://files.pythonhosted.org/packages/source/g/graphviz/graphviz-%{version}.tar.gz
|
||||
# PATCH-FIX-UPSTREAM https://github.com/xflr6/graphviz/pull/238 fix tests on Python 3.14
|
||||
Patch0: py314.patch
|
||||
BuildRequires: %{python_module base >= 3.8}
|
||||
BuildRequires: %{python_module coverage}
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module pytest >= 7}
|
||||
BuildRequires: %{python_module pytest-cov}
|
||||
BuildRequires: %{python_module pytest-mock >= 3}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: dos2unix
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: graphviz
|
||||
BuildRequires: graphviz-gd
|
||||
BuildRequires: graphviz-gnome
|
||||
BuildRequires: noto-sans-fonts
|
||||
BuildRequires: python-rpm-macros
|
||||
BuildRequires: w3m
|
||||
BuildRequires: xdg-utils
|
||||
Requires: graphviz
|
||||
Recommends: xdg-utils
|
||||
BuildArch: noarch
|
||||
%python_subpackages
|
||||
|
||||
%description
|
||||
This package facilitates the creation and rendering of graph descriptions in
|
||||
the DOT language of the Graphviz graph drawing software from Python.
|
||||
|
||||
It supports creating a graph object, assembling the graph by adding nodes and
|
||||
edges, and retrieving its DOT source code string, saving the source code to a
|
||||
file and rendering it with the Graphviz installation.
|
||||
|
||||
Using the view option/method, the resulting (PDF, PNG, SVG, etc.) file can be
|
||||
inspected with its default application. Graphs can also be rendered and
|
||||
displayed within IPython notebooks.
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -n graphviz-%{version}
|
||||
sed -i '/--cov/d' setup.cfg
|
||||
sed -i '/^mock_use_standalone_module/d' setup.cfg
|
||||
|
||||
# Fix wrong-file-end-of-line-encoding
|
||||
dos2unix LICENSE.txt README.rst docs/*.rst
|
||||
|
||||
%build
|
||||
%pyproject_wheel
|
||||
|
||||
%install
|
||||
%pyproject_install
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
%check
|
||||
# https://github.com/pytest-dev/pytest/issues/12123
|
||||
%pytest --ignore tests/conftest.py --ignore tests/backend/conftest.py
|
||||
|
||||
%files %{python_files}
|
||||
%license LICENSE.txt
|
||||
%doc README.rst
|
||||
%{python_sitelib}/graphviz
|
||||
%{python_sitelib}/graphviz-%{version}.dist-info
|
||||
|
||||
%changelog
|
||||
Reference in New Issue
Block a user