[New-bugs-announce] [issue41409] deque.pop(index) is not supported

Akuli report at bugs.python.org
Mon Jul 27 10:18:55 EDT 2020


New submission from Akuli <akuviljanen17 at gmail.com>:

The pop method of collections.deque can't be used like deque.pop(index), even though `del deque[index]` or deque.pop() without an argument works. This breaks the Liskov substitution principle because collections.abc.MutableMapping supports the .pop(index) usage. Is this intentional?

related typeshed issue: https://github.com/python/typeshed/issues/4364

----------
components: Library (Lib)
messages: 374378
nosy: Akuli
priority: normal
severity: normal
status: open
title: deque.pop(index) is not supported

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41409>
_______________________________________


More information about the New-bugs-announce mailing list