[issue32449] MappingView must inherit from Collection instead of Sized

2018-01-11 Thread Raymond Hettinger
Change by Raymond Hettinger : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue32449] MappingView must inherit from Collection instead of Sized

2018-01-03 Thread Yahya Abou Imran
Yahya Abou Imran added the comment: I'm sorry, It's already done... https://bugs.python.org/issue32467 -- ___ Python tracker ___ ___

[issue32449] MappingView must inherit from Collection instead of Sized

2018-01-03 Thread Raymond Hettinger
Raymond Hettinger added the comment: > Maybe I have to open a new one? No need. Just continue here. -- ___ Python tracker ___ ___ P

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-31 Thread Yahya Abou Imran
Yahya Abou Imran added the comment: Hmm... Okay, I understand. So the only objection I have left, it's that ValuesView isn't passing the is instance of Collection test whereas it should, since he has the full behavior of one. It could be passed in its register to solve this. But it's not re

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-31 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I concur with Raymond. MappingView is a public interface, not just a concrete implementation. Changing it will make third-party implementations of this interface not conforming it. -- nosy: +serhiy.storchaka ___

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-31 Thread Raymond Hettinger
Raymond Hettinger added the comment: > After I generate an UML diagram from collections.abc, I found > very strange that MappingView inherit from Sized instead > of Collection (new in python 3.6). That isn't strange at all. MappingView predates Collection, so of course it didn't inherit from

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-29 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +4928 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Un

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-29 Thread Yahya Abou Imran
Yahya Abou Imran added the comment: And I just saw that Raymon Hettinger made it inherting from Sized: https://github.com/python/cpython/blame/master/Lib/_collections_abc.py#L694 So I we were to ahve his opinion on this... -- ___ Python tracker

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-29 Thread Yahya Abou Imran
Yahya Abou Imran added the comment: https://mail.python.org/pipermail/python-ideas/2017-December/048489.html Guido is waiting for objection on this... I have absolutly no idea why this decision was made. These tests (ttps://github.com/python/cpython/blame/master/Lib/test/test_collections.py#

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-29 Thread R. David Murray
R. David Murray added the comment: Well, it would be a backward compatibility problem at a minimum. Obviously things were designed this way. Have you found out why? Is there a consensus on python-ideas that this should be changed? If so, please link to the thread. -- nosy: +r.davi

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-29 Thread Yahya Abou Imran
Yahya Abou Imran added the comment: Quoting my own post on python-ideas: After I generate an UML diagram from collections.abc, I found very strange that MappingView inherit from Sized instead of Collection (new in python 3.6). Yes, MappingView only define __len__ and not __iter__ and __contai

[issue32449] MappingView must inherit from Collection instead of Sized

2017-12-29 Thread Yahya Abou Imran
New submission from Yahya Abou Imran : Quoting my own post on python-ideas: After I generate an UML diagram from collections.abc, I found very strange that MappingView inherit from Sized instead of Collection (new in python 3.6). Yes, MappingView only define __len__ and not __iter__ and __cont