Interest in including OrderedSet in python standard library?
Hello, I am interested to know if the maintainers of this package would have interest in including this functionality in the python standard library. It seems natural for OrderedSet to sit next to OrderedDict in the collections package. There is a discussion on the Python Discussion Forums. It is not clear-cut that it should be added but I wanted to gauge the interest of the folks maintaining the current Python ordered set implementations.
https://discuss.python.org/t/add-orderedset-to-stdlib/12730/15
I definitely think an OrderedSet belongs in the stdlib.
I think that an OrderedSet that fits naturally in the stdlib would be different from this implementation, which predates the current Python implementation of ordered dicts and ended up doing some things differently. But I'm happy to discuss if you want to use parts of it.
@jagerber48 @rspeer
Related to: https://github.com/rspeer/ordered-set/issues/91
We can also discuss my implementation of StableSet which is based on Python 3.6 dict.
I'm not sure if we should propose either implementations, or both.
StableSet could be analogous to dict and OrderedSet could be analogous to OrdredDict
If StableSet is implemented in the stdlib not in pure Python then it would be without dict.values() which would eliminate the extra memory of a pointer per entry set.
@idanmiara I know very little about how some of this code development for python stdlib typically works, I've just been trying to get the communication wheels rolling. I suggest you involve yourself in the discussion here: https://discuss.python.org/t/add-orderedset-to-stdlib/12730/1. A brief summary of my takeaway from the thread is this: People are most interested in an implementation of an OrderedSet based on post 3.6 dict. It sounds like most people wouldn't be opposed to including something like this, but the main concern is answering the question of who would write the implementation and do the work to get it into stdlib and who would do maintenance on it. If you feel like you have opinions on any of those things I recommend you share what you've done in that thread and we go from there!