1
0

Compare commits

2 Commits

Author SHA256 Message Date
196e2b587b Accepting request 1227007 from devel:languages:python
- Update to 0.3.4:
  * Support python 3.13
  * fix: python < 3.7 using pip install failed
- Use pytest and license macros.
- Remove patch remove-failing-test.py, no longer required.

OBS-URL: https://build.opensuse.org/request/show/1227007
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-jsonformatter?expand=0&rev=2
2024-11-28 21:42:46 +00:00
c74dc07d62 - Update to 0.3.4:
* Support python 3.13
  * fix: python < 3.7 using pip install failed
- Use pytest and license macros.
- Remove patch remove-failing-test.py, no longer required.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-jsonformatter?expand=0&rev=3
2024-11-28 04:54:24 +00:00
5 changed files with 20 additions and 25 deletions

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:d69c4b294cd9030b6803659924908f979ae827f5bdccde6a3815c0afb062948f
size 15058

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:af71ae1534a80d6f60f8d5ee7bfa70c2e45389ed803ed94239f4305b7c68105d
size 21289

View File

@@ -1,3 +1,12 @@
-------------------------------------------------------------------
Thu Nov 28 04:53:42 UTC 2024 - Steve Kowalik <steven.kowalik@suse.com>
- Update to 0.3.4:
* Support python 3.13
* fix: python < 3.7 using pip install failed
- Use pytest and license macros.
- Remove patch remove-failing-test.py, no longer required.
-------------------------------------------------------------------
Mon Apr 8 08:43:00 UTC 2024 - Antonio Larrosa <alarrosa@suse.com>

View File

@@ -18,19 +18,19 @@
%{?sle15_python_module_pythons}
Name: python-jsonformatter
Version: 0.3.2
Version: 0.3.4
Release: 0
Summary: Python log in json format
License: BSD-2-Clause
URL: https://github.com/MyColorfulDays/jsonformatter.git
Source: https://files.pythonhosted.org/packages/source/j/jsonformatter/jsonformatter-%{version}.tar.gz
Patch0: remove-failing-test.py
BuildRequires: dos2unix
BuildRequires: python-rpm-macros
BuildRequires: %{python_module pip}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module wheel}
BuildRequires: dos2unix
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildArch: noarch
%python_subpackages
@@ -40,8 +40,8 @@ A formatter for python logging that outputs json log
%prep
%autosetup -p1 -n jsonformatter-%{version}
find . -type f -exec chmod -x {} \;
dos2unix jsonformatter/__init__.py
sed -i '1{\,^#!%{_bindir}/env python,d}' jsonformatter/*.py
dos2unix README.md
sed -i '1{\,^#!%{_bindir}/env python,d}' src/jsonformatter/*.py
%build
%pyproject_wheel
@@ -51,13 +51,11 @@ sed -i '1{\,^#!%{_bindir}/env python,d}' jsonformatter/*.py
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
%{python_expand #
export PYTHONPATH=%{buildroot}%{$python_sitelib}
$python test/test.py
}
%pytest -k 'not test_file_config' tests
%files %{python_files}
%doc README.md
%license LICENSE
%{python_sitelib}/jsonformatter
%{python_sitelib}/jsonformatter-%{version}.dist-info

View File

@@ -1,12 +0,0 @@
Index: jsonformatter-0.3.2/test/test.py
===================================================================
--- jsonformatter-0.3.2.orig/test/test.py
+++ jsonformatter-0.3.2/test/test.py
@@ -350,6 +350,7 @@ class JsonFormatterTest(unittest.TestCas
root.info('test json dumps parameter `ensure_ascii` False: 中文')
+ @unittest.skip('fails to run')
def test_file_config(self):
fileConfig(os.path.join(os.path.dirname(
__file__), 'logger_config.ini'))