WIP: refactoring traitlets to support nipype requirements#2
WIP: refactoring traitlets to support nipype requirements#2satra wants to merge 20 commits intoipython:masterfrom
Conversation
fix corresponding tests
|
I see you added BaseStr and Str - these were actually removed from the IPython-shipped traitlets because they were ambiguous, and no traits should actually be allowed to be ambiguously bytes or unicode. |
|
@minrk - pushed a quick fix and derived basestr from unicode |
|
Are you only using BaseStr and Str internally in this file, or do you use them directly elsewhere? Everywhere they are used in this PR should actually be Unicode instead, not BaseStr or Str. |
|
BaseStr only here, but Str is used elsewhere - once i've cleaned up the rest, i'll clean it up here. |
|
The issue being that Str is actually ambiguous about what its data contains (part of the the reason Python 3 changed 'str' to mean 'text' instead of 'bytes'). The Str traitlet adds extra ambiguity on top of that, because, as implemented here, it can be either str or unicode type. |
|
Note aso that ipython/ipython#4659 is not ready yet, and I'm not sure we should push traitlets too much forward while this PR is not in master. |
|
There have been a lot of changes upstream in IPython, due to the Widget architecture making Traitelts a significant public API. That's going to be the trickiest part of this. |
|
I would suggest waiting for 3.0 and then restart this package from scatch. |
d163288 to
bfa557f
Compare
Set calling program to UNKNOWN, when argv not in sys (take #2)
The main additions are:
This PR primarily serves as a placeholder for changes required to support nipype. It may turn out that some of these changes are orthogonal to IPython's view of traitlets (for example, support for Undefined as a valid value for any trait).