forked from pool/python-flake8-pyi
Accepting request 1105894 from home:mcalabkova:branches:devel:languages:python
- Update to 23.6.0
* Y011/Y014/Y015: Allow math constants math.inf, math.nan, math.e,
math.pi, math.tau, and their negatives in default values. Some
other semantically equivalent values, such as x = inf (from math
import inf), or x = np.inf (import numpy as np), should be rewritten
to x = math.inf.
* Y053: Disallow string or bytes literals with length >50 characters.
Previously this rule only applied to parameter default values;
it now applies everywhere.
* Y054: Disallow numeric literals with a string representation >10
characters long. Previously this rule only applied to parameter
default values; it now applies everywhere.
* Y055: Unions of the form type[X] | type[Y] can be simplified to type[X | Y].
* The way in which flake8-pyi modifies pyflakes runs has been improved.
* Introduce Y056: Various type checkers have different levels of support
for method calls on __all__. Use __all__ += ["foo", "bar"] instead,
as this is known to be supported by all major type checkers.
* Support Python 3.12
* Support PEP 695 syntax for declaring type aliases
* Introduce Y057: Do not use typing.ByteString or collections.abc.ByteString.
* flake8-pyi no longer supports being run on Python 3.7.
* flake8-pyi no longer supports being run with flake8 <v6.
OBS-URL: https://build.opensuse.org/request/show/1105894
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-flake8-pyi?expand=0&rev=19
This commit is contained in:
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:226866b75e8ae264e47799576ebbac96323cee6b85196bd286baa30a19bddf65
|
||||
size 46799
|
||||
3
flake8_pyi-23.6.0.tar.gz
Normal file
3
flake8_pyi-23.6.0.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:597c750fd0394a237d4e0b51feb222b3cc7a7ebee5b3c59a15b58f6b3f2836a7
|
||||
size 51066
|
||||
@@ -1,3 +1,29 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Aug 25 11:40:31 UTC 2023 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Update to 23.6.0
|
||||
* Y011/Y014/Y015: Allow math constants math.inf, math.nan, math.e,
|
||||
math.pi, math.tau, and their negatives in default values. Some
|
||||
other semantically equivalent values, such as x = inf (from math
|
||||
import inf), or x = np.inf (import numpy as np), should be rewritten
|
||||
to x = math.inf.
|
||||
* Y053: Disallow string or bytes literals with length >50 characters.
|
||||
Previously this rule only applied to parameter default values;
|
||||
it now applies everywhere.
|
||||
* Y054: Disallow numeric literals with a string representation >10
|
||||
characters long. Previously this rule only applied to parameter
|
||||
default values; it now applies everywhere.
|
||||
* Y055: Unions of the form type[X] | type[Y] can be simplified to type[X | Y].
|
||||
* The way in which flake8-pyi modifies pyflakes runs has been improved.
|
||||
* Introduce Y056: Various type checkers have different levels of support
|
||||
for method calls on __all__. Use __all__ += ["foo", "bar"] instead,
|
||||
as this is known to be supported by all major type checkers.
|
||||
* Support Python 3.12
|
||||
* Support PEP 695 syntax for declaring type aliases
|
||||
* Introduce Y057: Do not use typing.ByteString or collections.abc.ByteString.
|
||||
* flake8-pyi no longer supports being run on Python 3.7.
|
||||
* flake8-pyi no longer supports being run with flake8 <v6.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Mar 6 15:53:17 UTC 2023 - Daniel Garcia <daniel.garcia@suse.com>
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
%define skip_python2 1
|
||||
Name: python-flake8-pyi
|
||||
Version: 23.1.2
|
||||
Version: 23.6.0
|
||||
Release: 0
|
||||
Summary: A plugin for flake8 to enable linting .pyi files
|
||||
License: MIT
|
||||
@@ -29,14 +29,14 @@ Source: https://files.pythonhosted.org/packages/source/f/flake8-pyi/flak
|
||||
# PYTHONPATH resolution for tests running inside osc
|
||||
Patch0: set-tests-python-path.patch
|
||||
BuildRequires: %{python_module ast-decompiler}
|
||||
BuildRequires: %{python_module base >= 3.6.0}
|
||||
BuildRequires: %{python_module base >= 3.8.0}
|
||||
BuildRequires: %{python_module hatchling}
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: python-rpm-macros
|
||||
# SECTION test requirements
|
||||
BuildRequires: %{python_module attrs}
|
||||
BuildRequires: %{python_module flake8 >= 3.2.1}
|
||||
BuildRequires: %{python_module flake8 >= 6.0.0}
|
||||
BuildRequires: %{python_module pyflakes >= 2.1.1}
|
||||
# Use pytest directly to bypass setup.py test dependencies
|
||||
BuildRequires: %{python_module pytest}
|
||||
@@ -46,8 +46,8 @@ BuildRequires: %{python_module typing}
|
||||
# /SECTION
|
||||
BuildRequires: fdupes
|
||||
Requires: python-attrs
|
||||
Requires: python-base >= 3.6.0
|
||||
Requires: python-flake8 >= 3.2.1
|
||||
Requires: python-base >= 3.8.0
|
||||
Requires: python-flake8 >= 6.0.0
|
||||
Requires: python-pyflakes >= 2.1.1
|
||||
Requires: python-typing
|
||||
BuildArch: noarch
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
Index: flake8_pyi-23.1.2/tests/test_pyi_files.py
|
||||
Index: flake8_pyi-23.6.0/tests/test_pyi_files.py
|
||||
===================================================================
|
||||
--- flake8_pyi-23.1.2.orig/tests/test_pyi_files.py
|
||||
+++ flake8_pyi-23.1.2/tests/test_pyi_files.py
|
||||
@@ -35,16 +35,21 @@ def test_pyi_file(path: str) -> None:
|
||||
message = line[match.end() : end_pos].strip()
|
||||
expected_output += f"{path}:{lineno}: {match.group(1)}{message}\n"
|
||||
--- flake8_pyi-23.6.0.orig/tests/test_pyi_files.py
|
||||
+++ flake8_pyi-23.6.0/tests/test_pyi_files.py
|
||||
@@ -42,16 +42,21 @@ def test_pyi_file(path: str) -> None:
|
||||
option = flag.split("=")[0]
|
||||
assert option != "--ignore", bad_flag_msg
|
||||
|
||||
+ pythonpath = os.environ.get("PYTHONPATH")
|
||||
+ pythonpath = f"PYTHONPATH={pythonpath}:."
|
||||
|
||||
Reference in New Issue
Block a user