diff options
author | Alexander Smirnov <alex@ydb.tech> | 2024-12-13 10:25:10 +0000 |
---|---|---|
committer | Alexander Smirnov <alex@ydb.tech> | 2024-12-13 10:25:10 +0000 |
commit | f1d6d85b72fe40f506429a4ad6eb9cd7f3c7015b (patch) | |
tree | e58dd729657f1c2a3eb7922eb99d53c7fd476781 /contrib/python/zope.interface/py3/zope/interface/common/collections.py | |
parent | e73e490feb4e1f63d097697324aa48b643a62317 (diff) | |
parent | fab10ff25473117c056fd8c4ec06e7cbc4783cbd (diff) | |
download | ydb-f1d6d85b72fe40f506429a4ad6eb9cd7f3c7015b.tar.gz |
Merge branch 'rightlib' into mergelibs-241213-1023
Diffstat (limited to 'contrib/python/zope.interface/py3/zope/interface/common/collections.py')
-rw-r--r-- | contrib/python/zope.interface/py3/zope/interface/common/collections.py | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/contrib/python/zope.interface/py3/zope/interface/common/collections.py b/contrib/python/zope.interface/py3/zope/interface/common/collections.py index 543266d9cf3..defa8a15b94 100644 --- a/contrib/python/zope.interface/py3/zope/interface/common/collections.py +++ b/contrib/python/zope.interface/py3/zope/interface/common/collections.py @@ -38,6 +38,7 @@ from collections import UserList from collections import UserString from collections import abc +from zope.interface._compat import PY313_OR_OLDER from zope.interface.common import ABCInterface from zope.interface.common import optional @@ -190,13 +191,14 @@ class IMutableSequence(ISequence): extra_classes = (UserList,) -class IByteString(ISequence): - """ - This unifies `bytes` and `bytearray`. - """ - abc = _new_in_ver( - 'ByteString', True, (ISequence.getABC(),), (bytes, bytearray), - ) +if PY313_OR_OLDER: + class IByteString(ISequence): + """ + This unifies `bytes` and `bytearray`. + """ + abc = _new_in_ver( + 'ByteString', True, (ISequence.getABC(),), (bytes, bytearray), + ) class ISet(ICollection): |