Fix Requires to be correct
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-flasgger?expand=0&rev=23
This commit is contained in:
commit
e698e4f3f6
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
|
3
_multibuild
Normal file
3
_multibuild
Normal file
@ -0,0 +1,3 @@
|
||||
<multibuild>
|
||||
<package>test</package>
|
||||
</multibuild>
|
BIN
flasgger-0.9.7.1.tar.gz
(Stored with Git LFS)
Normal file
BIN
flasgger-0.9.7.1.tar.gz
(Stored with Git LFS)
Normal file
Binary file not shown.
114
python-flasgger.changes
Normal file
114
python-flasgger.changes
Normal file
@ -0,0 +1,114 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 23 03:51:17 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
|
||||
|
||||
- Switch to autosetup macro.
|
||||
- Clean up BuildRequires for test flavor.
|
||||
- Add patch remove-six.patch:
|
||||
* Remove use of six.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Aug 23 08:51:03 UTC 2024 - pgajdos@suse.com
|
||||
|
||||
- drop dependency on python-flex
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 3 10:05:02 UTC 2024 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- require setuptools
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Nov 27 18:45:20 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- require new mistune
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Aug 8 05:34:15 UTC 2023 - Steve Kowalik <steven.kowalik@suse.com>
|
||||
|
||||
- Update to 0.9.7.1:
|
||||
* fix: flask >== 2.3 json encoder change
|
||||
* removed usage of safe_str_cmp of werkzeug. using hmac.compare_digest
|
||||
instead (#532)
|
||||
* Fix openapi3 request parse validation (#505)
|
||||
* Fix required body if one parameter is required (#476)
|
||||
* Implemented the SwaggerUI urls config parameter which displays a
|
||||
dropdown of API specs instead of an editable textbox (#473)
|
||||
* Fix indentation in readme example (#480)
|
||||
* fix path parameter bug for integers (#485)
|
||||
* Wrapping APISpecsView get response in a try except (#420)
|
||||
* Trivial flake issue resolved for docker build of flasgger (#452)
|
||||
* Deprecate imp [Breaks py2.7 compatibility] (#413) Resolves #434
|
||||
* Remove python2
|
||||
* Fix error format and add regression tests
|
||||
* Extract is_openapi3 in utils and test it
|
||||
* Add flask_mongorest
|
||||
* Set displayOperationId to true
|
||||
* Add use func validate from utils
|
||||
* add test case for post request
|
||||
* Change test for swag_schema
|
||||
* Add Swagger UI auth config to ui.inioauth
|
||||
* Make available oauth2 redirect html
|
||||
- Switch to pyproject macros.
|
||||
- Stop using globs in %files
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Apr 21 12:25:11 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- add sle15_python_module_pythons (jsc#PED-68)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Apr 13 22:41:17 UTC 2023 - Matej Cepl <mcepl@suse.com>
|
||||
|
||||
- Make calling of %{sle15modernpython} optional.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Dec 22 08:47:43 UTC 2022 - Daniel Garcia <daniel.garcia@suse.com>
|
||||
|
||||
- Add multibuild for tests to avoid package build cycle.
|
||||
flasgger -> flex (testing) -> httpbin -> flasgger
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun Oct 23 10:03:15 UTC 2022 - John Vandenberg <jayvdb@gmail.com>
|
||||
|
||||
- Re-activate test suite
|
||||
- Also remove the conditional definition of python_module.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Apr 28 07:23:15 UTC 2022 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Update to 0.9.5
|
||||
* 'swag_from' supports 'pathlib.Path'
|
||||
* Added support for OpenAPI3 parameter schema parsing
|
||||
* Add support for custom validation_function and error_handler
|
||||
* Ensure downward compatibility for werkzeug
|
||||
* Changed jsonschema version supported to jsonschema>=3.0.1
|
||||
* Changed json data to be parsed from request directly
|
||||
* More changes, see upstream HISTORY
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Aug 6 14:25:47 UTC 2019 - Todd R <toddrme2178@gmail.com>
|
||||
|
||||
- Update to 0.9.3
|
||||
* Fix compatibility with Flask GraphQL
|
||||
* apispec_to_template definition bugfix
|
||||
* Bugfix: can't dict.update([dict])
|
||||
* Add support for docExpansion in UI 2
|
||||
* Switch `yaml.load` to `yaml.safe_load`.
|
||||
* Add safe getter with empty return if attrib does not exist
|
||||
* swagger-ui 3 version updated to 3.20.5
|
||||
* use JWT_AUTH_HEADER_NAME (default value: Authorization)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Mar 15 10:35:24 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
||||
|
||||
- Comment the builddeps as they create cycle, when the tests are
|
||||
actually working we need to mulitbuild this pkg
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Mar 14 17:03:22 UTC 2019 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Generalize description and use noun phrase.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Mar 14 11:59:26 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
||||
|
||||
- Initial commit, needed by httpbin
|
94
python-flasgger.spec
Normal file
94
python-flasgger.spec
Normal file
@ -0,0 +1,94 @@
|
||||
#
|
||||
# spec file for package python-flasgger
|
||||
#
|
||||
# Copyright (c) 2025 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/
|
||||
#
|
||||
|
||||
|
||||
%global flavor @BUILD_FLAVOR@%{nil}
|
||||
%if "%{flavor}" == "test"
|
||||
%define psuffix -test
|
||||
%bcond_without test
|
||||
%else
|
||||
%define psuffix %{nil}
|
||||
%bcond_with test
|
||||
%endif
|
||||
|
||||
%{?sle15_python_module_pythons}
|
||||
Name: python-flasgger%{psuffix}
|
||||
Version: 0.9.7.1
|
||||
Release: 0
|
||||
Summary: Tool to extract swagger specs from Flask projects
|
||||
License: MIT
|
||||
URL: https://github.com/flasgger/flasgger/
|
||||
Source: https://files.pythonhosted.org/packages/source/f/flasgger/flasgger-%{version}.tar.gz
|
||||
# PATCH-FIX-UPSTREAM Based on gh#flasgger/flasgger#629
|
||||
Patch0: remove-six.patch
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
Requires: python-Flask >= 0.10
|
||||
Requires: python-PyYAML >= 3.0
|
||||
Requires: python-jsonschema >= 3.0.1
|
||||
Requires: python-mistune >= 3
|
||||
Requires: python-packaging
|
||||
BuildArch: noarch
|
||||
%if %{with test}
|
||||
# SECTION test requirements
|
||||
BuildRequires: %{python_module flasgger = %{version}}
|
||||
BuildRequires: %{python_module marshmallow}
|
||||
BuildRequires: %{python_module pytest >= 3.0.7}
|
||||
# /SECTION
|
||||
%endif
|
||||
|
||||
%python_subpackages
|
||||
|
||||
%description
|
||||
Flasgger is a Flask extension to extract OpenAPI=Specification from all Flask views registered in an API.
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -n flasgger-%{version}
|
||||
|
||||
# Examples directory is not included in PyPI release
|
||||
rm tests/test_examples.py
|
||||
|
||||
find . -name .DS_Store -print -delete
|
||||
|
||||
%if !%{with test}
|
||||
%build
|
||||
%pyproject_wheel
|
||||
|
||||
%install
|
||||
%pyproject_install
|
||||
%{python_expand chmod -x %{buildroot}%{$python_sitelib}/flasgger/ui2/static/lang/*.js
|
||||
%fdupes %{buildroot}%{$python_sitelib}
|
||||
}
|
||||
%endif
|
||||
|
||||
%if %{with test}
|
||||
%check
|
||||
%pytest tests/
|
||||
%endif
|
||||
|
||||
%if !%{with test}
|
||||
%files %{python_files}
|
||||
%license LICENSE
|
||||
%doc README.md
|
||||
%{python_sitelib}/flasgger
|
||||
%{python_sitelib}/flasgger-%{version}.dist-info
|
||||
%endif
|
||||
|
||||
%changelog
|
57
remove-six.patch
Normal file
57
remove-six.patch
Normal file
@ -0,0 +1,57 @@
|
||||
From 0c4f8e15c6a730a20326ba78bf725e49e8682672 Mon Sep 17 00:00:00 2001
|
||||
From: Steve Kowalik <steven@wedontsleep.org>
|
||||
Date: Thu, 23 Jan 2025 14:29:09 +1100
|
||||
Subject: [PATCH] Remove use of six
|
||||
|
||||
Now that Python 2 support has been removed, we can stop using the crutch
|
||||
of six to support both versions. StringLike could probably be
|
||||
refactored now to be a subclass of str, but I have left that alone to
|
||||
make this diff small.
|
||||
---
|
||||
flasgger/utils.py | 5 ++---
|
||||
requirements.txt | 3 +--
|
||||
setup.py | 1 -
|
||||
3 files changed, 3 insertions(+), 6 deletions(-)
|
||||
|
||||
Index: flasgger-0.9.7.1/flasgger/utils.py
|
||||
===================================================================
|
||||
--- flasgger-0.9.7.1.orig/flasgger/utils.py
|
||||
+++ flasgger-0.9.7.1/flasgger/utils.py
|
||||
@@ -9,7 +9,6 @@ import re
|
||||
import sys
|
||||
import jsonschema
|
||||
import yaml
|
||||
-from six import string_types, text_type
|
||||
from copy import deepcopy
|
||||
from functools import wraps
|
||||
from importlib import import_module
|
||||
@@ -269,7 +268,7 @@ def swag_from(
|
||||
def is_path(specs):
|
||||
""" Returns True if specs is a string or pathlib.Path
|
||||
"""
|
||||
- is_str_path = isinstance(specs, string_types)
|
||||
+ is_str_path = isinstance(specs, str)
|
||||
try:
|
||||
from pathlib import Path
|
||||
is_py3_path = isinstance(specs, Path)
|
||||
@@ -928,7 +927,7 @@ class StringLike(object):
|
||||
|
||||
@property
|
||||
def text_type(self):
|
||||
- return text_type
|
||||
+ return str
|
||||
|
||||
|
||||
class LazyString(StringLike):
|
||||
Index: flasgger-0.9.7.1/setup.py
|
||||
===================================================================
|
||||
--- flasgger-0.9.7.1.orig/setup.py
|
||||
+++ flasgger-0.9.7.1/setup.py
|
||||
@@ -54,7 +54,6 @@ setup(
|
||||
'PyYAML>=3.0',
|
||||
'jsonschema>=3.0.1',
|
||||
'mistune',
|
||||
- 'six>=1.10.0',
|
||||
'packaging',
|
||||
],
|
||||
classifiers=[
|
Loading…
x
Reference in New Issue
Block a user