pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/devel/py-cattrs
Module Name: pkgsrc
Committed By: wiz
Date: Sun Nov 19 14:09:31 UTC 2023
Modified Files:
pkgsrc/devel/py-cattrs: Makefile PLIST distinfo
Log Message:
py-cattrs: update to 23.2.1.
## 23.2.1 (2023-11-18)
- Fix unnecessary `typing_extensions` import on Python 3.11.
## 23.2.0 (2023-11-17)
- **Potentially breaking**: skip _attrs_ fields marked as `init=False` by default. This change is potentially breaking for unstructuring.
- **Potentially breaking**: {py:func}`cattrs.gen.make_dict_structure_fn` and {py:func}`cattrs.gen.typeddicts.make_dict_structure_fn` will use the values for the `detailed_validation` and
`forbid_extra_keys` parameters from the given converter by default now.
If you're using these functions directly, the old behavior can be restored by passing in the desired values directly.
- **Potentially breaking**: The default union structuring strategy will also use fields annotated as `typing.Literal` to help guide structuring.
- Python 3.12 is now supported. Python 3.7 is no longer supported; use older releases there.
- Implement the `union passthrough` strategy, enabling much richer union handling for preconfigured converters.
- Introduce the `use_class_methods` strategy.
- The `omit` parameter of {py:func}`cattrs.override` is now of type `bool | None` (from `bool`).
`None` is the new default and means to apply default _cattrs_ handling to the attribute, which is to omit the attribute if it's marked as `init=False`, and keep it otherwise.
- Converters can now be initialized with custom fallback hook factories for un/structuring.
- Add support for `date` to preconfigured converters.
- Add support for `datetime.date`s to the PyYAML preconfigured converter.
- Fix {py:func}`format_exception() <cattrs.v.format_exception>` parameter working for recursive calls to {py:func}`transform_error <cattrs.transform_error>`.
- _attrs_ aliases are now supported, although aliased fields still map to their attribute name instead of their alias by default when un/structuring.
- Fix TypedDicts with periods in their field names.
- Optimize and improve unstructuring of `Optional` (unions of one type and `None`).
- Fix {py:func}`format_exception <cattrs.v.format_exception>` and {py:func}`transform_error <cattrs.transform_error>` type annotations.
- Improve the implementation of `cattrs._compat.is_typeddict`. The implementation is now simpler, and relies on fewer private implementation details from `typing` and typing_extensions.
- Improve handling of TypedDicts with forward references.
- Speed up generated _attrs_ and TypedDict structuring functions by changing their signature slightly.
- Fix copying of converters with function hooks.
- Broaden {py:func}`loads' <cattrs.preconf.orjson.OrjsonConverter.loads>` type definition for the preconf orjson converter.
- {py:class}`AttributeValidationNote <cattrs.AttributeValidationNote>` and {py:class}`IterableValidationNote <cattrs.IterableValidationNote>` are now picklable.
- Fix structuring `Final` lists.
- Fix certain cases of structuring `Annotated` types.
- Fix the tagged union strategy to work with `forbid_extra_keys`.
- Use PDM instead of Poetry.
- _cattrs_ is now linted with Ruff.
- Remove some unused lines in the unstructuring code.
- Fix handling classes inheriting from non-generic protocols.
- The documentation Makefile now supports the `htmlview` and `htmllive` targets.
- _cattrs_ is now published using PyPI Trusted Publishers, and `main` branch commits are automatically deployed to Test PyPI.
To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 pkgsrc/devel/py-cattrs/Makefile
cvs rdiff -u -r1.3 -r1.4 pkgsrc/devel/py-cattrs/PLIST
cvs rdiff -u -r1.2 -r1.3 pkgsrc/devel/py-cattrs/distinfo
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/devel/py-cattrs/Makefile
diff -u pkgsrc/devel/py-cattrs/Makefile:1.4 pkgsrc/devel/py-cattrs/Makefile:1.5
--- pkgsrc/devel/py-cattrs/Makefile:1.4 Sat Oct 28 19:56:57 2023
+++ pkgsrc/devel/py-cattrs/Makefile Sun Nov 19 14:09:31 2023
@@ -1,8 +1,7 @@
-# $NetBSD: Makefile,v 1.4 2023/10/28 19:56:57 wiz Exp $
+# $NetBSD: Makefile,v 1.5 2023/11/19 14:09:31 wiz Exp $
-DISTNAME= cattrs-23.1.2
+DISTNAME= cattrs-23.2.1
PKGNAME= ${PYPKGPREFIX}-${DISTNAME}
-PKGREVISION= 1
CATEGORIES= devel python
MASTER_SITES= ${MASTER_SITE_PYPI:=c/cattrs/}
@@ -11,16 +10,26 @@ HOMEPAGE= https://github.com/python-attr
COMMENT= Composable complex class support for attrs and dataclasses
LICENSE= mit
-TOOL_DEPENDS+= ${PYPKGPREFIX}-poetry-core>=0:../../devel/py-poetry-core
+TOOL_DEPENDS+= ${PYPKGPREFIX}-hatchling>=0:../../devel/py-hatchling
+TOOL_DEPENDS+= ${PYPKGPREFIX}-hatch-vcs>=0:../../devel/py-hatch-vcs
DEPENDS+= ${PYPKGPREFIX}-attrs>=20:../../devel/py-attrs
-# no tests included in pypi distfile
-#TEST_DEPENDS+= ${PYPKGPREFIX}-test>=0:../../devel/py-test
-#TEST_DEPENDS+= ${PYPKGPREFIX}-test-benchmark>=0:../../devel/py-test-benchmark
+# optional dependency
+# https://github.com/py-bson/bson/issues/122
+#TEST_DEPENDS+= ${PYPKGPREFIX}-bson>=0:../../wip/py-bson
+TEST_DEPENDS+= ${PYPKGPREFIX}-hypothesis>=0:../../devel/py-hypothesis
+TEST_DEPENDS+= ${PYPKGPREFIX}-immutables>=0:../../misc/py-immutables
+TEST_DEPENDS+= ${PYPKGPREFIX}-test-benchmark>=0:../../devel/py-test-benchmark
USE_LANGUAGES= # none
PYTHON_VERSIONS_INCOMPATIBLE= 27
+# bson, see above
+# as of 23.2.1
+# 597 passed, 1 skipped, 15 xfailed
+pre-test:
+ ${RM} -f ${WRKSRC}/tests/test_preconf.py
+
.include "../../lang/python/pyversion.mk"
.if ${PYTHON_VERSION} < 311
Index: pkgsrc/devel/py-cattrs/PLIST
diff -u pkgsrc/devel/py-cattrs/PLIST:1.3 pkgsrc/devel/py-cattrs/PLIST:1.4
--- pkgsrc/devel/py-cattrs/PLIST:1.3 Sat Oct 28 19:56:57 2023
+++ pkgsrc/devel/py-cattrs/PLIST Sun Nov 19 14:09:31 2023
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.3 2023/10/28 19:56:57 wiz Exp $
+@comment $NetBSD: PLIST,v 1.4 2023/11/19 14:09:31 wiz Exp $
${PYSITELIB}/cattr/__init__.py
${PYSITELIB}/cattr/__init__.pyc
${PYSITELIB}/cattr/__init__.pyo
@@ -42,10 +42,10 @@ ${PYSITELIB}/cattr/preconf/ujson.py
${PYSITELIB}/cattr/preconf/ujson.pyc
${PYSITELIB}/cattr/preconf/ujson.pyo
${PYSITELIB}/cattr/py.typed
-${PYSITELIB}/${WHEEL_INFODIR}/LICENSE
${PYSITELIB}/${WHEEL_INFODIR}/METADATA
${PYSITELIB}/${WHEEL_INFODIR}/RECORD
${PYSITELIB}/${WHEEL_INFODIR}/WHEEL
+${PYSITELIB}/${WHEEL_INFODIR}/licenses/LICENSE
${PYSITELIB}/cattrs/__init__.py
${PYSITELIB}/cattrs/__init__.pyc
${PYSITELIB}/cattrs/__init__.pyo
@@ -67,6 +67,9 @@ ${PYSITELIB}/cattrs/dispatch.pyo
${PYSITELIB}/cattrs/errors.py
${PYSITELIB}/cattrs/errors.pyc
${PYSITELIB}/cattrs/errors.pyo
+${PYSITELIB}/cattrs/fns.py
+${PYSITELIB}/cattrs/fns.pyc
+${PYSITELIB}/cattrs/fns.pyo
${PYSITELIB}/cattrs/gen/__init__.py
${PYSITELIB}/cattrs/gen/__init__.pyc
${PYSITELIB}/cattrs/gen/__init__.pyo
@@ -116,6 +119,9 @@ ${PYSITELIB}/cattrs/py.typed
${PYSITELIB}/cattrs/strategies/__init__.py
${PYSITELIB}/cattrs/strategies/__init__.pyc
${PYSITELIB}/cattrs/strategies/__init__.pyo
+${PYSITELIB}/cattrs/strategies/_class_methods.py
+${PYSITELIB}/cattrs/strategies/_class_methods.pyc
+${PYSITELIB}/cattrs/strategies/_class_methods.pyo
${PYSITELIB}/cattrs/strategies/_subclasses.py
${PYSITELIB}/cattrs/strategies/_subclasses.pyc
${PYSITELIB}/cattrs/strategies/_subclasses.pyo
Index: pkgsrc/devel/py-cattrs/distinfo
diff -u pkgsrc/devel/py-cattrs/distinfo:1.2 pkgsrc/devel/py-cattrs/distinfo:1.3
--- pkgsrc/devel/py-cattrs/distinfo:1.2 Tue Jun 6 08:09:47 2023
+++ pkgsrc/devel/py-cattrs/distinfo Sun Nov 19 14:09:31 2023
@@ -1,5 +1,5 @@
-$NetBSD: distinfo,v 1.2 2023/06/06 08:09:47 wiz Exp $
+$NetBSD: distinfo,v 1.3 2023/11/19 14:09:31 wiz Exp $
-BLAKE2s (cattrs-23.1.2.tar.gz) = 59b892a09ab7725d4e2339cda64a74f547c60e74fccf60657bc24745f0a2ad91
-SHA512 (cattrs-23.1.2.tar.gz) = bd55b75911ae44b554ea5e9d1d218c968c4906d9679adc40986c3e9b2b57af51e4b711e39e6e09997db1a2d41c22c6144ec259405c158273cbb9aa2f262c95c5
-Size (cattrs-23.1.2.tar.gz) = 39998 bytes
+BLAKE2s (cattrs-23.2.1.tar.gz) = 49f03604eeba0ecde2e11394b6ed6e73a6ab06e4d8b9361b9895dc5625cb8eea
+SHA512 (cattrs-23.2.1.tar.gz) = 45610f4cf9fb6e47f08d86de0ca4d1ce110858d0677d8314f0fd229e841aa1f13aa1c248ab15d17118b1e6b1bec4c4cd26e6018cf82729c15a325f6017ddaf53
+Size (cattrs-23.2.1.tar.gz) = 609625 bytes
Home |
Main Index |
Thread Index |
Old Index