commit 99e698c4ffeb722c2b7d7f5b8b3f2061d0a8acc79f9273f565b528585236e010 Author: Dirk Mueller Date: Sun Sep 1 19:15:23 2024 +0000 - add python313.patch: * skip known testfailure with 3.13 :func:`long_typename`, :func:`safe_repr`, :func:`short_repr`, OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-objgraph?expand=0&rev=19 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -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 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/objgraph-3.6.1.tar.gz b/objgraph-3.6.1.tar.gz new file mode 100644 index 0000000..e97a1da --- /dev/null +++ b/objgraph-3.6.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fe96c74147bbcaae8665b396e5388bdcc3197deebba4e6381f05202ee5b453a7 +size 759513 diff --git a/python-objgraph.changes b/python-objgraph.changes new file mode 100644 index 0000000..b858a39 --- /dev/null +++ b/python-objgraph.changes @@ -0,0 +1,129 @@ +------------------------------------------------------------------- +Sun Sep 1 19:14:13 UTC 2024 - Dirk Müller + +- add python313.patch: + * skip known testfailure with 3.13 + +------------------------------------------------------------------- +Sat Mar 16 08:32:06 UTC 2024 - Dirk Müller + +- update to 3.6.1: + * Add support for Python 3.12. + +------------------------------------------------------------------- +Tue Dec 12 10:53:15 UTC 2023 - Dirk Müller + +- update to 3.6.0: + * Add support for Python 3.9, 3.10, and 3.11. + * Drop support for Python 2.7 and 3.6. + +------------------------------------------------------------------- +Fri Apr 21 12:28:40 UTC 2023 - Dirk Müller + +- add sle15_python_module_pythons (jsc#PED-68) + +------------------------------------------------------------------- +Thu Apr 13 22:42:45 UTC 2023 - Matej Cepl + +- Make calling of %{sle15modernpython} optional. + +------------------------------------------------------------------- +Mon May 31 11:01:37 UTC 2021 - pgajdos@suse.com + +- version update to 3.5.0 + - Do not require ``mock`` for the test suite on Python 3; use unittest.mock + instead. + - 100% test coverage for each version of Python rather than combined, using + ``coverage-python-version``. + - Add the optional ``extra_node_attrs`` parameter to ``show_backrefs`` and + ``show_backrefs`` + - Fix IPython/Jupyter inline graph support code that would kick in even if you + explicitly passed a filename='foo.png' argument to + ``show_refs``/``show_backrefs``. See `issue 47 + `_. + - Add support for Python 3.8. + - Drop support for Python 3.5. +- %check: use %pytest rpm macro + +------------------------------------------------------------------- +Mon Jun 3 11:21:35 UTC 2019 - Tomáš Chvátal + +- Update to 3.4.1: + * Add support for Python 3.7. + * Drop support for Python 3.3 and 3.4. + +------------------------------------------------------------------- +Tue Dec 4 12:50:59 UTC 2018 - Matej Cepl + +- Remove superfluous devel dependency for noarch package + +------------------------------------------------------------------- +Thu Jun 7 20:27:33 UTC 2018 - jengelh@inai.de + +- Use noun phrase in summary. Replace 1st and 2nd person wording. + +------------------------------------------------------------------- +Thu May 3 14:30:39 UTC 2018 - toddrme2178@gmail.com + +- Update to version 3.4.0 + * New functions: :func:`get_new_ids`, :func:`at_addrs`. +- Update to version 3.3.0 + * New function: :func:`growth`. +- Update to version 3.2.0 + * New ``filter`` argument for :func:`typestats`, :func:`most_common_types`, + :func:`show_most_common_types`, :func:`show_growth`. + * Show lambda functions in a more human-friendly way. +- Update to version 3.1.2 + * Correct UTF-8 mojibake in the changelog and switch all links to HTTPS. +- Update to version 3.1.1 + * Add support for Python 3.6. + * Replace bare ``except:`` in ``safe_repr()`` with ``except Exception:``. +- Use %license tag + +------------------------------------------------------------------- +Wed Apr 19 16:16:46 UTC 2017 - toddrme2178@gmail.com + +- Update to version 3.1.0 + * Support displaying graphs inline in IPython/Jupyter notebooks (`issue 28 + `). +- Update to version 3.0.1 + * The ``file`` argument of :func:`show_most_common_types` and + :func:`show_growth` now defaults to ``None`` instead of ``sys.stdout``. + ``None`` is interpreted to be the same as ``sys.stdout``, which means + the right stdout will be used if you change it at runtime (which happens, + in doctests). +- Update to version 3.0.0 + * :func:`show_most_common_types` and :func:`show_growth` now accept a ``file`` + argument if you want to redirect the output elsewhere. + * Don't trust ``__class__`` to be accurate and ``__name__`` to be a string. + Fixes errors in some convoluted corner cases when mocks are involved. + * Drop support for Python 2.4, 2.5, and 2.6. + * Drop support for Python 3.1 and 3.2. + * Add support for Python 3.5. +- Update to version 2.0.1 + * Avoid creating reference cycles between the stack frame and the local + ``objects`` variable in :func:`by_type`, :func:`count`, and + :func:`typestats`. +- Update to version 2.0.0 + * :func:`show_refs` and :func:`show_backrefs` now accept a file-like object + (via the new ``output`` argument) as an alternative to a filename. + * Made internal helper methods private. This includes :func:`find_chain`, + :func:`show_graph`, :func:`obj_node_id`, :func:`obj_label`, :func:`quote`, + :func:`long_typename`, :func:`safe_repr`, :func:`short_repr`, + :func:`gradient`, :func:`edge_label`, and :func:`_program_in_path`. + * Correctly determine the name of old-style classes in :func:`count`, + :func:`by_type`, and graph drawing functions. +- Implement singlespec version. + +------------------------------------------------------------------- +Tue Sep 30 11:59:33 UTC 2014 - toddrme2178@gmail.com + +- Fix building. + * We don't actually need graphviz-python + * We do need graphviz-gnome after all + +------------------------------------------------------------------- +Tue Sep 30 10:47:41 UTC 2014 - toddrme2178@gmail.com + +- Initial version + diff --git a/python-objgraph.spec b/python-objgraph.spec new file mode 100644 index 0000000..4db3e66 --- /dev/null +++ b/python-objgraph.spec @@ -0,0 +1,70 @@ +# +# spec file for package python-objgraph +# +# Copyright (c) 2024 SUSE LLC +# +# 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-objgraph +Version: 3.6.1 +Release: 0 +Summary: Python module to draw object reference graphs with graphviz +License: MIT +Group: Development/Languages/Python +URL: http://mg.pov.lt/objgraph/ +Source: https://files.pythonhosted.org/packages/source/o/objgraph/objgraph-%{version}.tar.gz +# see https://github.com/mgedmin/objgraph/issues/80 +Patch1: python313.patch +BuildRequires: %{python_module graphviz} +BuildRequires: %{python_module pip} +BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} +BuildRequires: fdupes +BuildRequires: graphviz-gd +BuildRequires: graphviz-gnome +BuildRequires: python-rpm-macros +Requires: graphviz-gd +Requires: graphviz-gnome +Requires: python-graphviz +BuildArch: noarch +%python_subpackages + +%description +objgraph is a module for visual exploration of Python object graphs. + +graphviz is needed if pretty graphs are desired. +xdot can be used for interactive use. + +%prep +%autosetup -p1 -n objgraph-%{version} + +%build +%pyproject_wheel + +%install +%pyproject_install +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%check +%pyunittest discover -v + +%files %{python_files} +%doc README.rst CHANGES.rst HACKING.rst +%license LICENSE +%{python_sitelib}/objgraph.py +%pycache_only %{python_sitelib}/__pycache__/objgraph* +%{python_sitelib}/objgraph-%{version}.dist-info + +%changelog diff --git a/python313.patch b/python313.patch new file mode 100644 index 0000000..d69754d --- /dev/null +++ b/python313.patch @@ -0,0 +1,12 @@ +Index: objgraph-3.6.1/tests.py +=================================================================== +--- objgraph-3.6.1.orig/tests.py ++++ objgraph-3.6.1/tests.py +@@ -465,6 +465,7 @@ class StringRepresentationTest(GarbageCo + objgraph._gradient((0.1, 0.2, 0.3), + (0.2, 0.3, 0.4), 0, 0)) + ++ @skipIf(sys.version_info[1] > 12, "Python 3.13 fails with error here (gh#mgedmin/objgraph#80)") + def test_edge_label_frame_locals(self): + frame = sys._getframe() + self.assertEqual(' [label="f_locals",weight=10]',