These are chat archives for ipython/ipython

6th
Jan 2015
Stuart Mumford
@Cadair
Jan 06 2015 15:54
Hey, Happy new year all
@Carreau ping
Matthias Bussonnier
@Carreau
Jan 06 2015 16:24
@Cadair Yes ?
Stuart Mumford
@Cadair
Jan 06 2015 16:24
hey, I actually worked it out XD
Things had changed under me in master
But I do have another question that you or someone else might be able to help with.
Matthias Bussonnier
@Carreau
Jan 06 2015 16:26
what question ?
Stuart Mumford
@Cadair
Jan 06 2015 16:27
I am trying to create kernels in Python rather than read them in from a file
I can make a file which works (or at least it did last time I tried)
but when I try and recreate the JSON structure inside a KernelSpecManager subclass I can't seem to get it working
Matthias Bussonnier
@Carreau
Jan 06 2015 16:28
Hum weird. I know there might be some caching involved. DO you have the code somewhere ?
Stuart Mumford
@Cadair
Jan 06 2015 16:30
Is there a doc somewhere that describes what the keys should be in the constructor to KernelSpec/
Give me 5 on the code I am just putting it on GH
Matthias Bussonnier
@Carreau
Jan 06 2015 16:31
still pretty recent, so I doubt there is doc. Sorry about that.
Stuart Mumford
@Cadair
Jan 06 2015 16:32
That's ok, but I am basically just guessing as to what it does!
Matthias Bussonnier
@Carreau
Jan 06 2015 16:34
I'll add that on my todo, I'll have to run soon.
Stuart Mumford
@Cadair
Jan 06 2015 16:35
Basically my idea is that a list of directories can be provided, be it the ~/.virtualenvs dir or .conda/envs/ and it goes and finds all of the ipython executables and then uses those paths to generate KernelSpec objects
Andreas Klostermann
@akloster
Jan 06 2015 19:55
or an extendable kernel-discoverer, which can for example find remote kernels in a cluster
Jason Grout
@jasongrout
Jan 06 2015 21:50
Hi everyone. I'm curious what the current timeline for 3.0 is. Any idea?
Min RK
@minrk
Jan 06 2015 22:00
as soon as we can. We'll discuss it on Thursday, I'm sure.
I think we can cut a beta in a week or two.
Kyle Kelley
@rgbkrk
Jan 06 2015 22:04
ugggggg
I've been trying to make the debian docker image work
but the tests are failing no matter what I do with locale settings
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe1' in position 6: ordinal not in range(128)
Min RK
@minrk
Jan 06 2015 22:05
What exactly is failing?
Kyle Kelley
@rgbkrk
Jan 06 2015 22:06
1 error in utils, 48 in html 1 in nbconvert
I'll post the full log in my PR
Min RK
@minrk
Jan 06 2015 22:09
ok
Stuart Mumford
@Cadair
Jan 06 2015 22:20
@akloster In theory it will work to find kernels in any path <base_dir>/*/bin/ipython
Jason Grout
@jasongrout
Jan 06 2015 22:28
@Carreau: are you around?
Matthias Bussonnier
@Carreau
Jan 06 2015 22:29
a bit.
Jason Grout
@jasongrout
Jan 06 2015 22:29
I notice that in https://github.com/ipython/ipython/blob/5fe94896958a77c05a6186ae72a167ad9a53beb3/IPython/html/static/notebook/less/cell.less#L17, we now try to set the edit mode at a higher level than the cell div.
Matthias Bussonnier
@Carreau
Jan 06 2015 22:30
yes
Jason Grout
@jasongrout
Jan 06 2015 22:30
However, using the & like this causes some problems for me, since & is the entire parent selector.
Matthias Bussonnier
@Carreau
Jan 06 2015 22:30
you want to drop the div on div.cell ?
Jason Grout
@jasongrout
Jan 06 2015 22:31
basically, I do theming by setting a class on the body. Then I generate css for each theme by having the top-level theme class enclose the entire IPython css
but now, that one edit_mode css comes out as something like .edit_mode body.mytheme div.cell.selected
Matthias Bussonnier
@Carreau
Jan 06 2015 22:31
Oh, I see.
Jason Grout
@jasongrout
Jan 06 2015 22:32
can we split out that one edit_mode thing so we don't use &?
I can submit a PR
if you want
Matthias Bussonnier
@Carreau
Jan 06 2015 22:32
Yes, sure.
put a comment for the reason why.
we could also add an ID to the css link so that you can actually swap the theme.
Jason Grout
@jasongrout
Jan 06 2015 22:34
i don't understand your last comment
Matthias Bussonnier
@Carreau
Jan 06 2015 22:35
Do you regenerate the all css or just add some with body.mytheme ?
Jason Grout
@jasongrout
Jan 06 2015 22:35
all
otherwise weird precedence issues come up
Matthias Bussonnier
@Carreau
Jan 06 2015 22:36
so you could also name your theme mytheme.css and swap the style.min.css
Jason Grout
@jasongrout
Jan 06 2015 22:36
so my theme looks like body.mytheme { import the IPython css; theme customizations }
yes, I don't import style.min.css - I've overridden that to instead import all of my themes.
Matthias Bussonnier
@Carreau
Jan 06 2015 22:38
I would use something like ipython/ipython#7008 to generate N <theme>.css file and use js to swap the right link in the header.
because if you have lots of theme that could be megabytes to load. (just proposing alternative)
Also this allow you to "just" redefine variable in some cases.
(I'll drop really soon, getting late here)
Jason Grout
@jasongrout
Jan 06 2015 22:40
thanks; that's a good suggestion, and less kludgy than what I'm doing, I think.
I'll think about it.