Compare commits

...

12 Commits

Author SHA1 Message Date
openeuler-ci-bot
6dcec58dfe
!58 [sync] PR-56: fix test with latest pytest
From: @openeuler-sync-bot 
Reviewed-by: @zengwefeng 
Signed-off-by: @zengwefeng
2025-02-06 03:28:04 +00:00
Funda Wang
7062fb77a9 fix test with latest pytest
(cherry picked from commit dc788c8554ddce915a49aa2233c8efa4dbccfaab)
2025-02-06 09:16:21 +08:00
openeuler-ci-bot
69eebea641
!50 Upgrade to version 23.2.0
From: @jack0240 
Reviewed-by: @licihua 
Signed-off-by: @licihua
2024-01-30 02:00:21 +00:00
JackWei
fa344a33ee Upgrade to version 23.2.0 2024-01-30 09:14:30 +08:00
openeuler-ci-bot
392aabfe26
!46 update version to 22.2.0
From: @zhuofeng6 
Reviewed-by: @zengwefeng 
Signed-off-by: @zengwefeng
2023-08-01 02:40:55 +00:00
zhuofeng
40be9832e9 update version to 22.2.0 2023-07-29 10:24:21 +08:00
openeuler-ci-bot
eef8c2a515
!40 enable check
From: @tanyulong2021 
Reviewed-by: @zengwefeng 
Signed-off-by: @zengwefeng
2023-03-29 01:59:45 +00:00
tanyulong2021
b4ca97a53c enable check 2023-02-16 14:20:31 +08:00
openeuler-ci-bot
622176c7cb
!38 Fix minor stub issues
From: @cao-fei8 
Reviewed-by: @Charlie_li 
Signed-off-by: @Charlie_li
2023-01-17 07:31:19 +00:00
openeuler-ci-bot
ea068dc512
!34 Fix type docstring
From: @cao-fei8 
Reviewed-by: @Charlie_li 
Signed-off-by: @Charlie_li
2023-01-13 08:26:31 +00:00
cao-fei8
a264ff5594 Fix minor stub issues
Reference:
b9f35eb2f2

Signed-off-by: cao-fei8 <caofei@xfusion.com>
2023-01-13 15:34:09 +08:00
cao-fei8
984c9fd635 Fix type docstring
Reference:
6b73e8e015

Signed-off-by: cao-fei8 <caofei@xfusion.com>
2023-01-13 13:52:01 +08:00
7 changed files with 73 additions and 72 deletions

View File

@ -1,25 +0,0 @@
From 92ef1421b62cd7edcea8980f717b8758a51ac931 Mon Sep 17 00:00:00 2001
From: Hynek Schlawack <hs@ox.cx>
Date: Thu, 11 Aug 2022 07:11:18 +0200
Subject: [PATCH] Fix typo
---
CHANGELOG.rst | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index c61aeb5..6a8d02f 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -312,7 +312,7 @@ Backward-incompatible Changes
Changes
^^^^^^^
-- ``attr.define()`` et al now correct detect ``__eq__`` and ``__ne__``.
+- ``attr.define()`` et al now correctly detect ``__eq__`` and ``__ne__``.
`#671 <https://github.com/python-attrs/attrs/issues/671>`_
- ``attr.define()`` et al's hybrid behavior now also works correctly when arguments are passed.
`#675 <https://github.com/python-attrs/attrs/issues/675>`_
--
2.33.0

View File

@ -1,33 +0,0 @@
From 95e0c423ca31123a9537405fd2de5a1ee9f01b7c Mon Sep 17 00:00:00 2001
From: Hynek Schlawack <hs@ox.cx>
Date: Sat, 30 Jul 2022 13:23:03 +0200
Subject: [PATCH] Update .gitignore
---
.gitignore | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/.gitignore b/.gitignore
index d054dc6..f5c97f1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,12 +2,16 @@
*.pyc
.cache
.coverage*
+.direnv
+.envrc
.hypothesis
.mypy_cache
.pytest_cache
.tox
+.vscode
build
dist
docs/_build/
htmlcov
pip-wheel-metadata
+tmp
--
2.33.0

Binary file not shown.

BIN
attrs-23.2.0.tar.gz Normal file

Binary file not shown.

View File

@ -0,0 +1,40 @@
From b9084fab02c009a593b604562a69f36a5915c8e5 Mon Sep 17 00:00:00 2001
From: Denis Laxalde <denis@laxalde.org>
Date: Sat, 2 Mar 2024 07:40:36 +0100
Subject: [PATCH] Remove pytest.deprecated_call() in TestAssoc::test_unknown
(#1249)
assoc() no longer raises a deprecation warning since commit
22ae8473fb88d6e585b05c709e81e1a46398a649 but the 'with
pytest.deprecated_call():' in that test was not removed then (in
contrast with other test cases).
Maybe this got unnoticed due to a pytest bug?
In any case, using pytest 8+ (and keeping deprecated_call()) shows that
no warning is raised and the test fails.
Removing the upper bound on pytest in dev dependencies as tests now
pass with pytest 8.0.
Fix #1233.
Co-authored-by: Hynek Schlawack <hs@ox.cx>
---
tests/test_funcs.py | 4 +---
1 files changed, 1 insertion, 3 deletions(-)
diff --git a/tests/test_funcs.py b/tests/test_funcs.py
index 044aaab2c..398ba3576 100644
--- a/tests/test_funcs.py
+++ b/tests/test_funcs.py
@@ -600,9 +600,7 @@ def test_unknown(self, C):
AttrsAttributeNotFoundError.
"""
# No generated class will have a four letter attribute.
- with pytest.raises(
- AttrsAttributeNotFoundError
- ) as e, pytest.deprecated_call():
+ with pytest.raises(AttrsAttributeNotFoundError) as e:
assoc(C(), aaaa=2)
assert (f"aaaa is not an attrs attribute on {C!r}.",) == e.value.args

View File

@ -5,17 +5,15 @@ object protocols. \
%global modname attrs
%bcond_with tests
%bcond_without tests
Name: python-attrs
Summary: Python attributes without boilerplate
Version: 22.1.0
Release: 3
Version: 23.2.0
Release: 2
License: MIT
URL: http://www.attrs.org/
Source0: https://github.com/hynek/attrs/archive/%{version}/attrs-%{version}.tar.gz
Patch0: 0001-Update-.gitignore.patch
Patch1: 0001-Fix-typo.patch
URL: https://www.attrs.org/
Source0: https://github.com/python-attrs/attrs/archive/%{version}/attrs-%{version}.tar.gz
Patch6001: backport-Remove-pytest-deprecated_call.patch
BuildRequires: python%{python3_pkgversion}-setuptools
BuildRequires: python%{python3_pkgversion}-devel
@ -27,6 +25,9 @@ BuildRequires: python%{python3_pkgversion}-hypothesis python%{python3_pkgversio
BuildArch: noarch
BuildRequires: python3-pip python3-wheel python3-hatchling python3-hatch-fancy-pypi-readme
BuildRequires: python3-hatchling python3-hatch-vcs python3-pbr
%description
%{_description}
@ -42,10 +43,10 @@ Summary: %{summary}
%autosetup -p1 -n attrs-%{version}
%build
%py3_build
%pyproject_build
%install
%py3_install
%pyproject_install
%if %{with tests}
%check
@ -57,9 +58,27 @@ PYTHONPATH=$RPM_BUILD_ROOT/%{python3_sitelib} py.test-3 -v
%{python3_sitelib}/*
%files help
%doc AUTHORS.rst README.rst
%doc README.md
%changelog
* Tue Jan 28 2025 Funda Wang <fundawang@yeah.net> - 23.2.0-2
- fix test with latest pytest
* Mon Jan 29 2024 weihaohao <weihaohao2@huawei.com> - 23.2.0-1
- Update package to version 23.2.0
* Sat Jul 29 2023 zhuofeng <zhuofeng2@huawei.com> - 22.2.0-1
- update version to 22.2.0
* Thu Feb 16 2023 tanyulong <tanyulong@kylinos.cn> - 22.1.0-6
- enable check
* Fri Jan 13 2023 caofei <caofei@xfusion.com> - 22.1.0-5
- Fix minor stub issues
* Fri Jan 13 2023 caofei <caofei@xfusion.com> - 22.1.0-4
- Fix type docstring
* Mon Jan 9 2023 caofei <caofei@xfusion.com> - 22.1.0-3
- Fix typo

View File

@ -1,4 +1,4 @@
version_control: github
src_repo: hynek/attrs
tag_prefix: "^v"
seperator: "."
src_repo: python-attrs/attrs
tag_prefix:
separator: "."