forked from pool/python-blue
- Upgrade to 0.9.0:
- Fix test suite failures due to a confluence of problems - Upgrade dependency on Black to 22.1.0 to support Python 3.10 - Add link to demo site at https://iblueit.dev OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-blue?expand=0&rev=15
This commit is contained in:
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:e097b83a5937b9c420e4a18063525f5b38e65a4396976ea681bdb405f07269d1
|
||||
size 86462
|
||||
3
blue-0.9.0.tar.gz
Normal file
3
blue-0.9.0.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:b6191156d022a688f911daba92dcf673d64ff342cd9ceeb13be429cae997f95c
|
||||
size 87751
|
||||
@@ -1,3 +1,11 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed May 4 17:28:34 UTC 2022 - Matej Cepl <mcepl@suse.com>
|
||||
|
||||
- Upgrade to 0.9.0:
|
||||
- Fix test suite failures due to a confluence of problems
|
||||
- Upgrade dependency on Black to 22.1.0 to support Python 3.10
|
||||
- Add link to demo site at https://iblueit.dev
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Apr 23 18:57:58 UTC 2022 - Matej Cepl <mcepl@suse.com>
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
%{?!python_module:%define python_module() python3-%{**}}
|
||||
%define skip_python2 1
|
||||
Name: python-blue
|
||||
Version: 0.8.0
|
||||
Version: 0.9.0
|
||||
Release: 0
|
||||
Summary: A code formatter written in, and written for Python
|
||||
License: MIT
|
||||
@@ -67,6 +67,7 @@ HTML Documentation and examples for %name.
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -n blue-%{version}
|
||||
|
||||
# avoid pytest addopts for coverage checks
|
||||
sed -i '/--cov/d' tox.ini
|
||||
|
||||
|
||||
@@ -1,12 +1,15 @@
|
||||
Index: blue-0.8.0/blue/__init__.py
|
||||
===================================================================
|
||||
--- blue-0.8.0.orig/blue/__init__.py
|
||||
+++ blue-0.8.0/blue/__init__.py
|
||||
@@ -387,8 +387,9 @@ def main():
|
||||
---
|
||||
blue/__init__.py | 5 +++--
|
||||
setup.py | 2 +-
|
||||
2 files changed, 4 insertions(+), 3 deletions(-)
|
||||
|
||||
--- a/blue/__init__.py
|
||||
+++ b/blue/__init__.py
|
||||
@@ -448,8 +448,9 @@ def main():
|
||||
'Black', 'Blue'
|
||||
)
|
||||
# Change the config param callback to support setup.cfg, tox.ini, etc.
|
||||
- config_param = black.main.params[21]
|
||||
- config_param = black.main.params[25]
|
||||
- assert config_param.name == 'config'
|
||||
+ # the index changed somewhere between black 21.7b and 21.12b
|
||||
+ cfgidx = {p.name: i for (i, p) in enumerate(black.main.params)}['config']
|
||||
@@ -14,16 +17,14 @@ Index: blue-0.8.0/blue/__init__.py
|
||||
config_param.callback = read_configs
|
||||
# Change the version string by adding a redundant Click `version_option`
|
||||
# decorator on `black.main`. Fortunately the added `version_option` takes
|
||||
Index: blue-0.8.0/setup.py
|
||||
===================================================================
|
||||
--- blue-0.8.0.orig/setup.py
|
||||
+++ blue-0.8.0/setup.py
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -37,7 +37,7 @@ setup(
|
||||
packages=['blue'],
|
||||
tests_require=['tox'],
|
||||
cmdclass={'test': Tox},
|
||||
- install_requires=['black==21.7b0', 'flake8>=3.8'],
|
||||
+ install_requires=['black>=21.7b0', 'flake8>=3.8'],
|
||||
- install_requires=['black==22.1.0', 'flake8>=3.8'],
|
||||
+ install_requires=['black>=22.1.0', 'flake8>=3.8'],
|
||||
project_urls={
|
||||
'Documentation': 'https://blue.readthedocs.io/en/latest',
|
||||
'Source': 'https://github.com/grantjenks/blue.git',
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
---
|
||||
blue/__init__.py | 9 ++++++---
|
||||
1 file changed, 6 insertions(+), 3 deletions(-)
|
||||
blue/__init__.py | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
--- a/blue/__init__.py
|
||||
+++ b/blue/__init__.py
|
||||
@@ -15,7 +15,10 @@ import black.strings
|
||||
@@ -70,7 +70,10 @@ import black.strings
|
||||
from black import Leaf, Path, click, token
|
||||
from black.cache import user_cache_dir
|
||||
from black.comments import ProtoComment, make_comment
|
||||
@@ -16,14 +16,3 @@
|
||||
from black.linegen import LineGenerator as BlackLineGenerator
|
||||
from black.lines import Line
|
||||
from black.nodes import (
|
||||
@@ -263,8 +266,8 @@ def parse_pyproject_toml(path_config: st
|
||||
|
||||
If parsing fails, will raise a tomli.TOMLDecodeError
|
||||
"""
|
||||
- with open(path_config, encoding="utf8") as f:
|
||||
- pyproject_toml = tomli.load(f) # type: ignore # due to deprecated API usage
|
||||
+ with open(path_config, mode='rb') as f:
|
||||
+ pyproject_toml = tomli.load(f)
|
||||
config = pyproject_toml.get("tool", {}).get("blue", {})
|
||||
return {k.replace("--", "").replace("-", "_"): v for k, v in config.items()}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user