These are chat archives for ipython/ipython

8th
May 2015
Kyle Kelley
@rgbkrk
May 08 2015 00:21 UTC
yay, it's back up
Kyle Kelley
@rgbkrk
May 08 2015 04:55 UTC
oooh man, now that try.jupyter.org is linked from jupyter.org we're getting a good bit of traffic
Kind of jittery
I'm assuming they're bouncing pretty quick
Plenty holding strong though
Kyle Kelley
@rgbkrk
May 08 2015 05:01 UTC
Wow jupyter/nbviewer#451 is my favorite thread in a long time on Github
Fernando Perez
@fperez
May 08 2015 05:36 UTC
Second that, @rgbkrk :)
Kyle Kelley
@rgbkrk
May 08 2015 15:50 UTC
We should buy this to have a portable tmpnb or jupyterhub box at conferences
With all the drive by traffic of having try.jupyter.org on the jupyter.org page, we have no capacity on tmpnb
I'm going to add more servers.
Kyle Kelley
@rgbkrk
May 08 2015 16:09 UTC
I only have the pool sizes at 256
Bumping that to 512 for the next batch
Cull period is 10 minutes too, I may need to drop that to 5 minutes
This message was deleted
This message was deleted
Jason Grout
@jasongrout
May 08 2015 16:14 UTC
It would be really cool if you posted a blog showing usage graphs.
Kyle Kelley
@rgbkrk
May 08 2015 16:15 UTC
Considering there's a long line of people and I had it only ready for about 256 concurrent users....
it's not telling too much
status.jupyter.org is where that graph above comes from
One day I'd like to write another blog post...
Kyle Kelley
@rgbkrk
May 08 2015 16:39 UTC
there we go
and immediately containers are getting taken again
;)
Kyle Kelley
@rgbkrk
May 08 2015 16:51 UTC
The page a whole bunch of people are queued up on I took off the main tmpnb system
Kyle Kelley
@rgbkrk
May 08 2015 17:04 UTC
@ssanderson what are the current configs you're using to make IPython Notebook not give the warning on stop?
I'm interested in whatever makes tearing down a notebook in a container faster
Scott Sanderson
@ssanderson
May 08 2015 17:38 UTC
@rgbkrk what warnings do you mean?
I use a different entrypoint so that the SIGTERM sent by docker stop actually hits the notebook process
Kyle Kelley
@rgbkrk
May 08 2015 17:38 UTC
"Are you sure you want to shut down the notebook server, for serious?"
Ah, that's right
so no custom patches, a custom launcher
Scott Sanderson
@ssanderson
May 08 2015 17:39 UTC
yeah
Kyle Kelley
@rgbkrk
May 08 2015 17:39 UTC
I really don't want to resort to doing that
Now that I've finished off the ops and dev stuff I needed to do this morning, I'll look back at that again
Scott Sanderson
@ssanderson
May 08 2015 17:39 UTC
I think you have to; the issue is that the process structure of the default setup isn't forwarding signal handlers
hey, i had a quick question about hooks before i report an issue
i'd like to hook into the interpreter right before code is run, and i'd like to get the cell text about to be executed for the function i'm writing
pre_run_cell and pre_execute both seem too early to get the cell input, and pre_run_code_hook seems to be deprecated
is there an alternative that i should be considering? and is pre_run_code_hook actually going away soon?
Min RK
@minrk
May 08 2015 18:56 UTC
@takluyver can you answer the hook question?
Thomas Kluyver
@takluyver
May 08 2015 18:58 UTC
You could add an input transformer (or an AST transformer) that doesn't actually modify the input, just scans it.
oh interesting
i actually hadn't discovered input transformers --- i've only used events.register and set_hook
cool, thanks
(i'll probably just use pre_run_code_hook for now with history_manager.input_hist_raw for now, but i'll switch to scanning lines with a transformer if that goes away)
Thomas Kluyver
@takluyver
May 08 2015 19:57 UTC
ok. Thanks for letting us know, we might add the code to the events if there's enough demand.
Scott Sanderson
@ssanderson
May 08 2015 20:20 UTC
@takluyver I would probably also use an "I'm about to run some code" hook
right now I've got an AST visitor that actually translates the AST back into source code if it triggers an error
so having a convenient place to add a hook for "run this function on the slug of code about to be executed" would make it so that I could ast.compile it myself, run my transformer, and use the source code if it barfs
rather than having to translate the AST back to source, which is tricky and not guaranteed to produce exactly the same text
Min RK
@minrk
May 08 2015 20:26 UTC
makes sense
Scott Sanderson
@ssanderson
May 08 2015 20:26 UTC
just for completeness of "all the possible ways you could ever want to muck with python code", I kind of want to add a PR with support for @llllllllll's bytecode transformer library: https://github.com/llllllllll/codetransformer
I'll restrain myself on that one until I think of a use case that anyone else might have though... :)