summaryrefslogtreecommitdiffstats
path: root/contrib/python
diff options
context:
space:
mode:
authorrobot-piglet <[email protected]>2026-01-26 08:19:37 +0300
committerrobot-piglet <[email protected]>2026-01-26 08:33:33 +0300
commitcc3affe67e59b009a8ff68e48d8eec9a8ba72ac9 (patch)
treeb20b49fbcaa40bac4e6cb842d67a20f1ddfda070 /contrib/python
parentb5ca884548e50f9fd5434c4f2dd79f9cd865ab84 (diff)
Intermediate changes
commit_hash:3e6b6d99cc911eb8c99abcde84d23c9c0e145c82
Diffstat (limited to 'contrib/python')
-rw-r--r--contrib/python/zope.interface/py3/.dist-info/METADATA230
-rw-r--r--contrib/python/zope.interface/py3/ya.make2
-rw-r--r--contrib/python/zope.interface/py3/zope/interface/interface.py2
-rw-r--r--contrib/python/zope.interface/py3/zope/interface/tests/test_interface.py17
4 files changed, 145 insertions, 106 deletions
diff --git a/contrib/python/zope.interface/py3/.dist-info/METADATA b/contrib/python/zope.interface/py3/.dist-info/METADATA
index 88b0514c53a..356ba7e12de 100644
--- a/contrib/python/zope.interface/py3/.dist-info/METADATA
+++ b/contrib/python/zope.interface/py3/.dist-info/METADATA
@@ -1,18 +1,21 @@
Metadata-Version: 2.4
Name: zope.interface
-Version: 8.1.1
+Version: 8.2
Summary: Interfaces for Python
-Home-page: https://github.com/zopefoundation/zope.interface
-Author: Zope Foundation and Contributors
-Author-email: [email protected]
-License: ZPL-2.1
+Author-email: Zope Foundation and contributors <[email protected]>
+Maintainer-email: Plone Foundation and contributors <[email protected]>
+License-Expression: ZPL-2.1
+Project-URL: Documentation, https://zopeinterface.readthedocs.io
+Project-URL: Issues, https://github.com/zopefoundation/zope.interface/issues
+Project-URL: Source, https://github.com/zopefoundation/zope.interface
+Project-URL: Changelog, https://github.com/zopefoundation/zope.interface/blob/master/CHANGES.rst
Keywords: interface,components,plugins
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
-Classifier: License :: OSI Approved :: Zope Public License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
+Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
@@ -20,8 +23,6 @@ Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
-Classifier: Framework :: Zope :: 3
-Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.10
Description-Content-Type: text/x-rst
License-File: LICENSE.txt
@@ -37,18 +38,7 @@ Provides-Extra: testing
Requires-Dist: coverage[toml]; extra == "testing"
Requires-Dist: zope.event; extra == "testing"
Requires-Dist: zope.testing; extra == "testing"
-Dynamic: author
-Dynamic: author-email
-Dynamic: classifier
-Dynamic: description
-Dynamic: description-content-type
-Dynamic: home-page
-Dynamic: keywords
-Dynamic: license
Dynamic: license-file
-Dynamic: provides-extra
-Dynamic: requires-python
-Dynamic: summary
====================
``zope.interface``
@@ -82,19 +72,26 @@ the `Design By Contract`_ methodology support in Python.
For detailed documentation, please see https://zopeinterface.readthedocs.io/en/latest/
-=========
- Changes
-=========
+Change log
+==========
+
+8.2 (2026-01-09)
+----------------
+
+- Move all supported package metadata into ``pyproject.toml``.
+
+- Ignore ``__annotate_func__`` added in Python 3.14b1.
+
8.1.1 (2025-11-15)
-==================
+------------------
- Fix the GitHub workflow for publishing wheels, which failed for Linux/arm64.
(`#348 <https://github.com/zopefoundation/zope.interface/issues/348>`_)
8.1 (2025-11-10)
-================
+----------------
- Drop support for Python 3.9.
@@ -102,7 +99,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
8.0.1 (2025-09-25)
-==================
+------------------
- Make tests resilient against different ways of calling them.
@@ -110,7 +107,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
8.0 (2025-09-12)
-================
+----------------
- Replace ``pkg_resources`` namespace with PEP 420 native namespace.
@@ -121,7 +118,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
7.2 (2024-11-28)
-================
+----------------
- Add preliminary support for Python 3.14a2, this means that
``.common.builtins.IByteString`` and ``.common.collections.IByteString`` are
@@ -130,14 +127,14 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
7.1.1 (2024-10-23)
-==================
+------------------
- Fix segmentation faults in `weakrefobject.c` on Python 3.12 and 3.13.
(`#323 <https://github.com/zopefoundation/zope.interface/issues/323>`_)
7.1.0 (2024-10-10)
-==================
+------------------
- Declare support for Python 3.13.
@@ -146,28 +143,28 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
7.0.3 (2024-08-27)
-==================
+------------------
-- Fix `Assertion 'memb->type == T_PYSSIZET' failed.` for Python < 3.12.
+- Fix `Assertion 'memb->type -- T_PYSSIZET' failed.` for Python < 3.12.
(`#319 <https://github.com/zopefoundation/zope.interface/issues/319>`_)
7.0.2 (2024-08-26)
-==================
+------------------
- Fix reference-counting bug in C module initialization (broken in 7.0).
(`#316 <https://github.com/zopefoundation/zope.interface/issues/316>`_)
7.0.1 (2024-08-06)
-==================
+------------------
- Fix subclassability of ``ObjectSpecificationDescriptor`` (broken in 7.0).
(`#312 <https://github.com/zopefoundation/zope.interface/issues/312>`_)
7.0 (2024-08-06)
-================
+----------------
- Enable heap-based types (PEP 384) for Python >= 3.11.
@@ -177,21 +174,21 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
6.4.post2 (2024-05-24)
-======================
+----------------------
- Publish missing Windows wheels, second attempt.
(`#295 <https://github.com/zopefoundation/zope.interface/issues/295>`_)
6.4.post1 (2024-05-23)
-======================
+----------------------
- Publish missing Windows wheels.
(`#295 <https://github.com/zopefoundation/zope.interface/issues/295>`_)
6.4.post0 (2024-05-22)
-======================
+----------------------
- The sdist of version 6.4 was uploaded to PyPI as
``zope_interface-6.4.tar.gz`` instead of ``zope.interface-6.4-py2.tar.gz``
@@ -201,21 +198,22 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
6.4 (2024-05-15)
-================
+----------------
- Adjust for incompatible changes in Python 3.13b1.
(`#292 <https://github.com/zopefoundation/zope.interface/issues/292>`_)
- Build windows wheels on GHA.
+
6.3 (2024-04-12)
-================
+----------------
- Add preliminary support for Python 3.13 as of 3.13a6.
6.2 (2024-02-16)
-================
+----------------
- Add preliminary support for Python 3.13 as of 3.13a3.
@@ -224,7 +222,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
6.1 (2023-10-05)
-================
+----------------
- Build Linux binary wheels for Python 3.12.
@@ -234,7 +232,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
6.0 (2023-03-17)
-================
+----------------
- Build Linux binary wheels for Python 3.11.
@@ -252,19 +250,19 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
5.5.2 (2022-11-17)
-==================
+------------------
- Add support for building arm64 wheels on macOS.
5.5.1 (2022-11-03)
-==================
+------------------
- Add support for final Python 3.11 release.
5.5.0 (2022-10-10)
-==================
+------------------
- Add support for Python 3.10 and 3.11 (as of 3.11.0rc2).
@@ -277,7 +275,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
5.4.0 (2021-04-15)
-==================
+------------------
- Make the C implementation of the ``__providedBy__`` descriptor stop
ignoring all errors raised when accessing the instance's
@@ -301,14 +299,15 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
invalid orders. See `issue 193
<https://github.com/zopefoundation/zope.interface/issues/193>`_.
+
5.3.0 (2020-03-21)
-==================
+------------------
- No changes from 5.3.0a1
5.3.0a1 (2021-03-18)
-====================
+--------------------
- Improve the repr of ``zope.interface.Provides`` to remove ambiguity
about what is being provided. This is especially helpful diagnosing
@@ -353,8 +352,9 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
``zope.proxy`` and ``zope.location``. See `issue 207
<https://github.com/zopefoundation/zope.interface/issues/207>`_.
+
5.2.0 (2020-11-05)
-==================
+------------------
- Add documentation section ``Persistency and Equality``
(`#218 <https://github.com/zopefoundation/zope.interface/issues/218>`_).
@@ -365,7 +365,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
5.1.2 (2020-10-01)
-==================
+------------------
- Make sure to call each invariant only once when validating invariants.
Previously, invariants could be called multiple times because when an
@@ -373,8 +373,9 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
inheriting from that interface. See `pull request 215
<https://github.com/zopefoundation/zope.interface/pull/215/>`_.
+
5.1.1 (2020-09-30)
-==================
+------------------
- Fix the method definitions of ``IAdapterRegistry.subscribe``,
``subscriptions`` and ``subscribers``. Previously, they all were
@@ -410,8 +411,9 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
Note that such potential errors are not new, they are just once
again a possibility.
+
5.1.0 (2020-04-08)
-==================
+------------------
- Make ``@implementer(*iface)`` and ``classImplements(cls, *iface)``
ignore redundant interfaces. If the class already implements an
@@ -467,8 +469,9 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
internal cache could be mutated. See `issue 204
<https://github.com/zopefoundation/zope.interface/issues/204>`_.
+
5.0.2 (2020-03-30)
-==================
+------------------
- Ensure that objects that implement no interfaces (such as direct
subclasses of ``object``) still include ``Interface`` itself in
@@ -479,7 +482,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
5.0.1 (2020-03-21)
-==================
+------------------
- Ensure the resolution order for ``InterfaceClass`` is consistent.
See `issue 192 <https://github.com/zopefoundation/zope.interface/issues/192>`_.
@@ -494,7 +497,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
5.0.0 (2020-03-19)
-==================
+------------------
- Make an internal singleton object returned by APIs like
``implementedBy`` and ``directlyProvidedBy`` immutable. Previously,
@@ -714,21 +717,21 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.7.2 (2020-03-10)
-==================
+------------------
- Remove deprecated use of setuptools features. See `issue 30
<https://github.com/zopefoundation/zope.interface/issues/30>`_.
4.7.1 (2019-11-11)
-==================
+------------------
- Use Python 3 syntax in the documentation. See `issue 119
<https://github.com/zopefoundation/zope.interface/issues/119>`_.
4.7.0 (2019-11-11)
-==================
+------------------
- Drop support for Python 3.4.
@@ -743,7 +746,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.6.0 (2018-10-23)
-==================
+------------------
- Add support for Python 3.7
@@ -753,7 +756,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.5.0 (2018-04-19)
-==================
+------------------
- Drop support for 3.3, avoid accidental dependence breakage via setup.py.
See `PR 110 <https://github.com/zopefoundation/zope.interface/pull/110>`_.
@@ -765,7 +768,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.4.3 (2017-09-22)
-==================
+------------------
- Avoid exceptions when the ``__annotations__`` attribute is added to
interface definitions with Python 3.x type hints. See `issue 98
@@ -776,7 +779,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.4.2 (2017-06-14)
-==================
+------------------
- Fix a regression storing
``zope.component.persistentregistry.PersistentRegistry`` instances.
@@ -786,8 +789,9 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
of ``Components`` getting out of sync. See `issue 93
<https://github.com/zopefoundation/zope.interface/issues/93>`_.
+
4.4.1 (2017-05-13)
-==================
+------------------
- Simplify the caching of utility-registration data. In addition to
simplification, avoids spurious test failures when checking for
@@ -797,16 +801,18 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
- Raise ``ValueError`` when non-text names are passed to adapter registry
methods: prevents corruption of lookup caches.
+
4.4.0 (2017-04-21)
-==================
+------------------
- Avoid a warning from the C compiler.
(https://github.com/zopefoundation/zope.interface/issues/71)
- Add support for Python 3.6.
+
4.3.3 (2016-12-13)
-==================
+------------------
- Correct typos and ReST formatting errors in documentation.
@@ -820,21 +826,21 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.3.2 (2016-09-05)
-==================
+------------------
- Fix equality testing of ``implementedBy`` objects and proxies.
(https://github.com/zopefoundation/zope.interface/issues/55)
4.3.1 (2016-08-31)
-==================
+------------------
- Support Components subclasses that are not hashable.
(https://github.com/zopefoundation/zope.interface/issues/53)
4.3.0 (2016-08-31)
-==================
+------------------
- Add the ability to sort the objects returned by ``implementedBy``.
This is compatible with the way interface classes sort so they can
@@ -852,7 +858,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.2.0 (2016-06-10)
-==================
+------------------
- Add support for Python 3.5
@@ -860,14 +866,14 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.1.3 (2015-10-05)
-==================
+------------------
- Fix installation without a C compiler on Python 3.5
(https://github.com/zopefoundation/zope.interface/issues/24).
4.1.2 (2014-12-27)
-==================
+------------------
- Add support for PyPy3.
@@ -878,13 +884,13 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.1.1 (2014-03-19)
-==================
+------------------
- Add support for Python 3.4.
4.1.0 (2014-02-05)
-==================
+------------------
- Update ``boostrap.py`` to version 2.2.
@@ -893,25 +899,27 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
4.0.5 (2013-02-28)
-==================
+------------------
- Fix a bug where a decorated method caused false positive failures on
``verifyClass()``.
4.0.4 (2013-02-21)
-==================
+------------------
- Fix a bug that was revealed by porting zope.traversing. During a loop, the
loop body modified a weakref dict causing a ``RuntimeError`` error.
+
4.0.3 (2012-12-31)
-==================
+------------------
- Fleshed out PyPI Trove classifiers.
+
4.0.2 (2012-11-21)
-==================
+------------------
- Add support for Python 3.3.
@@ -920,16 +928,18 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
- LP #1055223: Fix test which depended on dictionary order and failed randomly
in Python 3.3.
+
4.0.1 (2012-05-22)
-==================
+------------------
- Drop explicit ``DeprecationWarnings`` for "class advice" APIS (these
APIs are still deprecated under Python 2.x, and still raise an exception
under Python 3.x, but no longer cause a warning to be emitted under
Python 2.x).
+
4.0.0 (2012-05-16)
-==================
+------------------
- Automated build of Sphinx HTML docs and running doctest snippets via tox.
@@ -967,8 +977,9 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
added in Python 3.3 (see PEP 3155 for rationale). Thanks to Antoine
Pitrou for the patch.
+
3.8.0 (2011-09-22)
-==================
+------------------
- New module ``zope.interface.registry``. This is code moved from
``zope.component.registry`` which implements a basic nonperistent component
@@ -996,19 +1007,22 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
- No longer Python 2.4 compatible (tested under 2.5, 2.6, 2.7, and 3.2).
+
3.7.0 (2011-08-13)
-==================
+------------------
- Move changes from 3.6.2 - 3.6.5 to a new 3.7.x release line.
+
3.6.7 (2011-08-20)
-==================
+------------------
- Fix sporadic failures on x86-64 platforms in tests of rich comparisons
of interfaces.
+
3.6.6 (2011-08-13)
-==================
+------------------
- LP #570942: Now correctly compare interfaces from different modules but
with the same names.
@@ -1019,8 +1033,9 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
- Revert to software as released with 3.6.1 for "stable" 3.6 release branch.
+
3.6.5 (2011-08-11)
-==================
+------------------
- LP #811792: work around buggy behavior in some subclasses of
``zope.interface.interface.InterfaceClass``, which invoke ``__hash__``
@@ -1034,19 +1049,22 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
- Fix testing deprecation warnings issued when tested under Py3K.
+
3.6.4 (2011-07-04)
-==================
+------------------
- LP 804951: InterfaceClass instances were unhashable under Python 3.x.
+
3.6.3 (2011-05-26)
-==================
+------------------
- LP #570942: Now correctly compare interfaces from different modules but
with the same names.
+
3.6.2 (2011-05-17)
-==================
+------------------
- Moved detailed documentation out-of-line from PyPI page, linking instead to
http://docs.zope.org/zope.interface .
@@ -1061,16 +1079,18 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
- setup.py now raises RuntimeError if you don't have Distutils installed when
running under Python 3.
+
3.6.1 (2010-05-03)
-==================
+------------------
- A non-ASCII character in the changelog made 3.6.0 uninstallable on
Python 3 systems with another default encoding than UTF-8.
- Fix compiler warnings under GCC 4.3.3.
+
3.6.0 (2010-04-29)
-==================
+------------------
- LP #185974: Clear the cache used by ``Specificaton.get`` inside
``Specification.changed``. Thanks to Jacob Holm for the patch.
@@ -1104,21 +1124,21 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
3.5.4 (2009-12-23)
-==================
+------------------
- Use the standard Python doctest module instead of zope.testing.doctest, which
has been deprecated.
3.5.3 (2009-12-08)
-==================
+------------------
- Fix an edge case: make providedBy() work when a class has '__provides__' in
its __slots__ (see http://thread.gmane.org/gmane.comp.web.zope.devel/22490)
3.5.2 (2009-07-01)
-==================
+------------------
- BaseAdapterRegistry.unregister, unsubscribe: Remove empty portions of
the data structures when something is removed. This avoids leaving
@@ -1127,7 +1147,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
3.5.1 (2009-03-18)
-==================
+------------------
- verifyObject: use getattr instead of hasattr to test for object attributes
in order to let exceptions other than AttributeError raised by properties
@@ -1143,7 +1163,7 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
3.5.0 (2008-10-26)
-==================
+------------------
- Fix declaration of _zope_interface_coptimizations, it's not a top level
package.
@@ -1163,20 +1183,20 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
3.4.1 (2007-10-02)
-==================
+------------------
- Fix a setup bug that prevented installation from source on systems
without setuptools.
3.4.0 (2007-07-19)
-==================
+------------------
- Final release for 3.4.0.
3.4.0b3 (2007-05-22)
-====================
+--------------------
- When checking whether an object is already registered, use identity
@@ -1184,14 +1204,14 @@ For detailed documentation, please see https://zopeinterface.readthedocs.io/en/l
3.3.0.1 (2007-01-03)
-====================
+--------------------
- Made a reference to OverflowWarning, which disappeared in Python
2.5, conditional.
3.3.0 (2007/01/03)
-==================
+------------------
New Features
------------
@@ -1220,26 +1240,26 @@ Bug Fixes
3.2.0.2 (2006-04-15)
-====================
+--------------------
- Fix packaging bug: 'package_dir' must be a *relative* path.
3.2.0.1 (2006-04-14)
-====================
+--------------------
- Packaging change: suppress inclusion of 'setup.cfg' in 'sdist' builds.
3.2.0 (2006-01-05)
-==================
+------------------
- Corresponds to the version of the zope.interface package shipped as part of
the Zope 3.2.0 release.
3.1.0 (2005-10-03)
-==================
+------------------
- Corresponds to the version of the zope.interface package shipped as part of
the Zope 3.1.0 release.
@@ -1252,7 +1272,7 @@ Bug Fixes
3.0.1 (2005-07-27)
-==================
+------------------
- Corresponds to the version of the zope.interface package shipped as part of
the Zope X3.0.1 release.
@@ -1262,7 +1282,7 @@ Bug Fixes
3.0.0 (2004-11-07)
-==================
+------------------
- Corresponds to the version of the zope.interface package shipped as part of
the Zope X3.0.0 release.
diff --git a/contrib/python/zope.interface/py3/ya.make b/contrib/python/zope.interface/py3/ya.make
index 8ed3c9c009c..9cd3113a9e7 100644
--- a/contrib/python/zope.interface/py3/ya.make
+++ b/contrib/python/zope.interface/py3/ya.make
@@ -2,7 +2,7 @@
PY3_LIBRARY()
-VERSION(8.1.1)
+VERSION(8.2)
LICENSE(ZPL-2.1)
diff --git a/contrib/python/zope.interface/py3/zope/interface/interface.py b/contrib/python/zope.interface/py3/zope/interface/interface.py
index ad8a7de6b36..1ce44e0f5d3 100644
--- a/contrib/python/zope.interface/py3/zope/interface/interface.py
+++ b/contrib/python/zope.interface/py3/zope/interface/interface.py
@@ -827,6 +827,8 @@ class InterfaceClass(_InterfaceClassBase):
'__firstlineno__',
# __classdictcell__: Python 3.14
'__classdictcell__',
+ # __annotate_func__: Python 3.14b1+
+ '__annotate_func__',
) and
aval is not _decorator_non_return # noqa W503
}
diff --git a/contrib/python/zope.interface/py3/zope/interface/tests/test_interface.py b/contrib/python/zope.interface/py3/zope/interface/tests/test_interface.py
index 5105c11575f..d5a7d8d8e76 100644
--- a/contrib/python/zope.interface/py3/zope/interface/tests/test_interface.py
+++ b/contrib/python/zope.interface/py3/zope/interface/tests/test_interface.py
@@ -718,6 +718,23 @@ class InterfaceClassTests(unittest.TestCase):
self.assertEqual(inst.__bases__, ())
self.assertEqual(list(inst.names()), [])
+ def test_ctor_attrs_w___annotate_func__(self) -> None:
+ from zope.interface import Attribute
+ from zope.interface import Interface
+ from zope.interface import directlyProvides
+ from zope.interface.verify import verifyObject
+
+ class IAnnotated(Interface):
+ value: int = Attribute("Value")
+
+ class Annotated:
+ value: int = 0
+
+ self.assertEqual(list(IAnnotated.names()), ['value'])
+ annotated = Annotated()
+ directlyProvides(annotated, IAnnotated)
+ verifyObject(IAnnotated, annotated)
+
def test_ctor_attrs_w__decorator_non_return(self):
from zope.interface.interface import _decorator_non_return
ATTRS = {'dropme': _decorator_non_return}