Re: Metaclasses in traitlets and PEP 487

Thomas Kluyver <[email protected]>
Newsgroups gmane.comp.python.ipython.devel
Message-ID <CAOvn4qgZdRaHLnoDQMt9q4D31o_wkDUznM=XMn6X40J119H72g@mail.gmail.com>
On 15 February 2016 at 14:29, Martin Teichmann <[email protected]>
wrote:

> This is currently the point of discussion. My current assumption is that
> larger projects (like IPython) will certainly want to maintain backwards
> compatibility, and are typically hesitant to add new dependencies.
>
> The backport on PyPI will just be one short file which tries to import the
> new classes in the standard library, and will fall back to an own
> implementation.
> One way would then be to add this PyPI package as a dependency to
> IPython. Another way would be to simply add that simple file to IPython,
> then we have either the backwards compatibility or the compatibility
> with other projects (if we did find the standard library classes), but not
> both.
>

I think we'd be OK with adding a small, pure-Python dependency like that.
It seems a bit silly to make a standardised metaclass to facilitate
multiple inheritance, and then make independent incompatible copies of it!

> You also mentioned situations in which you want to have compatibility
with C++ extension metaclasses. Those will only be compatible once our new
metaclass makes it into the interpreter proper. That will still take some
time, though.
Gotcha. I can still see the advantage of reducing the likelihood that
someone else will need that kind of craziness, though.

Thomas

_______________________________________________
IPython-dev mailing list
[email protected]
https://mail.scipy.org/mailman/listinfo/ipython-dev
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.