These are chat archives for ipython/ipython

20th
Jan 2015
Jonathan Frederic
@jdfreder
Jan 20 2015 00:34
@takluyver you cursed me
I've been working on an async problem for the past couple of hours... :horse:
Thomas Kluyver
@takluyver
Jan 20 2015 00:41
oh dear
he was just waiting for you to get back
:horse:
Min RK
@minrk
Jan 20 2015 17:10
slow busses today, so I might be a little late but I'll be there.
Damian Avila
@damianavila
Jan 20 2015 17:14
/@all, I will probably miss the meeting today... have a good day!
Thomas Kluyver
@takluyver
Jan 20 2015 17:20
@damianavila no worries, thanks for letting us know
Scott Sanderson
@ssanderson
Jan 20 2015 17:27
what time is the dev meeting? I may try to sit in for part of it.
I also figured out how to make my microphone not sound like it's on fire :)
Jonathan Frederic
@jdfreder
Jan 20 2015 17:27
Hey Scott
9:30
Jessica B. Hamrick
@jhamrick
Jan 20 2015 17:27
Usually it’s at 9:30
Scott Sanderson
@ssanderson
Jan 20 2015 17:28
so 2 minutes from now?
Jonathan Frederic
@jdfreder
Jan 20 2015 17:28
Yup
Thomas Kluyver
@takluyver
Jan 20 2015 17:28
we may wait for @minrk to arrive
his bus is apparently running a bit late
we usually start it from his computer
Min RK
@minrk
Jan 20 2015 17:29
almost there.
Thomas Kluyver
@takluyver
Jan 20 2015 17:29
great, we'll wait, then
Brian E. Granger
@ellisonbg
Jan 20 2015 17:31
ok
Thomas Kluyver
@takluyver
Jan 20 2015 17:33
Min's here, just getting a drink
Scott Sanderson
@ssanderson
Jan 20 2015 17:33
gotcha, I've got a planning meeting here at 1, (10 your time) in a few minutes; that may or may not end in time for me to hop in for the tail end of the dev meeting
Thomas Kluyver
@takluyver
Jan 20 2015 17:34
ok
it looks like it may be a fairly short one today, but looks can be deceiving
Brian E. Granger
@ellisonbg
Jan 20 2015 17:35
yep
Kyle Kelley
@rgbkrk
Jan 20 2015 17:42
yikes, got busy, joining now
Matthias Bussonnier
@Carreau
Jan 20 2015 18:40
had to go.
see you soon .
still searchng for flat, if not found I'll AirBnB for a few weeks.
Brian E. Granger
@ellisonbg
Jan 20 2015 18:41
ok bye!
Jason Grout
@jasongrout
Jan 20 2015 18:43
@jdfreder: did you have any questions about ipython/ipython#7509 that I could help with?
Jonathan Frederic
@jdfreder
Jan 20 2015 18:48
@jasongrout thanks, I may soon, not yet though. I'm going to try to implement the fix we talked about in the meeting. Let me know if you aren't listening and I'll fill you in.
Jason Grout
@jasongrout
Jan 20 2015 18:57
I wasn't listening.
and still am not listening...
so if you could fill me in after the meeting, that would be great (or better, summarize it on the PR, especially if it works)
Jonathan Frederic
@jdfreder
Jan 20 2015 20:29
@jasongrout sure, the output widget works by pushing and popping itself from a stack of output areas maintained in the codecell. Because of this, the output widget only needs a 'push' and 'pop' message. The iopub messages remain unchanged, the only change is that the codecell must route them appropriately. This whole design assumes messages are revcieved in the order they were sent from the backend. This was an okay assumption until the Promise stuff. With the addition of the Promise logic to comms, the custom widget messages are evaluated when the promises are evaluated (which is similar to setTimeout(f, 0);).
The push and pop messages are over a comm, and the iopub ones aren't. This means all push and pop messages appear AFTER the iopub messages.
The solution is to route the iopub messages over the widget custom message protocol.
Scott Sanderson
@ssanderson
Jan 20 2015 21:13
is there a straightforward way to forward command line arguments for the notebook server to frontend javascript?
Min RK
@minrk
Jan 20 2015 21:13
I'm not sure what you mean
what for?
Jonathan Frederic
@jdfreder
Jan 20 2015 21:14
@ssanderson with a widget :)
Min RK
@minrk
Jan 20 2015 21:14
With a custom template, you could add data to the page that comes from the command-line
Scott Sanderson
@ssanderson
Jan 20 2015 21:14
we have a bunch of logic in one of our nbextensions that talks to an external service: currently we pass that information to the javascript as part of an iframe querystring, but that's had weird race conditions that I don't fully understand
Min RK
@minrk
Jan 20 2015 21:14
I guess you could add sys.argv directly
Scott Sanderson
@ssanderson
Jan 20 2015 21:15
so what I'd like to be able to do is start the server with something like "ipython notebook --foo=bar", and have "bar" end up as a string constant in an nbextension
Jonathan Frederic
@jdfreder
Jan 20 2015 21:15
A widget where the traitlets were both config=true and sync=true, would work, but is probably not as good as the template method @minrk suggests.
Scott Sanderson
@ssanderson
Jan 20 2015 21:15
yeah, this is stuff that needs to be independent of any particular noteobok
it actually controls url rewriting on the notebooklist page, for example
Min RK
@minrk
Jan 20 2015 21:16
We recently merged server-side extensions, which let you add new handlers to the notebook
Scott Sanderson
@ssanderson
Jan 20 2015 21:17
I guess another possibility would be to just write a minimal javascript file that exports the constants I want, and then load with require in my nbextension?
I forget, is there a notion of frontend config that I can put this stuff in?
Scott Sanderson
@ssanderson
Jan 20 2015 21:53
going with the totally not hacky solution of "sed an environment variable into my javascript file during docker startup" for now; I'd be interested in talking about making it easier to do this sort of thing more robustly
Brian E. Granger
@ellisonbg
Jan 20 2015 23:12
Seeing this in the console = notebook validation error
[E 15:10:42.427 NotebookApp] Notebook JSON is invalid: u'name' is a required property

    Failed validating u'required' in schema[u'properties'][u'metadata'][u'properties'][u'language_info']:
        {u'description': u'Kernel information.',
         u'properties': {u'codemirror_mode': {u'description': u'The codemirror mode to use for code in this language.',
                                              u'oneOf': [{u'type': u'string'},
                                                         {u'type': u'object'}]},
                         u'file_extension': {u'description': u'The file extension for files in this language.',
                                             u'type': u'string'},
                         u'mimetype': {u'description': u'The mimetype corresponding to files in this language.',
                                       u'type': u'string'},
                         u'name': {u'description': u'The programming language which this kernel runs.',
                                   u'type': u'string'},
                         u'pygments_lexer': {u'description': u'The pygments lexer to use for code in this language.',
                                             u'type': u'string'}},
         u'required': [u'name'],
         u'type': u'object'}

    On instance[u'metadata'][u'language_info']:
        {}
Also see a modal dialog in the notebook with that information as well. Hmmm
Anyone else seeing it?
Min RK
@minrk
Jan 20 2015 23:37
you have empty language_info
either we should allow that or be more careful about ensuring it's filled.
I suspect it's a result of creating an empty notebook and reloading the page without saving.
Brian E. Granger
@ellisonbg
Jan 20 2015 23:43
Let me see if I can reproduce...
Min RK
@minrk
Jan 20 2015 23:47
@ellisonbg #7516