On Apr 4, 2020, at 12:45, Pete Wicken <petewic...@gmail.com> wrote: > > > Agreed that this could be achieved by a third party library; and probably > already is - but the ipaddress module in Python could also have been one.
Well, it was. Go read PEP 3144 that added it, and the discussion threads behind it. For years, there were attempts to propose an IP address library to Python that didn’t even make it as far as the PEP stage. Finally someone proposed adopting Google’s ipaddr—which wasn’t quite a category killer, but was very popular, and had a stable API, and the authors were willing to donate it. And it was rejected. Peter Moody took all the issues that came of during that discussion and forked ipaddr and came up with a new design that answered all of people’s concerns. He published a reference implementation and for months took feedback on it and improved it. Then he was ready to propose that for provisional acceptance into the stdlib (and to convert the external package into a backport for older versions of Python if it was accepted). And, after another round of bikeshedding, it got in. The existence of ipaddress should make the process for macaddress easier. (For one thing, a lot of design questions where two options seem good can be answered quickly by saying “ipaddress has the same question, see this thread, and they decided on A, so netaddress should also decide on A, both for the same reasons and for compatibility with ipaddress”.) But it still has to be done. If there already is a good library on PyPI today, it would make more sense to adopt it, or to use it as a starting point, than to start from scratch. The same way ipaddress happened—but hopefully less work. If there isn’t a good existing candidate, so it has to be designed from scratch, very few things go directly into the stdlib. Even things that are designed from the start to land there, like tulip (designed to become asyncio, which it did) and regex (designed to replace re, which it still hasn’t after 8 years or work) are almost always shared and used in the field before they’re proposed for inclusion (and then converted into a backport after inclusion). Although again, the process should be a lot easier with macaddress than with something as complicated as regex or as unprecedented as tulip. _______________________________________________ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/SED5D2SPA2EZNB5PFDGWAGJZTI7O4CWJ/ Code of Conduct: http://python.org/psf/codeofconduct/