Sync from SUSE:SLFO:Main python-xmltodict revision 949bfa6909b8f01ee9d7e4ec7a2e85fb
This commit is contained in:
commit
c7221b92b0
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
|
115
python-xmltodict.changes
Normal file
115
python-xmltodict.changes
Normal file
@ -0,0 +1,115 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue May 9 13:41:52 UTC 2023 - Johannes Kastl <kastl@b1-systems.de>
|
||||||
|
|
||||||
|
- add sle15_python_module_pythons
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Sun Jun 19 17:47:26 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
- update to 0.13.0:
|
||||||
|
* Add install info to readme for openSUSE. (#205)
|
||||||
|
* Support defaultdict for namespace mapping (#211)
|
||||||
|
* parse(generator) is now possible (#212)
|
||||||
|
* Processing comments on parsing from xml to dict (connected to #109) (#221)
|
||||||
|
* Add expand_iter kw to unparse to expand iterables (#213)
|
||||||
|
* Fixed some typos
|
||||||
|
* Add support for python3.8
|
||||||
|
* Drop Jython/Python 2 and add Python 3.9/3.10.
|
||||||
|
* Drop OrderedDict in Python >= 3.7
|
||||||
|
* Do not use len() to determine if a sequence is empty
|
||||||
|
* Add more namespace attribute tests
|
||||||
|
* Fix encoding issue in setup.py
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Feb 22 10:27:36 UTC 2022 - Steve Kowalik <steven.kowalik@suse.com>
|
||||||
|
|
||||||
|
- Add patch skip-tests-expat-245.patch:
|
||||||
|
* Do not run tests that make no sense with a current Expat.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri May 29 10:34:50 UTC 2020 - Marketa Calabkova <mcalabkova@suse.com>
|
||||||
|
|
||||||
|
- Replace nose with pytest
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Sat Apr 6 00:00:15 UTC 2019 - John Vandenberg <jayvdb@gmail.com>
|
||||||
|
|
||||||
|
- Add export LANG=en_US.UTF-8 to fix Leap builds
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Mar 26 12:20:55 UTC 2019 - Jan Engelhardt <jengelh@inai.de>
|
||||||
|
|
||||||
|
- Use noun phrase in summary.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Mar 26 11:02:52 UTC 2019 - pgajdos@suse.com
|
||||||
|
|
||||||
|
- version update to 0.12.0
|
||||||
|
* Allow force_commits=True for getting all keys as lists (#204)
|
||||||
|
* README.md: fix useless uses of cat (#200)
|
||||||
|
* Add FreeBSD install instructions (#199)
|
||||||
|
* Fix and simplify travis config (#192)
|
||||||
|
* Add support for Python 3.7 (#189)
|
||||||
|
* Drop support for EOL Python (#191)
|
||||||
|
* Use Markdown long_description on PyPI (#190)
|
||||||
|
* correct spelling mistake (#165)
|
||||||
|
* correctly unparse booleans (#180)
|
||||||
|
* Updates README.md with svg badge
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Dec 4 12:56:17 UTC 2018 - Matej Cepl <mcepl@suse.com>
|
||||||
|
|
||||||
|
- Remove superfluous devel dependency for noarch package
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu May 18 15:01:55 UTC 2017 - toddrme2178@gmail.com
|
||||||
|
|
||||||
|
- Implement single-spec version
|
||||||
|
- Fix source URL.
|
||||||
|
- Update to version 0.11.0
|
||||||
|
* Determine fileness by checking for read attr
|
||||||
|
* Add support for Python 3.6.
|
||||||
|
* Release as a universal wheel.
|
||||||
|
* Updated docs examples to use print function.
|
||||||
|
* unparse: pass short_empty_elements to XMLGenerator
|
||||||
|
* Added namespace support when unparsing.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Sep 6 07:25:55 UTC 2016 - mardnh@gmx.de
|
||||||
|
|
||||||
|
- update to version 0.10.2
|
||||||
|
+ Fixed defusedexpat expat import.
|
||||||
|
- v0.10.1
|
||||||
|
+ Use defusedexpat if available.
|
||||||
|
+ Allow non-string attributes in unparse.
|
||||||
|
+ Add postprocessor support for attributes.
|
||||||
|
+ Make command line interface Python 3-compatible.
|
||||||
|
- v0.10.0
|
||||||
|
+ Add force_list feature.
|
||||||
|
+ Add support for Python 3.4 and 3.5.
|
||||||
|
+ Performance optimization: use list instead of string for CDATA.
|
||||||
|
+ Include Arch Linux package instructions in README.
|
||||||
|
+ Improved documentation.
|
||||||
|
+ Allow any iterable in unparse, not just lists.
|
||||||
|
+ Bugfix: Process namespaces in attributes too.
|
||||||
|
+ Better testing under Python 2.6.
|
||||||
|
- v0.9.2
|
||||||
|
+ Fix multiroot check for list values
|
||||||
|
- v0.9.1
|
||||||
|
+ Only check single root when full_document=True
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Nov 27 14:46:28 UTC 2014 - boris@steki.net
|
||||||
|
|
||||||
|
- add python-xml to all *suse distributions as SLE 12 requires it too
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Nov 3 13:45:57 UTC 2014 - boris@steki.net
|
||||||
|
|
||||||
|
- add python-xml to requires to enable SLE build
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Sep 10 12:48:51 UTC 2014 - boris@steki.net
|
||||||
|
|
||||||
|
- initial packaging of 0.9.0 version
|
||||||
|
|
66
python-xmltodict.spec
Normal file
66
python-xmltodict.spec
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
#
|
||||||
|
# spec file for package python-xmltodict
|
||||||
|
#
|
||||||
|
# Copyright (c) 2023 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-xmltodict
|
||||||
|
Version: 0.13.0
|
||||||
|
Release: 0
|
||||||
|
Summary: Module to make XML working resemble JSON
|
||||||
|
License: MIT
|
||||||
|
URL: https://github.com/martinblech/xmltodict
|
||||||
|
Source: https://files.pythonhosted.org/packages/source/x/xmltodict/xmltodict-%{version}.tar.gz
|
||||||
|
Patch0: skip-tests-expat-245.patch
|
||||||
|
BuildRequires: %{python_module setuptools}
|
||||||
|
BuildRequires: %{python_module xml}
|
||||||
|
BuildRequires: fdupes
|
||||||
|
BuildRequires: python-rpm-macros
|
||||||
|
Requires: python-xml
|
||||||
|
BuildArch: noarch
|
||||||
|
BuildRequires: %{python_module pytest}
|
||||||
|
%python_subpackages
|
||||||
|
|
||||||
|
%description
|
||||||
|
xmltodict is a Python module that makes working with XML feel like you are
|
||||||
|
working with json, as in this:
|
||||||
|
http://www.xml.com/pub/a/2006/05/31/converting-between-xml-and-json.html
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup -p1 -n xmltodict-%{version}
|
||||||
|
sed -i '1{\@^#!%{_bindir}/env python@d}' xmltodict.py
|
||||||
|
|
||||||
|
%build
|
||||||
|
export LANG=en_US.UTF-8
|
||||||
|
%python_build
|
||||||
|
|
||||||
|
%install
|
||||||
|
export LANG=en_US.UTF-8
|
||||||
|
%python_install
|
||||||
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||||
|
|
||||||
|
%check
|
||||||
|
export LANG=en_US.UTF-8
|
||||||
|
%pytest
|
||||||
|
|
||||||
|
%files %{python_files}
|
||||||
|
%license LICENSE
|
||||||
|
%doc README.md
|
||||||
|
%{python_sitelib}/xmltodict.py*
|
||||||
|
%pycache_only %{python_sitelib}/__pycache__/xmltodict.*.py*
|
||||||
|
%{python_sitelib}/xmltodict-%{version}-py*.egg-info
|
||||||
|
|
||||||
|
%changelog
|
28
skip-tests-expat-245.patch
Normal file
28
skip-tests-expat-245.patch
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
Index: xmltodict-0.12.0/tests/test_xmltodict.py
|
||||||
|
===================================================================
|
||||||
|
--- xmltodict-0.12.0.orig/tests/test_xmltodict.py
|
||||||
|
+++ xmltodict-0.12.0/tests/test_xmltodict.py
|
||||||
|
@@ -8,6 +8,7 @@ except ImportError:
|
||||||
|
|
||||||
|
from xml.parsers.expat import ParserCreate
|
||||||
|
from xml.parsers import expat
|
||||||
|
+import pyexpat
|
||||||
|
|
||||||
|
|
||||||
|
def _encode(s):
|
||||||
|
@@ -167,6 +168,7 @@ class XMLToDictTestCase(unittest.TestCas
|
||||||
|
self.assertEqual(parse(xml),
|
||||||
|
parse(xml.encode('utf-8')))
|
||||||
|
|
||||||
|
+ @unittest.skipIf(pyexpat.version_info >= (2, 4, 5), reason="Makes no sense with current Expat")
|
||||||
|
def test_namespace_support(self):
|
||||||
|
xml = """
|
||||||
|
<root xmlns="http://defaultns.com/"
|
||||||
|
@@ -195,6 +197,7 @@ class XMLToDictTestCase(unittest.TestCas
|
||||||
|
res = parse(xml, process_namespaces=True)
|
||||||
|
self.assertEqual(res, d)
|
||||||
|
|
||||||
|
+ @unittest.skipIf(pyexpat.version_info >= (2, 4, 5), reason="Makes no sense with current Expat")
|
||||||
|
def test_namespace_collapse(self):
|
||||||
|
xml = """
|
||||||
|
<root xmlns="http://defaultns.com/"
|
BIN
xmltodict-0.13.0.tar.gz
(Stored with Git LFS)
Normal file
BIN
xmltodict-0.13.0.tar.gz
(Stored with Git LFS)
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user