These are chat archives for ipython/ipython

19th
Nov 2014
Jason Grout
@jasongrout
Nov 19 2014 00:12 UTC
Perhaps a success and error callback function would be easier to do generally
Min RK
@minrk
Nov 19 2014 00:26 UTC
I think if linked traitlets cannot actually be linked (e.g. an exception can be raised due to an invalid value), then they shouldn't be linked in the first place, so I would be -1 on suppressing such errors.
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 01:08 UTC
I have been using traitlet validation for checking bounds on numbers, length of strings or the dimensionality of an array.
I mean that traitlets may be linked, but not for all values...
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 01:20 UTC
you see what I mean?
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 16:41 UTC
Another useful addition to link is the possibility to add a comparison predicate between traitlets.
-> Numpy and Pandas trait types are such that == and != return arrays/dataframes.
Jason Grout
@jasongrout
Nov 19 2014 17:22 UTC
@minrk - it wouldn't be suppressing the errors, it would be catching them and doing something with them.
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 17:31 UTC
the default callback for failure could just re-send the exception
Jason Grout
@jasongrout
Nov 19 2014 17:34 UTC
@jdfreder? I have some questions about the promises pr that was merged
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 17:54 UTC
another way to resolve it is not to test for inequality in IPython.utils.traitlets.link or dlink
Jason Grout
@jasongrout
Nov 19 2014 17:56 UTC
so don't be smart, but just set things? I could see that happening.
Jonathan Frederic
@jdfreder
Nov 19 2014 17:59 UTC
@jasongrout shoot
also, if we find something, I can open a PR to fix it
I've just been scooting along on the persistence stuff
Jonathan Frederic
@jdfreder
Nov 19 2014 18:07 UTC
@jasongrout did you still want to get ipython/ipython#6675 rebased and merged before your talk this week? Or did you already give your talk?
Kyle Kelley
@rgbkrk
Nov 19 2014 18:10 UTC
@minrk Do you think tornado would accept adding get_json_body to RequestHandler?
Jason Grout
@jasongrout
Nov 19 2014 18:39 UTC
@jdfreder - I'm working on a PR
and my talk is this Saturday, I'll try to get #6675 before then.
Min RK
@minrk
Nov 19 2014 19:17 UTC
@rgbkrk I'm not sure. Requests has similar behavior, so maybe.
get_json_body has more magic than I think they would accept. I think they would want a raw loads that raises instead of returning None.
Jason Grout
@jasongrout
Nov 19 2014 19:23 UTC
@jdfreder: ipython/ipython#6988
Jonathan Frederic
@jdfreder
Nov 19 2014 19:24 UTC
thanks, looking
Jonathan Frederic
@jdfreder
Nov 19 2014 19:32 UTC
@jasongrout one comment inline
Jason Grout
@jasongrout
Nov 19 2014 19:43 UTC
doe
done
Jonathan Frederic
@jdfreder
Nov 19 2014 19:51 UTC
okay I pinged @takluyver for a second review, otherwise looks good to me (and it looks like it will pass Travis too)
Jason Grout
@jasongrout
Nov 19 2014 19:59 UTC
great; thanks
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 20:10 UTC
just opened a pr removing the comparisons in traitlet links to make it work with numpy arrays (which overload the comparison operators)
Jonathan Frederic
@jdfreder
Nov 19 2014 20:13 UTC
@SylvainCorlay I'll take a look
Jonathan Frederic
@jdfreder
Nov 19 2014 20:32 UTC
I left a comment in the PR : )
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 20:49 UTC
me too :) Is everyone fine with the Union traitlet type?
Kyle Kelley
@rgbkrk
Nov 19 2014 20:49 UTC
Totally
Jonathan Frederic
@jdfreder
Nov 19 2014 20:51 UTC
Yes
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 20:56 UTC
then let' s just wait for someone to find the merge button.
I am still thinking of the merge-this-now.com domain name
Kyle Kelley
@rgbkrk
Nov 19 2014 20:57 UTC
lol
It's not my domain area on IPython
it would be weird if I merged
@jdfreder can jam it
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 20:58 UTC
yeah, but you could help with the cross domain issue of merge-this-now.com -> github does not like iframes :)
Jonathan Frederic
@jdfreder
Nov 19 2014 20:58 UTC
@SylvainCorlay I can't find the merge button
;)
Kyle Kelley
@rgbkrk
Nov 19 2014 21:00 UTC
It's the one labeled "close"
:trollface:
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 21:01 UTC
no kidding, the "close" button on PRs really looks like a "cancel" button for comments
Jonathan Frederic
@jdfreder
Nov 19 2014 21:02 UTC
@rgbkrk ahh you tricked me! flips table
jdfreder @jdfreder flips his table
Kyle Kelley
@rgbkrk
Nov 19 2014 21:02 UTC
@SylvainCorlay Yeah, I hate that. I've done it before and had to re-open
Sylvain Corlay
@SylvainCorlay
Nov 19 2014 21:05 UTC
thanks!
Kyle Kelley
@rgbkrk
Nov 19 2014 22:05 UTC
I think the text editor PR is good to start with, should merge in its free of bells and whistles fashion
Otherwise all my comments are going to be about future things we should probably think about doing
Jonathan Frederic
@jdfreder
Nov 19 2014 22:21 UTC
That's @takluyver 's PR ? I'll take a look
Jason Grout
@jasongrout
Nov 19 2014 23:40 UTC
@jdfreder: viewlists at ipython/ipython#6990
Jonathan Frederic
@jdfreder
Nov 19 2014 23:41 UTC
Thanks @jasongrout , looking
Jason Grout
@jasongrout
Nov 19 2014 23:41 UTC
awesome, thanks.