11 Oct
2016
11 Oct
'16
12:09 p.m.
Hey, When creating deque instances using a value for maxlen, it would be nice to have a .full() method like what Queue provides, so one may do: my_deque = deque(maxlen=300) if my_deque.full(): do_something() instead of doing: if len(my_deque) == my_deque.maxlen: do_something() If people think it's a good idea, I can add a ticket in the tracker and try to provide a patch for the collections module maintainer. If this was already talked about, or is a bad idea, sorry! :) Cheers Tarek -- Tarek Ziadé | coding: https://ziade.org | running: https://foule.es | twitter: @tarek_ziade