From 2eb1738b8f57111b30f17a19d4420de17548cdb0dc5781584033684895ccad16 Mon Sep 17 00:00:00 2001 From: Todd R Date: Tue, 1 Nov 2016 20:03:22 +0000 Subject: [PATCH] Accepting request 438173 from home:TheBlackCat:branches:devel:languages:python Update to 1.2.3 OBS-URL: https://build.opensuse.org/request/show/438173 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pydot?expand=0&rev=7 --- example-demo.py | 7 --- example-rank.py | 7 --- pydot-1.0.28.tar.gz | 3 -- pydot-1.2.3.tar.gz | 3 ++ ....0.28_fix_pyparser_2_incompatibility.patch | 14 ----- python-pydot.changes | 52 +++++++++++++++++++ python-pydot.spec | 34 +++++------- 7 files changed, 67 insertions(+), 53 deletions(-) delete mode 100644 example-demo.py delete mode 100644 example-rank.py delete mode 100644 pydot-1.0.28.tar.gz create mode 100644 pydot-1.2.3.tar.gz delete mode 100644 python-pydot-1.0.28_fix_pyparser_2_incompatibility.patch diff --git a/example-demo.py b/example-demo.py deleted file mode 100644 index 64a1ca4..0000000 --- a/example-demo.py +++ /dev/null @@ -1,7 +0,0 @@ -#! /usr/bin/python -import pydot - -edges=[("Hello",2), ("Hello",3), ("Hello",4), (3,4)] -g=pydot.graph_from_edges(edges, directed=True) -g.write_jpeg('graph_from_edges_dot.jpg', prog='dot') -g.write_svg( 'graph_from_edges_dot.svg', prog='dot') diff --git a/example-rank.py b/example-rank.py deleted file mode 100644 index 36b8fd2..0000000 --- a/example-rank.py +++ /dev/null @@ -1,7 +0,0 @@ - -graph = pydot.Dot('graphname', graph_type='digraph') -subg = pydot.Subgraph('', rank='same') -subg.add_node(pydot.Node('a')) -graph.add_subgraph(subg) -subg.add_node(pydot.Node('b')) -subg.add_node(pydot.Node('c')) diff --git a/pydot-1.0.28.tar.gz b/pydot-1.0.28.tar.gz deleted file mode 100644 index 95a077a..0000000 --- a/pydot-1.0.28.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:1eeaff7b104fb8f305a98318dafde0b2d15f1efcdf8b16206465551cd46ed9df -size 19711 diff --git a/pydot-1.2.3.tar.gz b/pydot-1.2.3.tar.gz new file mode 100644 index 0000000..29c3bf5 --- /dev/null +++ b/pydot-1.2.3.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:edb5d3f249f97fbd9c4bb16959e61bc32ecf40eee1a9f6d27abe8d01c0a73502 +size 20268 diff --git a/python-pydot-1.0.28_fix_pyparser_2_incompatibility.patch b/python-pydot-1.0.28_fix_pyparser_2_incompatibility.patch deleted file mode 100644 index 30ff320..0000000 --- a/python-pydot-1.0.28_fix_pyparser_2_incompatibility.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/dot_parser.py b/dot_parser.py -index dedd61a..138d152 100644 ---- a/dot_parser.py -+++ b/dot_parser.py -@@ -25,8 +25,9 @@ from pyparsing import __version__ as pyparsing_version - from pyparsing import ( nestedExpr, Literal, CaselessLiteral, Word, Upcase, OneOrMore, ZeroOrMore, - Forward, NotAny, delimitedList, oneOf, Group, Optional, Combine, alphas, nums, - restOfLine, cStyleComment, nums, alphanums, printables, empty, quotedString, -- ParseException, ParseResults, CharsNotIn, _noncomma, dblQuotedString, QuotedString, ParserElement ) -+ ParseException, ParseResults, CharsNotIn, dblQuotedString, QuotedString, ParserElement ) - -+_noncomma = "".join( [ c for c in printables if c != "," ] ) - - class P_AttrList: diff --git a/python-pydot.changes b/python-pydot.changes index 23fef7b..6acc644 100644 --- a/python-pydot.changes +++ b/python-pydot.changes @@ -1,3 +1,55 @@ +------------------------------------------------------------------- +Tue Nov 1 19:38:17 UTC 2016 - toddrme2178@gmail.com + +- Update to 1.2.3 + - support Python 2.6 + - several corrections + - quote empty strings to avoid graphviz errors +- Update to 1.2.0 + - support Python 3 + - bumped dependency to `pyparsing >= 2.1.4` + - tests running on Travis CI + - tests require `chardet` + - detect character encoding for most test files + using the package `chardet` + - API: + + on all operating systems, search GraphViz + executables in environment `$PATH`, + using `subprocess.Popen`. + No paths hard-coded due to security and privacy issues. + + add option to pass GraphViz executable name + or absolute path as `prog` to `pydot.Dot.write_*` methods. + This provides an alternative to + adding GraphViz to the `$PATH`. + + the functions: + * `pydot.graph_from_dot_data` + * `pydot.graph_from_dot_file` + * `dot_parser.parse_dot_data` + changed to always return a `list` of graphs, + instead of behaving differently for singletons. + + require that the user explicitly give an encoding to + the function `pydot.graph_from_dot_file`, + with default encoding same as `io.open`. + + decode to unicode at program boundaries, and + treat binary images as bytes, + for more compatibility with python 3. + Use `io.open`, instead of the built-in `open`. + + rm function `pydot.set_graphviz_executables` + + rm attribute `pydot.Dot.progs` +- Update to 1.1.0 + - compatibility with `pyparsing >= 1.5.7` + - API: + + `pydot.Graph.to_string`: hide `subgraph` keyword only if so requested + + produce `warnings.warn` if `pydot.dot_parser` fails to import, + instead of `print` +- Update to 1.0.29 + - Maintenance release that keeps the same API + - pin `pyparsing == 1.5.7` + - update version number in source code + - update `setup.py` +- Remove unneeded python-pydot-1.0.28_fix_pyparser_2_incompatibility.patch +- Remove out-of-date example files + ------------------------------------------------------------------- Sat May 3 14:00:00 UTC 2014 - andrea@opensuse.org diff --git a/python-pydot.spec b/python-pydot.spec index 416d5ab..1c2d134 100644 --- a/python-pydot.spec +++ b/python-pydot.spec @@ -1,7 +1,7 @@ # # spec file for package python-pydot # -# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2016 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,54 +16,44 @@ # -%define modname pydot -Name: python-%{modname} -Version: 1.0.28 +Name: python-pydot +Version: 1.2.3 Release: 0 Url: http://code.google.com/p/pydot Summary: Create (dot) graphs from python License: MIT Group: Development/Libraries/Python -Source: http://%{modname}.googlecode.com/files/%{modname}-%{version}.tar.gz -Source1: example-demo.py -Source2: example-rank.py -Patch0: %{name}-1.0.28_fix_pyparser_2_incompatibility.patch +Source: https://files.pythonhosted.org/packages/source/p/pydot/pydot-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: python-devel -Requires: python-pyparsing +BuildRequires: python-pyparsing >= 2.1.4 +BuildRequires: python-setuptools Requires: graphviz -%if 0%{?suse_version} <= 1110 -%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")} -%else +Requires: python-pyparsing >= 2.1.4 BuildArch: noarch -%py_requires -%endif %description pydot allows to easily create both directed and non directed graphs from Python. Currently all attributes implemented in the Dot language are supported (up to Graphviz 2.16). %prep -%setup -q -n %{modname}-%{version} -%patch0 -p1 -mkdir examples && cp %{SOURCE1} %{SOURCE2} examples +%setup -q -n pydot-%{version} %build -export CFLAGS="%{optflags}" python setup.py build %install python setup.py install --prefix=%{_prefix} --root=%{buildroot} -rm -rf %{buildroot}/usr/{LICENSE,README} # Wronly installed by setup script +# rm -rf %{buildroot}/usr/{LICENSE,README} # Wronly installed by setup script %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) -%doc README LICENSE examples +%doc README.md LICENSE %{python_sitelib}/dot_parser.py* -%{python_sitelib}/%{modname}.py* -%{python_sitelib}/%{modname}-%{version}-py%{py_ver}.egg-info +%{python_sitelib}/pydot.py* +%{python_sitelib}/pydot-%{version}-py*.egg-info %changelog