Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #106623 > unrolled thread

deque is not a subclass of Sequence.

Started byAntoon Pardon <antoon.pardon@rece.vub.ac.be>
First post2016-04-07 10:49 +0200
Last post2016-04-07 10:49 +0200
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  deque is not a subclass of Sequence. Antoon Pardon <antoon.pardon@rece.vub.ac.be> - 2016-04-07 10:49 +0200

#106623 — deque is not a subclass of Sequence.

FromAntoon Pardon <antoon.pardon@rece.vub.ac.be>
Date2016-04-07 10:49 +0200
Subjectdeque is not a subclass of Sequence.
Message-ID<mailman.7.1460018974.2253.python-list@python.org>
Playing around with the collections and collections.abc modules in
python3.4 I stumbled upon the following: >>> from collections.abc import
Sequence >>> from collections import deque >>> isinstance(list(),
Sequence) True >>> isinstance(deque(), Sequence) False >>> This seems
strange to me. As far as I understand, the documentation indicates there
is no reason why deque shouldn't be a subclass of Sequence. Am I missing
something or can this be considered a bug? -- Antoon.

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web