From cordial.emily at gmail.com Tue Jul 1 18:23:12 2014 From: cordial.emily at gmail.com (Emily Schleiner) Date: Tue, 1 Jul 2014 15:23:12 -0700 Subject: [IPython-dev] website Message-ID: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> Dear IPython developers, A couple of months ago I spoke with Thomas at an Openhatch event about the IPython website and it sounds like some design work might be welcome. (?) I've been lurking on your lists to get to know the group some and have now forked the site on Github with the aim of making it responsive. So far I don't plan on revamping the basic shape or colors, but I'm interested to hear any design preferences from the community... Best wishes, Emily -- __________________________________ Emily Schleiner cordial-emily.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140701/7341f766/attachment.html> From takowl at gmail.com Tue Jul 1 21:22:46 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 1 Jul 2014 18:22:46 -0700 Subject: [IPython-dev] Making small kernels just got easier Message-ID: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> We just merged a PR that makes it much simpler to write wrapper kernels in Python for other languages. Simply subclass a class in IPython, and define a few methods and attributes, as described here: http://ipython.org/ipython-doc/dev/development/wrapperkernels.html For instance, I've just written a kernel for bash (no completion, but it can run commands): https://github.com/takluyver/bash_kernel To try this out, get the latest IPython development version, then pip install bash_kernel. Run ipython qtconsole --kernel bash to start it. Best wishes, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140701/3b6fd948/attachment.html> From mgadbois at gmail.com Tue Jul 1 22:01:56 2014 From: mgadbois at gmail.com (Martin Gadbois) Date: Tue, 1 Jul 2014 22:01:56 -0400 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> Message-ID: <CAN1QFFSuM0TsD+yu+ezA4XO+3ODGnUdx487entgcwSS53U9WSw@mail.gmail.com> What I was waiting for... thanks! On Tue, Jul 1, 2014 at 9:22 PM, Thomas Kluyver <takowl at gmail.com> wrote: > We just merged a PR that makes it much simpler to write wrapper kernels in > Python for other languages. Simply subclass a class in IPython, and define > a few methods and attributes, as described here: > http://ipython.org/ipython-doc/dev/development/wrapperkernels.html > > For instance, I've just written a kernel for bash (no completion, but it > can run commands): > https://github.com/takluyver/bash_kernel > > To try this out, get the latest IPython development version, then pip > install bash_kernel. Run ipython qtconsole --kernel bash to start it. > > Best wishes, > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Martin -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140701/66de9b3f/attachment.html> From takowl at gmail.com Tue Jul 1 23:05:35 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 1 Jul 2014 20:05:35 -0700 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAN1QFFSuM0TsD+yu+ezA4XO+3ODGnUdx487entgcwSS53U9WSw@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> <CAN1QFFSuM0TsD+yu+ezA4XO+3ODGnUdx487entgcwSS53U9WSw@mail.gmail.com> Message-ID: <CAOvn4qheG+yLGA9EWfd6CusTE8rNxf23xC3D27dMAYi7L+Y7pw@mail.gmail.com> Cool, what will you be writing a kernel for? Let us know how it goes - there's still time to refine this api before IPython 3 is released. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140701/20b6670f/attachment.html> From asmeurer at gmail.com Tue Jul 1 23:22:06 2014 From: asmeurer at gmail.com (Aaron Meurer) Date: Tue, 1 Jul 2014 22:22:06 -0500 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAOvn4qheG+yLGA9EWfd6CusTE8rNxf23xC3D27dMAYi7L+Y7pw@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> <CAN1QFFSuM0TsD+yu+ezA4XO+3ODGnUdx487entgcwSS53U9WSw@mail.gmail.com> <CAOvn4qheG+yLGA9EWfd6CusTE8rNxf23xC3D27dMAYi7L+Y7pw@mail.gmail.com> Message-ID: <CAKgW=6LyZuWx6uX+OnraxaVcA+sBXzpAPwFh-hfbgOEFnj0kaQ@mail.gmail.com> Does the existing kernels subclass from Kernel? I in particular want to know if it's possible to do custom completion by using a subclass of the default kernel that overrides do_complete? Aaron Meurer On Tue, Jul 1, 2014 at 10:05 PM, Thomas Kluyver <takowl at gmail.com> wrote: > Cool, what will you be writing a kernel for? Let us know how it goes - > there's still time to refine this api before IPython 3 is released. > > Thomas > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From takowl at gmail.com Wed Jul 2 01:43:18 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 1 Jul 2014 22:43:18 -0700 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAKgW=6LyZuWx6uX+OnraxaVcA+sBXzpAPwFh-hfbgOEFnj0kaQ@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> <CAN1QFFSuM0TsD+yu+ezA4XO+3ODGnUdx487entgcwSS53U9WSw@mail.gmail.com> <CAOvn4qheG+yLGA9EWfd6CusTE8rNxf23xC3D27dMAYi7L+Y7pw@mail.gmail.com> <CAKgW=6LyZuWx6uX+OnraxaVcA+sBXzpAPwFh-hfbgOEFnj0kaQ@mail.gmail.com> Message-ID: <CAOvn4qjY2t47iV8x3KWvLYgLr8r0n1=y=WKM8GGjwn2isPKvoA@mail.gmail.com> Yes, the standard IPython kernel is a subclass, and it should be possible to override do_complete. On 1 Jul 2014 20:22, "Aaron Meurer" <asmeurer at gmail.com> wrote: > Does the existing kernels subclass from Kernel? I in particular want > to know if it's possible to do custom completion by using a subclass > of the default kernel that overrides do_complete? > > Aaron Meurer > > On Tue, Jul 1, 2014 at 10:05 PM, Thomas Kluyver <takowl at gmail.com> wrote: > > Cool, what will you be writing a kernel for? Let us know how it goes - > > there's still time to refine this api before IPython 3 is released. > > > > Thomas > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140701/e64852c6/attachment.html> From mgadbois at gmail.com Wed Jul 2 07:01:20 2014 From: mgadbois at gmail.com (Martin Gadbois) Date: Wed, 2 Jul 2014 07:01:20 -0400 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAOvn4qheG+yLGA9EWfd6CusTE8rNxf23xC3D27dMAYi7L+Y7pw@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> <CAN1QFFSuM0TsD+yu+ezA4XO+3ODGnUdx487entgcwSS53U9WSw@mail.gmail.com> <CAOvn4qheG+yLGA9EWfd6CusTE8rNxf23xC3D27dMAYi7L+Y7pw@mail.gmail.com> Message-ID: <CAN1QFFQUy390JMi6Mtgz76Q9h0u7rvF6gxtzNCOs6jSHuwSjVg@mail.gmail.com> I asked earlier... http://mail.scipy.org/pipermail/ipython-dev/2014-May/013940.html On Tue, Jul 1, 2014 at 11:05 PM, Thomas Kluyver <takowl at gmail.com> wrote: > Cool, what will you be writing a kernel for? Let us know how it goes - > there's still time to refine this api before IPython 3 is released. > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Martin -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/2050e02e/attachment.html> From doug.blank at gmail.com Wed Jul 2 08:15:11 2014 From: doug.blank at gmail.com (Doug Blank) Date: Wed, 2 Jul 2014 08:15:11 -0400 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAN1QFFQUy390JMi6Mtgz76Q9h0u7rvF6gxtzNCOs6jSHuwSjVg@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> <CAN1QFFSuM0TsD+yu+ezA4XO+3ODGnUdx487entgcwSS53U9WSw@mail.gmail.com> <CAOvn4qheG+yLGA9EWfd6CusTE8rNxf23xC3D27dMAYi7L+Y7pw@mail.gmail.com> <CAN1QFFQUy390JMi6Mtgz76Q9h0u7rvF6gxtzNCOs6jSHuwSjVg@mail.gmail.com> Message-ID: <CAAusYCgX1goPxKtN442iizXYqcpc9YbKKAVdSdXOoVuaLXSwWQ@mail.gmail.com> On Wed, Jul 2, 2014 at 7:01 AM, Martin Gadbois <mgadbois at gmail.com> wrote: > I asked earlier... > > http://mail.scipy.org/pipermail/ipython-dev/2014-May/013940.html > One could just pass the contents of the cell to pysqlite, without even attempting to parse the SQL---is there anything to gain by parsing the SQL in Python, I wonder? I guess for completions, you will have to. It will be interesting to see how you handle selecting the database file; magic meta command? Does the base kernel handle any of the standard magic preprocessing? I have (and there are) a number of languages implemented in Python (Basic, LC3, BrainF*ck, Logo, Lua, ...) that could be turned into stand-alone kernels... will have to give this a try; thanks! -Doug > On Tue, Jul 1, 2014 at 11:05 PM, Thomas Kluyver <takowl at gmail.com> wrote: > >> Cool, what will you be writing a kernel for? Let us know how it goes - >> there's still time to refine this api before IPython 3 is released. >> >> Thomas >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Martin > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/839505ff/attachment.html> From jsw at fnal.gov Wed Jul 2 12:43:13 2014 From: jsw at fnal.gov (Jon Wilson) Date: Wed, 2 Jul 2014 11:43:13 -0500 Subject: [IPython-dev] Including notebooks in a wiki Message-ID: <53B436A1.50607@fnal.gov> Hi all, Having gotten a nice anaconda setup working including pandoc, I've naturally been asked to document it on our wiki, both use and the procedure I went through to set it up. In order to showcase how it works and how it can be used to load and analyze CDMS data, I was thinking of including a notebook that I wrote that does exactly that. I know that people regularly include notebooks in blogs, (e.g. jakevdp.github.io (nice blog btw!)). Does anyone have experience including a notebook in a wiki? The wiki in question is dokuwiki, but I expect that a solution for one wiki syntax wouldn't be too difficult to translate to another wiki syntax. Regards, Jon From nick.bollweg at gmail.com Wed Jul 2 12:46:53 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Wed, 2 Jul 2014 12:46:53 -0400 Subject: [IPython-dev] website In-Reply-To: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> Message-ID: <CACejjWy2b9o0jG-hwL6GyMCu5td2OfSYWL+eV3eauzVGojMAgA@mail.gmail.com> Sounds great! I'm not a core developer or anything, but have been lurking for a while as well. While I wouldn't see any kind of unification of these styles, as the needs of the "applications" are likely different from the needs of the marketing/documentation website, it might be good to make sure that we're kind of in the right neighborhood in terms of what tools are used across all of the ipython-branded websites. As you may have observed, a lot of the work on the "other websites" (nbviewer and the notebook) uses Bootstrap, FontAwesome and related tools, such as LESS and bower. It seems like there would be a natural win here for these to also be used for the generated .org site. To that end, it might be worth investigating sphinx-bootstrap-theme <https://github.com/ryan-roemer/sphinx-bootstrap-theme> as a starting point for what might be possible. Good luck, I'm looking forward to what you come up with! On Tue, Jul 1, 2014 at 6:23 PM, Emily Schleiner <cordial.emily at gmail.com> wrote: > Dear IPython developers, > > A couple of months ago I spoke with Thomas at an Openhatch event about the > IPython website and it sounds like some design work might be welcome. (?) > I've been lurking on your lists to get to know the group some and have now > forked the site on Github with the aim of making it responsive. So far I > don't plan on revamping the basic shape or colors, but I'm interested to > hear any design preferences from the community... > > Best wishes, > Emily > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/ddd688a8/attachment.html> From cordial.emily at gmail.com Wed Jul 2 13:04:52 2014 From: cordial.emily at gmail.com (Emily Schleiner) Date: Wed, 2 Jul 2014 10:04:52 -0700 Subject: [IPython-dev] website In-Reply-To: <CACejjWy2b9o0jG-hwL6GyMCu5td2OfSYWL+eV3eauzVGojMAgA@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CACejjWy2b9o0jG-hwL6GyMCu5td2OfSYWL+eV3eauzVGojMAgA@mail.gmail.com> Message-ID: <CABWt4EiJ+vsuuGimUn1jKnVO01mEAYCmExHWJ5iTDgYqGcsRKw@mail.gmail.com> All good points -- and I particularly like bootstrap in general. I'm just to the point of turning your basic format into a responsive format with media queries on images and divs. (I still have to work on the navigation menu and font sizing but you can see the progress here: https://github.com/cordial-emily/ipython-website.) I thought something simple might be a helpful first step. I'm looking forward to making more interesting changes, which I will create branches for soon... Thanks for the input! Emily On Wed, Jul 2, 2014 at 9:46 AM, Nicholas Bollweg <nick.bollweg at gmail.com> wrote: > Sounds great! > > I'm not a core developer or anything, but have been lurking for a while as > well. > > While I wouldn't see any kind of unification of these styles, as the needs > of the "applications" are likely different from the needs of the > marketing/documentation website, it might be good to make sure that we're > kind of in the right neighborhood in terms of what tools are used across > all of the ipython-branded websites. > > As you may have observed, a lot of the work on the "other websites" > (nbviewer and the notebook) uses Bootstrap, FontAwesome and related tools, > such as LESS and bower. It seems like there would be a natural win here for > these to also be used for the generated .org site. To that end, it might be > worth investigating sphinx-bootstrap-theme > <https://github.com/ryan-roemer/sphinx-bootstrap-theme> as a starting > point for what might be possible. > > Good luck, I'm looking forward to what you come up with! > > > On Tue, Jul 1, 2014 at 6:23 PM, Emily Schleiner <cordial.emily at gmail.com> > wrote: > >> Dear IPython developers, >> >> A couple of months ago I spoke with Thomas at an Openhatch event about >> the IPython website and it sounds like some design work might be welcome. >> (?) I've been lurking on your lists to get to know the group some and have >> now forked the site on Github with the aim of making it responsive. So far >> I don't plan on revamping the basic shape or colors, but I'm interested to >> hear any design preferences from the community... >> >> Best wishes, >> Emily >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- __________________________________ Emily Schleiner cordial-emily.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/d92e7459/attachment.html> From takowl at gmail.com Wed Jul 2 13:28:35 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 2 Jul 2014 10:28:35 -0700 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAN1QFFQUy390JMi6Mtgz76Q9h0u7rvF6gxtzNCOs6jSHuwSjVg@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> <CAN1QFFSuM0TsD+yu+ezA4XO+3ODGnUdx487entgcwSS53U9WSw@mail.gmail.com> <CAOvn4qheG+yLGA9EWfd6CusTE8rNxf23xC3D27dMAYi7L+Y7pw@mail.gmail.com> <CAN1QFFQUy390JMi6Mtgz76Q9h0u7rvF6gxtzNCOs6jSHuwSjVg@mail.gmail.com> Message-ID: <CAOvn4qjf0k5o+1O_KMZ0gm5DBrCE-Q=8hLbQdcg3EWdRWnC+KQ@mail.gmail.com> On 2 July 2014 04:01, Martin Gadbois <mgadbois at gmail.com> wrote: > I asked earlier... > > http://mail.scipy.org/pipermail/ipython-dev/2014-May/013940.html > Sorry, I'd forgotten that. I look forward to seeing the sqlite kernel. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/eaae4d4e/attachment.html> From jsw at fnal.gov Wed Jul 2 13:41:35 2014 From: jsw at fnal.gov (Jon Wilson) Date: Wed, 2 Jul 2014 12:41:35 -0500 Subject: [IPython-dev] website In-Reply-To: <CABWt4EiJ+vsuuGimUn1jKnVO01mEAYCmExHWJ5iTDgYqGcsRKw@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CACejjWy2b9o0jG-hwL6GyMCu5td2OfSYWL+eV3eauzVGojMAgA@mail.gmail.com> <CABWt4EiJ+vsuuGimUn1jKnVO01mEAYCmExHWJ5iTDgYqGcsRKw@mail.gmail.com> Message-ID: <53B4444F.1040304@fnal.gov> Hi Emily, You might consider using github pages (https://pages.github.com/) to host your fork of the site. This will make it easier to see the progress/results. Regards, Jon On 07/02/2014 12:04 PM, Emily Schleiner wrote: > All good points -- and I particularly like bootstrap in general. I'm > just to the point of turning your basic format into a responsive > format with media queries on images and divs. (I still have to work > on the navigation menu and font sizing but you can see the progress > here: https://github.com/cordial-emily/ipython-website.) I thought > something simple might be a helpful first step. > > I'm looking forward to making more interesting changes, which I will > create branches for soon... > Thanks for the input! > > Emily > > > On Wed, Jul 2, 2014 at 9:46 AM, Nicholas Bollweg > <nick.bollweg at gmail.com <mailto:nick.bollweg at gmail.com>> wrote: > > Sounds great! > > I'm not a core developer or anything, but have been lurking for a > while as well. > > While I wouldn't see any kind of unification of these styles, as > the needs of the "applications" are likely different from the > needs of the marketing/documentation website, it might be good to > make sure that we're kind of in the right neighborhood in terms of > what tools are used across all of the ipython-branded websites. > > As you may have observed, a lot of the work on the "other > websites" (nbviewer and the notebook) uses Bootstrap, FontAwesome > and related tools, such as LESS and bower. It seems like there > would be a natural win here for these to also be used for the > generated .org site. To that end, it might be worth investigating > sphinx-bootstrap-theme > <https://github.com/ryan-roemer/sphinx-bootstrap-theme> as a > starting point for what might be possible. > > Good luck, I'm looking forward to what you come up with! > > > On Tue, Jul 1, 2014 at 6:23 PM, Emily Schleiner > <cordial.emily at gmail.com <mailto:cordial.emily at gmail.com>> wrote: > > Dear IPython developers, > > A couple of months ago I spoke with Thomas at an Openhatch > event about the IPython website and it sounds like some design > work might be welcome. (?) I've been lurking on your lists to > get to know the group some and have now forked the site on > Github with the aim of making it responsive. So far I don't > plan on revamping the basic shape or colors, but I'm > interested to hear any design preferences from the community... > > Best wishes, > Emily > > -- > __________________________________ > Emily Schleiner > cordial-emily.com <http://cordial-emily.com> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com <http://cordial-emily.com> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/a6a90595/attachment.html> From takowl at gmail.com Wed Jul 2 13:43:57 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 2 Jul 2014 10:43:57 -0700 Subject: [IPython-dev] Including notebooks in a wiki In-Reply-To: <53B436A1.50607@fnal.gov> References: <53B436A1.50607@fnal.gov> Message-ID: <CAOvn4qiz07w7pjMzxmVM-yPaeWd=G+wrLAGVcF92bzb_QjUrFw@mail.gmail.com> Hi Jon, One way would be to write a dokuwiki exporter for nbconvert. You could base it on the rst exporter: https://github.com/ipython/ipython/blob/master/IPython/nbconvert/exporters/rst.py https://github.com/ipython/ipython/blob/master/IPython/nbconvert/templates/rst.tpl However, pandoc doesn't appear to be able to convert markdown to dokuwiki, so you'd need to find another tool to do that. Alternatively, you could use a dokuwiki plugin to render pages from a format that notebooks can be exported to, e.g. markdown: https://www.dokuwiki.org/plugin:markdownextra Or, going one step further, you could write a dokuwiki plugin to handle notebook files directly. But yuck, PHP. Thomas On 2 July 2014 09:43, Jon Wilson <jsw at fnal.gov> wrote: > Hi all, > Having gotten a nice anaconda setup working including pandoc, I've > naturally been asked to document it on our wiki, both use and the > procedure I went through to set it up. In order to showcase how it > works and how it can be used to load and analyze CDMS data, I was > thinking of including a notebook that I wrote that does exactly that. > > I know that people regularly include notebooks in blogs, (e.g. > jakevdp.github.io (nice blog btw!)). Does anyone have experience > including a notebook in a wiki? The wiki in question is dokuwiki, but I > expect that a solution for one wiki syntax wouldn't be too difficult to > translate to another wiki syntax. > Regards, > Jon > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/b9a3002c/attachment.html> From jsw at fnal.gov Wed Jul 2 13:47:39 2014 From: jsw at fnal.gov (Jon Wilson) Date: Wed, 2 Jul 2014 12:47:39 -0500 Subject: [IPython-dev] Including notebooks in a wiki In-Reply-To: <CAOvn4qiz07w7pjMzxmVM-yPaeWd=G+wrLAGVcF92bzb_QjUrFw@mail.gmail.com> References: <53B436A1.50607@fnal.gov> <CAOvn4qiz07w7pjMzxmVM-yPaeWd=G+wrLAGVcF92bzb_QjUrFw@mail.gmail.com> Message-ID: <53B445BB.7020408@fnal.gov> Hi Thomas, Thanks for these suggestions. It has occurred to me that the simplest thing would probably be to simply attach an HTML file to the page and link to it. That will likely be my starting point, as I've spent too much of my time on software stuff in the last several days. Have to get some other stuff done before I do any more development, and my next development project is probably to get pandas to read CERN ROOT files directly... Regards, Jon On 07/02/2014 12:43 PM, Thomas Kluyver wrote: > Hi Jon, > > One way would be to write a dokuwiki exporter for nbconvert. You could > base it on the rst exporter: > https://github.com/ipython/ipython/blob/master/IPython/nbconvert/exporters/rst.py > https://github.com/ipython/ipython/blob/master/IPython/nbconvert/templates/rst.tpl > > However, pandoc doesn't appear to be able to convert markdown to > dokuwiki, so you'd need to find another tool to do that. > > Alternatively, you could use a dokuwiki plugin to render pages from a > format that notebooks can be exported to, e.g. markdown: > https://www.dokuwiki.org/plugin:markdownextra > > Or, going one step further, you could write a dokuwiki plugin to > handle notebook files directly. But yuck, PHP. > > Thomas > > > On 2 July 2014 09:43, Jon Wilson <jsw at fnal.gov <mailto:jsw at fnal.gov>> > wrote: > > Hi all, > Having gotten a nice anaconda setup working including pandoc, I've > naturally been asked to document it on our wiki, both use and the > procedure I went through to set it up. In order to showcase how it > works and how it can be used to load and analyze CDMS data, I was > thinking of including a notebook that I wrote that does exactly that. > > I know that people regularly include notebooks in blogs, (e.g. > jakevdp.github.io <http://jakevdp.github.io> (nice blog btw!)). > Does anyone have experience > including a notebook in a wiki? The wiki in question is dokuwiki, > but I > expect that a solution for one wiki syntax wouldn't be too > difficult to > translate to another wiki syntax. > Regards, > Jon > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/b12af131/attachment.html> From cordial.emily at gmail.com Wed Jul 2 13:50:14 2014 From: cordial.emily at gmail.com (Emily Schleiner) Date: Wed, 2 Jul 2014 10:50:14 -0700 Subject: [IPython-dev] website In-Reply-To: <53B4444F.1040304@fnal.gov> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CACejjWy2b9o0jG-hwL6GyMCu5td2OfSYWL+eV3eauzVGojMAgA@mail.gmail.com> <CABWt4EiJ+vsuuGimUn1jKnVO01mEAYCmExHWJ5iTDgYqGcsRKw@mail.gmail.com> <53B4444F.1040304@fnal.gov> Message-ID: <CABWt4EgV0MPsJH=zK5BYQLqPqy1wjo2Q0WmSqtO1QeTmdeMV4Q@mail.gmail.com> Have never seen this before -- great! On Wed, Jul 2, 2014 at 10:41 AM, Jon Wilson <jsw at fnal.gov> wrote: > Hi Emily, > You might consider using github pages (https://pages.github.com/) to host > your fork of the site. This will make it easier to see the > progress/results. > Regards, > Jon > > > On 07/02/2014 12:04 PM, Emily Schleiner wrote: > > All good points -- and I particularly like bootstrap in general. I'm > just to the point of turning your basic format into a responsive format > with media queries on images and divs. (I still have to work on the > navigation menu and font sizing but you can see the progress here: > https://github.com/cordial-emily/ipython-website.) I thought something > simple might be a helpful first step. > > I'm looking forward to making more interesting changes, which I will > create branches for soon... > > Thanks for the input! > > Emily > > > On Wed, Jul 2, 2014 at 9:46 AM, Nicholas Bollweg <nick.bollweg at gmail.com> > wrote: > >> Sounds great! >> >> I'm not a core developer or anything, but have been lurking for a while >> as well. >> >> While I wouldn't see any kind of unification of these styles, as the >> needs of the "applications" are likely different from the needs of the >> marketing/documentation website, it might be good to make sure that we're >> kind of in the right neighborhood in terms of what tools are used across >> all of the ipython-branded websites. >> >> As you may have observed, a lot of the work on the "other websites" >> (nbviewer and the notebook) uses Bootstrap, FontAwesome and related tools, >> such as LESS and bower. It seems like there would be a natural win here for >> these to also be used for the generated .org site. To that end, it might be >> worth investigating sphinx-bootstrap-theme >> <https://github.com/ryan-roemer/sphinx-bootstrap-theme> as a starting >> point for what might be possible. >> >> Good luck, I'm looking forward to what you come up with! >> >> >> On Tue, Jul 1, 2014 at 6:23 PM, Emily Schleiner <cordial.emily at gmail.com >> > wrote: >> >>> Dear IPython developers, >>> >>> A couple of months ago I spoke with Thomas at an Openhatch event about >>> the IPython website and it sounds like some design work might be welcome. >>> (?) I've been lurking on your lists to get to know the group some and have >>> now forked the site on Github with the aim of making it responsive. So far >>> I don't plan on revamping the basic shape or colors, but I'm interested to >>> hear any design preferences from the community... >>> >>> Best wishes, >>> Emily >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > > > _______________________________________________ > IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- __________________________________ Emily Schleiner cordial-emily.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/ffb185f7/attachment.html> From gaitan at gmail.com Wed Jul 2 13:50:39 2014 From: gaitan at gmail.com (=?UTF-8?B?TWFydMOtbiBHYWl0w6Fu?=) Date: Wed, 2 Jul 2014 14:50:39 -0300 Subject: [IPython-dev] Including notebooks in a wiki In-Reply-To: <CAOvn4qiz07w7pjMzxmVM-yPaeWd=G+wrLAGVcF92bzb_QjUrFw@mail.gmail.com> References: <53B436A1.50607@fnal.gov> <CAOvn4qiz07w7pjMzxmVM-yPaeWd=G+wrLAGVcF92bzb_QjUrFw@mail.gmail.com> Message-ID: <CAOCZAuyV7B_j9+EOoHafxX4anzH++F5Uq5BfBc-mo0VeqVS7cQ@mail.gmail.com> Maybe through markdown. it's supported in dokuwiki via plugins. https://www.dokuwiki.org/plugin:markdown and you can use nbconvert to export the notebook nbconvert --to markdown On Wed, Jul 2, 2014 at 2:43 PM, Thomas Kluyver <takowl at gmail.com> wrote: > Hi Jon, > > One way would be to write a dokuwiki exporter for nbconvert. You could > base it on the rst exporter: > > https://github.com/ipython/ipython/blob/master/IPython/nbconvert/exporters/rst.py > > https://github.com/ipython/ipython/blob/master/IPython/nbconvert/templates/rst.tpl > > However, pandoc doesn't appear to be able to convert markdown to dokuwiki, > so you'd need to find another tool to do that. > > Alternatively, you could use a dokuwiki plugin to render pages from a > format that notebooks can be exported to, e.g. markdown: > https://www.dokuwiki.org/plugin:markdownextra > > Or, going one step further, you could write a dokuwiki plugin to handle > notebook files directly. But yuck, PHP. > > Thomas > > > On 2 July 2014 09:43, Jon Wilson <jsw at fnal.gov> wrote: > >> Hi all, >> Having gotten a nice anaconda setup working including pandoc, I've >> naturally been asked to document it on our wiki, both use and the >> procedure I went through to set it up. In order to showcase how it >> works and how it can be used to load and analyze CDMS data, I was >> thinking of including a notebook that I wrote that does exactly that. >> >> I know that people regularly include notebooks in blogs, (e.g. >> jakevdp.github.io (nice blog btw!)). Does anyone have experience >> including a notebook in a wiki? The wiki in question is dokuwiki, but I >> expect that a solution for one wiki syntax wouldn't be too difficult to >> translate to another wiki syntax. >> Regards, >> Jon >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- mgaitan.github.io textosypretextos.com.ar <http://textosyprextextos.com.ar> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/02440a3f/attachment.html> From takowl at gmail.com Wed Jul 2 13:58:03 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 2 Jul 2014 10:58:03 -0700 Subject: [IPython-dev] website In-Reply-To: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> Message-ID: <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> Hi Emily, Thanks, I'm flattered that you remembered our conversation. We're actually just working out the details of hiring a designer, someone who was already known to one of the core team. It will probably be a while before we have anything concrete to show from that, but I don't want you to spend a lot of time redesigning our website if we end up replacing it with a completely new site within a year. I'll discuss with the rest of the core team what's happening with the website, but don't get too far into changing it just yet. One possibility is that we could point you to another open source project that's interested in this kind of work. Next week we're at SciPy, a conference where the people behind lots of scientific Python projects get together, so we can ask people there about that. Best wishes, Thomas On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> wrote: > Dear IPython developers, > > A couple of months ago I spoke with Thomas at an Openhatch event about the > IPython website and it sounds like some design work might be welcome. (?) > I've been lurking on your lists to get to know the group some and have now > forked the site on Github with the aim of making it responsive. So far I > don't plan on revamping the basic shape or colors, but I'm interested to > hear any design preferences from the community... > > Best wishes, > Emily > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/dcf6b815/attachment.html> From jsw at fnal.gov Wed Jul 2 14:05:36 2014 From: jsw at fnal.gov (Jon Wilson) Date: Wed, 2 Jul 2014 13:05:36 -0500 Subject: [IPython-dev] Including notebooks in a wiki In-Reply-To: <CAOCZAuyV7B_j9+EOoHafxX4anzH++F5Uq5BfBc-mo0VeqVS7cQ@mail.gmail.com> References: <53B436A1.50607@fnal.gov> <CAOvn4qiz07w7pjMzxmVM-yPaeWd=G+wrLAGVcF92bzb_QjUrFw@mail.gmail.com> <CAOCZAuyV7B_j9+EOoHafxX4anzH++F5Uq5BfBc-mo0VeqVS7cQ@mail.gmail.com> Message-ID: <53B449F0.3030605@fnal.gov> Thanks, Mart?n, I will give that a try. I don't know whether the plugin is already installed, so it might be a fight to get the admins to install it, we'll see. Thanks again, Jon On 07/02/2014 12:50 PM, Mart?n Gait?n wrote: > Maybe through markdown. it's supported in dokuwiki via plugins. > https://www.dokuwiki.org/plugin:markdown and you can use nbconvert to > export the notebook > nbconvert --to markdown > > > > > > On Wed, Jul 2, 2014 at 2:43 PM, Thomas Kluyver <takowl at gmail.com > <mailto:takowl at gmail.com>> wrote: > > Hi Jon, > > One way would be to write a dokuwiki exporter for nbconvert. You > could base it on the rst exporter: > https://github.com/ipython/ipython/blob/master/IPython/nbconvert/exporters/rst.py > https://github.com/ipython/ipython/blob/master/IPython/nbconvert/templates/rst.tpl > > However, pandoc doesn't appear to be able to convert markdown to > dokuwiki, so you'd need to find another tool to do that. > > Alternatively, you could use a dokuwiki plugin to render pages > from a format that notebooks can be exported to, e.g. markdown: > https://www.dokuwiki.org/plugin:markdownextra > > Or, going one step further, you could write a dokuwiki plugin to > handle notebook files directly. But yuck, PHP. > > Thomas > > > On 2 July 2014 09:43, Jon Wilson <jsw at fnal.gov > <mailto:jsw at fnal.gov>> wrote: > > Hi all, > Having gotten a nice anaconda setup working including pandoc, I've > naturally been asked to document it on our wiki, both use and the > procedure I went through to set it up. In order to showcase > how it > works and how it can be used to load and analyze CDMS data, I was > thinking of including a notebook that I wrote that does > exactly that. > > I know that people regularly include notebooks in blogs, (e.g. > jakevdp.github.io <http://jakevdp.github.io> (nice blog > btw!)). Does anyone have experience > including a notebook in a wiki? The wiki in question is > dokuwiki, but I > expect that a solution for one wiki syntax wouldn't be too > difficult to > translate to another wiki syntax. > Regards, > Jon > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > -- > mgaitan.github.io <http://mgaitan.github.io> > textosypretextos.com.ar <http://textosyprextextos.com.ar> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/484f2978/attachment.html> From cordial.emily at gmail.com Wed Jul 2 14:25:16 2014 From: cordial.emily at gmail.com (Emily Schleiner) Date: Wed, 2 Jul 2014 11:25:16 -0700 Subject: [IPython-dev] website In-Reply-To: <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> Message-ID: <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> Hi Thomas, I've already added some responsiveness to the theme you already use -- and in the mean time before you have a complete change this might be helpful to you. I'll just finish up the last couple of adjustments and call it good. Thanks for letting me know! Emily On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver <takowl at gmail.com> wrote: > Hi Emily, > > Thanks, I'm flattered that you remembered our conversation. We're actually > just working out the details of hiring a designer, someone who was already > known to one of the core team. It will probably be a while before we have > anything concrete to show from that, but I don't want you to spend a lot of > time redesigning our website if we end up replacing it with a completely > new site within a year. I'll discuss with the rest of the core team what's > happening with the website, but don't get too far into changing it just yet. > > One possibility is that we could point you to another open source project > that's interested in this kind of work. Next week we're at SciPy, a > conference where the people behind lots of scientific Python projects get > together, so we can ask people there about that. > > Best wishes, > Thomas > > > On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> wrote: > >> Dear IPython developers, >> >> A couple of months ago I spoke with Thomas at an Openhatch event about >> the IPython website and it sounds like some design work might be welcome. >> (?) I've been lurking on your lists to get to know the group some and have >> now forked the site on Github with the aim of making it responsive. So far >> I don't plan on revamping the basic shape or colors, but I'm interested to >> hear any design preferences from the community... >> >> Best wishes, >> Emily >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- __________________________________ Emily Schleiner cordial-emily.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/61268145/attachment.html> From doug.blank at gmail.com Wed Jul 2 14:29:10 2014 From: doug.blank at gmail.com (Doug Blank) Date: Wed, 2 Jul 2014 14:29:10 -0400 Subject: [IPython-dev] Notebooks for humanities students Message-ID: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> We've just begun a month-long, intensive project on using Notebooks for humanities students (weird, huh? I'll explain later). One of the first things we're tackling is creating appropriate documentation for this use. Here is what we are thinking, especially for Markdown: * assume user knows very little about technologies * examples should not refer to HTML tags to explain the output (eg, the Daring Fireball examples [1] describe effects in terms of HTML tags rather than rendered forms); show the raw version *and* rendered form * examples should not require a running kernel, and should be useful as shown (eg, not like [2]) * markdown documentation should be useable by any kernel (eg, should not make use of kernel-specific items) * docs should try to be as notebook-specific as possible (we are writing docs specifically for this use) * we are trying to be complete... documenting everything that Markdown in the notebook can (and cannot do); we are studying the "marked" project's test suite Of course we will share all of these back to the community at large. Speaking of that, I notice that: https://github.com/ipython/ipython/blob/master/docs/source/about/license_and_copyright.rst doesn't have a license for documentation/notebooks. Would it be possible to add a Creative Commons license to that for documentation? I'd be glad to add a pull request if a particular document license is indicated. And then we'll use the same license. Which? If anyone else has ideas or comments on constructing useful documentation for all uses, please let us know. Thanks! -Doug [1] - http://daringfireball.net/projects/markdown/syntax [2] - http://nbviewer.ipython.org/github/ipython/ipython/blob/1.x/examples/notebooks/Part%204%20-%20Markdown%20Cells.ipynb -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/c1259d30/attachment.html> From fperez.net at gmail.com Wed Jul 2 14:43:12 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 2 Jul 2014 11:43:12 -0700 Subject: [IPython-dev] Notebooks for humanities students In-Reply-To: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> References: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> Message-ID: <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> On Wed, Jul 2, 2014 at 11:29 AM, Doug Blank <doug.blank at gmail.com> wrote: > Would it be possible to add a Creative Commons license to that for > documentation? I'd be glad to add a pull request if a particular document > license is indicated. And then we'll use the same license. Which? > I'd like to see all our documentation licensed under CC-BY, which I think of as the 'moral equivalent' of BSD http://creativecommons.org/licenses/by/4.0/ But I am NOT 'dictating' this as a decision. This is just a proposal so others can pitch in, in case there's any divergence of opinion. Once we reach a decision, a PR on that would be wonderful. Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/c927a1d8/attachment.html> From aron at ahmadia.net Wed Jul 2 14:45:41 2014 From: aron at ahmadia.net (Aron Ahmadia) Date: Wed, 2 Jul 2014 14:45:41 -0400 Subject: [IPython-dev] Notebooks for humanities students In-Reply-To: <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> References: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> Message-ID: <CAPhiW4j-WcLmaQ=KTB109g9WgOzY0C-irzhdJmRWGoaipy_EoQ@mail.gmail.com> +1 in general I strongly encourage that the license make it explicit that examples are available for reuse under the IPython BSD license: Here's how it's done for Software Carpentry: http://software-carpentry.org/license.html A On Wed, Jul 2, 2014 at 2:43 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Wed, Jul 2, 2014 at 11:29 AM, Doug Blank <doug.blank at gmail.com> wrote: > >> Would it be possible to add a Creative Commons license to that for >> documentation? I'd be glad to add a pull request if a particular document >> license is indicated. And then we'll use the same license. Which? >> > > I'd like to see all our documentation licensed under CC-BY, which I think > of as the 'moral equivalent' of BSD > > http://creativecommons.org/licenses/by/4.0/ > > But I am NOT 'dictating' this as a decision. This is just a proposal so > others can pitch in, in case there's any divergence of opinion. > > Once we reach a decision, a PR on that would be wonderful. > > Cheers > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/59ffb2b3/attachment.html> From ellisonbg at gmail.com Wed Jul 2 16:40:07 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Wed, 2 Jul 2014 13:40:07 -0700 Subject: [IPython-dev] Notebooks for humanities students In-Reply-To: <CAPhiW4j-WcLmaQ=KTB109g9WgOzY0C-irzhdJmRWGoaipy_EoQ@mail.gmail.com> References: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> <CAPhiW4j-WcLmaQ=KTB109g9WgOzY0C-irzhdJmRWGoaipy_EoQ@mail.gmail.com> Message-ID: <79249B66-50FE-4E96-BDE0-A859694FF523@gmail.com> +1 for CC for narrative text and BSD for code examples Sent from my iPhone > On Jul 2, 2014, at 11:45 AM, Aron Ahmadia <aron at ahmadia.net> wrote: > > +1 in general > > I strongly encourage that the license make it explicit that examples are available for reuse under the IPython BSD license: Here's how it's done for Software Carpentry: > > http://software-carpentry.org/license.html > > A > > >> On Wed, Jul 2, 2014 at 2:43 PM, Fernando Perez <fperez.net at gmail.com> wrote: >> >>> On Wed, Jul 2, 2014 at 11:29 AM, Doug Blank <doug.blank at gmail.com> wrote: >>> Would it be possible to add a Creative Commons license to that for documentation? I'd be glad to add a pull request if a particular document license is indicated. And then we'll use the same license. Which? >> >> I'd like to see all our documentation licensed under CC-BY, which I think of as the 'moral equivalent' of BSD >> >> http://creativecommons.org/licenses/by/4.0/ >> >> But I am NOT 'dictating' this as a decision. This is just a proposal so others can pitch in, in case there's any divergence of opinion. >> >> Once we reach a decision, a PR on that would be wonderful. >> >> Cheers >> >> f >> >> >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/b7f93e38/attachment.html> From cyrille.rossant at gmail.com Wed Jul 2 17:20:32 2014 From: cyrille.rossant at gmail.com (Cyrille Rossant) Date: Wed, 2 Jul 2014 23:20:32 +0200 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> Message-ID: <CA+-1RQQOu5JzmvHQ5OqUWYKo6=M4WjYpFPkrreJGUvOeL=Pm6A@mail.gmail.com> Can it work in the notebook? 2014-07-02 3:22 GMT+02:00 Thomas Kluyver <takowl at gmail.com>: > We just merged a PR that makes it much simpler to write wrapper kernels in > Python for other languages. Simply subclass a class in IPython, and define > a few methods and attributes, as described here: > http://ipython.org/ipython-doc/dev/development/wrapperkernels.html > > For instance, I've just written a kernel for bash (no completion, but it > can run commands): > https://github.com/takluyver/bash_kernel > > To try this out, get the latest IPython development version, then pip > install bash_kernel. Run ipython qtconsole --kernel bash to start it. > > Best wishes, > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/4933b93f/attachment.html> From doug.blank at gmail.com Wed Jul 2 18:28:19 2014 From: doug.blank at gmail.com (Doug Blank) Date: Wed, 2 Jul 2014 18:28:19 -0400 Subject: [IPython-dev] Notebooks for humanities students In-Reply-To: <79249B66-50FE-4E96-BDE0-A859694FF523@gmail.com> References: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> <CAPhiW4j-WcLmaQ=KTB109g9WgOzY0C-irzhdJmRWGoaipy_EoQ@mail.gmail.com> <79249B66-50FE-4E96-BDE0-A859694FF523@gmail.com> Message-ID: <CAAusYCj+Ma2K0uzMjji5sQQRsBZ7m7duDDoKw6EFfj-gqRpMkA@mail.gmail.com> On Wed, Jul 2, 2014 at 4:40 PM, Brian Granger <ellisonbg at gmail.com> wrote: > +1 for CC for narrative text and BSD for code examples > Yes, I agree that the CC-BY license for docs fits best with a BSD-licensed project. That way, there shouldn't be any problem going back and forth between code and documentation. -Doug > > Sent from my iPhone > > On Jul 2, 2014, at 11:45 AM, Aron Ahmadia <aron at ahmadia.net> wrote: > > +1 in general > > I strongly encourage that the license make it explicit that examples are > available for reuse under the IPython BSD license: Here's how it's done > for Software Carpentry: > > http://software-carpentry.org/license.html > > A > > > On Wed, Jul 2, 2014 at 2:43 PM, Fernando Perez <fperez.net at gmail.com> > wrote: > >> >> On Wed, Jul 2, 2014 at 11:29 AM, Doug Blank <doug.blank at gmail.com> wrote: >> >>> Would it be possible to add a Creative Commons license to that for >>> documentation? I'd be glad to add a pull request if a particular document >>> license is indicated. And then we'll use the same license. Which? >>> >> >> I'd like to see all our documentation licensed under CC-BY, which I think >> of as the 'moral equivalent' of BSD >> >> http://creativecommons.org/licenses/by/4.0/ >> >> But I am NOT 'dictating' this as a decision. This is just a proposal so >> others can pitch in, in case there's any divergence of opinion. >> >> Once we reach a decision, a PR on that would be wonderful. >> >> Cheers >> >> f >> >> >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/17ce04fa/attachment.html> From takowl at gmail.com Wed Jul 2 18:49:10 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 2 Jul 2014 15:49:10 -0700 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CA+-1RQQOu5JzmvHQ5OqUWYKo6=M4WjYpFPkrreJGUvOeL=Pm6A@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> <CA+-1RQQOu5JzmvHQ5OqUWYKo6=M4WjYpFPkrreJGUvOeL=Pm6A@mail.gmail.com> Message-ID: <CAOvn4qiShQjP1tupp+kyRcKBP3Djcm5=oFGvf+tTT8CH8+OPWA@mail.gmail.com> On 2 July 2014 14:20, Cyrille Rossant <cyrille.rossant at gmail.com> wrote: > Can it work in the notebook? It can, but it will be better by the time IPython 3 is released. At present, the notebook is only aware of one type of kernel, so you have to start it up with a long command line option like this: ipython notebook --KernelManager.kernel_cmd="['python','-m','echokernel', ' -f', '{connection_file}']" Soon, this will be unnecessary: the notebook UI will have a list of available kernels to pick from. I'm working on the next step for this in a PR: https://github.com/ipython/ipython/pull/6026 Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/0f106dd6/attachment.html> From asmeurer at gmail.com Wed Jul 2 19:55:46 2014 From: asmeurer at gmail.com (Aaron Meurer) Date: Wed, 2 Jul 2014 18:55:46 -0500 Subject: [IPython-dev] Making small kernels just got easier In-Reply-To: <CAOvn4qiShQjP1tupp+kyRcKBP3Djcm5=oFGvf+tTT8CH8+OPWA@mail.gmail.com> References: <CAOvn4qjFpeHk25QpBGGzzY5YpV6fbR6AZOdaEuH_hM8NzewXmA@mail.gmail.com> <CA+-1RQQOu5JzmvHQ5OqUWYKo6=M4WjYpFPkrreJGUvOeL=Pm6A@mail.gmail.com> <CAOvn4qiShQjP1tupp+kyRcKBP3Djcm5=oFGvf+tTT8CH8+OPWA@mail.gmail.com> Message-ID: <2406629050787931186@unknownmsgid> Will it be possible to set the default kernel in the settings? I just want to override the completion in the Python kernel to use Jedi. Aaron Meurer On Jul 2, 2014, at 5:49 PM, Thomas Kluyver <takowl at gmail.com> wrote: On 2 July 2014 14:20, Cyrille Rossant <cyrille.rossant at gmail.com> wrote: > Can it work in the notebook? It can, but it will be better by the time IPython 3 is released. At present, the notebook is only aware of one type of kernel, so you have to start it up with a long command line option like this: ipython notebook --KernelManager.kernel_cmd="['python','-m','echokernel', ' -f', '{connection_file}']" Soon, this will be unnecessary: the notebook UI will have a list of available kernels to pick from. I'm working on the next step for this in a PR: https://github.com/ipython/ipython/pull/6026 Thanks, Thomas _______________________________________________ IPython-dev mailing list IPython-dev at scipy.org http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/20a3a16f/attachment.html> From fperez.net at gmail.com Wed Jul 2 22:52:46 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 2 Jul 2014 19:52:46 -0700 Subject: [IPython-dev] Examples of custom CSS for side-by-side (horizontal) output layout? Message-ID: <CAHAreOrbw_T11kox841UxJaJYEEtpbA6xKmCG9aJerBgvo_fFw@mail.gmail.com> Hi folks, I know in the past people have mentioned having customized their notebook layouts to display output next to the input cells instead of below them. Does anyone have an example handy of this, so I can refer a colleague to it? Thanks! f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140702/2f3496ec/attachment.html> From bussonniermatthias at gmail.com Thu Jul 3 02:50:25 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Thu, 3 Jul 2014 08:50:25 +0200 Subject: [IPython-dev] Examples of custom CSS for side-by-side (horizontal) output layout? In-Reply-To: <CAHAreOrbw_T11kox841UxJaJYEEtpbA6xKmCG9aJerBgvo_fFw@mail.gmail.com> References: <CAHAreOrbw_T11kox841UxJaJYEEtpbA6xKmCG9aJerBgvo_fFw@mail.gmail.com> Message-ID: <96E193F9-ACDA-48FC-86AE-68F0E76F83D8@gmail.com> Le 3 juil. 2014 ? 04:52, Fernando Perez a ?crit : > Hi folks, > > I know in the past people have mentioned having customized their notebook layouts to display output next to the input cells instead of below them. > > Does anyone have an example handy of this, so I can refer a colleague to it? %%html <style> div.cell{ box-orient:horizontal; flex-direction:row; } div.cell *{ width:100%; } div.prompt{ width:80px; } </style> CF : https://twitter.com/Mbussonn/status/474189448452665344 -- M > > Thanks! > > f -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/34b8675a/attachment.html> From bussonniermatthias at gmail.com Thu Jul 3 02:54:15 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Thu, 3 Jul 2014 08:54:15 +0200 Subject: [IPython-dev] Notebooks for humanities students In-Reply-To: <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> References: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> Message-ID: <BF1B71D8-4E7A-44D2-A3E6-FB46D3B2F48A@gmail.com> Le 2 juil. 2014 ? 20:43, Fernando Perez a ?crit : > > On Wed, Jul 2, 2014 at 11:29 AM, Doug Blank <doug.blank at gmail.com> wrote: > Would it be possible to add a Creative Commons license to that for documentation? I'd be glad to add a pull request if a particular document license is indicated. And then we'll use the same license. Which? > > I'd like to see all our documentation licensed under CC-BY, which I think of as the 'moral equivalent' of BSD > > http://creativecommons.org/licenses/by/4.0/ +1 > Once we reach a decision, a PR on that would be wonderful. +1 -- M -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/b9a55c61/attachment.html> From doug.blank at gmail.com Thu Jul 3 07:31:14 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 3 Jul 2014 07:31:14 -0400 Subject: [IPython-dev] Notebooks for humanities students In-Reply-To: <BF1B71D8-4E7A-44D2-A3E6-FB46D3B2F48A@gmail.com> References: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> <BF1B71D8-4E7A-44D2-A3E6-FB46D3B2F48A@gmail.com> Message-ID: <CAAusYCiZkG3YcENUJBhebCpu4xEEBzZhL6GpcMYhgB6rT3iJPw@mail.gmail.com> On Thu, Jul 3, 2014 at 2:54 AM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 2 juil. 2014 ? 20:43, Fernando Perez a ?crit : > > > On Wed, Jul 2, 2014 at 11:29 AM, Doug Blank <doug.blank at gmail.com> wrote: > >> Would it be possible to add a Creative Commons license to that for >> documentation? I'd be glad to add a pull request if a particular document >> license is indicated. And then we'll use the same license. Which? >> > > I'd like to see all our documentation licensed under CC-BY, which I think > of as the 'moral equivalent' of BSD > > http://creativecommons.org/licenses/by/4.0/ > > > +1 > > Once we reach a decision, a PR on that would be wonderful. > > Done: https://github.com/ipython/ipython/pull/6074 -Doug > > +1 > > -- > M > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/64becebc/attachment.html> From fperez.net at gmail.com Thu Jul 3 09:13:38 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Thu, 3 Jul 2014 06:13:38 -0700 Subject: [IPython-dev] Examples of custom CSS for side-by-side (horizontal) output layout? In-Reply-To: <96E193F9-ACDA-48FC-86AE-68F0E76F83D8@gmail.com> References: <CAHAreOrbw_T11kox841UxJaJYEEtpbA6xKmCG9aJerBgvo_fFw@mail.gmail.com> <96E193F9-ACDA-48FC-86AE-68F0E76F83D8@gmail.com> Message-ID: <CAHAreOo98NPPrRDoL4uCXTrCGw1a8A6QhEGAMR=LPB8ONBcnPw@mail.gmail.com> Merci beaucoup ! On Jul 2, 2014 11:49 PM, "Matthias Bussonnier" <bussonniermatthias at gmail.com> wrote: > > Le 3 juil. 2014 ? 04:52, Fernando Perez a ?crit : > > Hi folks, > > I know in the past people have mentioned having customized their notebook > layouts to display output next to the input cells instead of below them. > > Does anyone have an example handy of this, so I can refer a colleague to > it? > > > > %%html > <style> > div.cell{ > box-orient:horizontal; > flex-direction:row; > } > > div.cell *{ > width:100%; > } > > div.prompt{ > width:80px; > > } > </style> > > CF : https://twitter.com/Mbussonn/status/474189448452665344 > > -- > M > > > Thanks! > > f > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/12de136c/attachment.html> From fperez.net at gmail.com Thu Jul 3 09:14:19 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Thu, 3 Jul 2014 06:14:19 -0700 Subject: [IPython-dev] Notebooks for humanities students In-Reply-To: <CAAusYCiZkG3YcENUJBhebCpu4xEEBzZhL6GpcMYhgB6rT3iJPw@mail.gmail.com> References: <CAAusYCgw8CBL16nGSAubAvEahR2DSg2QS7DdfF8ae0Op4BBFXA@mail.gmail.com> <CAHAreOp_o83Dr9DPZ0PBvmbjujQ9WFgomokaQGMDT-eBy8ud7A@mail.gmail.com> <BF1B71D8-4E7A-44D2-A3E6-FB46D3B2F48A@gmail.com> <CAAusYCiZkG3YcENUJBhebCpu4xEEBzZhL6GpcMYhgB6rT3iJPw@mail.gmail.com> Message-ID: <CAHAreOpOPK+2O09Yo0OkYugh3RLN18xUJSo_O5Du-3LWzYFhqw@mail.gmail.com> great, thanks! On Jul 3, 2014 4:31 AM, "Doug Blank" <doug.blank at gmail.com> wrote: > On Thu, Jul 3, 2014 at 2:54 AM, Matthias Bussonnier < > bussonniermatthias at gmail.com> wrote: > >> >> Le 2 juil. 2014 ? 20:43, Fernando Perez a ?crit : >> >> >> On Wed, Jul 2, 2014 at 11:29 AM, Doug Blank <doug.blank at gmail.com> wrote: >> >>> Would it be possible to add a Creative Commons license to that for >>> documentation? I'd be glad to add a pull request if a particular document >>> license is indicated. And then we'll use the same license. Which? >>> >> >> I'd like to see all our documentation licensed under CC-BY, which I think >> of as the 'moral equivalent' of BSD >> >> http://creativecommons.org/licenses/by/4.0/ >> >> >> +1 >> >> Once we reach a decision, a PR on that would be wonderful. >> >> Done: > > https://github.com/ipython/ipython/pull/6074 > > -Doug > > > >> >> +1 >> >> -- >> M >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/5bbe49d5/attachment.html> From bussonniermatthias at gmail.com Thu Jul 3 11:30:58 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Thu, 3 Jul 2014 17:30:58 +0200 Subject: [IPython-dev] Examples of custom CSS for side-by-side (horizontal) output layout? In-Reply-To: <CAHAreOo98NPPrRDoL4uCXTrCGw1a8A6QhEGAMR=LPB8ONBcnPw@mail.gmail.com> References: <CAHAreOrbw_T11kox841UxJaJYEEtpbA6xKmCG9aJerBgvo_fFw@mail.gmail.com> <96E193F9-ACDA-48FC-86AE-68F0E76F83D8@gmail.com> <CAHAreOo98NPPrRDoL4uCXTrCGw1a8A6QhEGAMR=LPB8ONBcnPw@mail.gmail.com> Message-ID: <2C6BE958-CB9A-43A5-B8ED-018150905810@gmail.com> Le 3 juil. 2014 ? 15:13, Fernando Perez a ?crit : > Merci beaucoup ! > Je t'en prie. Toujours heureux de trouver une occasion de ne pas faire ma dissertation. ? tout ? l'heure sur Google Hangout pour la r?union hebdomadaire de d?veloppement. -- M (You're welcome. Alway happy to find a reason not to write my PhD. See you for the dev meeting on Google Hangout in a few hours) -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/4176fee8/attachment.html> From fperez.net at gmail.com Thu Jul 3 12:57:07 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Thu, 3 Jul 2014 09:57:07 -0700 Subject: [IPython-dev] Examples of custom CSS for side-by-side (horizontal) output layout? In-Reply-To: <2C6BE958-CB9A-43A5-B8ED-018150905810@gmail.com> References: <CAHAreOrbw_T11kox841UxJaJYEEtpbA6xKmCG9aJerBgvo_fFw@mail.gmail.com> <96E193F9-ACDA-48FC-86AE-68F0E76F83D8@gmail.com> <CAHAreOo98NPPrRDoL4uCXTrCGw1a8A6QhEGAMR=LPB8ONBcnPw@mail.gmail.com> <2C6BE958-CB9A-43A5-B8ED-018150905810@gmail.com> Message-ID: <CAHAreOqQNK0Lpo1rCExC30yKHe6inJFSAZ2V2YjSVk2_xrVJcg@mail.gmail.com> La tradition continue... :) 2014-07-03 8:30 GMT-07:00 Matthias Bussonnier <bussonniermatthias at gmail.com> : > > Le 3 juil. 2014 ? 15:13, Fernando Perez a ?crit : > > Merci beaucoup ! > > Je t'en prie. > > Toujours heureux de trouver une occasion de ne pas faire ma dissertation. > > ? tout ? l'heure sur Google Hangout pour la r?union hebdomadaire de > d?veloppement. > -- > M > > > (You're welcome. > Alway happy to find a reason not to write my PhD. > See you for the dev meeting on Google Hangout in a few hours) > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/108c04e7/attachment.html> From doug.blank at gmail.com Thu Jul 3 13:59:45 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 3 Jul 2014 13:59:45 -0400 Subject: [IPython-dev] Format of RadioButtonsWidget description and options Message-ID: <CAAusYCgvdWEzdniRonr5kvmrzO22+AkeKfzsUgxsFBX=q-=y0A@mail.gmail.com> Devs, We are working on creating a MultipleChoiceWidget, and wondering if there are options for positioning, or using HTML in, say, the description. For example, if you run the following in a Notebook: ```python from IPython.html.widgets import (RadioButtonsWidget, ContainerWidget, ButtonWidget) from IPython.display import (display, clear_output) answers = ["a) apple", "b) banana", "c) cherry"] choices = RadioButtonsWidget(description="Q1: What is the best fruit?", values=answers) button = ButtonWidget(description="Check Me") container = ContainerWidget(children =[choices, button]) def on_click(button): clear_output() if answers.index(choices.value_name) == 1: print("Correct!! The best fruit is the banana") else: print("Incorrect. Try running the above code to see the best fruit.") button.on_click(on_click) container ``` (see attached for image of output) The description ("Q1: What is the best fruit?") appears to the left of the radio buttons. Is there a way to get it to display above the radio buttons? Is there a way to force a newline after the question? Also, is there a way to use markup in the radio options? Perhaps there is a need for a LabelWidget (as opposed to TextWidget for entry) to do the question? Any suggestions welcomed to make this work/act better. -Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/591c0201/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot from 2014-07-03 13:46:44.png Type: image/png Size: 52599 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/591c0201/attachment.png> From Kevin.D.Winters at erdc.dren.mil Thu Jul 3 14:39:31 2014 From: Kevin.D.Winters at erdc.dren.mil (Winters, Kevin D ERDC-RDE-CHL-MS) Date: Thu, 3 Jul 2014 18:39:31 +0000 Subject: [IPython-dev] Format of RadioButtonsWidget description and options Message-ID: <00FB624E-6921-4657-B0FE-BE9B726B042B@erdc.dren.mil> I?ve made compilations of widgets to achieve my goals of proper layout (usually wrapped in a class). Typically this means relying on the LatexWidget to act as labels for other widgets. I?ve made some alterations to your example to showcase my formatting method. The key issue with formatting to remember is that the css must be applied after the widget is displayed. When wrapped in a class, I?ve used the main widget compilation container?s on_displayed handler to guarantee that the formatting is applied correctly. ???python from IPython.html.widgets import (RadioButtonsWidget, ContainerWidget, ButtonWidget, LatexWidget) from IPython.display import (display, clear_output) answers = ["a) apple", "b) banana", "c) cherry"] question = LatexWidget(value="Q1: What is the best fruit?") choices = RadioButtonsWidget(description="", values=answers) button = ButtonWidget(description="Check Me") response = LatexWidget(value="") check = ContainerWidget(children=[button, response]) container = ContainerWidget(children=[question, choices, check]) def on_click(button): clear_output() if answers.index(choices.value_name) == 1: response.value = "Correct!! The best fruit is the banana" else: response.value = "Incorrect. Try running the above code to see the best fruit." button.on_click(on_click) display(container) choices.set_css({'padding-left':'30px'}) response.set_css({'padding-left':'10px'}) check.remove_class('vbox') check.add_class('hbox') check.set_css({'align-items':'center?}) ?'' Kevin -------------------- Kevin Winters Research Hydraulic Engineer US Army Corps of Engineers Engineer Research and Development Center 3909 Halls Ferry Road Vicksburg, MS 39180 601.634.2102 From doug.blank at gmail.com Thu Jul 3 14:47:39 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 3 Jul 2014 14:47:39 -0400 Subject: [IPython-dev] Format of RadioButtonsWidget description and options In-Reply-To: <00FB624E-6921-4657-B0FE-BE9B726B042B@erdc.dren.mil> References: <00FB624E-6921-4657-B0FE-BE9B726B042B@erdc.dren.mil> Message-ID: <CAAusYCg4hw=Ye83wrsSGdoX34xGfeL4BWwXd_pZ1VUjuww_xKg@mail.gmail.com> Kevin, thanks! I like both of these ideas (using Latex for the question, and using CSS to position). -Doug On Thu, Jul 3, 2014 at 2:39 PM, Winters, Kevin D ERDC-RDE-CHL-MS < Kevin.D.Winters at erdc.dren.mil> wrote: > I?ve made compilations of widgets to achieve my goals of proper layout > (usually wrapped in a class). Typically this means relying on the > LatexWidget to act as labels for other widgets. I?ve made some alterations > to your example to showcase my formatting method. The key issue with > formatting to remember is that the css must be applied after the widget is > displayed. When wrapped in a class, I?ve used the main widget compilation > container?s on_displayed handler to guarantee that the formatting is > applied correctly. > > ???python > > from IPython.html.widgets import (RadioButtonsWidget, ContainerWidget, > ButtonWidget, LatexWidget) > from IPython.display import (display, clear_output) > answers = ["a) apple", "b) banana", "c) cherry"] > question = LatexWidget(value="Q1: What is the best fruit?") > choices = RadioButtonsWidget(description="", values=answers) > button = ButtonWidget(description="Check Me") > response = LatexWidget(value="") > check = ContainerWidget(children=[button, response]) > container = ContainerWidget(children=[question, choices, check]) > > def on_click(button): > clear_output() > if answers.index(choices.value_name) == 1: > response.value = "Correct!! The best fruit is the banana" > else: > response.value = "Incorrect. Try running the above code to see the > best fruit." > > button.on_click(on_click) > display(container) > > choices.set_css({'padding-left':'30px'}) > response.set_css({'padding-left':'10px'}) > check.remove_class('vbox') > check.add_class('hbox') > check.set_css({'align-items':'center?}) > ?'' > > Kevin > > -------------------- > Kevin Winters > Research Hydraulic Engineer > US Army Corps of Engineers > Engineer Research and Development Center > 3909 Halls Ferry Road > Vicksburg, MS 39180 > 601.634.2102 > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/faec7548/attachment.html> From cordial.emily at gmail.com Thu Jul 3 20:15:41 2014 From: cordial.emily at gmail.com (Emily Schleiner) Date: Thu, 3 Jul 2014 17:15:41 -0700 Subject: [IPython-dev] website In-Reply-To: <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> Message-ID: <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> For anyone curious to see the changes I made, here is my branch on github: https://github.com/cordial-emily/ipython-website On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner <cordial.emily at gmail.com> wrote: > Hi Thomas, > > I've already added some responsiveness to the theme you already use -- and > in the mean time before you have a complete change this might be helpful to > you. I'll just finish up the last couple of adjustments and call it good. > > Thanks for letting me know! > > Emily > > > > > On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver <takowl at gmail.com> wrote: > >> Hi Emily, >> >> Thanks, I'm flattered that you remembered our conversation. We're >> actually just working out the details of hiring a designer, someone who was >> already known to one of the core team. It will probably be a while before >> we have anything concrete to show from that, but I don't want you to spend >> a lot of time redesigning our website if we end up replacing it with a >> completely new site within a year. I'll discuss with the rest of the core >> team what's happening with the website, but don't get too far into changing >> it just yet. >> >> One possibility is that we could point you to another open source project >> that's interested in this kind of work. Next week we're at SciPy, a >> conference where the people behind lots of scientific Python projects get >> together, so we can ask people there about that. >> >> Best wishes, >> Thomas >> >> >> On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> wrote: >> >>> Dear IPython developers, >>> >>> A couple of months ago I spoke with Thomas at an Openhatch event about >>> the IPython website and it sounds like some design work might be welcome. >>> (?) I've been lurking on your lists to get to know the group some and have >>> now forked the site on Github with the aim of making it responsive. So far >>> I don't plan on revamping the basic shape or colors, but I'm interested to >>> hear any design preferences from the community... >>> >>> Best wishes, >>> Emily >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > -- __________________________________ Emily Schleiner cordial-emily.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/31b8062c/attachment.html> From takowl at gmail.com Thu Jul 3 20:18:56 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 3 Jul 2014 17:18:56 -0700 Subject: [IPython-dev] website In-Reply-To: <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> Message-ID: <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> Thanks Emily. Can we ask you to post a built version of the website somewhere, so that it's easy to look at without cloning the repository and building the site? https://pages.github.com/ is probably the easiest way to do it. Thomas On 3 July 2014 17:15, Emily Schleiner <cordial.emily at gmail.com> wrote: > For anyone curious to see the changes I made, here is my branch on github: > https://github.com/cordial-emily/ipython-website > > > On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner <cordial.emily at gmail.com> > wrote: > >> Hi Thomas, >> >> I've already added some responsiveness to the theme you already use -- >> and in the mean time before you have a complete change this might be >> helpful to you. I'll just finish up the last couple of adjustments and call >> it good. >> >> Thanks for letting me know! >> >> Emily >> >> >> >> >> On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver <takowl at gmail.com> wrote: >> >>> Hi Emily, >>> >>> Thanks, I'm flattered that you remembered our conversation. We're >>> actually just working out the details of hiring a designer, someone who was >>> already known to one of the core team. It will probably be a while before >>> we have anything concrete to show from that, but I don't want you to spend >>> a lot of time redesigning our website if we end up replacing it with a >>> completely new site within a year. I'll discuss with the rest of the core >>> team what's happening with the website, but don't get too far into changing >>> it just yet. >>> >>> One possibility is that we could point you to another open source >>> project that's interested in this kind of work. Next week we're at SciPy, a >>> conference where the people behind lots of scientific Python projects get >>> together, so we can ask people there about that. >>> >>> Best wishes, >>> Thomas >>> >>> >>> On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> wrote: >>> >>>> Dear IPython developers, >>>> >>>> A couple of months ago I spoke with Thomas at an Openhatch event about >>>> the IPython website and it sounds like some design work might be welcome. >>>> (?) I've been lurking on your lists to get to know the group some and have >>>> now forked the site on Github with the aim of making it responsive. So far >>>> I don't plan on revamping the basic shape or colors, but I'm interested to >>>> hear any design preferences from the community... >>>> >>>> Best wishes, >>>> Emily >>>> >>>> -- >>>> __________________________________ >>>> Emily Schleiner >>>> cordial-emily.com >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com >> > > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/0c431922/attachment.html> From cordial.emily at gmail.com Thu Jul 3 23:42:17 2014 From: cordial.emily at gmail.com (Emily Schleiner) Date: Thu, 3 Jul 2014 20:42:17 -0700 Subject: [IPython-dev] website In-Reply-To: <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> Message-ID: <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> Here you go: http://cordial-emily.github.io/ -Emily On Thu, Jul 3, 2014 at 5:18 PM, Thomas Kluyver <takowl at gmail.com> wrote: > Thanks Emily. Can we ask you to post a built version of the website > somewhere, so that it's easy to look at without cloning the repository and > building the site? https://pages.github.com/ is probably the easiest way > to do it. > > Thomas > > > On 3 July 2014 17:15, Emily Schleiner <cordial.emily at gmail.com> wrote: > >> For anyone curious to see the changes I made, here is my branch on github: >> https://github.com/cordial-emily/ipython-website >> >> >> On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner <cordial.emily at gmail.com >> > wrote: >> >>> Hi Thomas, >>> >>> I've already added some responsiveness to the theme you already use -- >>> and in the mean time before you have a complete change this might be >>> helpful to you. I'll just finish up the last couple of adjustments and call >>> it good. >>> >>> Thanks for letting me know! >>> >>> Emily >>> >>> >>> >>> >>> On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver <takowl at gmail.com> >>> wrote: >>> >>>> Hi Emily, >>>> >>>> Thanks, I'm flattered that you remembered our conversation. We're >>>> actually just working out the details of hiring a designer, someone who was >>>> already known to one of the core team. It will probably be a while before >>>> we have anything concrete to show from that, but I don't want you to spend >>>> a lot of time redesigning our website if we end up replacing it with a >>>> completely new site within a year. I'll discuss with the rest of the core >>>> team what's happening with the website, but don't get too far into changing >>>> it just yet. >>>> >>>> One possibility is that we could point you to another open source >>>> project that's interested in this kind of work. Next week we're at SciPy, a >>>> conference where the people behind lots of scientific Python projects get >>>> together, so we can ask people there about that. >>>> >>>> Best wishes, >>>> Thomas >>>> >>>> >>>> On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> wrote: >>>> >>>>> Dear IPython developers, >>>>> >>>>> A couple of months ago I spoke with Thomas at an Openhatch event about >>>>> the IPython website and it sounds like some design work might be welcome. >>>>> (?) I've been lurking on your lists to get to know the group some and have >>>>> now forked the site on Github with the aim of making it responsive. So far >>>>> I don't plan on revamping the basic shape or colors, but I'm interested to >>>>> hear any design preferences from the community... >>>>> >>>>> Best wishes, >>>>> Emily >>>>> >>>>> -- >>>>> __________________________________ >>>>> Emily Schleiner >>>>> cordial-emily.com >>>>> >>>>> _______________________________________________ >>>>> IPython-dev mailing list >>>>> IPython-dev at scipy.org >>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>> >>>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com >>> >> >> >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- __________________________________ Emily Schleiner cordial-emily.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140703/14ab43d8/attachment.html> From aron at ahmadia.net Fri Jul 4 00:17:46 2014 From: aron at ahmadia.net (Aron Ahmadia) Date: Fri, 4 Jul 2014 00:17:46 -0400 Subject: [IPython-dev] website In-Reply-To: <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> Message-ID: <CAPhiW4iMzoUWgymBkFTfYVS2s0+xTBdeQgNR8Uvdq_GO0BRw1Q@mail.gmail.com> Hi Emily This is really nice work. I am not one of the core developers, but I have opinions anyway :) A couple of thoughts/questions: * Probably should be IPython Website in the title * The "Interactive Computing" is a little fuzzy on my Retina display * I really like the font * How do people feel about the content stretching out to the full page width? I have mixed feelings about this. Cheers, Aron On Thu, Jul 3, 2014 at 11:42 PM, Emily Schleiner <cordial.emily at gmail.com> wrote: > Here you go: > http://cordial-emily.github.io/ > > -Emily > > > On Thu, Jul 3, 2014 at 5:18 PM, Thomas Kluyver <takowl at gmail.com> wrote: > >> Thanks Emily. Can we ask you to post a built version of the website >> somewhere, so that it's easy to look at without cloning the repository and >> building the site? https://pages.github.com/ is probably the easiest way >> to do it. >> >> Thomas >> >> >> On 3 July 2014 17:15, Emily Schleiner <cordial.emily at gmail.com> wrote: >> >>> For anyone curious to see the changes I made, here is my branch on >>> github: >>> https://github.com/cordial-emily/ipython-website >>> >>> >>> On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner < >>> cordial.emily at gmail.com> wrote: >>> >>>> Hi Thomas, >>>> >>>> I've already added some responsiveness to the theme you already use -- >>>> and in the mean time before you have a complete change this might be >>>> helpful to you. I'll just finish up the last couple of adjustments and call >>>> it good. >>>> >>>> Thanks for letting me know! >>>> >>>> Emily >>>> >>>> >>>> >>>> >>>> On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver <takowl at gmail.com> >>>> wrote: >>>> >>>>> Hi Emily, >>>>> >>>>> Thanks, I'm flattered that you remembered our conversation. We're >>>>> actually just working out the details of hiring a designer, someone who was >>>>> already known to one of the core team. It will probably be a while before >>>>> we have anything concrete to show from that, but I don't want you to spend >>>>> a lot of time redesigning our website if we end up replacing it with a >>>>> completely new site within a year. I'll discuss with the rest of the core >>>>> team what's happening with the website, but don't get too far into changing >>>>> it just yet. >>>>> >>>>> One possibility is that we could point you to another open source >>>>> project that's interested in this kind of work. Next week we're at SciPy, a >>>>> conference where the people behind lots of scientific Python projects get >>>>> together, so we can ask people there about that. >>>>> >>>>> Best wishes, >>>>> Thomas >>>>> >>>>> >>>>> On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> wrote: >>>>> >>>>>> Dear IPython developers, >>>>>> >>>>>> A couple of months ago I spoke with Thomas at an Openhatch event >>>>>> about the IPython website and it sounds like some design work might be >>>>>> welcome. (?) I've been lurking on your lists to get to know the group some >>>>>> and have now forked the site on Github with the aim of making it >>>>>> responsive. So far I don't plan on revamping the basic shape or colors, but >>>>>> I'm interested to hear any design preferences from the community... >>>>>> >>>>>> Best wishes, >>>>>> Emily >>>>>> >>>>>> -- >>>>>> __________________________________ >>>>>> Emily Schleiner >>>>>> cordial-emily.com >>>>>> >>>>>> _______________________________________________ >>>>>> IPython-dev mailing list >>>>>> IPython-dev at scipy.org >>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>> >>>>>> >>>>> >>>>> _______________________________________________ >>>>> IPython-dev mailing list >>>>> IPython-dev at scipy.org >>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>> >>>>> >>>> >>>> >>>> -- >>>> __________________________________ >>>> Emily Schleiner >>>> cordial-emily.com >>>> >>> >>> >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/e28155a4/attachment.html> From doug.blank at gmail.com Fri Jul 4 08:32:28 2014 From: doug.blank at gmail.com (Doug Blank) Date: Fri, 4 Jul 2014 08:32:28 -0400 Subject: [IPython-dev] Examples of custom CSS for side-by-side (horizontal) output layout? In-Reply-To: <96E193F9-ACDA-48FC-86AE-68F0E76F83D8@gmail.com> References: <CAHAreOrbw_T11kox841UxJaJYEEtpbA6xKmCG9aJerBgvo_fFw@mail.gmail.com> <96E193F9-ACDA-48FC-86AE-68F0E76F83D8@gmail.com> Message-ID: <CAAusYChKps5K_W4dYaKfHuUbrU0x6MuL3TCk2U9Nj9SR6vLxBw@mail.gmail.com> On Thu, Jul 3, 2014 at 2:50 AM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 3 juil. 2014 ? 04:52, Fernando Perez a ?crit : > > Hi folks, > > I know in the past people have mentioned having customized their notebook > layouts to display output next to the input cells instead of below them. > > Does anyone have an example handy of this, so I can refer a colleague to > it? > > > > %%html > <style> > div.cell{ > box-orient:horizontal; > flex-direction:row; > } > > div.cell *{ > width:100%; > } > > div.prompt{ > width:80px; > > } > </style> > BTW, I find that I can go back and forth between horizontal and vertical styles sequentially in a notebook using this technique, as long as the HTML is entered into new cells. If I go back to a previously executed cell and attempt to re-run the HTML, then the notebook gets confused, and I need to create a new cell (or close and re-open the notebook). This is on Chromium 34.0.1847.116 on Ubuntu. -Doug > > CF : https://twitter.com/Mbussonn/status/474189448452665344 > > -- > M > > > Thanks! > > f > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/f6900847/attachment.html> From bussonniermatthias at gmail.com Fri Jul 4 09:03:41 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Fri, 4 Jul 2014 15:03:41 +0200 Subject: [IPython-dev] Examples of custom CSS for side-by-side (horizontal) output layout? In-Reply-To: <CAAusYChKps5K_W4dYaKfHuUbrU0x6MuL3TCk2U9Nj9SR6vLxBw@mail.gmail.com> References: <CAHAreOrbw_T11kox841UxJaJYEEtpbA6xKmCG9aJerBgvo_fFw@mail.gmail.com> <96E193F9-ACDA-48FC-86AE-68F0E76F83D8@gmail.com> <CAAusYChKps5K_W4dYaKfHuUbrU0x6MuL3TCk2U9Nj9SR6vLxBw@mail.gmail.com> Message-ID: <AC090BBC-83E5-480B-921F-849E921E63A9@gmail.com> Including css with %html follow normal css rules. Last in the dom take precedence (assuming same target specificity) what you see is not astonishing, and is one of the reason style should not be applied by displaying things in cells. -- M Envoy? de mon iPhone > Le 4 juil. 2014 ? 14:32, Doug Blank <doug.blank at gmail.com> a ?crit : > >> On Thu, Jul 3, 2014 at 2:50 AM, Matthias Bussonnier <bussonniermatthias at gmail.com> wrote: >> >>> Le 3 juil. 2014 ? 04:52, Fernando Perez a ?crit : >>> >>> Hi folks, >>> >>> I know in the past people have mentioned having customized their notebook layouts to display output next to the input cells instead of below them. >>> >>> Does anyone have an example handy of this, so I can refer a colleague to it? >> >> >> %%html >> <style> >> div.cell{ >> box-orient:horizontal; >> flex-direction:row; >> } >> >> div.cell *{ >> width:100%; >> } >> >> div.prompt{ >> width:80px; >> >> } >> </style> > > BTW, I find that I can go back and forth between horizontal and vertical styles sequentially in a notebook using this technique, as long as the HTML is entered into new cells. If I go back to a previously executed cell and attempt to re-run the HTML, then the notebook gets confused, and I need to create a new cell (or close and re-open the notebook). This is on Chromium 34.0.1847.116 on Ubuntu. > > -Doug > >> >> CF : https://twitter.com/Mbussonn/status/474189448452665344 >> >> -- >> M >>> >>> Thanks! >>> >>> f >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/2284c2bc/attachment.html> From jsw at fnal.gov Fri Jul 4 14:27:19 2014 From: jsw at fnal.gov (Jon Wilson) Date: Fri, 4 Jul 2014 13:27:19 -0500 Subject: [IPython-dev] website In-Reply-To: <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> Message-ID: <53B6F207.5080709@fnal.gov> Hi Emily, This is quite nice stuff. I'm glad that someone is making the effort to make a responsive page without overdesigning things. Far too many pages are very difficult to read on mobile devices. In my browser (Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:30.0) Gecko/20100101 Firefox/30.0), the text appears in a very light gray that is quite difficult to read against the white background. I don't know quite why this is. On my phone (Mozilla/5.0 (Android; Mobile; rv:30.0) Gecko/30.0 Firefox/30.0), the column widths are a bit rough -- the text in the left column is quite narrow, and one piece of the right column overruns the column width and causes horizontal scrolling. There is also a long vertical gap in the left column before reaching the end of the two-column section. Overall, I got the initial feeling that the two-column stuff was all unimportant gunk (not true, of course) that I had to scroll past to get to the real content. I think maybe the sidebar material could be moved to the end of the page? This is only commentary on the front page. I haven't yet taken a look at other pages. Regards, Jon On 07/03/2014 10:42 PM, Emily Schleiner wrote: > Here you go: > http://cordial-emily.github.io/ > > -Emily > > > On Thu, Jul 3, 2014 at 5:18 PM, Thomas Kluyver <takowl at gmail.com > <mailto:takowl at gmail.com>> wrote: > > Thanks Emily. Can we ask you to post a built version of the > website somewhere, so that it's easy to look at without cloning > the repository and building the site? https://pages.github.com/ is > probably the easiest way to do it. > > Thomas > > > On 3 July 2014 17:15, Emily Schleiner <cordial.emily at gmail.com > <mailto:cordial.emily at gmail.com>> wrote: > > For anyone curious to see the changes I made, here is my > branch on github: > https://github.com/cordial-emily/ipython-website > > > On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner > <cordial.emily at gmail.com <mailto:cordial.emily at gmail.com>> wrote: > > Hi Thomas, > > I've already added some responsiveness to the theme you > already use -- and in the mean time before you have a > complete change this might be helpful to you. I'll just > finish up the last couple of adjustments and call it good. > > Thanks for letting me know! > > Emily > > > > > On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver > <takowl at gmail.com <mailto:takowl at gmail.com>> wrote: > > Hi Emily, > > Thanks, I'm flattered that you remembered our > conversation. We're actually just working out the > details of hiring a designer, someone who was already > known to one of the core team. It will probably be a > while before we have anything concrete to show from > that, but I don't want you to spend a lot of time > redesigning our website if we end up replacing it with > a completely new site within a year. I'll discuss with > the rest of the core team what's happening with the > website, but don't get too far into changing it just yet. > > One possibility is that we could point you to another > open source project that's interested in this kind of > work. Next week we're at SciPy, a conference where the > people behind lots of scientific Python projects get > together, so we can ask people there about that. > > Best wishes, > Thomas > > > On 1 July 2014 15:23, Emily Schleiner > <cordial.emily at gmail.com > <mailto:cordial.emily at gmail.com>> wrote: > > Dear IPython developers, > > A couple of months ago I spoke with Thomas at an > Openhatch event about the IPython website and it > sounds like some design work might be welcome. (?) > I've been lurking on your lists to get to know > the group some and have now forked the site on > Github with the aim of making it responsive. So > far I don't plan on revamping the basic shape or > colors, but I'm interested to hear any design > preferences from the community... > > Best wishes, > Emily > > -- > __________________________________ > Emily Schleiner > cordial-emily.com <http://cordial-emily.com> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com <http://cordial-emily.com> > > > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com <http://cordial-emily.com> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com <http://cordial-emily.com> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/68f94f48/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot_2014-07-04-13-20-04.png Type: image/png Size: 195330 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/68f94f48/attachment.png> -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot from 2014-07-04 13:17:33.png Type: image/png Size: 334072 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/68f94f48/attachment-0001.png> From cordial.emily at gmail.com Fri Jul 4 15:51:19 2014 From: cordial.emily at gmail.com (Emily Schleiner) Date: Fri, 4 Jul 2014 12:51:19 -0700 Subject: [IPython-dev] website In-Reply-To: <53B6F207.5080709@fnal.gov> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> <53B6F207.5080709@fnal.gov> Message-ID: <CABWt4EgGDkcDENOkc148cVKsFYJjqWpnO7WPJ4G+urYU-zGhsQ@mail.gmail.com> Hi Aaron and Jon, Thanks for the feedback -- hearing about the look of the site on multiple devices is especially helpful. :) Let's see.. the gap in scrolling (preceding images) is something I should be able to fix. For the large screen size (1400 or more pixels wide) I'll limit the size of the logo so it doesn't look too pixelated and increase the margins some. The gray text on the mobile size sounds like an anomaly based on the devices I've seen so far, but I can increase the font weight for small devices Fyi, ideally I would like to redesign the whole structure with bootstrap etc but it sounds like it might not be worthwhile if the site is going to revamped soon anyway... These adjustments just make it possible to see all the content (as it stands) on phones. Thanks all! Emily On Fri, Jul 4, 2014 at 11:27 AM, Jon Wilson <jsw at fnal.gov> wrote: > Hi Emily, > This is quite nice stuff. I'm glad that someone is making the effort to > make a responsive page without overdesigning things. Far too many pages > are very difficult to read on mobile devices. > > In my browser (Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:30.0) > Gecko/20100101 Firefox/30.0), the text appears in a very light gray that is > quite difficult to read against the white background. I don't know quite > why this is. > > On my phone (Mozilla/5.0 (Android; Mobile; rv:30.0) Gecko/30.0 > Firefox/30.0), the column widths are a bit rough -- the text in the left > column is quite narrow, and one piece of the right column overruns the > column width and causes horizontal scrolling. There is also a long > vertical gap in the left column before reaching the end of the two-column > section. Overall, I got the initial feeling that the two-column stuff was > all unimportant gunk (not true, of course) that I had to scroll past to get > to the real content. I think maybe the sidebar material could be moved to > the end of the page? > > This is only commentary on the front page. I haven't yet taken a look at > other pages. > Regards, > Jon > > > On 07/03/2014 10:42 PM, Emily Schleiner wrote: > > Here you go: > http://cordial-emily.github.io/ > > -Emily > > > On Thu, Jul 3, 2014 at 5:18 PM, Thomas Kluyver <takowl at gmail.com> wrote: > >> Thanks Emily. Can we ask you to post a built version of the website >> somewhere, so that it's easy to look at without cloning the repository and >> building the site? https://pages.github.com/ is probably the easiest way >> to do it. >> >> Thomas >> >> >> On 3 July 2014 17:15, Emily Schleiner <cordial.emily at gmail.com> wrote: >> >>> For anyone curious to see the changes I made, here is my branch on >>> github: >>> https://github.com/cordial-emily/ipython-website >>> >>> >>> On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner < >>> cordial.emily at gmail.com> wrote: >>> >>>> Hi Thomas, >>>> >>>> I've already added some responsiveness to the theme you already use >>>> -- and in the mean time before you have a complete change this might be >>>> helpful to you. I'll just finish up the last couple of adjustments and call >>>> it good. >>>> >>>> Thanks for letting me know! >>>> >>>> Emily >>>> >>>> >>>> >>>> >>>> On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver <takowl at gmail.com> >>>> wrote: >>>> >>>>> Hi Emily, >>>>> >>>>> Thanks, I'm flattered that you remembered our conversation. We're >>>>> actually just working out the details of hiring a designer, someone who was >>>>> already known to one of the core team. It will probably be a while before >>>>> we have anything concrete to show from that, but I don't want you to spend >>>>> a lot of time redesigning our website if we end up replacing it with a >>>>> completely new site within a year. I'll discuss with the rest of the core >>>>> team what's happening with the website, but don't get too far into changing >>>>> it just yet. >>>>> >>>>> One possibility is that we could point you to another open source >>>>> project that's interested in this kind of work. Next week we're at SciPy, a >>>>> conference where the people behind lots of scientific Python projects get >>>>> together, so we can ask people there about that. >>>>> >>>>> Best wishes, >>>>> Thomas >>>>> >>>>> >>>>> On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> >>>>> wrote: >>>>> >>>>>> Dear IPython developers, >>>>>> >>>>>> A couple of months ago I spoke with Thomas at an Openhatch event >>>>>> about the IPython website and it sounds like some design work might be >>>>>> welcome. (?) I've been lurking on your lists to get to know the group some >>>>>> and have now forked the site on Github with the aim of making it >>>>>> responsive. So far I don't plan on revamping the basic shape or colors, but >>>>>> I'm interested to hear any design preferences from the community... >>>>>> >>>>>> Best wishes, >>>>>> Emily >>>>>> >>>>>> -- >>>>>> __________________________________ >>>>>> Emily Schleiner >>>>>> cordial-emily.com >>>>>> >>>>>> _______________________________________________ >>>>>> IPython-dev mailing list >>>>>> IPython-dev at scipy.org >>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>> >>>>>> >>>>> >>>>> _______________________________________________ >>>>> IPython-dev mailing list >>>>> IPython-dev at scipy.org >>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>> >>>>> >>>> >>>> >>>> -- >>>> __________________________________ >>>> Emily Schleiner >>>> cordial-emily.com >>>> >>> >>> >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > > > _______________________________________________ > IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- __________________________________ Emily Schleiner cordial-emily.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/ca9d62d9/attachment.html> From jsw at fnal.gov Fri Jul 4 16:13:47 2014 From: jsw at fnal.gov (Jon Wilson) Date: Fri, 4 Jul 2014 15:13:47 -0500 Subject: [IPython-dev] website In-Reply-To: <CABWt4EgGDkcDENOkc148cVKsFYJjqWpnO7WPJ4G+urYU-zGhsQ@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> <53B6F207.5080709@fnal.gov> <CABWt4EgGDkcDENOkc148cVKsFYJjqWpnO7WPJ4G+urYU-zGhsQ@mail.gmail.com> Message-ID: <53B70AFB.8040907@fnal.gov> Hi Emily, The text is fine on my phone. The gray text issue occurs on my laptop (Ubuntu 14.04, Firefox 30). Sorry that I wasn't clear about that. And, since I just used the word "issue" above, it occurs to me that I should actually be using github's "issue" feature rather than emailing you about it. Regards, Jon On 07/04/2014 02:51 PM, Emily Schleiner wrote: > Hi Aaron and Jon, > > Thanks for the feedback -- hearing about the look of the site on > multiple devices is especially helpful. :) > > Let's see.. the gap in scrolling (preceding images) is something I > should be able to fix. For the large screen size (1400 or more pixels > wide) I'll limit the size of the logo so it doesn't look too pixelated > and increase the margins some. > > The gray text on the mobile size sounds like an anomaly based on the > devices I've seen so far, but I can increase the font weight for small > devices > > Fyi, ideally I would like to redesign the whole structure with > bootstrap etc but it sounds like it might not be worthwhile if the > site is going to revamped soon anyway... These adjustments just make > it possible to see all the content (as it stands) on phones. > > Thanks all! > Emily > > > > > > > > > On Fri, Jul 4, 2014 at 11:27 AM, Jon Wilson <jsw at fnal.gov > <mailto:jsw at fnal.gov>> wrote: > > Hi Emily, > This is quite nice stuff. I'm glad that someone is making the > effort to make a responsive page without overdesigning things. > Far too many pages are very difficult to read on mobile devices. > > In my browser (Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:30.0) > Gecko/20100101 Firefox/30.0), the text appears in a very light > gray that is quite difficult to read against the white > background. I don't know quite why this is. > > On my phone (Mozilla/5.0 (Android; Mobile; rv:30.0) Gecko/30.0 > Firefox/30.0), the column widths are a bit rough -- the text in > the left column is quite narrow, and one piece of the right column > overruns the column width and causes horizontal scrolling. There > is also a long vertical gap in the left column before reaching the > end of the two-column section. Overall, I got the initial feeling > that the two-column stuff was all unimportant gunk (not true, of > course) that I had to scroll past to get to the real content. I > think maybe the sidebar material could be moved to the end of the > page? > > This is only commentary on the front page. I haven't yet taken a > look at other pages. > Regards, > Jon > > > On 07/03/2014 10:42 PM, Emily Schleiner wrote: >> Here you go: >> http://cordial-emily.github.io/ >> >> -Emily >> >> >> On Thu, Jul 3, 2014 at 5:18 PM, Thomas Kluyver <takowl at gmail.com >> <mailto:takowl at gmail.com>> wrote: >> >> Thanks Emily. Can we ask you to post a built version of the >> website somewhere, so that it's easy to look at without >> cloning the repository and building the site? >> https://pages.github.com/ is probably the easiest way to do it. >> >> Thomas >> >> >> On 3 July 2014 17:15, Emily Schleiner >> <cordial.emily at gmail.com <mailto:cordial.emily at gmail.com>> wrote: >> >> For anyone curious to see the changes I made, here is my >> branch on github: >> https://github.com/cordial-emily/ipython-website >> >> >> On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner >> <cordial.emily at gmail.com >> <mailto:cordial.emily at gmail.com>> wrote: >> >> Hi Thomas, >> >> I've already added some responsiveness to the theme >> you already use -- and in the mean time before you >> have a complete change this might be helpful to you. >> I'll just finish up the last couple of adjustments >> and call it good. >> >> Thanks for letting me know! >> >> Emily >> >> >> >> >> On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver >> <takowl at gmail.com <mailto:takowl at gmail.com>> wrote: >> >> Hi Emily, >> >> Thanks, I'm flattered that you remembered our >> conversation. We're actually just working out the >> details of hiring a designer, someone who was >> already known to one of the core team. It will >> probably be a while before we have anything >> concrete to show from that, but I don't want you >> to spend a lot of time redesigning our website if >> we end up replacing it with a completely new site >> within a year. I'll discuss with the rest of the >> core team what's happening with the website, but >> don't get too far into changing it just yet. >> >> One possibility is that we could point you to >> another open source project that's interested in >> this kind of work. Next week we're at SciPy, a >> conference where the people behind lots of >> scientific Python projects get together, so we >> can ask people there about that. >> >> Best wishes, >> Thomas >> >> >> On 1 July 2014 15:23, Emily Schleiner >> <cordial.emily at gmail.com >> <mailto:cordial.emily at gmail.com>> wrote: >> >> Dear IPython developers, >> >> A couple of months ago I spoke with Thomas at >> an Openhatch event about the IPython website >> and it sounds like some design work might be >> welcome. (?) I've been lurking on your lists >> to get to know the group some and have now >> forked the site on Github with the aim of >> making it responsive. So far I don't plan on >> revamping the basic shape or colors, but I'm >> interested to hear any design preferences >> from the community... >> >> Best wishes, >> Emily >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com <http://cordial-emily.com> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> <mailto:IPython-dev at scipy.org> >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com <http://cordial-emily.com> >> >> >> >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com <http://cordial-emily.com> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com <http://cordial-emily.com> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com <http://cordial-emily.com> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/a23c899b/attachment.html> From jsw at fnal.gov Fri Jul 4 16:21:38 2014 From: jsw at fnal.gov (Jon Wilson) Date: Fri, 4 Jul 2014 15:21:38 -0500 Subject: [IPython-dev] website In-Reply-To: <53B70AFB.8040907@fnal.gov> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> <53B6F207.5080709@fnal.gov> <CABWt4EgGDkcDENOkc148cVKsFYJjqWpnO7WPJ4G+urYU-zGhsQ@mail.gmail.com> <53B70AFB.8040907@fnal.gov> Message-ID: <53B70CD2.5050603@fnal.gov> Hmm, it seems that I cannot open issues on your fork unless you specifically enable them: http://programmers.stackexchange.com/questions/179468/forking-a-repo-on-github-but-allowing-new-issues-on-the-fork Regards, Jon On 07/04/2014 03:13 PM, Jon Wilson wrote: > Hi Emily, > The text is fine on my phone. The gray text issue occurs on my laptop > (Ubuntu 14.04, Firefox 30). Sorry that I wasn't clear about that. > > And, since I just used the word "issue" above, it occurs to me that I > should actually be using github's "issue" feature rather than emailing > you about it. > Regards, > Jon > > On 07/04/2014 02:51 PM, Emily Schleiner wrote: >> Hi Aaron and Jon, >> >> Thanks for the feedback -- hearing about the look of the site on >> multiple devices is especially helpful. :) >> >> Let's see.. the gap in scrolling (preceding images) is something I >> should be able to fix. For the large screen size (1400 or more >> pixels wide) I'll limit the size of the logo so it doesn't look too >> pixelated and increase the margins some. >> >> The gray text on the mobile size sounds like an anomaly based on the >> devices I've seen so far, but I can increase the font weight for >> small devices >> >> Fyi, ideally I would like to redesign the whole structure with >> bootstrap etc but it sounds like it might not be worthwhile if the >> site is going to revamped soon anyway... These adjustments just make >> it possible to see all the content (as it stands) on phones. >> >> Thanks all! >> Emily >> >> >> >> >> >> >> >> >> On Fri, Jul 4, 2014 at 11:27 AM, Jon Wilson <jsw at fnal.gov >> <mailto:jsw at fnal.gov>> wrote: >> >> Hi Emily, >> This is quite nice stuff. I'm glad that someone is making the >> effort to make a responsive page without overdesigning things. >> Far too many pages are very difficult to read on mobile devices. >> >> In my browser (Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:30.0) >> Gecko/20100101 Firefox/30.0), the text appears in a very light >> gray that is quite difficult to read against the white >> background. I don't know quite why this is. >> >> On my phone (Mozilla/5.0 (Android; Mobile; rv:30.0) Gecko/30.0 >> Firefox/30.0), the column widths are a bit rough -- the text in >> the left column is quite narrow, and one piece of the right >> column overruns the column width and causes horizontal >> scrolling. There is also a long vertical gap in the left column >> before reaching the end of the two-column section. Overall, I >> got the initial feeling that the two-column stuff was all >> unimportant gunk (not true, of course) that I had to scroll past >> to get to the real content. I think maybe the sidebar material >> could be moved to the end of the page? >> >> This is only commentary on the front page. I haven't yet taken a >> look at other pages. >> Regards, >> Jon >> >> >> On 07/03/2014 10:42 PM, Emily Schleiner wrote: >>> Here you go: >>> http://cordial-emily.github.io/ >>> >>> -Emily >>> >>> >>> On Thu, Jul 3, 2014 at 5:18 PM, Thomas Kluyver <takowl at gmail.com >>> <mailto:takowl at gmail.com>> wrote: >>> >>> Thanks Emily. Can we ask you to post a built version of the >>> website somewhere, so that it's easy to look at without >>> cloning the repository and building the site? >>> https://pages.github.com/ is probably the easiest way to do it. >>> >>> Thomas >>> >>> >>> On 3 July 2014 17:15, Emily Schleiner >>> <cordial.emily at gmail.com <mailto:cordial.emily at gmail.com>> >>> wrote: >>> >>> For anyone curious to see the changes I made, here is my >>> branch on github: >>> https://github.com/cordial-emily/ipython-website >>> >>> >>> On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner >>> <cordial.emily at gmail.com >>> <mailto:cordial.emily at gmail.com>> wrote: >>> >>> Hi Thomas, >>> >>> I've already added some responsiveness to the theme >>> you already use -- and in the mean time before you >>> have a complete change this might be helpful to you. >>> I'll just finish up the last couple of adjustments >>> and call it good. >>> >>> Thanks for letting me know! >>> >>> Emily >>> >>> >>> >>> >>> On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver >>> <takowl at gmail.com <mailto:takowl at gmail.com>> wrote: >>> >>> Hi Emily, >>> >>> Thanks, I'm flattered that you remembered our >>> conversation. We're actually just working out >>> the details of hiring a designer, someone who >>> was already known to one of the core team. It >>> will probably be a while before we have anything >>> concrete to show from that, but I don't want you >>> to spend a lot of time redesigning our website >>> if we end up replacing it with a completely new >>> site within a year. I'll discuss with the rest >>> of the core team what's happening with the >>> website, but don't get too far into changing it >>> just yet. >>> >>> One possibility is that we could point you to >>> another open source project that's interested in >>> this kind of work. Next week we're at SciPy, a >>> conference where the people behind lots of >>> scientific Python projects get together, so we >>> can ask people there about that. >>> >>> Best wishes, >>> Thomas >>> >>> >>> On 1 July 2014 15:23, Emily Schleiner >>> <cordial.emily at gmail.com >>> <mailto:cordial.emily at gmail.com>> wrote: >>> >>> Dear IPython developers, >>> >>> A couple of months ago I spoke with Thomas >>> at an Openhatch event about the IPython >>> website and it sounds like some design work >>> might be welcome. (?) I've been lurking on >>> your lists to get to know the group some and >>> have now forked the site on Github with the >>> aim of making it responsive. So far I don't >>> plan on revamping the basic shape or colors, >>> but I'm interested to hear any design >>> preferences from the community... >>> >>> Best wishes, >>> Emily >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com <http://cordial-emily.com> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> <mailto:IPython-dev at scipy.org> >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com <http://cordial-emily.com> >>> >>> >>> >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com <http://cordial-emily.com> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com <http://cordial-emily.com> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com <http://cordial-emily.com> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/5f157161/attachment.html> From cordial.emily at gmail.com Fri Jul 4 17:24:45 2014 From: cordial.emily at gmail.com (Emily Schleiner) Date: Fri, 4 Jul 2014 14:24:45 -0700 Subject: [IPython-dev] website In-Reply-To: <53B70CD2.5050603@fnal.gov> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> <53B6F207.5080709@fnal.gov> <CABWt4EgGDkcDENOkc148cVKsFYJjqWpnO7WPJ4G+urYU-zGhsQ@mail.gmail.com> <53B70AFB.8040907@fnal.gov> <53B70CD2.5050603@fnal.gov> Message-ID: <CABWt4EjhzLLocqD_ZbvA3n+L+Qjvmr9JpPBMP1kGtzHcszq3LQ@mail.gmail.com> Done, you can add the issue here: https://github.com/cordial-emily/cordial-emily.github.io/issues Thanks, Emily On Fri, Jul 4, 2014 at 1:21 PM, Jon Wilson <jsw at fnal.gov> wrote: > Hmm, it seems that I cannot open issues on your fork unless you > specifically enable them: > > http://programmers.stackexchange.com/questions/179468/forking-a-repo-on-github-but-allowing-new-issues-on-the-fork > > Regards, > Jon > > > On 07/04/2014 03:13 PM, Jon Wilson wrote: > > Hi Emily, > The text is fine on my phone. The gray text issue occurs on my laptop > (Ubuntu 14.04, Firefox 30). Sorry that I wasn't clear about that. > > And, since I just used the word "issue" above, it occurs to me that I > should actually be using github's "issue" feature rather than emailing you > about it. > Regards, > Jon > > On 07/04/2014 02:51 PM, Emily Schleiner wrote: > > Hi Aaron and Jon, > > Thanks for the feedback -- hearing about the look of the site on > multiple devices is especially helpful. :) > > Let's see.. the gap in scrolling (preceding images) is something I > should be able to fix. For the large screen size (1400 or more pixels > wide) I'll limit the size of the logo so it doesn't look too pixelated and > increase the margins some. > > The gray text on the mobile size sounds like an anomaly based on the > devices I've seen so far, but I can increase the font weight for small > devices > > Fyi, ideally I would like to redesign the whole structure with bootstrap > etc but it sounds like it might not be worthwhile if the site is going to > revamped soon anyway... These adjustments just make it possible to see all > the content (as it stands) on phones. > > Thanks all! > Emily > > > > > > > > > On Fri, Jul 4, 2014 at 11:27 AM, Jon Wilson <jsw at fnal.gov> wrote: > >> Hi Emily, >> This is quite nice stuff. I'm glad that someone is making the effort to >> make a responsive page without overdesigning things. Far too many pages >> are very difficult to read on mobile devices. >> >> In my browser (Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:30.0) >> Gecko/20100101 Firefox/30.0), the text appears in a very light gray that is >> quite difficult to read against the white background. I don't know quite >> why this is. >> >> On my phone (Mozilla/5.0 (Android; Mobile; rv:30.0) Gecko/30.0 >> Firefox/30.0), the column widths are a bit rough -- the text in the left >> column is quite narrow, and one piece of the right column overruns the >> column width and causes horizontal scrolling. There is also a long >> vertical gap in the left column before reaching the end of the two-column >> section. Overall, I got the initial feeling that the two-column stuff was >> all unimportant gunk (not true, of course) that I had to scroll past to get >> to the real content. I think maybe the sidebar material could be moved to >> the end of the page? >> >> This is only commentary on the front page. I haven't yet taken a look at >> other pages. >> Regards, >> Jon >> >> >> On 07/03/2014 10:42 PM, Emily Schleiner wrote: >> >> Here you go: >> http://cordial-emily.github.io/ >> >> -Emily >> >> >> On Thu, Jul 3, 2014 at 5:18 PM, Thomas Kluyver <takowl at gmail.com> wrote: >> >>> Thanks Emily. Can we ask you to post a built version of the website >>> somewhere, so that it's easy to look at without cloning the repository and >>> building the site? https://pages.github.com/ is probably the easiest >>> way to do it. >>> >>> Thomas >>> >>> >>> On 3 July 2014 17:15, Emily Schleiner <cordial.emily at gmail.com> wrote: >>> >>>> For anyone curious to see the changes I made, here is my branch on >>>> github: >>>> https://github.com/cordial-emily/ipython-website >>>> >>>> >>>> On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner < >>>> cordial.emily at gmail.com> wrote: >>>> >>>>> Hi Thomas, >>>>> >>>>> I've already added some responsiveness to the theme you already use >>>>> -- and in the mean time before you have a complete change this might be >>>>> helpful to you. I'll just finish up the last couple of adjustments and call >>>>> it good. >>>>> >>>>> Thanks for letting me know! >>>>> >>>>> Emily >>>>> >>>>> >>>>> >>>>> >>>>> On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver <takowl at gmail.com> >>>>> wrote: >>>>> >>>>>> Hi Emily, >>>>>> >>>>>> Thanks, I'm flattered that you remembered our conversation. We're >>>>>> actually just working out the details of hiring a designer, someone who was >>>>>> already known to one of the core team. It will probably be a while before >>>>>> we have anything concrete to show from that, but I don't want you to spend >>>>>> a lot of time redesigning our website if we end up replacing it with a >>>>>> completely new site within a year. I'll discuss with the rest of the core >>>>>> team what's happening with the website, but don't get too far into changing >>>>>> it just yet. >>>>>> >>>>>> One possibility is that we could point you to another open source >>>>>> project that's interested in this kind of work. Next week we're at SciPy, a >>>>>> conference where the people behind lots of scientific Python projects get >>>>>> together, so we can ask people there about that. >>>>>> >>>>>> Best wishes, >>>>>> Thomas >>>>>> >>>>>> >>>>>> On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> >>>>>> wrote: >>>>>> >>>>>>> Dear IPython developers, >>>>>>> >>>>>>> A couple of months ago I spoke with Thomas at an Openhatch event >>>>>>> about the IPython website and it sounds like some design work might be >>>>>>> welcome. (?) I've been lurking on your lists to get to know the group some >>>>>>> and have now forked the site on Github with the aim of making it >>>>>>> responsive. So far I don't plan on revamping the basic shape or colors, but >>>>>>> I'm interested to hear any design preferences from the community... >>>>>>> >>>>>>> Best wishes, >>>>>>> Emily >>>>>>> >>>>>>> -- >>>>>>> __________________________________ >>>>>>> Emily Schleiner >>>>>>> cordial-emily.com >>>>>>> >>>>>>> _______________________________________________ >>>>>>> IPython-dev mailing list >>>>>>> IPython-dev at scipy.org >>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>> >>>>>>> >>>>>> >>>>>> _______________________________________________ >>>>>> IPython-dev mailing list >>>>>> IPython-dev at scipy.org >>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>> >>>>>> >>>>> >>>>> >>>>> -- >>>>> __________________________________ >>>>> Emily Schleiner >>>>> cordial-emily.com >>>>> >>>> >>>> >>>> >>>> -- >>>> __________________________________ >>>> Emily Schleiner >>>> cordial-emily.com >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com >> >> >> _______________________________________________ >> IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > > > _______________________________________________ > IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > _______________________________________________ > IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- __________________________________ Emily Schleiner cordial-emily.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140704/8dad1adf/attachment.html> From sjdv1982 at gmail.com Sat Jul 5 21:54:09 2014 From: sjdv1982 at gmail.com (Sjoerd de Vries) Date: Sun, 6 Jul 2014 03:54:09 +0200 Subject: [IPython-dev] (no subject) Message-ID: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> Hi everyone, First, my compliments to the developers of IPython, a wonderful program that I feel is much underused. In my field of science (protein modelling) it is mostly about large software packages consisting of a cloud of command-line tools. This means that everyone (myself included) uses just the bash shell for interactive work. I consider this situation not ideal at all, and I think that IPython has the potential to provide something much better. However, command-line tool clouds are today's reality, and Python tools (numpy, scipy, matplotlib) just live in another universe until they are wrapped as a command-line tool. I feel that IPython needs to provide a better Python <=> shell interface than it does now. In particular, I have the following problems with it: 1. Python variable expansion within shell commands does not work seamlessly, especially if the command-line tool expects a file or stream. 2. Awk one-liners are mostly broken when entered in IPython. 3. Alias magic is incompatible with shell execution. This means that "%ls" is not the same as "!ls" (very confusing). 4. Shell execution also captures stderr I don't like to give negative criticism, especially since I am fairly new to IPython. So I have coded into IPython a possible solution that solves my problems. Hopefully it will be useful to the community. The code branch is at https://github.com/sjdv1982/ipython.git A detailed proposal is at https://raw.githubusercontent.com/sjdv1982/ipython/master/docs/source/whatsnew/pr/incompat-bangmode.rst All of the examples in the proposal are working with the code branch. cheers Sjoerd -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140706/aeb9dda4/attachment.html> From takowl at gmail.com Sat Jul 5 22:51:01 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Sat, 5 Jul 2014 19:51:01 -0700 Subject: [IPython-dev] (no subject) In-Reply-To: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> References: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> Message-ID: <CAOvn4qgFZ1ut88QpphyMB=mhto2+yVzQJ7QwFO5KJkHt1_L8TQ@mail.gmail.com> Hi Sjoerd, On 5 July 2014 18:54, Sjoerd de Vries <sjdv1982 at gmail.com> wrote: > However, command-line tool clouds are today's reality, and Python tools > (numpy, scipy, matplotlib) just live in another universe until they are > wrapped as a command-line tool. I feel that IPython needs to provide a > better Python <=> shell interface than it does now. In particular, I have > the following problems with it: > > 1. Python variable expansion within shell commands does not work > seamlessly, especially if the command-line tool expects a file or stream. > 2. Awk one-liners are mostly broken when entered in IPython. > 3. Alias magic is incompatible with shell execution. This means that "%ls" > is not the same as "!ls" (very confusing). > 4. Shell execution also captures stderr > > I don't like to give negative criticism, especially since I am fairly new > to IPython. So I have coded into IPython a possible solution that solves my > problems. Hopefully it will be useful to the community. > Thanks. This looks like some really interesting ideas, but I think most or all of it should live as an extension outside core IPython. We try to carefully keep the scope of IPython itself constrained, because it would be very easy for it to expand in a thousand directions, and I don't think this is a direction that the core team would use much, so consequently we wouldn't maintain it very well. If there are some simple hooks or something that IPython needs so you can extend it as you want, we can look at merging that, but things like the %bless magic, converters and parsing shell style pipelines should be in a separate project. You might be interested to know that in older releases of IPython, there was a sh profile which enabled various shell-like features: http://ipython.org/ipython-doc/rel-0.10.2/html/interactive/shell.html . It was broken in the big refactoring for 0.11, although by then several of the extra features had been folded into IPython's default mode, but it was never repaired, and eventually got deleted. Best wishes, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140705/9033466e/attachment.html> From sjdv1982 at gmail.com Sun Jul 6 16:58:03 2014 From: sjdv1982 at gmail.com (Sjoerd de Vries) Date: Sun, 6 Jul 2014 22:58:03 +0200 Subject: [IPython-dev] (no subject) In-Reply-To: <CAOvn4qgFZ1ut88QpphyMB=mhto2+yVzQJ7QwFO5KJkHt1_L8TQ@mail.gmail.com> References: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> <CAOvn4qgFZ1ut88QpphyMB=mhto2+yVzQJ7QwFO5KJkHt1_L8TQ@mail.gmail.com> Message-ID: <CACBGWQZ1+91-D49sPKFPHa_b-Gyc5bv8fa1vvi1fgG8rrEn=Cg@mail.gmail.com> Hi Thomas, Thanks. This looks like some really interesting ideas, but I think most or > all of it should live as an extension outside core IPython. We try to > carefully keep the scope of IPython itself constrained, because it would be > very easy for it to expand in a thousand directions, and I don't think this > is a direction that the core team would use much, so consequently we > wouldn't maintain it very well. If there are some simple hooks or something > that IPython needs so you can extend it as you want, we can look at merging > that, but things like the %bless magic, converters and parsing shell style > pipelines should be in a separate project. > You might be interested to know that in older releases of IPython, there > was a sh profile which enabled various shell-like features: > http://ipython.org/ipython-doc/rel-0.10.2/html/interactive/shell.html . > It was broken in the big refactoring for 0.11, although by then several of > the extra features had been folded into IPython's default mode, but it was > never repaired, and eventually got deleted. > > Best wishes, > Thomas > Thank you for your response, but I am a bit sad to hear this. Now that the sh profile is deleted, is system-shell-replacement no longer within the scope of IPython, ? Still, no problem... I can re-code these features as an extension: - %bless would be registered as a separate magic by the extension - Converters would be maintained in a separate module - The PipeEvaluator would be maintained in a separate module - The pipeline parser would be maintained in a separate module In addition, the extension would manipulate input_transformer_manager.logical_line_transforms, so that the standard input transformers "escaped_commands" and "assign_from_system" will be overruled. This is a bit rude, but it should work. However, it would still require the following modifications to the IPython core: - Support for evaluators, and the use of AliasEvaluator by %alias (to allow delayed evaluation) - A hook to change the %alias formatter class from DollarFormatter (to allow customized variable substitution) - A hook in FullEvalFormatter._vformat to be triggered on certain "conversion" values (for converters) - Additional optional arguments to interactiveshell methods "getoutput", "system_piped" and "system_raw" (for variable substitution and stderr capture) None of this would break any existing code. Would this be OK? cheers Sjoerd -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140706/b3721059/attachment.html> From fperez.net at gmail.com Sun Jul 6 17:51:33 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Sun, 6 Jul 2014 14:51:33 -0700 Subject: [IPython-dev] (no subject) In-Reply-To: <CACBGWQZ1+91-D49sPKFPHa_b-Gyc5bv8fa1vvi1fgG8rrEn=Cg@mail.gmail.com> References: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> <CAOvn4qgFZ1ut88QpphyMB=mhto2+yVzQJ7QwFO5KJkHt1_L8TQ@mail.gmail.com> <CACBGWQZ1+91-D49sPKFPHa_b-Gyc5bv8fa1vvi1fgG8rrEn=Cg@mail.gmail.com> Message-ID: <CAHAreOoCb1BvTi5ufu3TJZnvio=YLcN2nDSwEcZ_p_nYO6WBiw@mail.gmail.com> On Sun, Jul 6, 2014 at 1:58 PM, Sjoerd de Vries <sjdv1982 at gmail.com> wrote: > is system-shell-replacement no longer within the scope of IPython, ? Just to be clear, being a system shell replacement was *never* within the scope of IPython :) The sh profile was mostly a 'party trick' that could be useful in some circumstances, but that's it. Even as biased as I may be to the "ipython everywhere" idea, I *still* think it's not a very good idea to have a tool as complex as IPython playing a role of system shell. That's a job where simplicity and robustness should be more important than fancy features. Having said that, we're always happy to see the community build custom tools that fit their personal needs, even if it's not something that makes sense for the project as a whole. Cheers, f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140706/96a1e54f/attachment.html> From takowl at gmail.com Sun Jul 6 23:03:13 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Sun, 6 Jul 2014 22:03:13 -0500 Subject: [IPython-dev] (no subject) In-Reply-To: <CACBGWQZ1+91-D49sPKFPHa_b-Gyc5bv8fa1vvi1fgG8rrEn=Cg@mail.gmail.com> References: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> <CAOvn4qgFZ1ut88QpphyMB=mhto2+yVzQJ7QwFO5KJkHt1_L8TQ@mail.gmail.com> <CACBGWQZ1+91-D49sPKFPHa_b-Gyc5bv8fa1vvi1fgG8rrEn=Cg@mail.gmail.com> Message-ID: <CAOvn4qhHOXGddrH0QQrTj3cRM_myaNE0xkJyKG4FjwwCuR-+jg@mail.gmail.com> On 6 July 2014 15:58, Sjoerd de Vries <sjdv1982 at gmail.com> wrote: > Thank you for your response, but I am a bit sad to hear this. Now that the > sh profile is deleted, is system-shell-replacement no longer within the > scope of IPython, ? > As Fernando indicated, that's never really been IPython's aim. Of course we like seeing what people build with IPython, but that use case isn't something we especially support. > In addition, the extension would manipulate > input_transformer_manager.logical_line_transforms, so that the standard > input transformers "escaped_commands" and "assign_from_system" will be > overruled. This is a bit rude, but it should work. > That's OK, the input transformation API is there to allow this kind of extension. This is, however, a 'consenting adults' klnd of API - it's entirely possible to break IPython syntax with this, so it's up to you to ensure that things work together. > However, it would still require the following modifications to the IPython > core: > - Support for evaluators, and the use of AliasEvaluator by %alias (to > allow delayed evaluation) > - A hook to change the %alias formatter class from DollarFormatter (to > allow customized variable substitution) > - A hook in FullEvalFormatter._vformat to be triggered on certain > "conversion" values (for converters) > I think the simplest approach to this is something we've been talking about for a while - we shouldn't call var_expand for all magic commands. The obvious answer to this would be to not do it for any magics, and have the magics that want it call it internally, but we've hesitated because we think var_expand makes sense for the majority of magics, and it seems awkward to make them all call it for the sake of a few that don't. An alternative would be to decorate magic function definitions in some way to indicate that var_expand *shouldn't* be called (and leave calling them as the default). Other than that, magics just get the raw string, so you should be able to do whatever you want with that. > - Additional optional arguments to interactiveshell methods "getoutput", > "system_piped" and "system_raw" (for variable substitution and stderr > capture) > I think an argument for stderr capture makes sense. For controlling variable substitution, it might be easier to go down a level, to the (similarly named) functions which they call after doing var_expand. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140706/876ddc00/attachment.html> From thomas.wiecki at gmail.com Mon Jul 7 01:20:51 2014 From: thomas.wiecki at gmail.com (Thomas Wiecki) Date: Mon, 7 Jul 2014 07:20:51 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell Message-ID: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> Hi all, I'm trying to do some static syntax checks (AST parsing) on the code in an IPyNB cell and then either execute the cell or not. I'd also like to control the output that the cell produces. With the magic-interface I know that I can define a function that gets the cell code as a string. This would work well here except that I want this for all cells. With my limited understanding of the IPyNB internals I would see three ways this could be achieved: * There is a hook in the IPyNB I can use like the magic * I have to change the IPyNB client code to do the analysis before it's sent to the kernel. * I change the kernel to do the analysis. Which of these is the best? Can someone point me to the relevant code section I would need to make changes to? Thanks, Thomas -- Thomas Wiecki PhD candidate, Brown University Quantitative Researcher, Quantopian Inc, Boston -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/38b11e30/attachment.html> From cyrille.rossant at gmail.com Mon Jul 7 05:02:21 2014 From: cyrille.rossant at gmail.com (Cyrille Rossant) Date: Mon, 7 Jul 2014 11:02:21 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> Message-ID: <CA+-1RQT8JHeQJQO=XwppydQnGmJs4ioDGStifZAPKOOruNHAZw@mail.gmail.com> Maybe this can be useful? http://ipython.org/ipython-doc/dev/development/wrapperkernels.html 2014-07-07 7:20 GMT+02:00 Thomas Wiecki <thomas.wiecki at gmail.com>: > Hi all, > > I'm trying to do some static syntax checks (AST parsing) on the code in an > IPyNB cell and then either execute the cell or not. I'd also like to > control the output that the cell produces. > > With the magic-interface I know that I can define a function that gets the > cell code as a string. This would work well here except that I want this > for all cells. > > With my limited understanding of the IPyNB internals I would see three > ways this could be achieved: > * There is a hook in the IPyNB I can use like the magic > * I have to change the IPyNB client code to do the analysis before it's > sent to the kernel. > * I change the kernel to do the analysis. > > Which of these is the best? Can someone point me to the relevant code > section I would need to make changes to? > > Thanks, > Thomas > > -- > Thomas Wiecki > PhD candidate, Brown University > Quantitative Researcher, Quantopian Inc, Boston > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/b33c91d1/attachment.html> From sjdv1982 at gmail.com Mon Jul 7 05:12:32 2014 From: sjdv1982 at gmail.com (Sjoerd de Vries) Date: Mon, 7 Jul 2014 11:12:32 +0200 Subject: [IPython-dev] (no subject) In-Reply-To: <CAOvn4qhHOXGddrH0QQrTj3cRM_myaNE0xkJyKG4FjwwCuR-+jg@mail.gmail.com> References: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> <CAOvn4qgFZ1ut88QpphyMB=mhto2+yVzQJ7QwFO5KJkHt1_L8TQ@mail.gmail.com> <CACBGWQZ1+91-D49sPKFPHa_b-Gyc5bv8fa1vvi1fgG8rrEn=Cg@mail.gmail.com> <CAOvn4qhHOXGddrH0QQrTj3cRM_myaNE0xkJyKG4FjwwCuR-+jg@mail.gmail.com> Message-ID: <CACBGWQaYEWafs2JdBDz7GfGXeDk8uEGkf2_7PY1__Orj68E5CA@mail.gmail.com> On Mon, Jul 7, 2014 at 5:03 AM, Thomas Kluyver <takowl at gmail.com> wrote: > On 6 July 2014 15:58, Sjoerd de Vries <sjdv1982 at gmail.com> wrote: > >> Thank you for your response, but I am a bit sad to hear this. Now that >> the sh profile is deleted, is system-shell-replacement no longer within the >> scope of IPython, ? >> > > As Fernando indicated, that's never really been IPython's aim. Of course > we like seeing what people build with IPython, but that use case isn't > something we especially support. > Thank you for this clarification, it's all clear now. I will keep my hacks to myself for now, and I will distribute it as an extension once there are the necessary hooks in IPython. > > >> In addition, the extension would manipulate >> input_transformer_manager.logical_line_transforms, so that the standard >> input transformers "escaped_commands" and "assign_from_system" will be >> overruled. This is a bit rude, but it should work. >> > > That's OK, the input transformation API is there to allow this kind of > extension. This is, however, a 'consenting adults' klnd of API - it's > entirely possible to break IPython syntax with this, so it's up to you to > ensure that things work together. > > OK, I will take care :-) > However, it would still require the following modifications to the IPython >> core: >> - Support for evaluators, and the use of AliasEvaluator by %alias (to >> allow delayed evaluation) >> > - A hook to change the %alias formatter class from DollarFormatter (to >> allow customized variable substitution) >> - A hook in FullEvalFormatter._vformat to be triggered on certain >> "conversion" values (for converters) >> > > I think the simplest approach to this is something we've been talking > about for a while - we shouldn't call var_expand for all magic commands. > The obvious answer to this would be to not do it for any magics, and have > the magics that want it call it internally, but we've hesitated because we > think var_expand makes sense for the majority of magics, and it seems > awkward to make them all call it for the sake of a few that don't. An > alternative would be to decorate magic function definitions in some way to > indicate that var_expand *shouldn't* be called (and leave calling them as > the default). > > This would be great! Perhaps an @expand_variable decorator for IPython.core.magic.Magics? I hope that the var_expand policy for each magic will be stored somewhere, to make it overridable by "consenting adults" ;-) > >> - A hook to change the %alias formatter class from DollarFormatter (to >> allow customized variable substitution) >> - A hook in FullEvalFormatter._vformat to be triggered on certain >> "conversion" values (for converters) >> > What about these hooks, would they be OK? I can make a new branch with just this, it's a dozen lines or less. > >> - Additional optional arguments to interactiveshell methods >> "getoutput", "system_piped" and "system_raw" (for variable substitution and >> stderr capture) >> > > I think an argument for stderr capture makes sense. For controlling > variable substitution, it might be easier to go down a level, to the > (similarly named) functions which they call after doing var_expand. > Well, I can copy-paste "getoutput" and "system_piped" into my own extension and make the necessary changes there, if that's best. cheers Sjoerd -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/7a6f5aca/attachment.html> From ellisonbg at gmail.com Mon Jul 7 09:19:16 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Mon, 7 Jul 2014 08:19:16 -0500 Subject: [IPython-dev] website In-Reply-To: <CABWt4EjhzLLocqD_ZbvA3n+L+Qjvmr9JpPBMP1kGtzHcszq3LQ@mail.gmail.com> References: <CABWt4Ei1wihcb1x1bcXdgBDxRoHA6GAXObW7nLgL48bEkh2Vdw@mail.gmail.com> <CAOvn4qhLoD0zJPpWqODjz2norGpa92Kn8W1kYgvDhzL54FC42A@mail.gmail.com> <CABWt4EiWFXov8MxnzwW2zRBKoaNA=41b7YDg1y5LVjsZYObEvQ@mail.gmail.com> <CABWt4Eg23e+gLgU5RUPZyrKMdyfbu0f4k_kAXbX7-=H2ssrMSA@mail.gmail.com> <CAOvn4qgxEEDjRu4hYtjx7944U=BFCjr0G4_BDPpnL9MRzHfdig@mail.gmail.com> <CABWt4Eha=7thmhJopjJ62c8w3EqNOqwXn5CYa_P72ZqRHtA3CA@mail.gmail.com> <53B6F207.5080709@fnal.gov> <CABWt4EgGDkcDENOkc148cVKsFYJjqWpnO7WPJ4G+urYU-zGhsQ@mail.gmail.com> <53B70AFB.8040907@fnal.gov> <53B70CD2.5050603@fnal.gov> <CABWt4EjhzLLocqD_ZbvA3n+L+Qjvmr9JpPBMP1kGtzHcszq3LQ@mail.gmail.com> Message-ID: <CAH4pYpR9WAfosYDFuQ7fhw6NknGfzzU7TH+U0Y1z8Aodi_dVmQ@mail.gmail.com> Emily, can you open a pull request so we can see and discuss the diffs more easily? On Fri, Jul 4, 2014 at 4:24 PM, Emily Schleiner <cordial.emily at gmail.com> wrote: > Done, you can add the issue here: > https://github.com/cordial-emily/cordial-emily.github.io/issues > > Thanks, > Emily > > > On Fri, Jul 4, 2014 at 1:21 PM, Jon Wilson <jsw at fnal.gov> wrote: >> >> Hmm, it seems that I cannot open issues on your fork unless you >> specifically enable them: >> >> http://programmers.stackexchange.com/questions/179468/forking-a-repo-on-github-but-allowing-new-issues-on-the-fork >> >> Regards, >> Jon >> >> >> On 07/04/2014 03:13 PM, Jon Wilson wrote: >> >> Hi Emily, >> The text is fine on my phone. The gray text issue occurs on my laptop >> (Ubuntu 14.04, Firefox 30). Sorry that I wasn't clear about that. >> >> And, since I just used the word "issue" above, it occurs to me that I >> should actually be using github's "issue" feature rather than emailing you >> about it. >> Regards, >> Jon >> >> On 07/04/2014 02:51 PM, Emily Schleiner wrote: >> >> Hi Aaron and Jon, >> >> Thanks for the feedback -- hearing about the look of the site on multiple >> devices is especially helpful. :) >> >> Let's see.. the gap in scrolling (preceding images) is something I should >> be able to fix. For the large screen size (1400 or more pixels wide) I'll >> limit the size of the logo so it doesn't look too pixelated and increase the >> margins some. >> >> The gray text on the mobile size sounds like an anomaly based on the >> devices I've seen so far, but I can increase the font weight for small >> devices >> >> Fyi, ideally I would like to redesign the whole structure with bootstrap >> etc but it sounds like it might not be worthwhile if the site is going to >> revamped soon anyway... These adjustments just make it possible to see all >> the content (as it stands) on phones. >> >> Thanks all! >> Emily >> >> >> >> >> >> >> >> >> On Fri, Jul 4, 2014 at 11:27 AM, Jon Wilson <jsw at fnal.gov> wrote: >>> >>> Hi Emily, >>> This is quite nice stuff. I'm glad that someone is making the effort to >>> make a responsive page without overdesigning things. Far too many pages are >>> very difficult to read on mobile devices. >>> >>> In my browser (Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:30.0) >>> Gecko/20100101 Firefox/30.0), the text appears in a very light gray that is >>> quite difficult to read against the white background. I don't know quite >>> why this is. >>> >>> On my phone (Mozilla/5.0 (Android; Mobile; rv:30.0) Gecko/30.0 >>> Firefox/30.0), the column widths are a bit rough -- the text in the left >>> column is quite narrow, and one piece of the right column overruns the >>> column width and causes horizontal scrolling. There is also a long vertical >>> gap in the left column before reaching the end of the two-column section. >>> Overall, I got the initial feeling that the two-column stuff was all >>> unimportant gunk (not true, of course) that I had to scroll past to get to >>> the real content. I think maybe the sidebar material could be moved to the >>> end of the page? >>> >>> This is only commentary on the front page. I haven't yet taken a look at >>> other pages. >>> Regards, >>> Jon >>> >>> >>> On 07/03/2014 10:42 PM, Emily Schleiner wrote: >>> >>> Here you go: >>> http://cordial-emily.github.io/ >>> >>> -Emily >>> >>> >>> On Thu, Jul 3, 2014 at 5:18 PM, Thomas Kluyver <takowl at gmail.com> wrote: >>>> >>>> Thanks Emily. Can we ask you to post a built version of the website >>>> somewhere, so that it's easy to look at without cloning the repository and >>>> building the site? https://pages.github.com/ is probably the easiest way to >>>> do it. >>>> >>>> Thomas >>>> >>>> >>>> On 3 July 2014 17:15, Emily Schleiner <cordial.emily at gmail.com> wrote: >>>>> >>>>> For anyone curious to see the changes I made, here is my branch on >>>>> github: >>>>> https://github.com/cordial-emily/ipython-website >>>>> >>>>> >>>>> On Wed, Jul 2, 2014 at 11:25 AM, Emily Schleiner >>>>> <cordial.emily at gmail.com> wrote: >>>>>> >>>>>> Hi Thomas, >>>>>> >>>>>> I've already added some responsiveness to the theme you already use -- >>>>>> and in the mean time before you have a complete change this might be helpful >>>>>> to you. I'll just finish up the last couple of adjustments and call it good. >>>>>> >>>>>> Thanks for letting me know! >>>>>> >>>>>> Emily >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> On Wed, Jul 2, 2014 at 10:58 AM, Thomas Kluyver <takowl at gmail.com> >>>>>> wrote: >>>>>>> >>>>>>> Hi Emily, >>>>>>> >>>>>>> Thanks, I'm flattered that you remembered our conversation. We're >>>>>>> actually just working out the details of hiring a designer, someone who was >>>>>>> already known to one of the core team. It will probably be a while before we >>>>>>> have anything concrete to show from that, but I don't want you to spend a >>>>>>> lot of time redesigning our website if we end up replacing it with a >>>>>>> completely new site within a year. I'll discuss with the rest of the core >>>>>>> team what's happening with the website, but don't get too far into changing >>>>>>> it just yet. >>>>>>> >>>>>>> One possibility is that we could point you to another open source >>>>>>> project that's interested in this kind of work. Next week we're at SciPy, a >>>>>>> conference where the people behind lots of scientific Python projects get >>>>>>> together, so we can ask people there about that. >>>>>>> >>>>>>> Best wishes, >>>>>>> Thomas >>>>>>> >>>>>>> >>>>>>> On 1 July 2014 15:23, Emily Schleiner <cordial.emily at gmail.com> >>>>>>> wrote: >>>>>>>> >>>>>>>> Dear IPython developers, >>>>>>>> >>>>>>>> A couple of months ago I spoke with Thomas at an Openhatch event >>>>>>>> about the IPython website and it sounds like some design work might be >>>>>>>> welcome. (?) I've been lurking on your lists to get to know the group some >>>>>>>> and have now forked the site on Github with the aim of making it responsive. >>>>>>>> So far I don't plan on revamping the basic shape or colors, but I'm >>>>>>>> interested to hear any design preferences from the community... >>>>>>>> >>>>>>>> Best wishes, >>>>>>>> Emily >>>>>>>> >>>>>>>> -- >>>>>>>> __________________________________ >>>>>>>> Emily Schleiner >>>>>>>> cordial-emily.com >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> IPython-dev mailing list >>>>>>>> IPython-dev at scipy.org >>>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>>> >>>>>>> >>>>>>> >>>>>>> _______________________________________________ >>>>>>> IPython-dev mailing list >>>>>>> IPython-dev at scipy.org >>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>> >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> __________________________________ >>>>>> Emily Schleiner >>>>>> cordial-emily.com >>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> __________________________________ >>>>> Emily Schleiner >>>>> cordial-emily.com >>>>> >>>>> _______________________________________________ >>>>> IPython-dev mailing list >>>>> IPython-dev at scipy.org >>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>> >>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>> >>> >>> >>> -- >>> __________________________________ >>> Emily Schleiner >>> cordial-emily.com >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >> >> >> >> -- >> __________________________________ >> Emily Schleiner >> cordial-emily.com >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > > -- > __________________________________ > Emily Schleiner > cordial-emily.com > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From takowl at gmail.com Mon Jul 7 09:47:13 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 7 Jul 2014 08:47:13 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> Message-ID: <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> On 7 July 2014 00:20, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > With my limited understanding of the IPyNB internals I would see three > ways this could be achieved: > * There is a hook in the IPyNB I can use like the magic > * I have to change the IPyNB client code to do the analysis before it's > sent to the kernel. > * I change the kernel to do the analysis. > > Which of these is the best? Can someone point me to the relevant code > section I would need to make changes to? I think you can make use of the hooks already in the kernel. If you're just checking the AST, it's fairly straightforward: just register an AST transformer as described here: http://ipython.org/ipython-doc/dev/config/inputtransforms.html#ast-transformations . It doesn't need to do any transformations: you can simply inspect the code and return it unchanged. Or you can replace it all with Pass() to prevent the cell from executing. It would still look as if it had executed from the frontend, though. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/33d7a45b/attachment.html> From dave.hirschfeld at gmail.com Mon Jul 7 12:04:24 2014 From: dave.hirschfeld at gmail.com (Dave Hirschfeld) Date: Mon, 7 Jul 2014 16:04:24 +0000 (UTC) Subject: [IPython-dev] ipython trust mynotebook doesn't work Message-ID: <loom.20140707T173557-977@post.gmane.org> I'm trying to share a notebook however running ipython trust mynotebook.ipynb from the command line results in Signing notebook: .\mynotebook.ipynb and I can then see a signature field has been added to the notebook metadata however I still can't see the html output in the notebook!? Is anyone else having problems with the notebook security? Thanks, Dave From fperez.net at gmail.com Mon Jul 7 12:07:23 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 7 Jul 2014 11:07:23 -0500 Subject: [IPython-dev] ipython trust mynotebook doesn't work In-Reply-To: <loom.20140707T173557-977@post.gmane.org> References: <loom.20140707T173557-977@post.gmane.org> Message-ID: <CAHAreOo+oL8YfLqUQUjX1wQ2tvztzHyYxLKz7p5krG15FdX_HQ@mail.gmail.com> Hi Dave, there seems to be an issue with the trust command, it was just reported on the tracker: https://github.com/ipython/ipython/issues/6091 In the meantime, can you try using the "trust this notebook" dialog in the file menu? Please let us know if that helps... Best f On Mon, Jul 7, 2014 at 11:04 AM, Dave Hirschfeld <dave.hirschfeld at gmail.com> wrote: > I'm trying to share a notebook however running > > ipython trust mynotebook.ipynb > > from the command line results in > > Signing notebook: .\mynotebook.ipynb > > and I can then see a signature field has been added to the notebook > metadata > however I still can't see the html output in the notebook!? > > Is anyone else having problems with the notebook security? > > Thanks, > Dave > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/ffd9347e/attachment.html> From fperez.net at gmail.com Mon Jul 7 12:07:23 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 7 Jul 2014 11:07:23 -0500 Subject: [IPython-dev] ipython trust mynotebook doesn't work In-Reply-To: <loom.20140707T173557-977@post.gmane.org> References: <loom.20140707T173557-977@post.gmane.org> Message-ID: <CAHAreOo+oL8YfLqUQUjX1wQ2tvztzHyYxLKz7p5krG15FdX_HQ@mail.gmail.com> Hi Dave, there seems to be an issue with the trust command, it was just reported on the tracker: https://github.com/ipython/ipython/issues/6091 In the meantime, can you try using the "trust this notebook" dialog in the file menu? Please let us know if that helps... Best f On Mon, Jul 7, 2014 at 11:04 AM, Dave Hirschfeld <dave.hirschfeld at gmail.com> wrote: > I'm trying to share a notebook however running > > ipython trust mynotebook.ipynb > > from the command line results in > > Signing notebook: .\mynotebook.ipynb > > and I can then see a signature field has been added to the notebook > metadata > however I still can't see the html output in the notebook!? > > Is anyone else having problems with the notebook security? > > Thanks, > Dave > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/ffd9347e/attachment-0001.html> From thomas.wiecki at gmail.com Mon Jul 7 12:41:31 2014 From: thomas.wiecki at gmail.com (Thomas Wiecki) Date: Mon, 7 Jul 2014 18:41:31 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> Message-ID: <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> Thanks, I think the wrapper kernel will give me more freedom. Once I have the kernel.json, how can I launch an IPython NB with this new kernel? Couldn't find a way to link to the json file. On Mon, Jul 7, 2014 at 3:47 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 7 July 2014 00:20, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > >> With my limited understanding of the IPyNB internals I would see three >> ways this could be achieved: >> * There is a hook in the IPyNB I can use like the magic >> * I have to change the IPyNB client code to do the analysis before it's >> sent to the kernel. >> * I change the kernel to do the analysis. >> >> Which of these is the best? Can someone point me to the relevant code >> section I would need to make changes to? > > > I think you can make use of the hooks already in the kernel. If you're > just checking the AST, it's fairly straightforward: just register an AST > transformer as described here: > http://ipython.org/ipython-doc/dev/config/inputtransforms.html#ast-transformations > . It doesn't need to do any transformations: you can simply inspect the > code and return it unchanged. Or you can replace it all with Pass() to > prevent the cell from executing. It would still look as if it had executed > from the frontend, though. > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Thomas Wiecki PhD candidate, Brown University Quantitative Researcher, Quantopian Inc, Boston -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/c55d5cda/attachment.html> From alessandro.gagliardi at glassdoor.com Mon Jul 7 12:46:47 2014 From: alessandro.gagliardi at glassdoor.com (Alessandro Gagliardi) Date: Mon, 7 Jul 2014 16:46:47 +0000 Subject: [IPython-dev] toggle line numbers on Mac Message-ID: <CFE01D04.D333%alessandro.gagliardi@glassdoor.com> Stupid question, but I can?t find the answer online. (Maybe I?m Googling it wrong.) Anyway, keyboard shortcuts on a Mac says Cmd+l: toggle line numbers. But when I try Cmd+l in Firefox or Chrome, the browser intercepts it and puts my cursor in the address field. Any idea how to fix this? Thanks, -Alessandro -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/20ef0fd5/attachment.html> From takowl at gmail.com Mon Jul 7 12:48:43 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 7 Jul 2014 11:48:43 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> Message-ID: <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> On 7 July 2014 11:41, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > Once I have the kernel.json, how can I launch an IPython NB with this new > kernel? Couldn't find a way to link to the json file. That part's not implemented yet - once it is, there will be a dropdown menu in the notebook UI to select kernels. For now, you need to start the notebook server with a long command like this: ipython notebook --KernelManager.kernel_cmd="['python', '-m', 'my_module']" -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/64d6786b/attachment.html> From jiffyclub at gmail.com Mon Jul 7 12:51:59 2014 From: jiffyclub at gmail.com (Matt Davis) Date: Mon, 7 Jul 2014 09:51:59 -0700 Subject: [IPython-dev] toggle line numbers on Mac In-Reply-To: <CFE01D04.D333%alessandro.gagliardi@glassdoor.com> References: <CFE01D04.D333%alessandro.gagliardi@glassdoor.com> Message-ID: <CAMqnrZoyj3LP7PmMV4hyKVK8hw69sB0kjWVjYXQerW6Ek1QndQ@mail.gmail.com> If you're using IPython 2+ with the new modal interface then just "l" while in command mode will toggle line numbers. On older IPython versions maybe it's ctrl-l? - Matt On Mon, Jul 7, 2014 at 9:46 AM, Alessandro Gagliardi < alessandro.gagliardi at glassdoor.com> wrote: > Stupid question, but I can?t find the answer online. (Maybe I?m Googling > it wrong.) Anyway, keyboard shortcuts on a Mac says Cmd+l: toggle line > numbers. But when I try Cmd+l in Firefox or Chrome, the browser intercepts > it and puts my cursor in the address field. Any idea how to fix this? > > Thanks, > -Alessandro > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/e6bca33e/attachment.html> From bussonniermatthias at gmail.com Mon Jul 7 12:53:30 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 7 Jul 2014 18:53:30 +0200 Subject: [IPython-dev] toggle line numbers on Mac In-Reply-To: <CFE01D04.D333%alessandro.gagliardi@glassdoor.com> References: <CFE01D04.D333%alessandro.gagliardi@glassdoor.com> Message-ID: <2317F1B6-FB1E-40BF-A53D-0B29274D28D2@gmail.com> Le 7 juil. 2014 ? 18:46, Alessandro Gagliardi a ?crit : > Stupid question, but I can?t find the answer online. (Maybe I?m Googling it wrong.) Anyway, > keyboard shortcuts on a Mac says Cmd+l: toggle line numbers. Where does it says that (so that it could be fixed) ? Which version of IPython ? In 2.0 and above, in command mode 'L' should be sufficient. An Ctrl+M, L on previous versions. -- M > But when I try Cmd+l in Firefox or Chrome, the browser intercepts it and puts my cursor in the address field. Any idea how to fix this? > > Thanks, > -Alessandro > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From thomas.wiecki at gmail.com Mon Jul 7 12:57:54 2014 From: thomas.wiecki at gmail.com (Thomas Wiecki) Date: Mon, 7 Jul 2014 18:57:54 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> Message-ID: <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> OK, that seems to work. I copy&pasted the EchoKernel example but it seems to stall (cell id turns to * and stays that way). Any way I can debug this? print's don't seem to get shown. On Mon, Jul 7, 2014 at 6:48 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 7 July 2014 11:41, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > >> Once I have the kernel.json, how can I launch an IPython NB with this new >> kernel? Couldn't find a way to link to the json file. > > > That part's not implemented yet - once it is, there will be a dropdown > menu in the notebook UI to select kernels. For now, you need to start the > notebook server with a long command like this: > > ipython notebook --KernelManager.kernel_cmd="['python', '-m', 'my_module']" > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Thomas Wiecki PhD candidate, Brown University Quantitative Researcher, Quantopian Inc, Boston -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/74754261/attachment.html> From alessandro.gagliardi at glassdoor.com Mon Jul 7 13:00:27 2014 From: alessandro.gagliardi at glassdoor.com (Alessandro Gagliardi) Date: Mon, 7 Jul 2014 17:00:27 +0000 Subject: [IPython-dev] IPython-dev Digest, Vol 126, Issue 19 In-Reply-To: <mailman.11257.1404751337.1017.ipython-dev@scipy.org> Message-ID: <CFE01F92.D335%alessandro.gagliardi@glassdoor.com> Ah, quite so. The help says: Cmd ? s : save notebook l : toggle line numbers o : toggle output I mistakenly assumed the ?Cmd? applied to the following two commands as well. As I said, stupid question. :) Thanks, -Alessandro Date: Mon, 7 Jul 2014 09:51:59 -0700 From: Matt Davis <jiffyclub at gmail.com<mailto:jiffyclub at gmail.com>> Subject: Re: [IPython-dev] toggle line numbers on Mac To: IPython developers list <ipython-dev at scipy.org<mailto:ipython-dev at scipy.org>> Message-ID: <CAMqnrZoyj3LP7PmMV4hyKVK8hw69sB0kjWVjYXQerW6Ek1QndQ at mail.gmail.com<mailto:CAMqnrZoyj3LP7PmMV4hyKVK8hw69sB0kjWVjYXQerW6Ek1QndQ at mail.gmail.com>> Content-Type: text/plain; charset="utf-8" If you're using IPython 2+ with the new modal interface then just "l" while in command mode will toggle line numbers. On older IPython versions maybe it's ctrl-l? - Matt -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/828c26e8/attachment.html> From fperez.net at gmail.com Mon Jul 7 13:02:28 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 7 Jul 2014 12:02:28 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> Message-ID: <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> Try it first using a terminal client: ipython console --existing ... .json. Once you know that works, move over to the notebook. Less moving parts.... f On Mon, Jul 7, 2014 at 11:57 AM, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > OK, that seems to work. I copy&pasted the EchoKernel example but it seems > to stall (cell id turns to * and stays that way). Any way I can debug this? > print's don't seem to get shown. > > > On Mon, Jul 7, 2014 at 6:48 PM, Thomas Kluyver <takowl at gmail.com> wrote: > >> On 7 July 2014 11:41, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: >> >>> Once I have the kernel.json, how can I launch an IPython NB with this >>> new kernel? Couldn't find a way to link to the json file. >> >> >> That part's not implemented yet - once it is, there will be a dropdown >> menu in the notebook UI to select kernels. For now, you need to start the >> notebook server with a long command like this: >> >> ipython notebook --KernelManager.kernel_cmd="['python', '-m', 'my_module']" >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Thomas Wiecki > PhD candidate, Brown University > Quantitative Researcher, Quantopian Inc, Boston > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/d75a9786/attachment.html> From dave.hirschfeld at gmail.com Mon Jul 7 13:04:24 2014 From: dave.hirschfeld at gmail.com (Dave Hirschfeld) Date: Mon, 7 Jul 2014 17:04:24 +0000 (UTC) Subject: [IPython-dev] ipython trust mynotebook doesn't work References: <loom.20140707T173557-977@post.gmane.org> <CAHAreOo+oL8YfLqUQUjX1wQ2tvztzHyYxLKz7p5krG15FdX_HQ@mail.gmail.com> Message-ID: <loom.20140707T184919-207@post.gmane.org> Fernando Perez <fperez.net <at> gmail.com> writes: > > > Hi Dave, > there seems to be an issue with the trust command, it was just reported on the tracker: > > > https://github.com/ipython/ipython/issues/6091 > > > In the meantime, can you try?using the "trust this notebook" dialog in the file menu? Please let us know if that helps... > > Best > > > f > > I don't seem to have that option - I'm guessing that's in a not-yet-released version of IPython? In [14]: print sys_info() {'commit_hash': '681fd77', 'commit_source': 'installation', 'default_encoding': 'cp1252', 'ipython_path': 'C:\\dev\\bin\\Anaconda\\lib\\site-packages\\IPython', 'ipython_version': '2.1.0', 'os_name': 'nt', 'platform': 'Windows-7-6.1.7601-SP1', 'sys_executable': 'C:\\dev\\bin\\Anaconda\\python.exe', 'sys_platform': 'win32', 'sys_version': '2.7.5 |Anaconda 2.0.0 (64-bit)| (default, Jul 1 2013, 12:37:52) [MSC v.1500 64 bit (AMD64)]'} http://imgur.com/t54RizV If so, I can test out master a bit later and report back... -Dave From nathan12343 at gmail.com Mon Jul 7 13:09:23 2014 From: nathan12343 at gmail.com (Nathan Goldbaum) Date: Mon, 7 Jul 2014 12:09:23 -0500 Subject: [IPython-dev] ipython trust mynotebook doesn't work In-Reply-To: <loom.20140707T184919-207@post.gmane.org> References: <loom.20140707T173557-977@post.gmane.org> <CAHAreOo+oL8YfLqUQUjX1wQ2tvztzHyYxLKz7p5krG15FdX_HQ@mail.gmail.com> <loom.20140707T184919-207@post.gmane.org> Message-ID: <CAJXewOkZd2Yzob+H3t=chwNxZXpUkiKkY-43ZWYO_W_o9=gZog@mail.gmail.com> It should be on the "File" dropdown menu is the notebook web interface. On Monday, July 7, 2014, Dave Hirschfeld <dave.hirschfeld at gmail.com> wrote: > Fernando Perez <fperez.net <at> gmail.com> writes: > > > > > > > Hi Dave, > > there seems to be an issue with the trust command, it was just reported > on > the tracker: > > > > > > https://github.com/ipython/ipython/issues/6091 > > > > > > In the meantime, can you try using the "trust this notebook" dialog in > the > file menu? Please let us know if that helps... > > > > Best > > > > > > f > > > > > > I don't seem to have that option - I'm guessing that's in a > not-yet-released > version of IPython? > > In [14]: print sys_info() > {'commit_hash': '681fd77', > 'commit_source': 'installation', > 'default_encoding': 'cp1252', > 'ipython_path': 'C:\\dev\\bin\\Anaconda\\lib\\site-packages\\IPython', > 'ipython_version': '2.1.0', > 'os_name': 'nt', > 'platform': 'Windows-7-6.1.7601-SP1', > 'sys_executable': 'C:\\dev\\bin\\Anaconda\\python.exe', > 'sys_platform': 'win32', > 'sys_version': '2.7.5 |Anaconda 2.0.0 (64-bit)| (default, Jul 1 2013, > 12:37:52) [MSC v.1500 64 bit (AMD64)]'} > > http://imgur.com/t54RizV > > > If so, I can test out master a bit later and report back... > > -Dave > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <javascript:;> > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/82c349fb/attachment.html> From nathan12343 at gmail.com Mon Jul 7 13:09:23 2014 From: nathan12343 at gmail.com (Nathan Goldbaum) Date: Mon, 7 Jul 2014 12:09:23 -0500 Subject: [IPython-dev] ipython trust mynotebook doesn't work In-Reply-To: <loom.20140707T184919-207@post.gmane.org> References: <loom.20140707T173557-977@post.gmane.org> <CAHAreOo+oL8YfLqUQUjX1wQ2tvztzHyYxLKz7p5krG15FdX_HQ@mail.gmail.com> <loom.20140707T184919-207@post.gmane.org> Message-ID: <CAJXewOkZd2Yzob+H3t=chwNxZXpUkiKkY-43ZWYO_W_o9=gZog@mail.gmail.com> It should be on the "File" dropdown menu is the notebook web interface. On Monday, July 7, 2014, Dave Hirschfeld <dave.hirschfeld at gmail.com> wrote: > Fernando Perez <fperez.net <at> gmail.com> writes: > > > > > > > Hi Dave, > > there seems to be an issue with the trust command, it was just reported > on > the tracker: > > > > > > https://github.com/ipython/ipython/issues/6091 > > > > > > In the meantime, can you try using the "trust this notebook" dialog in > the > file menu? Please let us know if that helps... > > > > Best > > > > > > f > > > > > > I don't seem to have that option - I'm guessing that's in a > not-yet-released > version of IPython? > > In [14]: print sys_info() > {'commit_hash': '681fd77', > 'commit_source': 'installation', > 'default_encoding': 'cp1252', > 'ipython_path': 'C:\\dev\\bin\\Anaconda\\lib\\site-packages\\IPython', > 'ipython_version': '2.1.0', > 'os_name': 'nt', > 'platform': 'Windows-7-6.1.7601-SP1', > 'sys_executable': 'C:\\dev\\bin\\Anaconda\\python.exe', > 'sys_platform': 'win32', > 'sys_version': '2.7.5 |Anaconda 2.0.0 (64-bit)| (default, Jul 1 2013, > 12:37:52) [MSC v.1500 64 bit (AMD64)]'} > > http://imgur.com/t54RizV > > > If so, I can test out master a bit later and report back... > > -Dave > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <javascript:;> > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/82c349fb/attachment-0001.html> From jenshnielsen at gmail.com Mon Jul 7 13:50:36 2014 From: jenshnielsen at gmail.com (Jens Nielsen) Date: Mon, 7 Jul 2014 12:50:36 -0500 Subject: [IPython-dev] toggle line numbers on Mac In-Reply-To: <2317F1B6-FB1E-40BF-A53D-0B29274D28D2@gmail.com> References: <CFE01D04.D333%alessandro.gagliardi@glassdoor.com> <2317F1B6-FB1E-40BF-A53D-0B29274D28D2@gmail.com> Message-ID: <CAM-Pw02AKMSRVEm+_vM9+evuiNSX8jWQ=UGDghO1=5UHvTS_Ww@mail.gmail.com> Matthias, I think the issue is that all shortcuts below cmd-s, which are just a single character, are read as implicit cmd + char. I.e. this issue https://github.com/ipython/ipython/issues/5531 /Jens On Mon, Jul 7, 2014 at 11:53 AM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 7 juil. 2014 ? 18:46, Alessandro Gagliardi a ?crit : > > > Stupid question, but I can?t find the answer online. (Maybe I?m Googling > it wrong.) Anyway, > > > > keyboard shortcuts on a Mac says Cmd+l: toggle line numbers. > > Where does it says that (so that it could be fixed) ? Which version of > IPython ? > > In 2.0 and above, in command mode 'L' should be sufficient. An Ctrl+M, L > on previous versions. > -- > M > > > > But when I try Cmd+l in Firefox or Chrome, the browser intercepts it and > puts my cursor in the address field. Any idea how to fix this? > > > > Thanks, > > -Alessandro > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/427f67bb/attachment.html> From bussonniermatthias at gmail.com Mon Jul 7 14:18:42 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 7 Jul 2014 20:18:42 +0200 Subject: [IPython-dev] toggle line numbers on Mac In-Reply-To: <CAM-Pw02AKMSRVEm+_vM9+evuiNSX8jWQ=UGDghO1=5UHvTS_Ww@mail.gmail.com> References: <CFE01D04.D333%alessandro.gagliardi@glassdoor.com> <2317F1B6-FB1E-40BF-A53D-0B29274D28D2@gmail.com> <CAM-Pw02AKMSRVEm+_vM9+evuiNSX8jWQ=UGDghO1=5UHvTS_Ww@mail.gmail.com> Message-ID: <43E86FBB-7216-4F40-9519-086298187393@gmail.com> Le 7 juil. 2014 ? 19:50, Jens Nielsen a ?crit : > Matthias, I think the issue is that all shortcuts below cmd-s, which are just a single character, are read as implicit cmd + char. > I.e. this issue https://github.com/ipython/ipython/issues/5531 I yes, I see. Maybe we should reopen the issue to find a way to fix that. -- M > > /Jens > > > On Mon, Jul 7, 2014 at 11:53 AM, Matthias Bussonnier <bussonniermatthias at gmail.com> wrote: > > Le 7 juil. 2014 ? 18:46, Alessandro Gagliardi a ?crit : > > > Stupid question, but I can?t find the answer online. (Maybe I?m Googling it wrong.) Anyway, > > > > keyboard shortcuts on a Mac says Cmd+l: toggle line numbers. > > Where does it says that (so that it could be fixed) ? Which version of IPython ? > > In 2.0 and above, in command mode 'L' should be sufficient. An Ctrl+M, L on previous versions. > -- > M > > > > But when I try Cmd+l in Firefox or Chrome, the browser intercepts it and puts my cursor in the address field. Any idea how to fix this? > > > > Thanks, > > -Alessandro > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From thomas.wiecki at gmail.com Mon Jul 7 14:21:07 2014 From: thomas.wiecki at gmail.com (Thomas Wiecki) Date: Mon, 7 Jul 2014 20:21:07 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> Message-ID: <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> Thanks Fernando. I launch the kernel, but once I connect with the console this happens: >>python echokernel.py main NOTE: When using the `ipython kernel` entry point, Ctrl-C will not work. To exit, you will have to explicitly quit this process, by either sending "quit" from a client, or using Ctrl-\ in UNIX-like environments. To read more about this, see https://github.com/ipython/ipython/issues/2049 To connect another client to this kernel, use: --existing kernel-22662.json [IPKernelApp] ERROR | Invalid Message Traceback (most recent call last): File "/home/wiecki/envs/zipline_ipydev/lib/python2.7/site-packages/IPython/kernel/zmq/kernelbase.py", line 160, in dispatch_shell msg = self.session.unserialize(msg, content=True, copy=False) File "/home/wiecki/envs/zipline_ipydev/lib/python2.7/site-packages/IPython/kernel/zmq/session.py", line 822, in unserialize raise ValueError("Invalid Signature: %r" % signature) ValueError: Invalid Signature: '5a5e527fdb5c50a2fbeb2d6cdecb974ce32531c535c6adf8dc6ed124df112fb4' [IPKernelApp] ERROR | Invalid Message On Mon, Jul 7, 2014 at 7:02 PM, Fernando Perez <fperez.net at gmail.com> wrote: > Try it first using a terminal client: > > > ipython console --existing ... .json. > > Once you know that works, move over to the notebook. Less moving parts.... > > f > > > On Mon, Jul 7, 2014 at 11:57 AM, Thomas Wiecki <thomas.wiecki at gmail.com> > wrote: > >> OK, that seems to work. I copy&pasted the EchoKernel example but it seems >> to stall (cell id turns to * and stays that way). Any way I can debug this? >> print's don't seem to get shown. >> >> >> On Mon, Jul 7, 2014 at 6:48 PM, Thomas Kluyver <takowl at gmail.com> wrote: >> >>> On 7 July 2014 11:41, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: >>> >>>> Once I have the kernel.json, how can I launch an IPython NB with this >>>> new kernel? Couldn't find a way to link to the json file. >>> >>> >>> That part's not implemented yet - once it is, there will be a dropdown >>> menu in the notebook UI to select kernels. For now, you need to start the >>> notebook server with a long command like this: >>> >>> ipython notebook --KernelManager.kernel_cmd="['python', '-m', 'my_module']" >>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> >> -- >> Thomas Wiecki >> PhD candidate, Brown University >> Quantitative Researcher, Quantopian Inc, Boston >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Thomas Wiecki PhD candidate, Brown University Quantitative Researcher, Quantopian Inc, Boston -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/112342c1/attachment.html> From cyrille.rossant at gmail.com Mon Jul 7 14:34:41 2014 From: cyrille.rossant at gmail.com (Cyrille Rossant) Date: Mon, 7 Jul 2014 20:34:41 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> Message-ID: <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> I think you have to use ipython qtconsole --kernel ... Le lundi 7 juillet 2014, Thomas Wiecki <thomas.wiecki at gmail.com> a ?crit : > Thanks Fernando. > > I launch the kernel, but once I connect with the console this happens: > > >>python echokernel.py > main > NOTE: When using the `ipython kernel` entry point, Ctrl-C will not work. > > To exit, you will have to explicitly quit this process, by either sending > "quit" from a client, or using Ctrl-\ in UNIX-like environments. > > To read more about this, see > https://github.com/ipython/ipython/issues/2049 > > > To connect another client to this kernel, use: > --existing kernel-22662.json > [IPKernelApp] ERROR | Invalid Message > Traceback (most recent call last): > File > "/home/wiecki/envs/zipline_ipydev/lib/python2.7/site-packages/IPython/kernel/zmq/kernelbase.py", > line 160, in dispatch_shell > msg = self.session.unserialize(msg, content=True, copy=False) > File > "/home/wiecki/envs/zipline_ipydev/lib/python2.7/site-packages/IPython/kernel/zmq/session.py", > line 822, in unserialize > raise ValueError("Invalid Signature: %r" % signature) > ValueError: Invalid Signature: > '5a5e527fdb5c50a2fbeb2d6cdecb974ce32531c535c6adf8dc6ed124df112fb4' > [IPKernelApp] ERROR | Invalid Message > > > On Mon, Jul 7, 2014 at 7:02 PM, Fernando Perez <fperez.net at gmail.com > <javascript:_e(%7B%7D,'cvml','fperez.net at gmail.com');>> wrote: > >> Try it first using a terminal client: >> >> >> ipython console --existing ... .json. >> >> Once you know that works, move over to the notebook. Less moving parts.... >> >> f >> >> >> On Mon, Jul 7, 2014 at 11:57 AM, Thomas Wiecki <thomas.wiecki at gmail.com >> <javascript:_e(%7B%7D,'cvml','thomas.wiecki at gmail.com');>> wrote: >> >>> OK, that seems to work. I copy&pasted the EchoKernel example but it >>> seems to stall (cell id turns to * and stays that way). Any way I can debug >>> this? print's don't seem to get shown. >>> >>> >>> On Mon, Jul 7, 2014 at 6:48 PM, Thomas Kluyver <takowl at gmail.com >>> <javascript:_e(%7B%7D,'cvml','takowl at gmail.com');>> wrote: >>> >>>> On 7 July 2014 11:41, Thomas Wiecki <thomas.wiecki at gmail.com >>>> <javascript:_e(%7B%7D,'cvml','thomas.wiecki at gmail.com');>> wrote: >>>> >>>>> Once I have the kernel.json, how can I launch an IPython NB with this >>>>> new kernel? Couldn't find a way to link to the json file. >>>> >>>> >>>> That part's not implemented yet - once it is, there will be a dropdown >>>> menu in the notebook UI to select kernels. For now, you need to start the >>>> notebook server with a long command like this: >>>> >>>> ipython notebook --KernelManager.kernel_cmd="['python', '-m', 'my_module']" >>>> >>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> <javascript:_e(%7B%7D,'cvml','IPython-dev at scipy.org');> >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> >>> -- >>> Thomas Wiecki >>> PhD candidate, Brown University >>> Quantitative Researcher, Quantopian Inc, Boston >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> <javascript:_e(%7B%7D,'cvml','IPython-dev at scipy.org');> >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> <javascript:_e(%7B%7D,'cvml','IPython-dev at scipy.org');> >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Thomas Wiecki > PhD candidate, Brown University > Quantitative Researcher, Quantopian Inc, Boston > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/7be2505b/attachment.html> From takowl at gmail.com Mon Jul 7 14:42:04 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 7 Jul 2014 13:42:04 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> Message-ID: <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> On 7 July 2014 13:34, Cyrille Rossant <cyrille.rossant at gmail.com> wrote: > I think you have to use ipython qtconsole --kernel ... No, it should work with ipython console as well. Thomas, are you using current master IPython on both sides? -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/6dc2c59f/attachment.html> From fperez.net at gmail.com Mon Jul 7 14:43:58 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 7 Jul 2014 13:43:58 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> Message-ID: <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> On Mon, Jul 7, 2014 at 1:42 PM, Thomas Kluyver <takowl at gmail.com> wrote: > No, it should work with ipython console as well. > > Thomas, are you using current master IPython on both sides? > I can reproduce the problem on master as well... Best f -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/3e18f806/attachment.html> From takowl at gmail.com Mon Jul 7 14:50:32 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 7 Jul 2014 13:50:32 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> Message-ID: <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> On 7 July 2014 13:43, Fernando Perez <fperez.net at gmail.com> wrote: > I can reproduce the problem on master as well... OK, so can I, in fact. I'll investigate later on, unless Min beats me to it. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/39d94a5d/attachment.html> From benjaminrk at gmail.com Mon Jul 7 15:06:12 2014 From: benjaminrk at gmail.com (MinRK) Date: Mon, 7 Jul 2014 14:06:12 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> Message-ID: <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> Race! Not sure what caused it, but the fix is here <https://github.com/ipython/ipython/pull/6092>. -MinRK ? On Mon, Jul 7, 2014 at 1:50 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 7 July 2014 13:43, Fernando Perez <fperez.net at gmail.com> wrote: > >> I can reproduce the problem on master as well... > > > OK, so can I, in fact. I'll investigate later on, unless Min beats me to > it. > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/ead5dbfe/attachment.html> From takowl at gmail.com Mon Jul 7 15:09:23 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 7 Jul 2014 14:09:23 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> Message-ID: <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> Well, debugging-by-invoking-Min succeeds again. ;-) On 7 July 2014 14:06, MinRK <benjaminrk at gmail.com> wrote: > Race! > > Not sure what caused it, but the fix is here > <https://github.com/ipython/ipython/pull/6092>. > > -MinRK > ? > > > On Mon, Jul 7, 2014 at 1:50 PM, Thomas Kluyver <takowl at gmail.com> wrote: > >> On 7 July 2014 13:43, Fernando Perez <fperez.net at gmail.com> wrote: >> >>> I can reproduce the problem on master as well... >> >> >> OK, so can I, in fact. I'll investigate later on, unless Min beats me to >> it. >> >> Thomas >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/fcbdfe92/attachment.html> From bjonen at gmail.com Mon Jul 7 15:27:31 2014 From: bjonen at gmail.com (bjonen) Date: Mon, 7 Jul 2014 12:27:31 -0700 (PDT) Subject: [IPython-dev] Getting the size of ipython notebook cell Message-ID: <1404761251524-5063264.post@n6.nabble.com> Hey giuys, I am working on a patch for pandas that allows a dataframe's string representation to scale with the height and width of the terminal. It would be nice to make this possible in the ipython notebook also. However, for this I would need a way to infer the current size of a cell in the notebook to cut the dataframe appropriately. Anybody know a way to do this? For completeness, here the link to the corresponding pandas issue: https://github.com/pydata/pandas/issues/7180#issuecomment-47335444 Thanks, Benjamin -- View this message in context: http://python.6.x6.nabble.com/Getting-the-size-of-ipython-notebook-cell-tp5063264.html Sent from the IPython - Development mailing list archive at Nabble.com. From takowl at gmail.com Mon Jul 7 15:35:27 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 7 Jul 2014 14:35:27 -0500 Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <1404761251524-5063264.post@n6.nabble.com> References: <1404761251524-5063264.post@n6.nabble.com> Message-ID: <CAOvn4qj7s69cEb6eSqU1WRNbbK8tWkFzuCQGDdRMHvchjfWmww@mail.gmail.com> On 7 July 2014 14:27, bjonen <bjonen at gmail.com> wrote: > I am working on a patch for pandas that allows a dataframe's string > representation to scale with the height and width of the terminal. > It would be nice to make this possible in the ipython notebook also. > However, for this I would need a way to infer the current size of a cell in > the notebook to cut the dataframe appropriately. > > Anybody know a way to do this? > There's certainly no practical way to do this at the moment, and I don't think we should add one. For instance, what if the user resizes their browser after displaying it? What if they share the notebook with people whose screens are bigger or smaller? I don't think trying to tailor the output to the screen size like that makes sense. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/e44579d7/attachment.html> From bussonniermatthias at gmail.com Mon Jul 7 15:37:51 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 7 Jul 2014 21:37:51 +0200 Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <1404761251524-5063264.post@n6.nabble.com> References: <1404761251524-5063264.post@n6.nabble.com> Message-ID: <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> Hi Benjamin, Le 7 juil. 2014 ? 21:27, bjonen a ?crit : > Hey giuys, > > I am working on a patch for pandas that allows a dataframe's string > representation to scale with the height and width of the terminal. > It would be nice to make this possible in the ipython notebook also. > However, for this I would need a way to infer the current size of a cell in > the notebook to cut the dataframe appropriately. > > Anybody know a way to do this? To add to thomas answer : As for anythings related to knowing something related to the frontend, it is not possible with IPython protocol. - The kernel does not know is is connected to a notebook. - The notebook can be run headless (width make no sense) - several notebook can window can be connected at the same give with live sync between them (so width not unique) [ might be anticipating tomorrow (today?) announcement as scipy] - Window can be resized .... - notebook displayed in nbviewer And so on, and so forth. The only thing you can try to if you want dynamic things is to use dynamic table with javascript/html. -- M > > For completeness, here the link to the corresponding pandas issue: > https://github.com/pydata/pandas/issues/7180#issuecomment-47335444 > > Thanks, > Benjamin > > > > -- > View this message in context: http://python.6.x6.nabble.com/Getting-the-size-of-ipython-notebook-cell-tp5063264.html > Sent from the IPython - Development mailing list archive at Nabble.com. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From fperez.net at gmail.com Mon Jul 7 15:39:25 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 7 Jul 2014 14:39:25 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> Message-ID: <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> don't tell him that! He's going to figure out how people think I'm actually a productive human being! :) On Mon, Jul 7, 2014 at 2:09 PM, Thomas Kluyver <takowl at gmail.com> wrote: > Well, debugging-by-invoking-Min succeeds again. ;-) > > > On 7 July 2014 14:06, MinRK <benjaminrk at gmail.com> wrote: > >> Race! >> >> Not sure what caused it, but the fix is here >> <https://github.com/ipython/ipython/pull/6092>. >> >> -MinRK >> ? >> >> >> On Mon, Jul 7, 2014 at 1:50 PM, Thomas Kluyver <takowl at gmail.com> wrote: >> >>> On 7 July 2014 13:43, Fernando Perez <fperez.net at gmail.com> wrote: >>> >>>> I can reproduce the problem on master as well... >>> >>> >>> OK, so can I, in fact. I'll investigate later on, unless Min beats me to >>> it. >>> >>> Thomas >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/b81fe53c/attachment.html> From thomas.wiecki at gmail.com Mon Jul 7 16:26:37 2014 From: thomas.wiecki at gmail.com (Thomas Wiecki) Date: Mon, 7 Jul 2014 22:26:37 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> Message-ID: <CAPcXcF13-wR_9zx6XrHM7PfW=b_3Upk0R7bDPDEG6_n2dMeWmw@mail.gmail.com> OK, after the fix the echo kernel works in console but the NB still stalls with [*]. Any pointers? On Mon, Jul 7, 2014 at 9:39 PM, Fernando Perez <fperez.net at gmail.com> wrote: > don't tell him that! He's going to figure out how people think I'm > actually a productive human being! :) > > > On Mon, Jul 7, 2014 at 2:09 PM, Thomas Kluyver <takowl at gmail.com> wrote: > >> Well, debugging-by-invoking-Min succeeds again. ;-) >> >> >> On 7 July 2014 14:06, MinRK <benjaminrk at gmail.com> wrote: >> >>> Race! >>> >>> Not sure what caused it, but the fix is here >>> <https://github.com/ipython/ipython/pull/6092>. >>> >>> -MinRK >>> ? >>> >>> >>> On Mon, Jul 7, 2014 at 1:50 PM, Thomas Kluyver <takowl at gmail.com> wrote: >>> >>>> On 7 July 2014 13:43, Fernando Perez <fperez.net at gmail.com> wrote: >>>> >>>>> I can reproduce the problem on master as well... >>>> >>>> >>>> OK, so can I, in fact. I'll investigate later on, unless Min beats me >>>> to it. >>>> >>>> Thomas >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Thomas Wiecki PhD candidate, Brown University Quantitative Researcher, Quantopian Inc, Boston -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/fc1a0826/attachment.html> From fperez.net at gmail.com Mon Jul 7 16:32:52 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 7 Jul 2014 15:32:52 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF13-wR_9zx6XrHM7PfW=b_3Upk0R7bDPDEG6_n2dMeWmw@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> <CAPcXcF13-wR_9zx6XrHM7PfW=b_3Upk0R7bDPDEG6_n2dMeWmw@mail.gmail.com> Message-ID: <CAHAreOog71MfZ4ic+ebBu1TzFE3xAZeiPjX9CRNsqh1__3R_iQ@mail.gmail.com> On Mon, Jul 7, 2014 at 3:26 PM, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > OK, after the fix the echo kernel works in console but the NB still stalls > with [*]. Any pointers? I can replicate the problem with the nb, but at least now the text console `ipython console` and the qtconsole do work. Perhaps you can move forward with either of those, while we sort out what's going on with the nb... f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/4982ffdf/attachment.html> From thomas.wiecki at gmail.com Mon Jul 7 16:36:43 2014 From: thomas.wiecki at gmail.com (Thomas Wiecki) Date: Mon, 7 Jul 2014 22:36:43 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAHAreOog71MfZ4ic+ebBu1TzFE3xAZeiPjX9CRNsqh1__3R_iQ@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> <CAPcXcF13-wR_9zx6XrHM7PfW=b_3Upk0R7bDPDEG6_n2dMeWmw@mail.gmail.com> <CAHAreOog71MfZ4ic+ebBu1TzFE3xAZeiPjX9CRNsqh1__3R_iQ@mail.gmail.com> Message-ID: <CAPcXcF2Mf39OJ0AVG6sWjBrKBU0pkzL8eYEOSYBvsC7zYnwuWg@mail.gmail.com> Sounds good -- let me know. Thanks for the help. On Mon, Jul 7, 2014 at 10:32 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Mon, Jul 7, 2014 at 3:26 PM, Thomas Wiecki <thomas.wiecki at gmail.com> > wrote: > >> OK, after the fix the echo kernel works in console but the NB still >> stalls with [*]. Any pointers? > > > I can replicate the problem with the nb, but at least now the text > console `ipython console` and the qtconsole do work. > > Perhaps you can move forward with either of those, while we sort out > what's going on with the nb... > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Thomas Wiecki PhD candidate, Brown University Quantitative Researcher, Quantopian Inc, Boston -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/2b674d80/attachment.html> From takowl at gmail.com Mon Jul 7 21:46:32 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 7 Jul 2014 20:46:32 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF2Mf39OJ0AVG6sWjBrKBU0pkzL8eYEOSYBvsC7zYnwuWg@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> <CAPcXcF13-wR_9zx6XrHM7PfW=b_3Upk0R7bDPDEG6_n2dMeWmw@mail.gmail.com> <CAHAreOog71MfZ4ic+ebBu1TzFE3xAZeiPjX9CRNsqh1__3R_iQ@mail.gmail.com> <CAPcXcF2Mf39OJ0AVG6sWjBrKBU0pkzL8eYEOSYBvsC7zYnwuWg@mail.gmail.com> Message-ID: <CAOvn4qhzxMvkc=Hg-Yx5mDzajdCwpZwFokKhxsJXy8-TYgUZtw@mail.gmail.com> Sorry, I gave an incomplete command in my previous link. kernel_cmd should be the same sequence of arguments you wrote in the kernel.json file, including the all-important {connection_file} parameter, which is replaced with the path to the connection file: ipython notebook --KernelManager.kernel_cmd="['python', '-m', 'my_module', '-f', '{connection_file}']" On 7 July 2014 15:36, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > Sounds good -- let me know. Thanks for the help. > > > On Mon, Jul 7, 2014 at 10:32 PM, Fernando Perez <fperez.net at gmail.com> > wrote: > >> >> On Mon, Jul 7, 2014 at 3:26 PM, Thomas Wiecki <thomas.wiecki at gmail.com> >> wrote: >> >>> OK, after the fix the echo kernel works in console but the NB still >>> stalls with [*]. Any pointers? >> >> >> I can replicate the problem with the nb, but at least now the text >> console `ipython console` and the qtconsole do work. >> >> Perhaps you can move forward with either of those, while we sort out >> what's going on with the nb... >> >> f >> >> >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Thomas Wiecki > PhD candidate, Brown University > Quantitative Researcher, Quantopian Inc, Boston > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/b9737042/attachment.html> From takowl at gmail.com Mon Jul 7 22:21:08 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 7 Jul 2014 21:21:08 -0500 Subject: [IPython-dev] (no subject) In-Reply-To: <CACBGWQaYEWafs2JdBDz7GfGXeDk8uEGkf2_7PY1__Orj68E5CA@mail.gmail.com> References: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> <CAOvn4qgFZ1ut88QpphyMB=mhto2+yVzQJ7QwFO5KJkHt1_L8TQ@mail.gmail.com> <CACBGWQZ1+91-D49sPKFPHa_b-Gyc5bv8fa1vvi1fgG8rrEn=Cg@mail.gmail.com> <CAOvn4qhHOXGddrH0QQrTj3cRM_myaNE0xkJyKG4FjwwCuR-+jg@mail.gmail.com> <CACBGWQaYEWafs2JdBDz7GfGXeDk8uEGkf2_7PY1__Orj68E5CA@mail.gmail.com> Message-ID: <CAOvn4qhzmxJZbA2Qe45t4gk+0kWjcmuiV4-gwG+emLnv20aTPg@mail.gmail.com> On 7 July 2014 04:12, Sjoerd de Vries <sjdv1982 at gmail.com> wrote: > - A hook to change the %alias formatter class from DollarFormatter (to >>> allow customized variable substitution) >>> - A hook in FullEvalFormatter._vformat to be triggered on certain >>> "conversion" values (for converters) >>> >> > What about these hooks, would they be OK? I can make a new branch with > just this, it's a dozen lines or less. > I guess I'm not entirely sure why we should add hooks from inside these classes - isn't it easier for you to subclass and override the relevant bits? We can look into breaking up the API if it makes sense, though. > - Additional optional arguments to interactiveshell methods "getoutput", >>> "system_piped" and "system_raw" (for variable substitution and stderr >>> capture) >>> >> >> I think an argument for stderr capture makes sense. For controlling >> variable substitution, it might be easier to go down a level, to the >> (similarly named) functions which they call after doing var_expand. >> > > Well, I can copy-paste "getoutput" and "system_piped" into my own > extension and make the necessary changes there, if that's best. > Let's brainstorm on APIs a bit, because I feel like we're swimming in process control APIs - subprocess, pexpect, our own process machinery in IPython.utils. It shouldn't be necessary to reinvent the wheel again. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140707/dede13ee/attachment.html> From thomas.wiecki at gmail.com Tue Jul 8 01:47:51 2014 From: thomas.wiecki at gmail.com (Thomas Wiecki) Date: Tue, 8 Jul 2014 07:47:51 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAOvn4qhzxMvkc=Hg-Yx5mDzajdCwpZwFokKhxsJXy8-TYgUZtw@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> <CAPcXcF13-wR_9zx6XrHM7PfW=b_3Upk0R7bDPDEG6_n2dMeWmw@mail.gmail.com> <CAHAreOog71MfZ4ic+ebBu1TzFE3xAZeiPjX9CRNsqh1__3R_iQ@mail.gmail.com> <CAPcXcF2Mf39OJ0AVG6sWjBrKBU0pkzL8eYEOSYBvsC7zYnwuWg@mail.gmail.com> <CAOvn4qhzxMvkc=Hg-Yx5mDzajdCwpZwFokKhxsJXy8-TYgUZtw@mail.gmail.com> Message-ID: <CAPcXcF2-n6E+OjC7-FJ3_SYZze0m1DZCJWjaJY2M66HAe-HWuA@mail.gmail.com> Thanks, that works. On Tue, Jul 8, 2014 at 3:46 AM, Thomas Kluyver <takowl at gmail.com> wrote: > Sorry, I gave an incomplete command in my previous link. kernel_cmd should > be the same sequence of arguments you wrote in the kernel.json file, > including the all-important {connection_file} parameter, which is replaced > with the path to the connection file: > > ipython notebook --KernelManager.kernel_cmd="['python', '-m', 'my_module', '-f', '{connection_file}']" > > > > > On 7 July 2014 15:36, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > >> Sounds good -- let me know. Thanks for the help. >> >> >> On Mon, Jul 7, 2014 at 10:32 PM, Fernando Perez <fperez.net at gmail.com> >> wrote: >> >>> >>> On Mon, Jul 7, 2014 at 3:26 PM, Thomas Wiecki <thomas.wiecki at gmail.com> >>> wrote: >>> >>>> OK, after the fix the echo kernel works in console but the NB still >>>> stalls with [*]. Any pointers? >>> >>> >>> I can replicate the problem with the nb, but at least now the text >>> console `ipython console` and the qtconsole do work. >>> >>> Perhaps you can move forward with either of those, while we sort out >>> what's going on with the nb... >>> >>> f >>> >>> >>> -- >>> Fernando Perez (@fperez_org; http://fperez.org) >>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >>> fernando.perez-at-berkeley: contact me here for any direct mail >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> >> -- >> Thomas Wiecki >> PhD candidate, Brown University >> Quantitative Researcher, Quantopian Inc, Boston >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Thomas Wiecki PhD candidate, Brown University Quantitative Researcher, Quantopian Inc, Boston -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/d7ee20df/attachment.html> From dave.hirschfeld at gmail.com Tue Jul 8 02:54:19 2014 From: dave.hirschfeld at gmail.com (Dave Hirschfeld) Date: Tue, 8 Jul 2014 06:54:19 +0000 (UTC) Subject: [IPython-dev] ipython trust mynotebook doesn't work References: <loom.20140707T173557-977@post.gmane.org> <CAHAreOo+oL8YfLqUQUjX1wQ2tvztzHyYxLKz7p5krG15FdX_HQ@mail.gmail.com> Message-ID: <loom.20140708T085135-573@post.gmane.org> Fernando Perez <fperez.net <at> gmail.com> writes: > > > Hi Dave, > there seems to be an issue with the trust command, it was just reported on the tracker: > > > https://github.com/ipython/ipython/issues/6091 > > > In the meantime, can you try?using the "trust this notebook" dialog in the file menu? Please let us know if that helps... > > Best > > > f > I can confirm that I was having the same issue as in #6091 - signing the notebook *with the profile running the notebook server* solved the problem for me. I do think #6094 is an important improvement to the docs. Thanks for your help! -Dave From bjonen at gmail.com Tue Jul 8 03:34:47 2014 From: bjonen at gmail.com (bjonen) Date: Tue, 8 Jul 2014 00:34:47 -0700 (PDT) Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> References: <1404761251524-5063264.post@n6.nabble.com> <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> Message-ID: <1404804887295-5063344.post@n6.nabble.com> Thanks for the replies! > The only thing you can try to if you want dynamic things is to use dynamic > table with javascript/html. You mean allowing the user to resize the dataframe? Benjamin -- View this message in context: http://python.6.x6.nabble.com/Getting-the-size-of-ipython-notebook-cell-tp5063264p5063344.html Sent from the IPython - Development mailing list archive at Nabble.com. From bussonniermatthias at gmail.com Tue Jul 8 03:57:51 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 8 Jul 2014 09:57:51 +0200 Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <1404804887295-5063344.post@n6.nabble.com> References: <1404761251524-5063264.post@n6.nabble.com> <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> <1404804887295-5063344.post@n6.nabble.com> Message-ID: <9F241A5C-A273-4699-AFD5-83268AFE0FEE@gmail.com> Envoy? de mon iPhone > Le 8 juil. 2014 ? 09:34, bjonen <bjonen at gmail.com> a ?crit : > > Thanks for the replies! > >> The only thing you can try to if you want dynamic things is to use dynamic >> table with javascript/html. > > You mean allowing the user to resize the dataframe? For example. Or use @media-query that change the style of the df depending on browser window size. Have a look at bootstrap doc for example. > > Benjamin > > > > -- > View this message in context: http://python.6.x6.nabble.com/Getting-the-size-of-ipython-notebook-cell-tp5063264p5063344.html > Sent from the IPython - Development mailing list archive at Nabble.com. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From sjdv1982 at gmail.com Tue Jul 8 04:25:50 2014 From: sjdv1982 at gmail.com (Sjoerd de Vries) Date: Tue, 8 Jul 2014 10:25:50 +0200 Subject: [IPython-dev] (no subject) In-Reply-To: <CAOvn4qhzmxJZbA2Qe45t4gk+0kWjcmuiV4-gwG+emLnv20aTPg@mail.gmail.com> References: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> <CAOvn4qgFZ1ut88QpphyMB=mhto2+yVzQJ7QwFO5KJkHt1_L8TQ@mail.gmail.com> <CACBGWQZ1+91-D49sPKFPHa_b-Gyc5bv8fa1vvi1fgG8rrEn=Cg@mail.gmail.com> <CAOvn4qhHOXGddrH0QQrTj3cRM_myaNE0xkJyKG4FjwwCuR-+jg@mail.gmail.com> <CACBGWQaYEWafs2JdBDz7GfGXeDk8uEGkf2_7PY1__Orj68E5CA@mail.gmail.com> <CAOvn4qhzmxJZbA2Qe45t4gk+0kWjcmuiV4-gwG+emLnv20aTPg@mail.gmail.com> Message-ID: <CACBGWQZWEYwpcZJYpxgihZKs5pdCL14bh-rGYG72NCgxAqRd6w@mail.gmail.com> On Jul 8, 2014 4:22 AM, "Thomas Kluyver" <takowl at gmail.com> wrote: > > On 7 July 2014 04:12, Sjoerd de Vries <sjdv1982 at gmail.com> wrote: >>>> >>>> - A hook to change the %alias formatter class from DollarFormatter (to allow customized variable substitution) >>>> - A hook in FullEvalFormatter._vformat to be triggered on certain "conversion" values (for converters) >> >> >> What about these hooks, would they be OK? I can make a new branch with just this, it's a dozen lines or less. > > > I guess I'm not entirely sure why we should add hooks from inside these classes - isn't it easier for you to subclass and override the relevant bits? We can look into breaking up the API if it makes sense, though. > >>>> >>>> - Additional optional arguments to interactiveshell methods "getoutput", "system_piped" and "system_raw" (for variable substitution and stderr capture) >>> >>> >>> I think an argument for stderr capture makes sense. For controlling variable substitution, it might be easier to go down a level, to the (similarly named) functions which they call after doing var_expand. >> >> >> Well, I can copy-paste "getoutput" and "system_piped" into my own extension and make the necessary changes there, if that's best. > > > Let's brainstorm on APIs a bit, because I feel like we're swimming in process control APIs - subprocess, pexpect, our own process machinery in IPython.utils. It shouldn't be necessary to reinvent the wheel again. > > Thanks, > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > OK, I will create a new branch with just the hooks and a few usage examples. In the process, I will test if a hook is really needed or if the same result can be obtained with subclasses within the extension. Cheers Sjoerd -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/eee6a1cd/attachment.html> From thomas.wiecki at gmail.com Tue Jul 8 05:22:46 2014 From: thomas.wiecki at gmail.com (Thomas Wiecki) Date: Tue, 8 Jul 2014 11:22:46 +0200 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF2-n6E+OjC7-FJ3_SYZze0m1DZCJWjaJY2M66HAe-HWuA@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> <CAPcXcF13-wR_9zx6XrHM7PfW=b_3Upk0R7bDPDEG6_n2dMeWmw@mail.gmail.com> <CAHAreOog71MfZ4ic+ebBu1TzFE3xAZeiPjX9CRNsqh1__3R_iQ@mail.gmail.com> <CAPcXcF2Mf39OJ0AVG6sWjBrKBU0pkzL8eYEOSYBvsC7zYnwuWg@mail.gmail.com> <CAOvn4qhzxMvkc=Hg-Yx5mDzajdCwpZwFokKhxsJXy8-TYgUZtw@mail.gmail.com> <CAPcXcF2-n6E+OjC7-FJ3_SYZze0m1DZCJWjaJY2M66HAe-HWuA@mail.gmail.com> Message-ID: <CAPcXcF2yhhEDyNCFWA8EtOp_wgayTpG73TCXShddLnwqwxV5-Q@mail.gmail.com> The IPython console works well now. However, using the NB client and sending: self.send_response(self.iopub_socket, 'stream', stream_content) and then returning: return {'status': 'error', 'ename': 'foo', 'evalue': 'bar', 'traceback': messages, 'execution_count': self.execution_count, } Do not display anything in the NB (they do both show up in the console). The cell does not get executed so I think it's executing the correct path. Any ideas? Also, since I want to use a Python kernel I'm inheriting from IPythonKernel. Might that be the problem? I suspect there would be a NotebookKernel (that also supports the magics, which currently give me a syntaxi error) that I can't find. On Tue, Jul 8, 2014 at 7:47 AM, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > Thanks, that works. > > > On Tue, Jul 8, 2014 at 3:46 AM, Thomas Kluyver <takowl at gmail.com> wrote: > >> Sorry, I gave an incomplete command in my previous link. kernel_cmd >> should be the same sequence of arguments you wrote in the kernel.json file, >> including the all-important {connection_file} parameter, which is replaced >> with the path to the connection file: >> >> ipython notebook --KernelManager.kernel_cmd="['python', '-m', 'my_module', '-f', '{connection_file}']" >> >> >> >> >> On 7 July 2014 15:36, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: >> >>> Sounds good -- let me know. Thanks for the help. >>> >>> >>> On Mon, Jul 7, 2014 at 10:32 PM, Fernando Perez <fperez.net at gmail.com> >>> wrote: >>> >>>> >>>> On Mon, Jul 7, 2014 at 3:26 PM, Thomas Wiecki <thomas.wiecki at gmail.com> >>>> wrote: >>>> >>>>> OK, after the fix the echo kernel works in console but the NB still >>>>> stalls with [*]. Any pointers? >>>> >>>> >>>> I can replicate the problem with the nb, but at least now the text >>>> console `ipython console` and the qtconsole do work. >>>> >>>> Perhaps you can move forward with either of those, while we sort out >>>> what's going on with the nb... >>>> >>>> f >>>> >>>> >>>> -- >>>> Fernando Perez (@fperez_org; http://fperez.org) >>>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >>>> fernando.perez-at-berkeley: contact me here for any direct mail >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> >>> -- >>> Thomas Wiecki >>> PhD candidate, Brown University >>> Quantitative Researcher, Quantopian Inc, Boston >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Thomas Wiecki > PhD candidate, Brown University > Quantitative Researcher, Quantopian Inc, Boston > -- Thomas Wiecki PhD candidate, Brown University Quantitative Researcher, Quantopian Inc, Boston -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/900db5f9/attachment.html> From takowl at gmail.com Tue Jul 8 09:45:01 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 8 Jul 2014 08:45:01 -0500 Subject: [IPython-dev] Static code analysis of IPython Notebook cell In-Reply-To: <CAPcXcF2yhhEDyNCFWA8EtOp_wgayTpG73TCXShddLnwqwxV5-Q@mail.gmail.com> References: <CAPcXcF38p1U-eVB8cd4c6yDGJjx57otB4zcPjb1H3b4Q35P9Wg@mail.gmail.com> <CAOvn4qi+OFX0iQMMB=sst+YaCUk+8fS=Ovr=0zwFSpNcQZGqAw@mail.gmail.com> <CAPcXcF369QP5rH-t_vvoGqfLnzSzyS5mj4Fj774ZqKsHa43gsw@mail.gmail.com> <CAOvn4qhaHbRdTDyHRCJ_GVB8b0VMjeh9wSmD3oafQvwv9cUYxg@mail.gmail.com> <CAPcXcF3Zd4Wb9N_UYEgw+rm78WWUvJtXDX5WnFpWfdbrEHp=Mg@mail.gmail.com> <CAHAreOpgM=HBiMzTJqLNPO3LLTGkXrueLj1qoWPfp+Yby2JXiA@mail.gmail.com> <CAPcXcF2ho6OzreDt9O9EqaJ4GsfMaRE5t0ey6-kkG7+-ETrXyA@mail.gmail.com> <CA+-1RQSdXAwehA2-8EfDcobcJkMbFOcUdpjgDeUHBMx0qZe+wA@mail.gmail.com> <CAOvn4qirMNmx++=r=-wPCnhnr==P++rsvqs0Brj13ZHes-FPgg@mail.gmail.com> <CAHAreOoT8OqTpoTvOuRmQW+o07qdjqNMT3GV=7bcGoRM=r6QQw@mail.gmail.com> <CAOvn4qitv+=ULDea=nJ=M8Z_BaTWqaaLhcTqsL_qw6pgDCiN=g@mail.gmail.com> <CAHNn8BXk2gCpg40GBGEf84esLOGCQfFoGZoGXK11uowsi_G5hw@mail.gmail.com> <CAOvn4qi_7YWgMZYCLXss5URhanJe+njdU-9Ajj3OhJK+RJwu7Q@mail.gmail.com> <CAHAreOqCWhsSW2JOSuT9k4rBOdF9QSZzQLbhwNM62PzXvwfGhw@mail.gmail.com> <CAPcXcF13-wR_9zx6XrHM7PfW=b_3Upk0R7bDPDEG6_n2dMeWmw@mail.gmail.com> <CAHAreOog71MfZ4ic+ebBu1TzFE3xAZeiPjX9CRNsqh1__3R_iQ@mail.gmail.com> <CAPcXcF2Mf39OJ0AVG6sWjBrKBU0pkzL8eYEOSYBvsC7zYnwuWg@mail.gmail.com> <CAOvn4qhzxMvkc=Hg-Yx5mDzajdCwpZwFokKhxsJXy8-TYgUZtw@mail.gmail.com> <CAPcXcF2-n6E+OjC7-FJ3_SYZze0m1DZCJWjaJY2M66HAe-HWuA@mail.gmail.com> <CAPcXcF2yhhEDyNCFWA8EtOp_wgayTpG73TCXShddLnwqwxV5-Q@mail.gmail.com> Message-ID: <CAOvn4qgvzbtkw-M+Le=4uN4xUs-TjFMqR+xHyVAt+F+_MWwung@mail.gmail.com> On 8 July 2014 04:22, Thomas Wiecki <thomas.wiecki at gmail.com> wrote: > The IPython console works well now. However, using the NB client and > sending: > self.send_response(self.iopub_socket, 'stream', stream_content) > What is stream_content? Can you show a runnable example? > Also, since I want to use a Python kernel I'm inheriting from > IPythonKernel. Might that be the problem? I suspect there would be a > NotebookKernel (that also supports the magics, which currently give me a > syntaxi error) that I can't find. No, there's only one IPython kernel class - the magics work the same way in every frontend. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/c48b3c8f/attachment.html> From bjonen at gmail.com Tue Jul 8 10:10:55 2014 From: bjonen at gmail.com (bjonen) Date: Tue, 8 Jul 2014 07:10:55 -0700 (PDT) Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <9F241A5C-A273-4699-AFD5-83268AFE0FEE@gmail.com> References: <1404761251524-5063264.post@n6.nabble.com> <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> <1404804887295-5063344.post@n6.nabble.com> <9F241A5C-A273-4699-AFD5-83268AFE0FEE@gmail.com> Message-ID: <1404828655658-5063400.post@n6.nabble.com> I see, that's an interesting idea. So I guess one way to get this to work would be to perform the truncation using javascript depending on the screen size information gathered from @media screen. Right now, pandas returns the html code for the table, as such: u'<div style="max-height:1000px;max-width:1500px;overflow:auto;">\n \n \n \n \n .... Could we simply prepend a <script> block with the necessary javascript? -- View this message in context: http://python.6.x6.nabble.com/Getting-the-size-of-ipython-notebook-cell-tp5063264p5063400.html Sent from the IPython - Development mailing list archive at Nabble.com. From bussonniermatthias at gmail.com Tue Jul 8 12:46:46 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 8 Jul 2014 18:46:46 +0200 Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <1404828655658-5063400.post@n6.nabble.com> References: <1404761251524-5063264.post@n6.nabble.com> <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> <1404804887295-5063344.post@n6.nabble.com> <9F241A5C-A273-4699-AFD5-83268AFE0FEE@gmail.com> <1404828655658-5063400.post@n6.nabble.com> Message-ID: <155F2467-EFE0-4926-8390-ED19EFDCD9CD@gmail.com> Le 8 juil. 2014 ? 16:10, bjonen a ?crit : > I see, that's an interesting idea. So I guess one way to get this to work > would be to perform the truncation using javascript depending on the screen > size information gathered from @media screen. Truncation is never a good idea, you will always get the truncation wrong in some cases. > > Right now, pandas returns the html code for the table, as such: > u'<div style="max-height:1000px;max-width:1500px;overflow:auto;">\n > \n \n > \n \n > .... > > Could we simply prepend a <script> block with the necessary javascript? Javascript it not totally an answer either, you will/might not be able to listen for a resize event. I would investigate pure css stuff like that : https://css-tricks.com/examples/ResponsiveTables/responsive.php and use bootstrap responsive utilities: http://getbootstrap.com/css/#responsive-utilities If you really want responsive table with dynamism and javascript I would suggest doing it in separate package like mpld3 does for matplotlib, or cyrile rossant handson table. http://nbviewer.ipython.org/gist/rossant/9463955 Publishing scripts tag is always brittle and unreliable. -- M > > > > -- > View this message in context: http://python.6.x6.nabble.com/Getting-the-size-of-ipython-notebook-cell-tp5063264p5063400.html > Sent from the IPython - Development mailing list archive at Nabble.com. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From wstein at gmail.com Tue Jul 8 13:31:46 2014 From: wstein at gmail.com (William Stein) Date: Tue, 8 Jul 2014 10:31:46 -0700 Subject: [IPython-dev] ijulia? Message-ID: <CACLE5GDudtHNhivKxQCBodjvF-A0GHDfW4hCwj1rJmje6J85+w@mail.gmail.com> Hi, I keep getting requests for IJulia (https://github.com/JuliaLang/IJulia.jl) support in SageMathCloud. However, all my many attempts to get anywhere with IJulia so far have completely failed, and I have no clue even how to successfully install it. I've tried the directions, which all seem to work with no errors. However, the end result is that things just don't work at all. In particular, despite IPython claiming to load with the 'julia' profile, it's still just plain ipython (in julia ans would be 2 below): ~/salvus/salvus$ ipython console --profile julia Python 2.7.5 (default, May 5 2014, 17:28:45) Type "copyright", "credits" or "license" for more information. IPython 2.1.0 -- An enhanced Interactive Python. IPython profile: julia In [1]: 2 Out[1]: 2 In [2]: ans --------------------------------------------------------------------------- NameError Traceback (most recent call last) QUESTION: Does anybody reading this use IJulia? Is it even supposed to work with IPython 2.1? -- William -- William Stein Professor of Mathematics University of Washington http://wstein.org From bussonniermatthias at gmail.com Tue Jul 8 13:44:07 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 8 Jul 2014 19:44:07 +0200 Subject: [IPython-dev] ijulia? In-Reply-To: <CACLE5GDudtHNhivKxQCBodjvF-A0GHDfW4hCwj1rJmje6J85+w@mail.gmail.com> References: <CACLE5GDudtHNhivKxQCBodjvF-A0GHDfW4hCwj1rJmje6J85+w@mail.gmail.com> Message-ID: <B3D16462-DF0D-4263-8FA4-C8529C00DDA7@gmail.com> It does work in here. You need to install IJulia from within a Julia repl. > Pkg.add('IJulia') IJulia should create the julia profile by itself during the install. IIRC you can use > Pkg.build('IJulia') to be sure. you can then start ipython --profile=julia with --debug flag to get more info : in particular you want line like : [ZMQTerminalIPythonApp] {'BaseIPythonApplication': {'profile': 'julia'}, 'Application': {'log_level': 10}, 'KernelManager': {'kernel_cmd': ['~/julia/usr/bin/julia', '-F', '~/.julia/IJulia/src/kernel.jl', '{connection_file}'] }} below is the full output for me (in IPython 3.0): -- M $ ipython console --profile=julia --debug [ZMQTerminalIPythonApp] Config changed: [ZMQTerminalIPythonApp] {'BaseIPythonApplication': {'profile': 'julia'}, 'Application': {'log_level': 10}} [ZMQTerminalIPythonApp] IPYTHONDIR set to: /Users/bussonniermatthias/.ipython [ZMQTerminalIPythonApp] Using existing profile dir: '/Users/bussonniermatthias/.ipython/profile_julia' [ZMQTerminalIPythonApp] Searching path ['/Users/bussonniermatthias/dissertation', '/Users/bussonniermatthias/.ipython/profile_julia'] for config files [ZMQTerminalIPythonApp] Attempting to load config file: ipython_config.py [ZMQTerminalIPythonApp] Loaded config file: /Users/bussonniermatthias/.ipython/profile_julia/ipython_config.py [ZMQTerminalIPythonApp] Config changed: [ZMQTerminalIPythonApp] {'BaseIPythonApplication': {'profile': 'julia'}, 'Application': {'log_level': 10}, 'KernelManager': {'kernel_cmd': ['/Users/bussonniermatthias/julia/usr/bin/julia', '-F', '/Users/bussonniermatthias/.julia/IJulia/src/kernel.jl', '{connection_file}']}} [ZMQTerminalIPythonApp] Attempting to load config file: ipython_console_config.py [ZMQTerminalIPythonApp] Connection File not found: /Users/bussonniermatthias/.ipython/profile_julia/security/kernel-43123.json /Users/bussonniermatthias/ipython/IPython/kernel/manager.py:87: UserWarning: Setting kernel_cmd is deprecated, use kernel_spec to start different kernels. # you shouldn't get that in 2.0. warnings.warn("Setting kernel_cmd is deprecated, use kernel_spec to " [ZMQTerminalIPythonApp] Connecting to: tcp://127.0.0.1:51318 [ZMQTerminalIPythonApp] connecting shell channel to tcp://127.0.0.1:51315 [ZMQTerminalIPythonApp] connecting iopub channel to tcp://127.0.0.1:51316 [ZMQTerminalIPythonApp] connecting stdin channel to tcp://127.0.0.1:51317 [ZMQTerminalIPythonApp] connecting heartbeat channel to tcp://127.0.0.1:51319 IPython Console 3.0.0-dev IPython profile: julia [ZMQTerminalIPythonApp] Loading IPython extensions... [ZMQTerminalIPythonApp] Loading IPython extension: storemagic [ZMQTerminalIPythonApp] Starting IPython's mainloop... Starting kernel event loops. In [1]: 2 Out[1]: 2 In [2]: ans Out[2]: 2 In [3]: Le 8 juil. 2014 ? 19:31, William Stein a ?crit : > Hi, > > I keep getting requests for IJulia > (https://github.com/JuliaLang/IJulia.jl) support in SageMathCloud. > > However, all my many attempts to get anywhere with IJulia so far have > completely failed, and I have no clue even how to successfully install > it. I've tried the directions, which all seem to work with no errors. > However, the end result is that things just don't work at all. In > particular, despite IPython claiming to load with the 'julia' profile, > it's still just plain ipython (in julia ans would be 2 below): > > ~/salvus/salvus$ ipython console --profile julia > Python 2.7.5 (default, May 5 2014, 17:28:45) > Type "copyright", "credits" or "license" for more information. > IPython 2.1.0 -- An enhanced Interactive Python. > IPython profile: julia > In [1]: 2 > Out[1]: 2 > In [2]: ans > --------------------------------------------------------------------------- > NameError Traceback (most recent call last) > > > > QUESTION: Does anybody reading this use IJulia? Is it even supposed > to work with IPython 2.1? > > -- William > > > -- > William Stein > Professor of Mathematics > University of Washington > http://wstein.org > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From takowl at gmail.com Tue Jul 8 16:16:52 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 8 Jul 2014 15:16:52 -0500 Subject: [IPython-dev] Public-domain browser terminal interface Message-ID: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> The terminal-in-the-browser libraries we've previously looked at (shell-in-a-box and GateOne) are GPL/AGPL licensed, which made us very wary of doing anything with them. I've just found ajaxterm, which is in the public domain, so we could use it freely. It doesn't look very actively maintained, but the server side is about 600 lines of Python, so we could easily understand it and fix problems as we encounter them: https://github.com/antonylesuisse/qweb/blob/master/ajaxterm/ajaxterm.py This came up in a talk about GraphTerm, which is an interesting project doing some of the same things we're doing. It includes inline display of graphical output, and can load and save our notebooks - it has a concept of a 'progressively fillable notebook', which contains hidden solutions which are visible to students after they submit their own solution. http://code.mindmeldr.com/graphterm/ Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/2af5ce08/attachment.html> From fperez.net at gmail.com Tue Jul 8 16:25:40 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 8 Jul 2014 15:25:40 -0500 Subject: [IPython-dev] Public-domain browser terminal interface In-Reply-To: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> References: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> Message-ID: <CAHAreOqBtAD-N-3oWUDH9wFnCgi-Yc3UnhRni3ouD=sGHcUmDg@mail.gmail.com> Didn't William mention a link to a BSD/MIT one somewhere? On Tue, Jul 8, 2014 at 3:16 PM, Thomas Kluyver <takowl at gmail.com> wrote: > The terminal-in-the-browser libraries we've previously looked at > (shell-in-a-box and GateOne) are GPL/AGPL licensed, which made us very wary > of doing anything with them. I've just found ajaxterm, which is in the > public domain, so we could use it freely. It doesn't look very actively > maintained, but the server side is about 600 lines of Python, so we could > easily understand it and fix problems as we encounter them: > > https://github.com/antonylesuisse/qweb/blob/master/ajaxterm/ajaxterm.py > > This came up in a talk about GraphTerm, which is an interesting project > doing some of the same things we're doing. It includes inline display of > graphical output, and can load and save our notebooks - it has a concept of > a 'progressively fillable notebook', which contains hidden solutions which > are visible to students after they submit their own solution. > > http://code.mindmeldr.com/graphterm/ > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/20143b01/attachment.html> From wstein at gmail.com Tue Jul 8 16:26:37 2014 From: wstein at gmail.com (William Stein) Date: Tue, 8 Jul 2014 13:26:37 -0700 Subject: [IPython-dev] Public-domain browser terminal interface In-Reply-To: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> References: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> Message-ID: <CACLE5GCsu1p5ZSP+rpKhY+DawSy4-5m76naujQMNOjYbO3MnVg@mail.gmail.com> On Tue, Jul 8, 2014 at 1:16 PM, Thomas Kluyver <takowl at gmail.com> wrote: > The terminal-in-the-browser libraries we've previously looked at > (shell-in-a-box and GateOne) are GPL/AGPL licensed, which made us very wary > of doing anything with them. I've just found ajaxterm, which is in the What about term.js? It's MIT licensed (partly due to me asking nicely), and is what many online IDE projects (including SageMathCloud) use: https://github.com/chjj/term.js/ Maybe it isn't an option for you because the backend is Node.js instead of Python. I just wanted to double check, just in case. Regarding term.js -- I've written code for theming term.js with color schemes, added a scrollbar, etc.. I'm willing to share it, and other changes I've made to term.js, but right now I don't want to spend time doing so, beyond handing a pile of code to somebody if there is interest. You can try term.js by just creating a terminal in SageMathCloud. Also, be sure to try changing terminal settings under account settings. > public domain, so we could use it freely. It doesn't look very actively > maintained, but the server side is about 600 lines of Python, so we could > easily understand it and fix problems as we encounter them: > > https://github.com/antonylesuisse/qweb/blob/master/ajaxterm/ajaxterm.py I have the strong impression -- starting with the name and timeframe -- that ajaxterm doesn't use websockets. It's basically from before the modern era of websockets. So if you use it, you'll have to rewrite it to use websockets, since websockets are a massive improvement over AJAX. -- William > > This came up in a talk about GraphTerm, which is an interesting project > doing some of the same things we're doing. It includes inline display of > graphical output, and can load and save our notebooks - it has a concept of > a 'progressively fillable notebook', which contains hidden solutions which > are visible to students after they submit their own solution. > > http://code.mindmeldr.com/graphterm/ > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- William Stein Professor of Mathematics University of Washington http://wstein.org From fperez.net at gmail.com Tue Jul 8 16:31:42 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 8 Jul 2014 15:31:42 -0500 Subject: [IPython-dev] Public-domain browser terminal interface In-Reply-To: <CACLE5GCsu1p5ZSP+rpKhY+DawSy4-5m76naujQMNOjYbO3MnVg@mail.gmail.com> References: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> <CACLE5GCsu1p5ZSP+rpKhY+DawSy4-5m76naujQMNOjYbO3MnVg@mail.gmail.com> Message-ID: <CAHAreOrsYkyficMxW5b-qQQLEVcgJNO5=FdfhL-PDpGR+qUKhg@mail.gmail.com> On Tue, Jul 8, 2014 at 3:26 PM, William Stein <wstein at gmail.com> wrote: > What about term.js? It's MIT licensed (partly due to me asking > nicely), and is what many online IDE projects (including > SageMathCloud) use: > > https://github.com/chjj/term.js/ > Thanks, that's the link I had in mind!! > Maybe it isn't an option for you because the backend is Node.js > instead of Python. I just wanted to double check, just in case. > Not a problem at all. We're thinking of this for the multiuser server, which has a Node component as well, so it's perfect. We might take you up on your 'pile of code' offer later, but we'll let you know if we have the bandwidth for it. To start with, we'll probably be OK with the plain vanilla code as-is. Thanks again! f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/7059ed1f/attachment.html> From wstein at gmail.com Tue Jul 8 16:42:23 2014 From: wstein at gmail.com (William Stein) Date: Tue, 8 Jul 2014 13:42:23 -0700 Subject: [IPython-dev] Public-domain browser terminal interface In-Reply-To: <CAHAreOrsYkyficMxW5b-qQQLEVcgJNO5=FdfhL-PDpGR+qUKhg@mail.gmail.com> References: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> <CACLE5GCsu1p5ZSP+rpKhY+DawSy4-5m76naujQMNOjYbO3MnVg@mail.gmail.com> <CAHAreOrsYkyficMxW5b-qQQLEVcgJNO5=FdfhL-PDpGR+qUKhg@mail.gmail.com> Message-ID: <CACLE5GBfDfV4aZMtErwMXNYORUMfmtqft0zOiYwu=DaUPGLbgQ@mail.gmail.com> On Tue, Jul 8, 2014 at 1:31 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Tue, Jul 8, 2014 at 3:26 PM, William Stein <wstein at gmail.com> wrote: >> >> What about term.js? It's MIT licensed (partly due to me asking >> nicely), and is what many online IDE projects (including >> SageMathCloud) use: >> >> https://github.com/chjj/term.js/ > > > Thanks, that's the link I had in mind!! > >> >> Maybe it isn't an option for you because the backend is Node.js >> instead of Python. I just wanted to double check, just in case. > > > Not a problem at all. We're thinking of this for the multiuser server, which > has a Node component as well, so it's perfect. > > We might take you up on your 'pile of code' offer later, but we'll let you > know if we have the bandwidth for it. To start with, we'll probably be OK > with the plain vanilla code as-is. > > Thanks again! One particular thing I added was resizing the backend pty in response to changing the terminal size. This involved a little bit of new tricky node.js code. It works in node 0.8.x, but didn't work _last time I tried_ with Node 0.10.x, which is why all SageMathCloud projects are still running 0.8.x. Anyway, if you guys go with term.js you'll inevitably run into the same issue, so keep me posted. -- W/illiam > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- William Stein Professor of Mathematics University of Washington http://wstein.org From gundalav at gmail.com Tue Jul 8 20:46:41 2014 From: gundalav at gmail.com (Gundala Viswanath) Date: Wed, 9 Jul 2014 09:46:41 +0900 Subject: [IPython-dev] Enabling Author Insertion During Latex-PDF conversion in IPython 2.1 Message-ID: <CADVKSzx66ChFx23D1r2Q83Z9eS7TqjMvsdUOp+btcKOHp+EeyA@mail.gmail.com> I have the following Ipynb file: https://gist.github.com/anonymous/6ed30142e2e68e9cd1a9 With this command: $ ipython nbconvert --to latex --post PDF --SphinxTransformer.author="John Doe" Untitled1.ipynb I hoped that the author could be automatically inserted in the final PDF. But it doesn't seem to work. What's the way to go about it? - G.V. From chenjandrew at gmail.com Tue Jul 8 22:42:18 2014 From: chenjandrew at gmail.com (Andrew Chen) Date: Tue, 8 Jul 2014 19:42:18 -0700 Subject: [IPython-dev] running multiple cells simultaneously Message-ID: <CADxNwqHrjnvxbFy_FO1-Ox0gJ8OExPM9jnFqeHKoTSDbt30cwA@mail.gmail.com> I?m interested in being able to run mutiple ipython notebook cells simultaneously: for example, to run a loop in once cell, and use another loop with interactive widgets to tune some parameter of the loop in the first cell. I am aware of the ipython.parallel, but this seems doesn?t seem perfectly relevant because the parallel interface is still a blocking REPL loop. The interaction (as I understand it) is ?read - EvaluateOnSeparateProcesses/Kernels - PrintAllResultsFromProcesses?, where I am interested in essentially being able to have ?read-evaluate?.<switch to a different cell> read-evaluate-print <switch back>... print?. I also tried to use standard python threads, and attempted to use the advice from this thread to redirect the cell output: http://stackoverflow.com/questions/14393989/per-cell-output-for-threaded-ipython-notebooks however, it did not work as advertised, and threads have a nasty habit of being difficult to debug. I?m curious if this is possible, and what I would need to do/look at to enable this functionality. Thanks, Andrew -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/77a527a3/attachment.html> From doug.blank at gmail.com Tue Jul 8 23:04:18 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 8 Jul 2014 23:04:18 -0400 Subject: [IPython-dev] running multiple cells simultaneously In-Reply-To: <CADxNwqHrjnvxbFy_FO1-Ox0gJ8OExPM9jnFqeHKoTSDbt30cwA@mail.gmail.com> References: <CADxNwqHrjnvxbFy_FO1-Ox0gJ8OExPM9jnFqeHKoTSDbt30cwA@mail.gmail.com> Message-ID: <CAAusYCjM=QPNjiQPjcegx_NunHd4fqHR2E-XhZA5GaNTEk3O0Q@mail.gmail.com> On Tue, Jul 8, 2014 at 10:42 PM, Andrew Chen <chenjandrew at gmail.com> wrote: > I?m interested in being able to run mutiple ipython notebook cells > simultaneously: for example, to run a loop in once cell, and use another > loop with interactive widgets to tune some parameter of the loop in the > first cell. > > I am aware of the ipython.parallel, but this seems doesn?t seem perfectly > relevant because the parallel interface is still a blocking REPL loop. The > interaction (as I understand it) is ?read - > EvaluateOnSeparateProcesses/Kernels - PrintAllResultsFromProcesses?, where > I am interested in essentially being able to have ?read-evaluate?.<switch > to a different cell> read-evaluate-print <switch back>... print?. > > I also tried to use standard python threads, and attempted to use the > advice from > this thread to redirect the cell output: > http://stackoverflow.com/questions/14393989/per-cell-output-for-threaded-ipython-notebooks > however, it did not work as advertised, and threads have a nasty habit of > being difficult to debug. > > I?m curious if this is possible, and what I would need to do/look at to > enable this functionality. > It probably doesn't help you, but we have implemented this behavior in our IronPython kernel [1]. You need only issue: session = calico.GetSession() session.SetBlocking(False) Cells then no longer wait for execution completion, and the kernel can accept further commands to execute. Currently, however, we don't have any way to access those threads that continue to run. We have most of the IPy 2.0 widget functionality, but no scipy, numpy, etc. -Doug [1] - http://calicoproject.org/ > > Thanks, > Andrew > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/0d4d04a4/attachment.html> From wstein at gmail.com Wed Jul 9 02:04:29 2014 From: wstein at gmail.com (William Stein) Date: Tue, 8 Jul 2014 23:04:29 -0700 Subject: [IPython-dev] running multiple cells simultaneously In-Reply-To: <CADxNwqHrjnvxbFy_FO1-Ox0gJ8OExPM9jnFqeHKoTSDbt30cwA@mail.gmail.com> References: <CADxNwqHrjnvxbFy_FO1-Ox0gJ8OExPM9jnFqeHKoTSDbt30cwA@mail.gmail.com> Message-ID: <CACLE5GBT56A1QwCnByP8q8vCBOs-z9ecfKjuB1Kn+X7J9NBxVA@mail.gmail.com> On Tue, Jul 8, 2014 at 7:42 PM, Andrew Chen <chenjandrew at gmail.com> wrote: > I'm interested in being able to run mutiple ipython notebook cells > simultaneously: for example, to run a loop in once cell, and use another > loop with interactive widgets to tune some parameter of the loop in the > first cell. > > I am aware of the ipython.parallel, but this seems doesn't seem perfectly > relevant because the parallel interface is still a blocking REPL loop. The > interaction (as I understand it) is "read - > EvaluateOnSeparateProcesses/Kernels - PrintAllResultsFromProcesses", where I > am interested in essentially being able to have "read-evaluate....<switch to a > different cell> read-evaluate-print <switch back>... print". > > I also tried to use standard python threads, and attempted to use the advice > from > this thread to redirect the cell output: > http://stackoverflow.com/questions/14393989/per-cell-output-for-threaded-ipython-notebooks > however, it did not work as advertised, and threads have a nasty habit of > being difficult to debug. > > I'm curious if this is possible, and what I would need to do/look at to > enable this functionality. Quick remark. I implemented something like this a while ago for SageMathCloud (SMC) worksheets. You put %fork at the beginning of a cell, and that cell starts running as a forked off subprocess. You can continue evaluating any other cells as normal, or making new "%fork" cells. When the subprocess finishes evaluation, any newly created pickle-able variables are pickled, and set in the calling parent process. That's it. Using fork means that you can run multiple CPU-bound computations in parallel. I've attached the source code for what I did for SMC, in case it is inspiring. William -- William Stein Professor of Mathematics University of Washington http://wstein.org -------------- next part -------------- A non-text attachment was scrubbed... Name: Screen Shot 2014-07-08 at 11.02.28 PM.png Type: image/png Size: 179503 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/4f42f693/attachment.png> -------------- next part -------------- A non-text attachment was scrubbed... Name: fork.py Type: text/x-python-script Size: 3065 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140708/4f42f693/attachment.bin> From bjonen at gmail.com Wed Jul 9 11:56:57 2014 From: bjonen at gmail.com (bjonen) Date: Wed, 9 Jul 2014 08:56:57 -0700 (PDT) Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <155F2467-EFE0-4926-8390-ED19EFDCD9CD@gmail.com> References: <1404761251524-5063264.post@n6.nabble.com> <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> <1404804887295-5063344.post@n6.nabble.com> <9F241A5C-A273-4699-AFD5-83268AFE0FEE@gmail.com> <1404828655658-5063400.post@n6.nabble.com> <155F2467-EFE0-4926-8390-ED19EFDCD9CD@gmail.com> Message-ID: <1404921417188-5063532.post@n6.nabble.com> > Truncation is never a good idea, you will always get the truncation wrong > in some cases. Not sure why you think it is a bad idea. If you think about large datasets: In my opinion it is much more convenient to only see a start and the end of the frame (both row and column direction) instead of having to scroll through hundreds of columns (see https://github.com/pydata/pandas/pull/7086). Of course this would be an optional behavior. > Javascript it not totally an answer either, you will/might not be able to > listen for a resize event. > I would investigate pure css stuff like that : > https://css-tricks.com/examples/ResponsiveTables/responsive.php > and use bootstrap responsive utilities: > http://getbootstrap.com/css/#responsive-utilities > If you really want responsive table with dynamism and javascript I would > suggest doing it in separate package like mpld3 does for matplotlib, or > cyrile rossant handson table. > http://nbviewer.ipython.org/gist/rossant/9463955 > Publishing scripts tag is always brittle and unreliable. Thanks for your help! Sounds like what I had in mind is difficult and probably not worth the trouble. Benjamin -- View this message in context: http://python.6.x6.nabble.com/Getting-the-size-of-ipython-notebook-cell-tp5063264p5063532.html Sent from the IPython - Development mailing list archive at Nabble.com. From bussonniermatthias at gmail.com Wed Jul 9 12:41:33 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 9 Jul 2014 18:41:33 +0200 Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <1404921417188-5063532.post@n6.nabble.com> References: <1404761251524-5063264.post@n6.nabble.com> <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> <1404804887295-5063344.post@n6.nabble.com> <9F241A5C-A273-4699-AFD5-83268AFE0FEE@gmail.com> <1404828655658-5063400.post@n6.nabble.com> <155F2467-EFE0-4926-8390-ED19EFDCD9CD@gmail.com> <1404921417188-5063532.post@n6.nabble.com> Message-ID: <501617D7-691E-4114-9C26-CCB2E23E162D@gmail.com> Le 9 juil. 2014 ? 17:56, bjonen a ?crit : > >> Truncation is never a good idea, you will always get the truncation wrong >> in some cases. > > Not sure why you think it is a bad idea. If you think about large datasets: > In my opinion it is much more convenient to only see a start and the end of > the frame (both row and column direction) instead of having to scroll > through hundreds of columns (see > https://github.com/pydata/pandas/pull/7086). Of course this would be an > optional behavior. Because everyone has different opinion :-) I think it would be nice to have the behavior for things like head() which are explicit. But you will piss off user that have users that have data frame that are just slightly too big to fit, and will be forced to explicitly tell not to truncate. But that my point of view, and I'm probably not an as heavy panda user as you are. Hopefully widget might help. you might have a .widget() that show a subpart of the table and fetches the new parts as you scroll, and then you can do almost whatever with search fields? -- MD > >> Javascript it not totally an answer either, you will/might not be able to >> listen for a resize event. >> I would investigate pure css stuff like that : > >> https://css-tricks.com/examples/ResponsiveTables/responsive.php > >> and use bootstrap responsive utilities: > >> http://getbootstrap.com/css/#responsive-utilities > >> If you really want responsive table with dynamism and javascript I would >> suggest doing it in separate package like mpld3 does for matplotlib, or >> cyrile rossant handson table. > >> http://nbviewer.ipython.org/gist/rossant/9463955 > >> Publishing scripts tag is always brittle and unreliable. > > Thanks for your help! Sounds like what I had in mind is difficult and > probably not worth the trouble. > > Benjamin > > > > -- > View this message in context: http://python.6.x6.nabble.com/Getting-the-size-of-ipython-notebook-cell-tp5063264p5063532.html > Sent from the IPython - Development mailing list archive at Nabble.com. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From takowl at gmail.com Wed Jul 9 12:52:32 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 9 Jul 2014 11:52:32 -0500 Subject: [IPython-dev] Getting the size of ipython notebook cell In-Reply-To: <501617D7-691E-4114-9C26-CCB2E23E162D@gmail.com> References: <1404761251524-5063264.post@n6.nabble.com> <1BF41D3C-A23C-492E-AC70-251212F5D046@gmail.com> <1404804887295-5063344.post@n6.nabble.com> <9F241A5C-A273-4699-AFD5-83268AFE0FEE@gmail.com> <1404828655658-5063400.post@n6.nabble.com> <155F2467-EFE0-4926-8390-ED19EFDCD9CD@gmail.com> <1404921417188-5063532.post@n6.nabble.com> <501617D7-691E-4114-9C26-CCB2E23E162D@gmail.com> Message-ID: <CAOvn4qg0u5j=mo65tk+QdgvVBL_7=JEJL=2C=Cr-XH-S+i=91Q@mail.gmail.com> On 9 July 2014 11:41, Matthias Bussonnier <bussonniermatthias at gmail.com> wrote: > But you will piss off user that have users that have data frame that are > just slightly too big to fit, > and will be forced to explicitly tell not to truncate. I think truncation by default is necessary - data frames can easily be far too big to display wholesale. Of course choosing where you start truncating is difficult, but pandas exposes that as a configurable option (and the default displays far more than numpy before it starts truncating). > you might have a .widget() that show a subpart of the table and fetches the new parts as you scroll It would be great to see something like this, but it's also important to have a good static display. Apart from anything else, you can't rely on having a kernel running with that object in the namespace to render the notebook - dynamically loading data from the kernel won't work on nbviewer, for instance. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140709/e596f367/attachment.html> From max_linke at gmx.de Thu Jul 10 05:19:03 2014 From: max_linke at gmx.de (Max Linke) Date: Thu, 10 Jul 2014 11:19:03 +0200 Subject: [IPython-dev] Memory consumption of running notebook Message-ID: <1404983943.13472.1.camel@archi> Hi I often have 10 and more notebooks running at the same time. It can happen that one or two of them contain large arrays that fill up my memory and it is not obvious from the cell-content which notebook consumes the most memory. Is there a way to see how much memory each notebook is roughly using? If I understand the notebooks correct a new python process is started for each running notebook, then I would already be happy with a way to see which process is running which notebook. best Max From ingolf.becker at googlemail.com Thu Jul 10 05:42:11 2014 From: ingolf.becker at googlemail.com (Ingolf Becker) Date: Thu, 10 Jul 2014 10:42:11 +0100 Subject: [IPython-dev] Memory consumption of running notebook In-Reply-To: <1404983943.13472.1.camel@archi> References: <1404983943.13472.1.camel@archi> Message-ID: <CAPET0ywvRQthgDtkX7M9Q5OdneZo+6eG_y0=nOuUZtAWdKp97w@mail.gmail.com> Which OS are you using? On unix based systems, the one liner `!cat /proc/{os.getpid()}/status | grep VmSize` will give you the memory occupied by the current ipython process. You can of course run that command in parallel on all nodes. If you want more functionality, or you are on Windows, I suppose you could do something like [1]. I hope this helps! [1] https://stackoverflow.com/questions/938733/total-memory-used-by-python-process On 10 July 2014 10:19, Max Linke <max_linke at gmx.de> wrote: > Hi > > I often have 10 and more notebooks running at the same time. It can > happen that one or two of them contain large arrays that fill up my memory > and it is not obvious from the cell-content which notebook consumes the > most memory. > Is there a way to see how much memory each notebook is roughly using? > If I understand the notebooks correct a new python process is started > for each running notebook, then I would already be happy with a way to > see which process is running which notebook. > > best Max > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140710/d10b59c4/attachment.html> From cyrille.rossant at gmail.com Thu Jul 10 08:15:47 2014 From: cyrille.rossant at gmail.com (Cyrille Rossant) Date: Thu, 10 Jul 2014 14:15:47 +0200 Subject: [IPython-dev] custom mime types in the notebook Message-ID: <CA+-1RQQfYnTf=AtG3HmCT3YK3NjYdsN2EvFKpQ5X4fnLTFgNeg@mail.gmail.com> Hi, Let's say I have a Javascript application that can read files in a custom JSON format. I want to create an IPython extension where: * some Python functions may return objects in this format * the notebook understands this format and uses my JS app to display them * cell outputs in that format are saved in the JSON notebook, along with other representations (text, image) What's the best way to do it? Should I create a custom mime type "application/myapp", and extend the notebook to use the JS app for that mime type (if that's even possible)? Thanks Cyrille From cyrille.rossant at gmail.com Thu Jul 10 08:48:05 2014 From: cyrille.rossant at gmail.com (Cyrille Rossant) Date: Thu, 10 Jul 2014 14:48:05 +0200 Subject: [IPython-dev] loading a static JS file when loading an IPython extension in the notebook Message-ID: <CA+-1RQQk+a48Ompy4auoKV=ZJmuR1KQEVGKge_w_QWFvdfeuUg@mail.gmail.com> Hi, What is the best way to write an IPython extension such that `%load_ext myext` loads `myscript.js` in the current notebook? If possible, I'd prefer to avoid asking users to make manual changes to custom.js or similar. Thanks, Cyrille From takowl at gmail.com Thu Jul 10 09:56:14 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 10 Jul 2014 08:56:14 -0500 Subject: [IPython-dev] Memory consumption of running notebook In-Reply-To: <1404983943.13472.1.camel@archi> References: <1404983943.13472.1.camel@archi> Message-ID: <CAOvn4qikH9N2Tj6w8fNBCjHqF6UrjYAWWPq+S27jO+rLr0DhNQ@mail.gmail.com> On 10 July 2014 04:19, Max Linke <max_linke at gmx.de> wrote: > I often have 10 and more notebooks running at the same time. It can > happen that one or two of them contain large arrays that fill up my memory > and it is not obvious from the cell-content which notebook consumes the > most memory. > Is there a way to see how much memory each notebook is roughly using? > If I understand the notebooks correct a new python process is started > for each running notebook, then I would already be happy with a way to > see which process is running which notebook. > I think Ingolf's answer is the best solution at present, but I wonder if this is something that we can discover and display in the dashboard 'running' tab, perhaps using a module like psutil. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140710/5f67de9d/attachment.html> From benjaminrk at gmail.com Thu Jul 10 10:06:06 2014 From: benjaminrk at gmail.com (MinRK) Date: Thu, 10 Jul 2014 09:06:06 -0500 Subject: [IPython-dev] Memory consumption of running notebook In-Reply-To: <CAPET0ywvRQthgDtkX7M9Q5OdneZo+6eG_y0=nOuUZtAWdKp97w@mail.gmail.com> References: <1404983943.13472.1.camel@archi> <CAPET0ywvRQthgDtkX7M9Q5OdneZo+6eG_y0=nOuUZtAWdKp97w@mail.gmail.com> Message-ID: <CAHNn8BW1M=bG6t3STfzoXwqSEj95NRh5PV9p=Kk86WZ8yqMzbQ@mail.gmail.com> It might make sense to put some resource info in the Running tab. On Thu, Jul 10, 2014 at 4:42 AM, Ingolf Becker <ingolf.becker at googlemail.com > wrote: > Which OS are you using? On unix based systems, the one liner > `!cat /proc/{os.getpid()}/status | grep VmSize` > will give you the memory occupied by the current ipython process. You can > of course run that command in parallel on all nodes. If you want more > functionality, or you are on Windows, I suppose you could do something like > [1]. > > I hope this helps! > > [1] > https://stackoverflow.com/questions/938733/total-memory-used-by-python-process > > > > > On 10 July 2014 10:19, Max Linke <max_linke at gmx.de> wrote: > >> Hi >> >> I often have 10 and more notebooks running at the same time. It can >> happen that one or two of them contain large arrays that fill up my memory >> and it is not obvious from the cell-content which notebook consumes the >> most memory. >> Is there a way to see how much memory each notebook is roughly using? >> If I understand the notebooks correct a new python process is started >> for each running notebook, then I would already be happy with a way to >> see which process is running which notebook. >> >> best Max >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140710/5be6c41c/attachment.html> From andy at payne.org Thu Jul 10 12:55:14 2014 From: andy at payne.org (Andrew Payne) Date: Thu, 10 Jul 2014 12:55:14 -0400 Subject: [IPython-dev] (no subject) In-Reply-To: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> References: <CACBGWQYnfSbtQ4ShHTL5DxjCuh4JfCFxH4C=+1nRaHJCFxWYGg@mail.gmail.com> Message-ID: <CABbuyuVeo_fSZZBrkFgup9GuS+6OVgU+hj6B5P99Wq+HO6pVFQ@mail.gmail.com> Following up on the shell discussion: A detailed proposal is at > > https://raw.githubusercontent.com/sjdv1982/ipython/master/docs/source/whatsnew/pr/incompat-bangmode.rst > All of the examples in the proposal are working with the code branch. > Reading your issues and proposals, my design advice (as an IPython user) would be to consolidate them into a new custom magic, based on the existing %sx (!), that performs the way you want. See the source here: https://github.com/ipython/ipython/blob/master/IPython/core/magics/osm.py You could do shell-compatible variable expansion, etc. For the idea of having Python functions participate in the pipeline (e.g. your "%bless" magic), you could: 1. For each pipeline stage, first look for a Python function of the name and use it if it exists (aggressive, could have surprising name collisions), 2. Have a safe character prefix that indicates a Python function call vs a exec process invocation, OR, 3. Have a decorator (e.g. @mkpipe) that marks a Python function as being a pipe function I agree with the previous comments: the style of using Unix pipes and commands (esp. intermixed with Python) is probably off to the side of mainstream IPython use. But if you write your custom magic, you get exactly what you want AND it's much more likely to work with future IPython versions. :) -andy -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140710/b0baea85/attachment.html> From ntezak at stanford.edu Thu Jul 10 17:11:18 2014 From: ntezak at stanford.edu (Nikolas Tezak) Date: Thu, 10 Jul 2014 16:11:18 -0500 Subject: [IPython-dev] IPython circuit editing widget Message-ID: <E1061BD3-C522-4D06-A5CE-DC66DFAD92C5@stanford.edu> Hi everybody, here's a link to the visual circuit editing / schematic capture widget in the notebook I presented at SciPy today. It?s still pretty rough and I?m not exactly proud of my JS skills but it already works pretty well! Maybe someone else can reuse this if they are creating a complex SVG based interactive widget. The repo https://github.com/ntezak/cirq The talk https://conference.scipy.org/scipy2014/schedule/presentation/1743/ If anybody is interested I can make my slides available somewhere, too. Best, Nik From princess.jasmine.lognnes at gmail.com Fri Jul 11 06:02:40 2014 From: princess.jasmine.lognnes at gmail.com (Jasmine Lognnes) Date: Fri, 11 Jul 2014 12:02:40 +0200 Subject: [IPython-dev] Recommended hardware specs? Message-ID: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> Dear developers =) Does anyone know the recommended hardware specs for one instance of IPython? Numer of CPU's, speed and memory. Hugs, Jasmine =) From p.f.moore at gmail.com Fri Jul 11 06:35:47 2014 From: p.f.moore at gmail.com (Paul Moore) Date: Fri, 11 Jul 2014 11:35:47 +0100 Subject: [IPython-dev] Memory consumption of running notebook In-Reply-To: <1404983943.13472.1.camel@archi> References: <1404983943.13472.1.camel@archi> Message-ID: <CACac1F-5Yr31PLiM8i0h9EVMJ5cuSMCq1sudXPffYbT58Kwp2Q@mail.gmail.com> On 10 July 2014 10:19, Max Linke <max_linke at gmx.de> wrote: > Is there a way to see how much memory each notebook is roughly using? > If I understand the notebooks correct a new python process is started > for each running notebook, then I would already be happy with a way to > see which process is running which notebook. If you have psutil installed, you could use p = psutil.Process() p.memory_info() There's *lots* more you can do with psutil... Paul From princess.jasmine.lognnes at gmail.com Fri Jul 11 06:54:56 2014 From: princess.jasmine.lognnes at gmail.com (Jasmine Lognnes) Date: Fri, 11 Jul 2014 12:54:56 +0200 Subject: [IPython-dev] Recommended hardware specs? In-Reply-To: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> References: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> Message-ID: <CAKWq6+ey-wx4LcQ39LEKonMQJFi5Pfjb50qL-TZWsuHT99wX2A@mail.gmail.com> Btw. It is server side hw specs I am interested in =) On 11 July 2014 12:02, Jasmine Lognnes <princess.jasmine.lognnes at gmail.com> wrote: > Dear developers =) > > Does anyone know the recommended hardware specs for one instance of > IPython? Numer of CPU's, speed and memory. > > Hugs, > Jasmine =) From andy at payne.org Fri Jul 11 07:34:30 2014 From: andy at payne.org (Andrew Payne) Date: Fri, 11 Jul 2014 07:34:30 -0400 Subject: [IPython-dev] custom mime types in the notebook In-Reply-To: <CA+-1RQQfYnTf=AtG3HmCT3YK3NjYdsN2EvFKpQ5X4fnLTFgNeg@mail.gmail.com> References: <CA+-1RQQfYnTf=AtG3HmCT3YK3NjYdsN2EvFKpQ5X4fnLTFgNeg@mail.gmail.com> Message-ID: <CABbuyuX2DFHrRrzn3burJUj-LHae2U0jVxNGmS-U11Fm_30mxg@mail.gmail.com> On Thu, Jul 10, 2014 at 8:15 AM, Cyrille Rossant <cyrille.rossant at gmail.com> wrote: > > Let's say I have a Javascript application that can read files in a > custom JSON format. I want to create an IPython extension where: > > * some Python functions may return objects in this format > * the notebook understands this format and uses my JS app to display them > * cell outputs in that format are saved in the JSON notebook, along > with other representations (text, image) if I understand what you're trying to do, you should be able to get *part* of this by having your Python code return Javascript fragments for rendering in the notebook cell. Your fragments would be your (a) JSON data combined with (b) whatever JS invocation you need to display it or interact with it in the cell. For example: from IPython.display import Javascript Javascript(" var data = {*your JSON data here*}; *invoke_your_function*(data); ") You can also have your objects implement _repr_javascript_() which would generate the above fragment. In addition, you will want to make sure your Javascript library is loaded. There are subtleties here, including lots of possible race conditions where your cell is executed before your libraries are fully loaded. To avoid this case, preface your fragments with the right calls to 'require.js', see: http://requirejs.org/ For detailed examples of most of this, see my notebook: http://nbviewer.ipython.org/github/payne92/notebooks/blob/master/00%20Javascript%20In%20Notebooks.ipynb > What's the best way to do it? Should I create a custom mime type > "application/myapp", and extend the notebook to use the JS app for > that mime type (if that's even possible)? I think this opens up a can of worms (certainly relative to the approach above). Going this route, you start to introduce dependencies on how the notebook is served, and you make the notebook itself less portable. I hope this is helpful. (and if you have any feedback on my example notebook, please let me know). -andy -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140711/ef0eb221/attachment.html> From andy at payne.org Fri Jul 11 07:40:27 2014 From: andy at payne.org (Andrew Payne) Date: Fri, 11 Jul 2014 07:40:27 -0400 Subject: [IPython-dev] Recommended hardware specs? In-Reply-To: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> References: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> Message-ID: <CABbuyuXLsWdyaAH-xfMb1cDBghChTn6g=ZQ3d=942-vxCJM1Ug@mail.gmail.com> On Fri, Jul 11, 2014 at 6:02 AM, Jasmine Lognnes < princess.jasmine.lognnes at gmail.com> wrote: > Does anyone know the recommended hardware specs for one instance of > IPython? Numer of CPU's, speed and memory. This is very difficult to answer generally, as it depends *entirely *on what sort of interactive computing you are doing and how compute intensive it is. I've run the notebook server on everything from a seven-year-old MacBook to a 3 GHz quad core Intel server with 32 gig of RAM -- it all works, just at different speeds. If you want to get a sense of performance, you might consider starting with a free virtual server at Amazon http://aws.amazon.com/free/, Rackspace http://www.rackspace.com/cloud/servers/pricing/, etc. (not endorsing any one provider). -andy -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140711/757f0da5/attachment.html> From nick.bollweg at gmail.com Fri Jul 11 09:38:32 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Fri, 11 Jul 2014 09:38:32 -0400 Subject: [IPython-dev] loading a static JS file when loading an IPython extension in the notebook In-Reply-To: <CA+-1RQQk+a48Ompy4auoKV=ZJmuR1KQEVGKge_w_QWFvdfeuUg@mail.gmail.com> References: <CA+-1RQQk+a48Ompy4auoKV=ZJmuR1KQEVGKge_w_QWFvdfeuUg@mail.gmail.com> Message-ID: <CACejjWzqJfKUvr-K3_LHw_gfcjOQhoyLEk+HPu_iSPE4ZJGHUg@mail.gmail.com> Here's the most recent thread on that: http://python.6.x6.nabble.com/Loading-nbextension-on-widget-instantiation-tt5060760.html#none I captured some of the pattens into a cookiecutter template: https://github.com/bollwyvl/cookiecutter-ipython-widget You can use this pattern, even if you aren't using widgets, though. The key chores are: - make sure your static files, in a folder, get copied on install (MANIFEST.in) - when you are ready to use your JS, copy static into the nbextensions directory (in the users profile) with IPython.html.nbextensions.install_nbextension - display them (and/or any css) with display Here is the file I use for encapsulating those steps: https://github.com/bollwyvl/cookiecutter-ipython-widget/blob/master/%7B%7Bcookiecutter.repo_name%7D%7D/%7B%7Bcookiecutter.pkg_name%7D%7D/widgets/mixins.py It gets called each time an instance of a class is instantiated. It was suggested that this is preferable over loading it at import time. Hope this helps! On Thu, Jul 10, 2014 at 8:48 AM, Cyrille Rossant <cyrille.rossant at gmail.com> wrote: > Hi, > > What is the best way to write an IPython extension such that > `%load_ext myext` loads `myscript.js` in the current notebook? If > possible, I'd prefer to avoid asking users to make manual changes to > custom.js or similar. > > Thanks, > Cyrille > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140711/6fb2fc09/attachment.html> From takowl at gmail.com Fri Jul 11 10:35:48 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 11 Jul 2014 09:35:48 -0500 Subject: [IPython-dev] Recommended hardware specs? In-Reply-To: <CAKWq6+ey-wx4LcQ39LEKonMQJFi5Pfjb50qL-TZWsuHT99wX2A@mail.gmail.com> References: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> <CAKWq6+ey-wx4LcQ39LEKonMQJFi5Pfjb50qL-TZWsuHT99wX2A@mail.gmail.com> Message-ID: <CAOvn4qi16a7vxVe4VDOmFA4rOQ6_oeuPxJR_Z+FysedPCaytqg@mail.gmail.com> IPython itself doesn't have any special resource requirements - any reasonably recent machine should be capable of running it. The question is more likely to hinge on what you're trying to do in IPython: if you're using a lot of big arrays, you'll need a lot of memory, for instance. On 11 July 2014 05:54, Jasmine Lognnes <princess.jasmine.lognnes at gmail.com> wrote: > Btw. It is server side hw specs I am interested in =) > > > > On 11 July 2014 12:02, Jasmine Lognnes > <princess.jasmine.lognnes at gmail.com> wrote: > > Dear developers =) > > > > Does anyone know the recommended hardware specs for one instance of > > IPython? Numer of CPU's, speed and memory. > > > > Hugs, > > Jasmine =) > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140711/3c095c0e/attachment.html> From takowl at gmail.com Fri Jul 11 10:50:28 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 11 Jul 2014 09:50:28 -0500 Subject: [IPython-dev] loading a static JS file when loading an IPython extension in the notebook In-Reply-To: <CA+-1RQQk+a48Ompy4auoKV=ZJmuR1KQEVGKge_w_QWFvdfeuUg@mail.gmail.com> References: <CA+-1RQQk+a48Ompy4auoKV=ZJmuR1KQEVGKge_w_QWFvdfeuUg@mail.gmail.com> Message-ID: <CAOvn4qhRceYo=vLBFRPN_g5du6PqKQGAu1hiLtrVm46RALYoHg@mail.gmail.com> On 10 July 2014 07:48, Cyrille Rossant <cyrille.rossant at gmail.com> wrote: > What is the best way to write an IPython extension such that > `%load_ext myext` loads `myscript.js` in the current notebook? If > possible, I'd prefer to avoid asking users to make manual changes to > custom.js or similar. > We are going to come up with a mechanism for installing and using notebook extensions that doesn't depend on IPython kernel-side extensions, because it should be independent of the kernel language. So for pure JS extensions, I'd rather get that sorted out than have hacks to load them from Python. However, there is a need for code which has both a Python component and a JS piece. In that case, you can load the JS by doing something like this: pkgdir = os.path.dirname(__file__) nbextensions.install_nbextension([os.path.join(pkgdir, 'myjsdir')], symlink= True) display(Javascript("IPython.load_extensions('myjsdir/somefile');")) This is what I do in mobilechelonian: https://github.com/takluyver/mobilechelonian/blob/master/mobilechelonian/__init__.py We are also going to build a mechanism to allow widgets to specify the file where their JS part is contained, which will be loaded with requirejs, which will make this unnecessary in many cases. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140711/c8a8f559/attachment.html> From cyrille.rossant at gmail.com Fri Jul 11 12:50:50 2014 From: cyrille.rossant at gmail.com (Cyrille Rossant) Date: Fri, 11 Jul 2014 18:50:50 +0200 Subject: [IPython-dev] custom mime types in the notebook In-Reply-To: <CABbuyuX2DFHrRrzn3burJUj-LHae2U0jVxNGmS-U11Fm_30mxg@mail.gmail.com> References: <CA+-1RQQfYnTf=AtG3HmCT3YK3NjYdsN2EvFKpQ5X4fnLTFgNeg@mail.gmail.com> <CABbuyuX2DFHrRrzn3burJUj-LHae2U0jVxNGmS-U11Fm_30mxg@mail.gmail.com> Message-ID: <CA+-1RQTzxBfrphGcLAsAPmP8js-BW17nHNjezz=B5PEgvo5w3Q@mail.gmail.com> >> What's the best way to do it? Should I create a custom mime type >> "application/myapp", and extend the notebook to use the JS app for >> that mime type (if that's even possible)? > > I think this opens up a can of worms (certainly relative to the approach > above). Going this route, you start to introduce dependencies on how the > notebook is served, and you make the notebook itself less portable. Thanks. Could you elaborate on why this approach would make the notebook less portable? Let's take an example. Imagine I want to display 3D models in a notebook using a JS library (like three.js). Approach 1: * My cell's output contains data in several mime types: PNG with a screenshot, and OBJ (for example) with the full 3D model. It seems to me that the nbformat is designed for this (multiple MIME types representing the same logical data). * If the client understands the OBJ mime type, it displays it using three.js. * Otherwise, it just displays the PNG screenshot. Approach 2 would be to embed the entire Javascript code in the output + <script include jslibraries> (like you suggest, and like mpld3 does, unless I'm mistaken) I guess my questions are: * Which of those two approaches is recommended by IPython devs? * Is the notebook designed for approach 1 use-case or not? It seems to me that approach 1 is cleaner while approach 2 looks like a hack, but that's just my opinion. Best, Cyrille From rmatthewmerrifield at gmail.com Fri Jul 11 18:22:41 2014 From: rmatthewmerrifield at gmail.com (Matt Merrifield) Date: Fri, 11 Jul 2014 15:22:41 -0700 Subject: [IPython-dev] Recommended hardware specs? In-Reply-To: <CAKWq6+ey-wx4LcQ39LEKonMQJFi5Pfjb50qL-TZWsuHT99wX2A@mail.gmail.com> References: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> <CAKWq6+ey-wx4LcQ39LEKonMQJFi5Pfjb50qL-TZWsuHT99wX2A@mail.gmail.com> Message-ID: <CAOORUGJm=9m=QdqoUp0Y1wu64Q5u8Vgu3T=VFFAJ_s6FqiRF1A@mail.gmail.com> Depends on what you want to do with it, I suppose. Here at work, we typically take about a dozen 300Mb text files, parse them into pandas DataFrame objects (20-30 columns of floats, 100K+ rows), and then do simple math and plot some stuff. No cryptography or genome sequencing or anything particularly resource-intensive, but it soaks up a fair amount of RAM. Our hex-core Xeon W3670 @3.2 Ghz with 12 GB of RAM is overkill most of the time, but yesterday somebody got a bit ambitious and crashed it by drawing up about 600 matplotlib figures without explicitly closing any of them. A co-worker installed his own server instance on a laptop with a Core2Duo@ 2.5Ghz (4GB RAM) and it was a bit too slow to do his work effectively (too much waiting for files to parse), but it ran okay. A friend of mine has been solving Project Euler problems on her 2009 macbook for a while now, and IPython runs great for what she wants to do. Somewhere in the middle is probably fine. Any mid-range hardware from the last year or so, and you'll be able to do some real work on it. I know that's anecdotal at best, but hopefully it gives you some bechmarks. -Matt On Fri, Jul 11, 2014 at 3:54 AM, Jasmine Lognnes <princess.jasmine.lognnes at gmail.com> wrote: > Btw. It is server side hw specs I am interested in =) > > > > On 11 July 2014 12:02, Jasmine Lognnes > <princess.jasmine.lognnes at gmail.com> wrote: >> Dear developers =) >> >> Does anyone know the recommended hardware specs for one instance of >> IPython? Numer of CPU's, speed and memory. >> >> Hugs, >> Jasmine =) > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From benjaminrk at gmail.com Fri Jul 11 18:42:40 2014 From: benjaminrk at gmail.com (MinRK) Date: Fri, 11 Jul 2014 17:42:40 -0500 Subject: [IPython-dev] loading a static JS file when loading an IPython extension in the notebook In-Reply-To: <CA+-1RQQk+a48Ompy4auoKV=ZJmuR1KQEVGKge_w_QWFvdfeuUg@mail.gmail.com> References: <CA+-1RQQk+a48Ompy4auoKV=ZJmuR1KQEVGKge_w_QWFvdfeuUg@mail.gmail.com> Message-ID: <CAHNn8BXvD0JyfTZBKC-+K1RPW96fmA14r83jhCrk1Axsh8xBwQ@mail.gmail.com> %load_ext myext should do: # stage javascript to nbextensions: from IPython.html.nbextensions import install_nbextension install_nbextension(myjsfiles) # load javascript in the frontend: from IPython.display import display, Javascript display(Javascript("IPython.load_extensions('mextension')")) -MinRK On Thu, Jul 10, 2014 at 7:48 AM, Cyrille Rossant <cyrille.rossant at gmail.com> wrote: > Hi, > > What is the best way to write an IPython extension such that > `%load_ext myext` loads `myscript.js` in the current notebook? If > possible, I'd prefer to avoid asking users to make manual changes to > custom.js or similar. > > Thanks, > Cyrille > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140711/2991d826/attachment.html> From wstein at gmail.com Sat Jul 12 10:48:15 2014 From: wstein at gmail.com (William Stein) Date: Sat, 12 Jul 2014 07:48:15 -0700 Subject: [IPython-dev] different kernels - one filename - no metadata ?? Message-ID: <CACLE5GA4OWzNaCp3CwhaTK7wRdRs_wQYzfVH8inxaTUHRipiYA@mail.gmail.com> Hi, My understanding is that the IPython notebook server has the ability to start with various profiles, e.g., ipython notebook --profile julia ... to start in Julia mode. It then operates as a Julia notebook, called IJulia. Whenever one opens an .ipynb file using this notebook, it works in Julia mode, etc. Something seems confusing to me about this whole setup, and I'm curious whether: (1) this is your design intention, or (2) this is just a temporary problem that you hope to fix ASAP, or (3) I'm completely missing the point. This is causing me confusion in trying to further integrate IPython with multi-kernel support into SageMathCloud, in a user friendly way. I want to make sure to match my implementation with your intentions so it is the most user friendly. Here's my concern. Suppose a person frequently uses the IPython notebook on their laptop (say) with several different kernels, called lets say kernel0, kernel1 and kernel2. Is that person really supposed to: (1) start three separate IPython notebook servers running on three different ports, (2) name all the corresponding notebooks with the same extension, say "a0.ipynb", "a1.ipynb", "a2.ipynb"? (3) when opening "a1.ipynb", how do they know which kernel/server to use? Won't all three of the servers list all of the ipynb files? To me this seems potentially confusing. First, wouldn't it be less confusing to have exactly one notebook server (tornado process) that can handle all profile/kernel types simultaneously, and embed the choice of profile (and kernel) in the file itself, or in the filename extension? Second, how can one tell which kernel to use to open a given ipynb file? Obviously our user could make up some conventions like a0-kernel2.ipynb means "open with kernel2", but that seems error prone. In the sage notebook (from 2006), we had a similar problem, and our solution was that the first line of the file specified the configuration (so which mode it used). With SageMathCloud "sage worksheets" (.sagews), the only way to set a mode is to explicitly type a command into the worksheet -- so it's very explicit, like I think maybe IPython notebook 1.x was (?); however, we're considering using file extensions to specify a default, so foo.smc-r would be an R worksheet, foo.smc-sage would be a sage worksheet, foo.smc-python3 a python3 worksheet, foo.smc-gap a gap one, etc. William -- William Stein Professor of Mathematics University of Washington http://wstein.org From wstein at gmail.com Sat Jul 12 11:09:35 2014 From: wstein at gmail.com (William Stein) Date: Sat, 12 Jul 2014 08:09:35 -0700 Subject: [IPython-dev] [sage-cloud] ijulia? In-Reply-To: <CAGG4CB65WdtCh+gFHxxGe6jAKieWwqwjRbb1USwqqUOO8=6XJQ@mail.gmail.com> References: <CACLE5GDudtHNhivKxQCBodjvF-A0GHDfW4hCwj1rJmje6J85+w@mail.gmail.com> <53BC3C53.6020402@creativetrax.com> <53BD56DA.2000706@creativetrax.com> <CACLE5GDA4sqohWJYTxfmDFgV5xTEioP2y1GnmtXw_kguU6RAtQ@mail.gmail.com> <53BD70AF.7050106@creativetrax.com> <192686da-2a2a-4fb7-ba04-edaea4a8d7a3@googlegroups.com> <CALVmk4G_NviFP+220sMt3KZz9q5Au1O7gjYUsbYcPQzS0U+aqw@mail.gmail.com> <ccf45233-1d2c-426d-a9a8-1cc10e0b39e7@googlegroups.com> <CALVmk4HipuFG7qbgUoZ6kMjg3UvOWOiEYOyxmfoK4QRXwZnc+A@mail.gmail.com> <CAGG4CB65WdtCh+gFHxxGe6jAKieWwqwjRbb1USwqqUOO8=6XJQ@mail.gmail.com> Message-ID: <CACLE5GCgXWi+8Li3tGXc7t0nk7WBT8u4g1sa1M5FM+=SJ1L=zA@mail.gmail.com> On Sat, Jul 12, 2014 at 8:02 AM, Harald Schilly <harald.schilly at gmail.com> wrote: > On Sat, Jul 12, 2014 at 4:32 PM, William A Stein <wstein at uw.edu> wrote: >> I'll write to IPython-dev. The problem isn't about determining >> whether somebody started the ipython notebook server in julia mode, >> but determining which mode the IPython notebook *needs* to be started >> in order to open a given ipynb document. > > To me, this looks like there must be a convention to store that > information in the ipynb metadata. Right now, I can only see "name" > and "signature". My first idea would be to add an additional key > "backend" (?) and the values are "ipython", "python", "julia", "R", > "sage", ... with the default being "ipython" of course. Is this is a suggestion for a way to change IPython notebook itself? For IPython users: If you start an IPython notebook server (say in python mode) and try to open a notebook with backend:'julia', would it just give an error and tell the user to run another notebook server with a julia backend? For SageMathCloud users: I can write code to start several notebook servers, which run simulaneously, I guess, assuming their state files don't conflict. -- William > > Harald > > -- > You received this message because you are subscribed to the Google Groups "sage-cloud" group. > To unsubscribe from this group and stop receiving emails from it, send an email to sage-cloud+unsubscribe at googlegroups.com. > To view this discussion on the web visit https://groups.google.com/d/msgid/sage-cloud/CAGG4CB65WdtCh%2BgFHxxGe6jAKieWwqwjRbb1USwqqUOO8%3D6XJQ%40mail.gmail.com. > For more options, visit https://groups.google.com/d/optout. -- William Stein Professor of Mathematics University of Washington http://wstein.org From benjaminrk at gmail.com Sat Jul 12 12:20:31 2014 From: benjaminrk at gmail.com (MinRK) Date: Sat, 12 Jul 2014 11:20:31 -0500 Subject: [IPython-dev] loading a static JS file when loading an IPython extension in the notebook In-Reply-To: <CACejjWzqJfKUvr-K3_LHw_gfcjOQhoyLEk+HPu_iSPE4ZJGHUg@mail.gmail.com> References: <CA+-1RQQk+a48Ompy4auoKV=ZJmuR1KQEVGKge_w_QWFvdfeuUg@mail.gmail.com> <CACejjWzqJfKUvr-K3_LHw_gfcjOQhoyLEk+HPu_iSPE4ZJGHUg@mail.gmail.com> Message-ID: <CAHNn8BVE-sXVhZqVNJaMymH4tdomS1E_M0Vsa2de0d8iasSq4g@mail.gmail.com> On Fri, Jul 11, 2014 at 8:38 AM, Nicholas Bollweg <nick.bollweg at gmail.com> wrote: > Here's the most recent thread on that: > > http://python.6.x6.nabble.com/Loading-nbextension-on-widget-instantiation-tt5060760.html#none > > I captured some of the pattens into a cookiecutter template: > https://github.com/bollwyvl/cookiecutter-ipython-widget > Very nice! We should probably have something like this in the IPython docs. > > > You can use this pattern, even if you aren't using widgets, though. > > The key chores are: > > - make sure your static files, in a folder, get copied on install > (MANIFEST.in) > - when you are ready to use your JS, copy static into the nbextensions directory > (in the users profile) with > IPython.html.nbextensions.install_nbextension > - display them (and/or any css) with display > > > Here is the file I use for encapsulating those steps: > > https://github.com/bollwyvl/cookiecutter-ipython-widget/blob/master/%7B%7Bcookiecutter.repo_name%7D%7D/%7B%7Bcookiecutter.pkg_name%7D%7D/widgets/mixins.py > It gets called each time an instance of a class is instantiated. It was > suggested that this is preferable over loading it at import time. > > Hope this helps! > > > On Thu, Jul 10, 2014 at 8:48 AM, Cyrille Rossant < > cyrille.rossant at gmail.com> wrote: > >> Hi, >> >> What is the best way to write an IPython extension such that >> `%load_ext myext` loads `myscript.js` in the current notebook? If >> possible, I'd prefer to avoid asking users to make manual changes to >> custom.js or similar. >> >> Thanks, >> Cyrille >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140712/47c32814/attachment.html> From benjaminrk at gmail.com Sat Jul 12 12:23:54 2014 From: benjaminrk at gmail.com (MinRK) Date: Sat, 12 Jul 2014 11:23:54 -0500 Subject: [IPython-dev] custom mime types in the notebook In-Reply-To: <CA+-1RQTzxBfrphGcLAsAPmP8js-BW17nHNjezz=B5PEgvo5w3Q@mail.gmail.com> References: <CA+-1RQQfYnTf=AtG3HmCT3YK3NjYdsN2EvFKpQ5X4fnLTFgNeg@mail.gmail.com> <CABbuyuX2DFHrRrzn3burJUj-LHae2U0jVxNGmS-U11Fm_30mxg@mail.gmail.com> <CA+-1RQTzxBfrphGcLAsAPmP8js-BW17nHNjezz=B5PEgvo5w3Q@mail.gmail.com> Message-ID: <CAHNn8BV6gni-tssQ64yKHNRLqbQDBoJV1cSCeL565x=q4ubY4w@mail.gmail.com> I can't speak for every IPython dev, but I agree that approach 1 is theoretically cleaner. However, approach 2 is a lot easier to get working and can be used to get the nicer representation on nbviewer, which approach 1 cannot. I can't say which I prefer, but I can say which I tend to do, and that's #2. But doing something is different from endorsing it :) -MinRK On Fri, Jul 11, 2014 at 11:50 AM, Cyrille Rossant <cyrille.rossant at gmail.com > wrote: > >> What's the best way to do it? Should I create a custom mime type > >> "application/myapp", and extend the notebook to use the JS app for > >> that mime type (if that's even possible)? > > > > I think this opens up a can of worms (certainly relative to the approach > > above). Going this route, you start to introduce dependencies on how > the > > notebook is served, and you make the notebook itself less portable. > > Thanks. Could you elaborate on why this approach would make the > notebook less portable? > > Let's take an example. Imagine I want to display 3D models in a > notebook using a JS library (like three.js). > > Approach 1: > > * My cell's output contains data in several mime types: PNG with a > screenshot, and OBJ (for example) with the full 3D model. It seems to > me that the nbformat is designed for this (multiple MIME types > representing the same logical data). > > * If the client understands the OBJ mime type, it displays it using > three.js. > > * Otherwise, it just displays the PNG screenshot. > > Approach 2 would be to embed the entire Javascript code in the output > + <script include jslibraries> (like you suggest, and like mpld3 does, > unless I'm mistaken) > > I guess my questions are: > > * Which of those two approaches is recommended by IPython devs? > * Is the notebook designed for approach 1 use-case or not? > > It seems to me that approach 1 is cleaner while approach 2 looks like > a hack, but that's just my opinion. > > Best, > Cyrille > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140712/cd878821/attachment.html> From andy at payne.org Sat Jul 12 16:47:55 2014 From: andy at payne.org (Andrew Payne) Date: Sat, 12 Jul 2014 16:47:55 -0400 Subject: [IPython-dev] custom mime types in the notebook In-Reply-To: <CA+-1RQTzxBfrphGcLAsAPmP8js-BW17nHNjezz=B5PEgvo5w3Q@mail.gmail.com> References: <CA+-1RQQfYnTf=AtG3HmCT3YK3NjYdsN2EvFKpQ5X4fnLTFgNeg@mail.gmail.com> <CABbuyuX2DFHrRrzn3burJUj-LHae2U0jVxNGmS-U11Fm_30mxg@mail.gmail.com> <CA+-1RQTzxBfrphGcLAsAPmP8js-BW17nHNjezz=B5PEgvo5w3Q@mail.gmail.com> Message-ID: <CABbuyuWuws1k+HWocE8CGGvtpwYNAwmuOiTuMVXxMijFoS8_VA@mail.gmail.com> > >> What's the best way to do it? Should I create a custom mime type > >> "application/myapp", and extend the notebook to use the JS app for > >> that mime type (if that's even possible)? > > > > I think this opens up a can of worms (certainly relative to the approach > > above). Going this route, you start to introduce dependencies on how > the > > notebook is served, and you make the notebook itself less portable. > > Thanks. Could you elaborate on why this approach would make the > notebook less portable? > Right now, IPython supports plain text, markdown, HTML, "JSON", Javascript, PDF, PNG, JPEG, and SVG with "formatters". (See: http://ipython.org/ipython-doc/dev/api/generated/IPython.core.formatters.html) You *could* write your own new formatter for your datatype, but then you're reaching into lesser-used code areas that have changed in the past. In my experience, those are areas that *tend* to have future change risk. (Also, your suggestion of a MIME type suggested (to me) that you were getting into dynamically probing some rendering capability in the browser, which gets more complicated). >From the use case you describe (a JSON model rendered my three.js), I would just do your approach #2: create a completely self-contained Javascript() cell result. The sample Javascript notebook I originally mentioned uses three.js as the example of an external library, and shows you how to navigate some of the nuances with that (e.g. the event loop): http://nbviewer.ipython.org/github/payne92/notebooks/blob/master/00%20Javascript%20In%20Notebooks.ipynb If you care about non-WebGL cases, your Javascript code should probe for WebGL and fall back to rendering your PNG if it is not present. If you care about non-Web IPython notebooks (e.g. qtconsole), return a Python object with two repr methods: _repr_javascript_() and _repr_png_(). The notebook runtime will pick the "best" based on what's available: PNG on qtconsole, and Javascript on the Web. (Personally, I wouldn't worry too much about this: I think the Web notebook is the future). -andy > Let's take an example. Imagine I want to display 3D models in a > notebook using a JS library (like three.js). > > Approach 1: > > * My cell's output contains data in several mime types: PNG with a > screenshot, and OBJ (for example) with the full 3D model. It seems to > me that the nbformat is designed for this (multiple MIME types > representing the same logical data). > > * If the client understands the OBJ mime type, it displays it using > three.js. > > * Otherwise, it just displays the PNG screenshot. > > Approach 2 would be to embed the entire Javascript code in the output > + <script include jslibraries> (like you suggest, and like mpld3 does, > unless I'm mistaken) > > I guess my questions are: > > * Which of those two approaches is recommended by IPython devs? > * Is the notebook designed for approach 1 use-case or not? > > It seems to me that approach 1 is cleaner while approach 2 looks like > a hack, but that's just my opinion. > > Best, > Cyrille > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140712/73081101/attachment.html> From bjorn.madsen at operationsresearchgroup.com Sun Jul 13 07:12:24 2014 From: bjorn.madsen at operationsresearchgroup.com (Bjorn Madsen) Date: Sun, 13 Jul 2014 12:12:24 +0100 Subject: [IPython-dev] Activate python3 on windows Message-ID: <CALCPZ6c6zQXkqSjxnyA5Hw4nyqb5A3gDpW6eHuJYPKfaBtSwhg@mail.gmail.com> Hello - I have one of those days where I am questioning my grammar-school skills... On a fresh anaconda install I use cmd.exe and successfully create a new environment: C:\Anaconda>conda create -n py3k python=3 with python-3.4.1 package as the only installed package (perfect) and Proceed ([y]/n)? = y Anaconda fetches, extracts and links the package(s), and provides the helpful message: # # To activate this environment, use: # > activate py3k # To which I merryly type: C:\Anaconda>activate py3k and cmd.exe prints: Activating environment "py3k"... In the attempt: [py3k] C:\Anaconda>ipython qtconsole the result is python 2.7.6 which is a surprise. In the second attempt: [py3k] C:\Anaconda> ipython qtconsole --profile=py3k the result is still python 2.7.6 The intention is to have a ipython qtconsole running python 3 using anaconda. What am I to jet-lagged to get? PS. If it can be done without activating a new environment, then please share how... Kind regards, -- Bjorn Madsen *Researcher Complex Systems Research* Ph.: (+44) 0 7792 030 720 bjorn.madsen at operationsresearchgroup.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/ad2cd9e7/attachment.html> From python at elbonia.de Sun Jul 13 07:20:55 2014 From: python at elbonia.de (Juergen Hasch) Date: Sun, 13 Jul 2014 13:20:55 +0200 Subject: [IPython-dev] Activate python3 on windows In-Reply-To: <CALCPZ6c6zQXkqSjxnyA5Hw4nyqb5A3gDpW6eHuJYPKfaBtSwhg@mail.gmail.com> References: <CALCPZ6c6zQXkqSjxnyA5Hw4nyqb5A3gDpW6eHuJYPKfaBtSwhg@mail.gmail.com> Message-ID: <53C26B97.80704@elbonia.de> You have to install IPython in your environment, too. Try "conda list" to see what packeges are installed. If you do "conda install ipython" it should give you IPython with Python 3. Am 13.07.2014 13:12, schrieb Bjorn Madsen: > Hello - I have one of those days where I am questioning my grammar-school skills... > > On a fresh anaconda install I use cmd.exe and successfully create a new environment: > C:\Anaconda>conda create -n py3k python=3 > with python-3.4.1 package as the only installed package (perfect) and > Proceed ([y]/n)? > = y > Anaconda fetches, extracts and links the package(s), and provides the helpful message: > # > # To activate this environment, use: > # > activate py3k > # > To which I merryly type: > C:\Anaconda>activate py3k > and cmd.exe prints: > Activating environment "py3k"... > In the attempt: > [py3k] C:\Anaconda>ipython qtconsole > the result is python 2.7.6 which is a surprise. > In the second attempt: > [py3k] C:\Anaconda> ipython qtconsole --profile=py3k > the result is still python 2.7.6 > > The intention is to have a ipython qtconsole running python 3 using anaconda. What am I to jet-lagged to get? > > PS. If it can be done without activating a new environment, then please share how... > > Kind regards, > > -- > Bjorn Madsen > /Researcher Complex Systems Research/ > Ph.: (+44) 0 7792 030 720 > bjorn.madsen at operationsresearchgroup.com <mailto:bjorn.madsen at operationsresearchgroup.com> > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From bjorn.madsen at operationsresearchgroup.com Sun Jul 13 07:56:21 2014 From: bjorn.madsen at operationsresearchgroup.com (Bjorn Madsen) Date: Sun, 13 Jul 2014 12:56:21 +0100 Subject: [IPython-dev] Activate python3 on windows In-Reply-To: <53C26B97.80704@elbonia.de> References: <CALCPZ6c6zQXkqSjxnyA5Hw4nyqb5A3gDpW6eHuJYPKfaBtSwhg@mail.gmail.com> <53C26B97.80704@elbonia.de> Message-ID: <CALCPZ6eHuRCp16d5trv4_jBeHvu9Tr+-2fmoe815NdBLpR=+nQ@mail.gmail.com> Success... Thanks Juergen :-) On 13 July 2014 12:20, Juergen Hasch <python at elbonia.de> wrote: > You have to install IPython in your environment, too. > > Try "conda list" to see what packeges are installed. > If you do "conda install ipython" it should give you IPython with Python 3. > > > Am 13.07.2014 13:12, schrieb Bjorn Madsen: > > Hello - I have one of those days where I am questioning my > grammar-school skills... > > > > On a fresh anaconda install I use cmd.exe and successfully create a new > environment: > > C:\Anaconda>conda create -n py3k python=3 > > with python-3.4.1 package as the only installed package (perfect) and > > Proceed ([y]/n)? > > = y > > Anaconda fetches, extracts and links the package(s), and provides the > helpful message: > > # > > # To activate this environment, use: > > # > activate py3k > > # > > To which I merryly type: > > C:\Anaconda>activate py3k > > and cmd.exe prints: > > Activating environment "py3k"... > > In the attempt: > > [py3k] C:\Anaconda>ipython qtconsole > > the result is python 2.7.6 which is a surprise. > > In the second attempt: > > [py3k] C:\Anaconda> ipython qtconsole --profile=py3k > > the result is still python 2.7.6 > > > > The intention is to have a ipython qtconsole running python 3 using > anaconda. What am I to jet-lagged to get? > > > > PS. If it can be done without activating a new environment, then please > share how... > > > > Kind regards, > > > > -- > > Bjorn Madsen > > /Researcher Complex Systems Research/ > > Ph.: (+44) 0 7792 030 720 > > bjorn.madsen at operationsresearchgroup.com <mailto: > bjorn.madsen at operationsresearchgroup.com> > > > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Bjorn Madsen *Researcher Complex Systems Research* Ph.: (+44) 0 7792 030 720 bjorn.madsen at operationsresearchgroup.com -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/6d630c98/attachment.html> From max_linke at gmx.de Thu Jul 10 08:19:24 2014 From: max_linke at gmx.de (Max Linke) Date: Thu, 10 Jul 2014 14:19:24 +0200 Subject: [IPython-dev] Memory consumption of running notebook In-Reply-To: <CAPET0ywvRQthgDtkX7M9Q5OdneZo+6eG_y0=nOuUZtAWdKp97w@mail.gmail.com> References: <1404983943.13472.1.camel@archi> <CAPET0ywvRQthgDtkX7M9Q5OdneZo+6eG_y0=nOuUZtAWdKp97w@mail.gmail.com> Message-ID: <1404994764.14702.1.camel@archi> On Thu, 2014-07-10 at 10:42 +0100, Ingolf Becker wrote: > Which OS are you using? On unix based systems, the one liner > `!cat /proc/{os.getpid()}/status | grep VmSize` Yeah that works and helps already thanks. best Max > will give you the memory occupied by the current ipython process. You can > of course run that command in parallel on all nodes. If you want more > functionality, or you are on Windows, I suppose you could do something like > [1]. > > I hope this helps! > > [1] > https://stackoverflow.com/questions/938733/total-memory-used-by-python-process > > > > > On 10 July 2014 10:19, Max Linke <max_linke at gmx.de> wrote: > > > Hi > > > > I often have 10 and more notebooks running at the same time. It can > > happen that one or two of them contain large arrays that fill up my memory > > and it is not obvious from the cell-content which notebook consumes the > > most memory. > > Is there a way to see how much memory each notebook is roughly using? > > If I understand the notebooks correct a new python process is started > > for each running notebook, then I would already be happy with a way to > > see which process is running which notebook. > > > > best Max > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From andy at payne.org Sun Jul 13 11:12:05 2014 From: andy at payne.org (Andrew Payne) Date: Sun, 13 Jul 2014 11:12:05 -0400 Subject: [IPython-dev] Memory consumption of running notebook In-Reply-To: <CAHNn8BW1M=bG6t3STfzoXwqSEj95NRh5PV9p=Kk86WZ8yqMzbQ@mail.gmail.com> References: <1404983943.13472.1.camel@archi> <CAPET0ywvRQthgDtkX7M9Q5OdneZo+6eG_y0=nOuUZtAWdKp97w@mail.gmail.com> <CAHNn8BW1M=bG6t3STfzoXwqSEj95NRh5PV9p=Kk86WZ8yqMzbQ@mail.gmail.com> Message-ID: <CABbuyuW9Qy6N77so5sPWMOk8ggt=pcqP3qw-ACA+bZ1yOg+j=g@mail.gmail.com> > It might make sense to put some resource info in the Running tab. > Perhaps you have the kernel provide a status object summarizing current resource usage (CPU load, memory, CPU cycles used, garbage collection, etc.) in the display formatter convention (e.g. _repr_html_() etc). All front ends can display the basic text rendering, but this would enable fancier graphic/HTML/Javascript/interactive renderings for the Web front end. Also, consider adding it as an option under the "Kernel" menu on the Web notebook UI page. -andy -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/4db5f0bd/attachment.html> From sylvain.corlay at gmail.com Sun Jul 13 14:28:49 2014 From: sylvain.corlay at gmail.com (Sylvain Corlay) Date: Sun, 13 Jul 2014 14:28:49 -0400 Subject: [IPython-dev] ijulia? In-Reply-To: <B3D16462-DF0D-4263-8FA4-C8529C00DDA7@gmail.com> References: <CACLE5GDudtHNhivKxQCBodjvF-A0GHDfW4hCwj1rJmje6J85+w@mail.gmail.com> <B3D16462-DF0D-4263-8FA4-C8529C00DDA7@gmail.com> Message-ID: <CAK=Phk46nCw-W6-u9tczVj3QQRv=9cm1vesVgKrhEyf+BpT-jw@mail.gmail.com> I agree that it would be relevant to have some language information in the metadata of the ipynb file, but not directly the backend name, to allow concurrent backends to coexist for a given language. This would be very useful to people developing kernels. The different backends could be registered in ipython_notebook_config.py -the executable -the name of the corresponding language -a short user-friendly name for the backend . When opening a notebook from the dashboard, a warning could be triggered or a choice could be given depending on whether multiple or no backend is available. Cheers, On Tue, Jul 8, 2014 at 1:44 PM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > It does work in here. > > You need to install IJulia from within a Julia repl. > > > Pkg.add('IJulia') > > IJulia should create the julia profile by itself during the install. IIRC > you can use > > > Pkg.build('IJulia') > > to be sure. > > you can then start ipython --profile=julia with --debug flag to get more > info : > > > in particular you want line like : > > [ZMQTerminalIPythonApp] {'BaseIPythonApplication': {'profile': 'julia'}, > 'Application': {'log_level': 10}, > 'KernelManager': {'kernel_cmd': ['~/julia/usr/bin/julia', '-F', > '~/.julia/IJulia/src/kernel.jl', '{connection_file}'] > }} > > below is the full output for me (in IPython 3.0): > -- > M > > $ ipython console --profile=julia --debug > > [ZMQTerminalIPythonApp] Config changed: > [ZMQTerminalIPythonApp] {'BaseIPythonApplication': {'profile': 'julia'}, > 'Application': {'log_level': 10}} > [ZMQTerminalIPythonApp] IPYTHONDIR set to: > /Users/bussonniermatthias/.ipython > [ZMQTerminalIPythonApp] Using existing profile dir: > '/Users/bussonniermatthias/.ipython/profile_julia' > [ZMQTerminalIPythonApp] Searching path > ['/Users/bussonniermatthias/dissertation', > '/Users/bussonniermatthias/.ipython/profile_julia'] for config files > [ZMQTerminalIPythonApp] Attempting to load config file: ipython_config.py > [ZMQTerminalIPythonApp] Loaded config file: > /Users/bussonniermatthias/.ipython/profile_julia/ipython_config.py > [ZMQTerminalIPythonApp] Config changed: > [ZMQTerminalIPythonApp] {'BaseIPythonApplication': {'profile': 'julia'}, > 'Application': {'log_level': 10}, 'KernelManager': {'kernel_cmd': > ['/Users/bussonniermatthias/julia/usr/bin/julia', '-F', > '/Users/bussonniermatthias/.julia/IJulia/src/kernel.jl', > '{connection_file}']}} > [ZMQTerminalIPythonApp] Attempting to load config file: > ipython_console_config.py > [ZMQTerminalIPythonApp] Connection File not found: > /Users/bussonniermatthias/.ipython/profile_julia/security/kernel-43123.json > /Users/bussonniermatthias/ipython/IPython/kernel/manager.py:87: > UserWarning: Setting kernel_cmd is deprecated, use kernel_spec to start > different kernels. # you shouldn't get that in 2.0. > warnings.warn("Setting kernel_cmd is deprecated, use kernel_spec to " > [ZMQTerminalIPythonApp] Connecting to: tcp://127.0.0.1:51318 > [ZMQTerminalIPythonApp] connecting shell channel to tcp://127.0.0.1:51315 > [ZMQTerminalIPythonApp] connecting iopub channel to tcp://127.0.0.1:51316 > [ZMQTerminalIPythonApp] connecting stdin channel to tcp://127.0.0.1:51317 > [ZMQTerminalIPythonApp] connecting heartbeat channel to tcp:// > 127.0.0.1:51319 > IPython Console 3.0.0-dev > > IPython profile: julia > > [ZMQTerminalIPythonApp] Loading IPython extensions... > [ZMQTerminalIPythonApp] Loading IPython extension: storemagic > [ZMQTerminalIPythonApp] Starting IPython's mainloop... > Starting kernel event loops. > > In [1]: 2 > Out[1]: 2 > > In [2]: ans > Out[2]: 2 > > In [3]: > > Le 8 juil. 2014 ? 19:31, William Stein a ?crit : > > > Hi, > > > > I keep getting requests for IJulia > > (https://github.com/JuliaLang/IJulia.jl) support in SageMathCloud. > > > > However, all my many attempts to get anywhere with IJulia so far have > > completely failed, and I have no clue even how to successfully install > > it. I've tried the directions, which all seem to work with no errors. > > However, the end result is that things just don't work at all. In > > particular, despite IPython claiming to load with the 'julia' profile, > > it's still just plain ipython (in julia ans would be 2 below): > > > > ~/salvus/salvus$ ipython console --profile julia > > Python 2.7.5 (default, May 5 2014, 17:28:45) > > Type "copyright", "credits" or "license" for more information. > > IPython 2.1.0 -- An enhanced Interactive Python. > > IPython profile: julia > > In [1]: 2 > > Out[1]: 2 > > In [2]: ans > > > --------------------------------------------------------------------------- > > NameError Traceback (most recent call > last) > > > > > > > > QUESTION: Does anybody reading this use IJulia? Is it even supposed > > to work with IPython 2.1? > > > > -- William > > > > > > -- > > William Stein > > Professor of Mathematics > > University of Washington > > http://wstein.org > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/55c42569/attachment.html> From markbak at gmail.com Sun Jul 13 16:27:04 2014 From: markbak at gmail.com (Mark Bakker) Date: Sun, 13 Jul 2014 22:27:04 +0200 Subject: [IPython-dev] %%markdown or %loadmarkdown ? Message-ID: <CAEX=yabtsT02nFTa41k5N30_uCpqh14oeWaRwxaMSByUOvvUSw@mail.gmail.com> I was wondering whether there is something like a %% markdown magic that changes a code cell to markdown. I want to use this with the %load command. So actually, a %loadmarkdown would be even better Usage: In class assignments I want the students to load exercises (written in markdown) from a server. Sure, I can let them do a %load and then manually change the cell to markdown, but it would be much nicer if it changes automatically. And I think others will find use for such functionality. Thanks, Mark -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/caba0e8f/attachment.html> From rgbkrk at gmail.com Sun Jul 13 17:56:25 2014 From: rgbkrk at gmail.com (Kyle Kelley) Date: Sun, 13 Jul 2014 15:56:25 -0600 Subject: [IPython-dev] =?utf-8?q?Vulnerability_in_IPython_Notebook_?= =?utf-8?b?4omkIDEuMQ==?= Message-ID: <CA+tbMaVhkrHm85T=jKL31=6avhNh5-=mQ+h-XkNaWN8_5hbBEg@mail.gmail.com> Everyone, On IPython ? 1.1, a remote site could have exploited a vulnerability in cross origin websocket handling to execute code on an IPython kernel, with knowledge of the kernel id (which requires user intervention). This vulnerability was patched in https://github.com/ipython/ipython/pull/4845 and reported to the CVE (Common Vulnerabilities and Exposure) database. Summary given to the CVE database: The origin of websocket requests was not verified within the IPython notebook server. If an attacker has knowledge of an IPython kernel id they can run arbitrary code on a user's machine when the client visits a crafted malicious page. The CVE ID is CVE-2014-342 ( http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-342). If you were at SciPy and watched the final round of lightning talks, you already know about this vulnerability (as much as you can within a 5 minute talk that is). I wrote a more detailed explanation at http://lambdaops.com/cross-origin-websocket-hijacking-of-ipython Feel free to ask us (the IPython team) any questions! Regards, Kyle Kelley -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/bdcaf500/attachment.html> From benjaminrk at gmail.com Sun Jul 13 22:39:57 2014 From: benjaminrk at gmail.com (MinRK) Date: Sun, 13 Jul 2014 19:39:57 -0700 Subject: [IPython-dev] Recommended hardware specs? In-Reply-To: <CAOvn4qi16a7vxVe4VDOmFA4rOQ6_oeuPxJR_Z+FysedPCaytqg@mail.gmail.com> References: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> <CAKWq6+ey-wx4LcQ39LEKonMQJFi5Pfjb50qL-TZWsuHT99wX2A@mail.gmail.com> <CAOvn4qi16a7vxVe4VDOmFA4rOQ6_oeuPxJR_Z+FysedPCaytqg@mail.gmail.com> Message-ID: <CAHNn8BVU62PMVLwrOdV0Xa=ZWywjT9sApAxNt-6mtiyvRK71JA@mail.gmail.com> Right. For simple IPython Notebook usage, a Raspberry Pi is plenty. IPython itself doesn't consume much. Rather, what you do in an IPython session (with numpy, scipy, scikit-learn, etc.) will govern what you need. -MinRK On Fri, Jul 11, 2014 at 7:35 AM, Thomas Kluyver <takowl at gmail.com> wrote: > IPython itself doesn't have any special resource requirements - any > reasonably recent machine should be capable of running it. The question is > more likely to hinge on what you're trying to do in IPython: if you're > using a lot of big arrays, you'll need a lot of memory, for instance. > > > On 11 July 2014 05:54, Jasmine Lognnes <princess.jasmine.lognnes at gmail.com > > wrote: > >> Btw. It is server side hw specs I am interested in =) >> >> >> >> On 11 July 2014 12:02, Jasmine Lognnes >> <princess.jasmine.lognnes at gmail.com> wrote: >> > Dear developers =) >> > >> > Does anyone know the recommended hardware specs for one instance of >> > IPython? Numer of CPU's, speed and memory. >> > >> > Hugs, >> > Jasmine =) >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/7338b433/attachment.html> From takowl at gmail.com Sun Jul 13 22:48:29 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Sun, 13 Jul 2014 21:48:29 -0500 Subject: [IPython-dev] Memory consumption of running notebook In-Reply-To: <CABbuyuW9Qy6N77so5sPWMOk8ggt=pcqP3qw-ACA+bZ1yOg+j=g@mail.gmail.com> References: <1404983943.13472.1.camel@archi> <CAPET0ywvRQthgDtkX7M9Q5OdneZo+6eG_y0=nOuUZtAWdKp97w@mail.gmail.com> <CAHNn8BW1M=bG6t3STfzoXwqSEj95NRh5PV9p=Kk86WZ8yqMzbQ@mail.gmail.com> <CABbuyuW9Qy6N77so5sPWMOk8ggt=pcqP3qw-ACA+bZ1yOg+j=g@mail.gmail.com> Message-ID: <CAOvn4qib4BjMZFK63vcRNoRsik3FLt+WvcuLSQwKPQO1F49x1g@mail.gmail.com> On 13 Jul 2014 18:35, "Andrew Payne" <andy at payne.org> wrote: > Perhaps you have the kernel provide a status object summarizing current resource usage (CPU load, memory, CPU cycles used, garbage collection, etc.) in the display formatter convention (e.g. _repr_html_() etc). I think this should mostly be in the server, not the kernel - it's something that would be useful for all kernels, but there's no need to reimplement it in each language. What could be useful in the kernel is a way to discover what objects are using most memory. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/6022b62d/attachment.html> From benjaminrk at gmail.com Sun Jul 13 23:06:24 2014 From: benjaminrk at gmail.com (MinRK) Date: Sun, 13 Jul 2014 20:06:24 -0700 Subject: [IPython-dev] [sage-cloud] ijulia? In-Reply-To: <CACLE5GCgXWi+8Li3tGXc7t0nk7WBT8u4g1sa1M5FM+=SJ1L=zA@mail.gmail.com> References: <CACLE5GDudtHNhivKxQCBodjvF-A0GHDfW4hCwj1rJmje6J85+w@mail.gmail.com> <53BC3C53.6020402@creativetrax.com> <53BD56DA.2000706@creativetrax.com> <CACLE5GDA4sqohWJYTxfmDFgV5xTEioP2y1GnmtXw_kguU6RAtQ@mail.gmail.com> <53BD70AF.7050106@creativetrax.com> <192686da-2a2a-4fb7-ba04-edaea4a8d7a3@googlegroups.com> <CALVmk4G_NviFP+220sMt3KZz9q5Au1O7gjYUsbYcPQzS0U+aqw@mail.gmail.com> <ccf45233-1d2c-426d-a9a8-1cc10e0b39e7@googlegroups.com> <CALVmk4HipuFG7qbgUoZ6kMjg3UvOWOiEYOyxmfoK4QRXwZnc+A@mail.gmail.com> <CAGG4CB65WdtCh+gFHxxGe6jAKieWwqwjRbb1USwqqUOO8=6XJQ@mail.gmail.com> <CACLE5GCgXWi+8Li3tGXc7t0nk7WBT8u4g1sa1M5FM+=SJ1L=zA@mail.gmail.com> Message-ID: <CAHNn8BVsqE7L1jZZpXe2oQ2y8onbQPGpGvmcQGBvU9MNKfe6KQ@mail.gmail.com> On Sat, Jul 12, 2014 at 8:09 AM, William Stein <wstein at gmail.com> wrote: > On Sat, Jul 12, 2014 at 8:02 AM, Harald Schilly > <harald.schilly at gmail.com> wrote: > > On Sat, Jul 12, 2014 at 4:32 PM, William A Stein <wstein at uw.edu> wrote: > >> I'll write to IPython-dev. The problem isn't about determining > >> whether somebody started the ipython notebook server in julia mode, > >> but determining which mode the IPython notebook *needs* to be started > >> in order to open a given ipynb document. > > > > To me, this looks like there must be a convention to store that > > information in the ipynb metadata. Right now, I can only see "name" > > and "signature". My first idea would be to add an additional key > > "backend" (?) and the values are "ipython", "python", "julia", "R", > > "sage", ... with the default being "ipython" of course. > > Is this is a suggestion for a way to change IPython notebook itself? > > For IPython users: If you start an IPython notebook server (say in > python mode) and try to open a notebook with backend:'julia', would it > just give an error and tell the user to run another notebook server > with a julia backend? > > For SageMathCloud users: I can write code to start several notebook > servers, which run simulaneously, I guess, assuming their state files > don't conflict. > IPython 3 adds a 'kernel spec' for describing different kinds of kernels, so there won't be a reason to have separate notebook servers for different kernels. PR #6126 <https://github.com/ipython/ipython/pull/6126> adds one of the last pieces for this, so you can switch kernels at runtime, and associate a notebook with a given kernel. -MinRK > > -- William > > > > > Harald > > > > -- > > You received this message because you are subscribed to the Google > Groups "sage-cloud" group. > > To unsubscribe from this group and stop receiving emails from it, send > an email to sage-cloud+unsubscribe at googlegroups.com. > > To view this discussion on the web visit > https://groups.google.com/d/msgid/sage-cloud/CAGG4CB65WdtCh%2BgFHxxGe6jAKieWwqwjRbb1USwqqUOO8%3D6XJQ%40mail.gmail.com > . > > For more options, visit https://groups.google.com/d/optout. > > > > -- > William Stein > Professor of Mathematics > University of Washington > http://wstein.org > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140713/57136f2f/attachment.html> From rgbkrk at gmail.com Mon Jul 14 11:20:13 2014 From: rgbkrk at gmail.com (Kyle Kelley) Date: Mon, 14 Jul 2014 09:20:13 -0600 Subject: [IPython-dev] =?utf-8?q?Vulnerability_in_IPython_Notebook_?= =?utf-8?b?4omkIDEuMQ==?= In-Reply-To: <CA+tbMaVhkrHm85T=jKL31=6avhNh5-=mQ+h-XkNaWN8_5hbBEg@mail.gmail.com> References: <CA+tbMaVhkrHm85T=jKL31=6avhNh5-=mQ+h-XkNaWN8_5hbBEg@mail.gmail.com> Message-ID: <CA+tbMaVRpHiiH5yAMTwWfCqDZT5=4iPrwh5E5nDTCkqvsMZfpA@mail.gmail.com> Whoops! Correction, CVE ID was truncated. It should read: The CVE ID is CVE-2014-3429 ( http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-3429). On Sun, Jul 13, 2014 at 3:56 PM, Kyle Kelley <rgbkrk at gmail.com> wrote: > Everyone, > > On IPython ? 1.1, a remote site could have exploited a vulnerability in > cross origin websocket handling to execute code on an IPython kernel, with > knowledge of the kernel id (which requires user intervention). > > This vulnerability was patched in > https://github.com/ipython/ipython/pull/4845 and reported to the CVE > (Common Vulnerabilities and Exposure) database. > > Summary given to the CVE database: The origin of websocket requests was > not verified within the IPython notebook server. If an attacker has > knowledge of an IPython kernel id they can run arbitrary code on a user's > machine when the client visits a crafted malicious page. > > The CVE ID is CVE-2014-342 ( > http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-342). > > If you were at SciPy and watched the final round of lightning talks, you > already know about this vulnerability (as much as you can within a 5 minute > talk that is). > > I wrote a more detailed explanation at > http://lambdaops.com/cross-origin-websocket-hijacking-of-ipython > > Feel free to ask us (the IPython team) any questions! > > Regards, > > Kyle Kelley > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140714/b7e9d9fd/attachment.html> From bussonniermatthias at gmail.com Mon Jul 14 11:52:26 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 14 Jul 2014 17:52:26 +0200 Subject: [IPython-dev] IPython circuit editing widget In-Reply-To: <E1061BD3-C522-4D06-A5CE-DC66DFAD92C5@stanford.edu> References: <E1061BD3-C522-4D06-A5CE-DC66DFAD92C5@stanford.edu> Message-ID: <D488D715-0325-48B5-941D-157F7E463E8D@gmail.com> Hi Nik ! Talk is online : Demo start around 12min. http://youtu.be/-kUzWdKOgqc?t=12m33s Looks **really** super nice ! -- M Le 10 juil. 2014 ? 23:11, Nikolas Tezak a ?crit : > Hi everybody, > > here's a link to the visual circuit editing / schematic capture widget in the notebook I presented at SciPy today. > It?s still pretty rough and I?m not exactly proud of my JS skills but it already works pretty well! > > Maybe someone else can reuse this if they are creating a complex SVG based interactive widget. > > The repo > https://github.com/ntezak/cirq > > The talk > https://conference.scipy.org/scipy2014/schedule/presentation/1743/ > > If anybody is interested I can make my slides available somewhere, too. > Best, > > Nik > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From takowl at gmail.com Mon Jul 14 14:25:59 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 14 Jul 2014 11:25:59 -0700 Subject: [IPython-dev] [sage-cloud] ijulia? In-Reply-To: <CACLE5GCgXWi+8Li3tGXc7t0nk7WBT8u4g1sa1M5FM+=SJ1L=zA@mail.gmail.com> References: <CACLE5GDudtHNhivKxQCBodjvF-A0GHDfW4hCwj1rJmje6J85+w@mail.gmail.com> <53BC3C53.6020402@creativetrax.com> <53BD56DA.2000706@creativetrax.com> <CACLE5GDA4sqohWJYTxfmDFgV5xTEioP2y1GnmtXw_kguU6RAtQ@mail.gmail.com> <53BD70AF.7050106@creativetrax.com> <192686da-2a2a-4fb7-ba04-edaea4a8d7a3@googlegroups.com> <CALVmk4G_NviFP+220sMt3KZz9q5Au1O7gjYUsbYcPQzS0U+aqw@mail.gmail.com> <ccf45233-1d2c-426d-a9a8-1cc10e0b39e7@googlegroups.com> <CALVmk4HipuFG7qbgUoZ6kMjg3UvOWOiEYOyxmfoK4QRXwZnc+A@mail.gmail.com> <CAGG4CB65WdtCh+gFHxxGe6jAKieWwqwjRbb1USwqqUOO8=6XJQ@mail.gmail.com> <CACLE5GCgXWi+8Li3tGXc7t0nk7WBT8u4g1sa1M5FM+=SJ1L=zA@mail.gmail.com> Message-ID: <CAOvn4qiN=520RyWShecK_QuvaR5+jNHdzGUZq+Ynz13Ar_Ej2Q@mail.gmail.com> On 12 July 2014 08:09, William Stein <wstein at gmail.com> wrote: > > To me, this looks like there must be a convention to store that > > information in the ipynb metadata. Right now, I can only see "name" > > and "signature". My first idea would be to add an additional key > > "backend" (?) and the values are "ipython", "python", "julia", "R", > > "sage", ... with the default being "ipython" of course. > > Is this is a suggestion for a way to change IPython notebook itself? > > For IPython users: If you start an IPython notebook server (say in > python mode) and try to open a notebook with backend:'julia', would it > just give an error and tell the user to run another notebook server > with a julia backend? > No, there will be no need to start another server, the server will simply start the appropriate kernel. Our metadata format is a bit different - rather than a single value, it will be a dictionary of several values, so that, for instance, highlighting can be done correctly even if the relevant kernel isn't installed. It will look something like this: "metadata": {"kernelspec": {"name": "ijulia", "language": "julia", "codemirror_mode": "julia"}, ...} For more details see these links: https://github.com/ipython/ipython/wiki/IPEP-25:-Registry-of-installed-kernels https://github.com/ipython/ipython/pull/6126 Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140714/a3123afe/attachment.html> From erik.m.bray at gmail.com Mon Jul 14 18:14:52 2014 From: erik.m.bray at gmail.com (Erik Bray) Date: Mon, 14 Jul 2014 18:14:52 -0400 Subject: [IPython-dev] IPython circuit editing widget In-Reply-To: <E1061BD3-C522-4D06-A5CE-DC66DFAD92C5@stanford.edu> References: <E1061BD3-C522-4D06-A5CE-DC66DFAD92C5@stanford.edu> Message-ID: <CAOTD34Y6qfiafjayEtS=SqUEvbZfRwvbHBqpCmZf8Xg9uHRx6g@mail.gmail.com> On Thu, Jul 10, 2014 at 5:11 PM, Nikolas Tezak <ntezak at stanford.edu> wrote: > Hi everybody, > > here's a link to the visual circuit editing / schematic capture widget in the notebook I presented at SciPy today. > It?s still pretty rough and I?m not exactly proud of my JS skills but it already works pretty well! > > Maybe someone else can reuse this if they are creating a complex SVG based interactive widget. > > The repo > https://github.com/ntezak/cirq > > The talk > https://conference.scipy.org/scipy2014/schedule/presentation/1743/ > > If anybody is interested I can make my slides available somewhere, too. > Best, That looks very cool! I don't know how I missed this at SciPy. I will have to see if I can adapt this for use in my PyQC package [1] where interactive circuit editing is a big want (currently circuits are just displayed as static images rendered from LaTeX. I'll let you know how it goes once I get around to it. Thanks, Erik [1] https://bitbucket.org/embray/pyqc From ribonucleico at gmail.com Tue Jul 15 09:02:16 2014 From: ribonucleico at gmail.com (Josh Wasserstein) Date: Tue, 15 Jul 2014 09:02:16 -0400 Subject: [IPython-dev] Step-by-step debugging with IPython Message-ID: <CAD4ivxVa3SV8PGYFOrM3oavAyWU+7h4BE2S_pUihAJS4zzdExA@mail.gmail.com> Hi, I use IPython every day in my work, and want to strongly congratulate Fernando P, Min RK, T. Kluyver, J. Frederic, etc. and the rest of the IPython dev community for the effort they have put over the years to bring it to where it is. This software and the vision put forward is making a difference in industry and academia. One thing I sorely miss since I started using IPython ~2 years ago is the ability to do step-by-step debugging with IPython. From conversations with peers and my own survey on the topic <http://stackoverflow.com/questions/16867347/step-by-step-debugging-with-ipython>, I think there is quite a strong interest in having a full-fledged IPython debugger. Still the accepted answer to that post seems to be the only solution so far, and as I explain in it, it has its limitations. This makes me wonder if: 1) I am doing things wrong 2) The current status of IPython does not provide the debugging functionality stated in the OP. And the reason behind 2) could be: a. Limitations of Python / execution model that make this inviable b. There is not enough interest to justify an effort to improve the debugging model / the relatively high complexity required to have Python / IPython support this workflow I think the original question in SO explains well the workflow and features that I think would make IPython a great companion for debugging, but let me know otherwise. Any insight on the topic would be very helpful. Thanks again for all the great work! Josh -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140715/9c97984e/attachment.html> From ASchneiderman at asha.org Tue Jul 15 11:18:48 2014 From: ASchneiderman at asha.org (Anders Schneiderman) Date: Tue, 15 Jul 2014 11:18:48 -0400 Subject: [IPython-dev] How to display really long strings? Message-ID: <93268EE5694C0A4BBB888C2EEFEEEC22B3EDB90226@EXCH2008.hq.asha.org> I need to do a series of transformations to a column in a pandas data frame that contains very long strings. When I try to display the column via head, etc, IPython Notebook truncates it - a totally understandable approach for most long strings, but it means I can't see whether the transformations were done properly. Any thoughts about a one-off workaround? I took a look at the documentation but couldn't figure out how to do it. Thanks! Anders Schneiderman Database Services Manager | ASHA | (301) 296-8651 -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140715/f32cfaaa/attachment.html> From ntezak at stanford.edu Tue Jul 15 21:15:29 2014 From: ntezak at stanford.edu (Nikolas Tezak) Date: Tue, 15 Jul 2014 18:15:29 -0700 Subject: [IPython-dev] IPython circuit editing widget In-Reply-To: <CAOTD34Y6qfiafjayEtS=SqUEvbZfRwvbHBqpCmZf8Xg9uHRx6g@mail.gmail.com> References: <E1061BD3-C522-4D06-A5CE-DC66DFAD92C5@stanford.edu> <CAOTD34Y6qfiafjayEtS=SqUEvbZfRwvbHBqpCmZf8Xg9uHRx6g@mail.gmail.com> Message-ID: <80DCDD78-95C3-436C-B387-A9272B497B4A@stanford.edu> Thanks guys, I have updated and cleaned up the package quite a bit today, and added a proper BSD license statement! @Erik, your package is interesting! Have you seen my own QNET package yet? Between your package, sympy?s quantum physics module (which Robert Johansson from QuTiP has been extending) and my own package there seems to be significant overlap. Maybe we could join forces and create one really nice quantum algebra package (and include that with sympy). I was already talking about this with Brian Granger at SciPy. If you?d like more information on how to customize the visual layout and representation of the components and ports, let me know! Best, Nik On Jul 14, 2014, at 3:14 PM, Erik Bray <erik.m.bray at gmail.com> wrote: > On Thu, Jul 10, 2014 at 5:11 PM, Nikolas Tezak <ntezak at stanford.edu> wrote: >> Hi everybody, >> >> here's a link to the visual circuit editing / schematic capture widget in the notebook I presented at SciPy today. >> It?s still pretty rough and I?m not exactly proud of my JS skills but it already works pretty well! >> >> Maybe someone else can reuse this if they are creating a complex SVG based interactive widget. >> >> The repo >> https://github.com/ntezak/cirq >> >> The talk >> https://conference.scipy.org/scipy2014/schedule/presentation/1743/ >> >> If anybody is interested I can make my slides available somewhere, too. >> Best, > > That looks very cool! I don't know how I missed this at SciPy. I > will have to see if I can adapt this for use in my PyQC package [1] > where interactive circuit editing is a big want (currently circuits > are just displayed as static images rendered from LaTeX. I'll let you > know how it goes once I get around to it. > > Thanks, > > Erik > > > [1] https://bitbucket.org/embray/pyqc > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From jbzdak at gmail.com Wed Jul 16 09:08:44 2014 From: jbzdak at gmail.com (=?UTF-8?Q?mgr_in=C5=BC=2E_Jacek_Bzdak?=) Date: Wed, 16 Jul 2014 15:08:44 +0200 Subject: [IPython-dev] Recommended hardware specs? In-Reply-To: <CAHNn8BVU62PMVLwrOdV0Xa=ZWywjT9sApAxNt-6mtiyvRK71JA@mail.gmail.com> References: <CAKWq6+eVrtrMUBv4xswhN91tM6vNevXesXVTDqF+Bs4QAFsPEg@mail.gmail.com> <CAKWq6+ey-wx4LcQ39LEKonMQJFi5Pfjb50qL-TZWsuHT99wX2A@mail.gmail.com> <CAOvn4qi16a7vxVe4VDOmFA4rOQ6_oeuPxJR_Z+FysedPCaytqg@mail.gmail.com> <CAHNn8BVU62PMVLwrOdV0Xa=ZWywjT9sApAxNt-6mtiyvRK71JA@mail.gmail.com> Message-ID: <CA+FttVNryojSPAEMuTrk4v6U8ugrjXUzGPMtCycZ_RC4b5Bj0w@mail.gmail.com> I have very good experiences with running ipython on bigger machines. You can run ipython notebook on 64 core machine with GBs of RAM and it'll work just fine. IPython parallel library is very straightforward to use. You (with some care) can also write your notebook to run computations on many machines. So what you need is totally dependent on what you do. JB 2014-07-14 4:39 GMT+02:00 MinRK <benjaminrk at gmail.com>: > Right. For simple IPython Notebook usage, a Raspberry Pi is plenty. > IPython itself doesn't consume much. Rather, what you do in an IPython > session (with numpy, scipy, scikit-learn, etc.) will govern what you need. > > -MinRK > > > On Fri, Jul 11, 2014 at 7:35 AM, Thomas Kluyver <takowl at gmail.com> wrote: > >> IPython itself doesn't have any special resource requirements - any >> reasonably recent machine should be capable of running it. The question is >> more likely to hinge on what you're trying to do in IPython: if you're >> using a lot of big arrays, you'll need a lot of memory, for instance. >> >> >> On 11 July 2014 05:54, Jasmine Lognnes < >> princess.jasmine.lognnes at gmail.com> wrote: >> >>> Btw. It is server side hw specs I am interested in =) >>> >>> >>> >>> On 11 July 2014 12:02, Jasmine Lognnes >>> <princess.jasmine.lognnes at gmail.com> wrote: >>> > Dear developers =) >>> > >>> > Does anyone know the recommended hardware specs for one instance of >>> > IPython? Numer of CPU's, speed and memory. >>> > >>> > Hugs, >>> > Jasmine =) >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140716/8887f29b/attachment.html> From tarun.gaba7 at gmail.com Wed Jul 16 12:47:37 2014 From: tarun.gaba7 at gmail.com (TARUN GABA) Date: Wed, 16 Jul 2014 22:17:37 +0530 Subject: [IPython-dev] HTML display does not works when using Widgets Message-ID: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> Hi all I am working on a module, which requires use of IPython widgets and some rendered HTML. I am using the dev branch from the repository. $ ipython --version 3.0.0-dev this is the code snippet, I am trying to implement: def my_func(): HTML("<b>Some html</b>") some_widget.interact #display widget When I call this function from the notebook, only widget is rendered on the output cell, not the HTML. I guess that might be because widgets use different "type" of output method compared to usual output method. Can anybody please point me to the best way to implement it(both HTML and widget in same output cell.) Thanks Tarun Gaba -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140716/2da5831b/attachment.html> From jtaylor.debian at googlemail.com Wed Jul 16 14:19:24 2014 From: jtaylor.debian at googlemail.com (Julian Taylor) Date: Wed, 16 Jul 2014 20:19:24 +0200 Subject: [IPython-dev] =?utf-8?q?Vulnerability_in_IPython_Notebook_?= =?utf-8?b?4omkIDEuMQ==?= In-Reply-To: <CA+tbMaVRpHiiH5yAMTwWfCqDZT5=4iPrwh5E5nDTCkqvsMZfpA@mail.gmail.com> References: <CA+tbMaVhkrHm85T=jKL31=6avhNh5-=mQ+h-XkNaWN8_5hbBEg@mail.gmail.com> <CA+tbMaVRpHiiH5yAMTwWfCqDZT5=4iPrwh5E5nDTCkqvsMZfpA@mail.gmail.com> Message-ID: <53C6C22C.9050009@googlemail.com> Why wasn't this disclosed on the appropriate channels 6 month ago when it was fixed? It didn't even get a proper changelog entry nor did distribution maintainers get informed at all. Remote execution on localhost notebooks is really really bad, even if you do need the kernel id. This should have been posted to oss-security at the latest when 1.2.0 was released ... On 14.07.2014 17:20, Kyle Kelley wrote: > Whoops! > > Correction, CVE ID was truncated. It should read: > > The CVE ID is CVE-2014-3429 > (http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-3429). > > > > On Sun, Jul 13, 2014 at 3:56 PM, Kyle Kelley <rgbkrk at gmail.com > <mailto:rgbkrk at gmail.com>> wrote: > > Everyone, > > On IPython ? 1.1, a remote site could have exploited a vulnerability > in cross origin websocket handling to execute code on an IPython > kernel, with knowledge of the kernel id (which requires user > intervention). > > This vulnerability was patched > in https://github.com/ipython/ipython/pull/4845 and reported to the > CVE (Common Vulnerabilities and Exposure) database. > > Summary given to the CVE database: The origin of websocket requests > was not verified within the IPython notebook server. If an attacker > has knowledge of an IPython kernel id they can run arbitrary code on > a user's machine when the client visits a crafted malicious page. > > The CVE ID is CVE-2014-342 > (http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-342). > > If you were at SciPy and watched the final round of lightning talks, > you already know about this vulnerability (as much as you can within > a 5 minute talk that is). > > I wrote a more detailed explanation > at http://lambdaops.com/cross-origin-websocket-hijacking-of-ipython > > Feel free to ask us (the IPython team) any questions! > > Regards, > > Kyle Kelley > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From nathan12343 at gmail.com Wed Jul 16 18:00:28 2014 From: nathan12343 at gmail.com (Nathan Goldbaum) Date: Wed, 16 Jul 2014 15:00:28 -0700 Subject: [IPython-dev] Aynchronously displaying stdout from parallel engines Message-ID: <CAJXewOmeO6+zhtTeyK5TXEWPry1U19ns+zBumYLJKR5vL_1iUg@mail.gmail.com> Hi all, I'm finding myself dealing with a lengthy computation using an IPython parallel cluster and MPI4py. I'd like to be able to see what my workers are doing while they are doing it. In particular, I'd like to be able to get the stdout stream from each engine and display it somehow in the output of a client notebook. So far I've used AsyncResult.wait_interactive() to see what my workers are doing, but this only shows that my computations haven't completed yet - not what they are doing at any given moment. Is it possible to set up something similar to wait_interactive that can asynchronously stream stdout from each of the workers? Thanks for your help, Nathan -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140716/65699cfa/attachment.html> From jr at sun.ac.za Thu Jul 17 04:19:40 2014 From: jr at sun.ac.za (Johann Rohwer) Date: Thu, 17 Jul 2014 10:19:40 +0200 Subject: [IPython-dev] test from where a module is imported Message-ID: <1851667.fXX6ETTmBj@bc433789> Sorry if this appears multiple times, my first post does not seem to have made it to the list. --------------------------------------------- Hi all, Say I'm developing a Python module and would like to know from where the user imports this module, i.e. from a regular Python shell, an IPython shell, an IPython qtconsole, or an IPython notebook. I would like to enable additional features in my module depending on e.g. useful stuff that is available in the notebook. But I want the module also to be able to be imported and run in any of the other environments, so it's really more like a test from where we are imported. I can think of various hacks on how to achieve this but would like to know if there is The Right Way (TM) and if so, what it is. Thanks, Johann The integrity and confidentiality of this email is governed by these terms / Hierdie terme bepaal die integriteit en vertroulikheid van hierdie epos. http://www.sun.ac.za/emaildisclaimer From dave.hirschfeld at gmail.com Thu Jul 17 06:37:30 2014 From: dave.hirschfeld at gmail.com (Dave Hirschfeld) Date: Thu, 17 Jul 2014 10:37:30 +0000 (UTC) Subject: [IPython-dev] Aynchronously displaying stdout from parallel engines References: <CAJXewOmeO6+zhtTeyK5TXEWPry1U19ns+zBumYLJKR5vL_1iUg@mail.gmail.com> Message-ID: <loom.20140717T123608-581@post.gmane.org> Nathan Goldbaum <nathan12343 <at> gmail.com> writes: > > Hi all, > I'm finding myself dealing with a lengthy computation using an IPython parallel cluster and MPI4py. > > I'd like to be able to see what my workers are doing while they are doing it. ?In particular, I'd like to be able to get the stdout stream from each engine and display it somehow in the output of a client notebook. > > > So far I've used AsyncResult.wait_interactive() to see what my workers are doing, but this only shows that my computations haven't completed yet - not what they are doing at any given moment. ? > > > Is it possible to set up something similar to wait_interactive that can asynchronously stream stdout from each of the workers? > > Thanks for your help, > > Nathan > Fortunately @minrk has a time machine! https://github.com/ipython/ipython/blob/master/examples/Parallel%20Computing /iopubwatcher.py HTH, Dave From will at thearete.co.uk Thu Jul 17 07:50:26 2014 From: will at thearete.co.uk (William Furnass) Date: Thu, 17 Jul 2014 12:50:26 +0100 Subject: [IPython-dev] How to display really long strings? Message-ID: <CAJJEUTLXCJBsZ3w1Xc9X-MyKwebE1mHfHkt9EvwCOSrPRVtrKg@mail.gmail.com> > ---------- Forwarded message ---------- > From: Anders Schneiderman <ASchneiderman at asha.org> > To: "ipython-dev at scipy.org" <ipython-dev at scipy.org> > Cc: > Date: Tue, 15 Jul 2014 11:18:48 -0400 > Subject: [IPython-dev] How to display really long strings? > > I need to do a series of transformations to a column in a pandas data frame that contains very long strings. When I try to display the column via head, etc, IPython Notebook truncates it - a totally understandable approach for most long strings, but it means I can't see whether the transformations were done properly. Any thoughts about a one-off workaround? I took a look at the documentation but couldn't figure out how to do it. Have you tried changing the following pandas output display options? pandas.set_option('display.width', 1000) pandas.set_option('display.max_colwidth', 100) Regards, Will From andy at payne.org Thu Jul 17 10:51:30 2014 From: andy at payne.org (Andrew Payne) Date: Thu, 17 Jul 2014 10:51:30 -0400 Subject: [IPython-dev] HTML display does not works when using Widgets In-Reply-To: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> References: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> Message-ID: <CABbuyuXspd7f5=c8ykx57TwX_EZLkdBk7KLeqmbtVaa6y_6eLw@mail.gmail.com> > def my_func(): > HTML("<b>Some html</b>") > some_widget.interact #display widget > > When I call this function from the notebook, only widget is rendered on > the output cell, not the HTML. > I guess that might be because widgets use different "type" of output method > compared to usual output method. > Try calling display(HTML("your html")). See: http://ipython.org/ipython-doc/dev/api/generated/IPython.core.display.html#IPython.core.display.display display() causes your Python object to be displayed on the frontend (e.g. in the notebook). IPython normally displays last item in the cell / return value for you automatically, but you can call display() directly to force an object (other than the last item) to be displayed. For example: [image: Inline image 1] I hope this is helpful. -andy -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140717/fd36c2cd/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot_071714_105041_AM.jpg Type: image/jpeg Size: 26639 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140717/fd36c2cd/attachment.jpg> From ellisonbg at gmail.com Thu Jul 17 10:58:07 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Thu, 17 Jul 2014 07:58:07 -0700 Subject: [IPython-dev] HTML display does not works when using Widgets In-Reply-To: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> References: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> Message-ID: <CAH4pYpQ=6iw-Qc853zzq7nQauMdBa3ONVGV-BL=71guwE2Wzhw@mail.gmail.com> Wrap the HTML is a call to IPython.display.display On Wed, Jul 16, 2014 at 9:47 AM, TARUN GABA <tarun.gaba7 at gmail.com> wrote: > Hi all > > I am working on a module, which requires use of IPython widgets and some > rendered HTML. > I am using the dev branch from the repository. > > $ ipython --version > 3.0.0-dev > > > > this is the code snippet, I am trying to implement: > > def my_func(): > HTML("<b>Some html</b>") > some_widget.interact #display widget > > When I call this function from the notebook, only widget is rendered on the > output cell, not the HTML. > I guess that might be because widgets use different "type" of output method > compared to usual output method. > > Can anybody please point me to the best way to implement it(both HTML and > widget in same output cell.) > > Thanks > > Tarun Gaba > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From bussonniermatthias at gmail.com Thu Jul 17 11:37:49 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Thu, 17 Jul 2014 17:37:49 +0200 Subject: [IPython-dev] HTML display does not works when using Widgets In-Reply-To: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> References: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> Message-ID: <246116F9-A6F7-4D66-95AA-D89C6705E009@gmail.com> Hello tarun. Le 16 juil. 2014 ? 18:47, TARUN GABA a ?crit : > > this is the code snippet, I am trying to implement: > > def my_func(): > HTML("<b>Some html</b>") > some_widget.interact #display widget Here you are creating an HTML object, that you do not assign to anything, and do not display() it. I'am not sure why you expect it to be on the page. Are you trying to pass the HTML object to the widget ? -- M From benjaminrk at gmail.com Thu Jul 17 12:55:28 2014 From: benjaminrk at gmail.com (MinRK) Date: Thu, 17 Jul 2014 09:55:28 -0700 Subject: [IPython-dev] HTML display does not works when using Widgets In-Reply-To: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> References: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> Message-ID: <CAHNn8BVH7P3EqGpvZGoNyXRL3e8H3S7vapJTpzLTHZFZ0j34RA@mail.gmail.com> HTML("some html") doesn't trigger any display, it just creates the object. If you want to display it, call `display(HTML("some html"))` On Wed, Jul 16, 2014 at 9:47 AM, TARUN GABA <tarun.gaba7 at gmail.com> wrote: > Hi all > > I am working on a module, which requires use of IPython widgets and some > rendered HTML. > I am using the dev branch from the repository. > > $ ipython --version > 3.0.0-dev > > > > this is the code snippet, I am trying to implement: > > def my_func(): > HTML("<b>Some html</b>") > some_widget.interact #display widget > > When I call this function from the notebook, only widget is rendered on > the output cell, not the HTML. > I guess that might be because widgets use different "type" of output method > compared to usual output method. > > Can anybody please point me to the best way to implement it(both HTML and > widget in same output cell.) > > Thanks > > Tarun Gaba > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140717/60434106/attachment.html> From takowl at gmail.com Thu Jul 17 12:59:00 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 17 Jul 2014 09:59:00 -0700 Subject: [IPython-dev] HTML display does not works when using Widgets In-Reply-To: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> References: <CAHAono0tdbBSs+F_suTb3=S9fmWJr7ZOHhJksOC5UecWBhDoWA@mail.gmail.com> Message-ID: <CAOvn4qi-VKZCPfoAzFsC+ruDkhsbH+vGrKT=a=TCjXzQGy1SjQ@mail.gmail.com> On 16 July 2014 09:47, TARUN GABA <tarun.gaba7 at gmail.com> wrote: > def my_func(): > HTML("<b>Some html</b>") > some_widget.interact #display widget > HTML() only creates an HTML display object, it doesn't actually display it. If you put it at the end of the cell, then it's is displayed automatically, but to display it anywhere else, you'll need to call IPython.display.display() on it. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140717/38216ff2/attachment.html> From andy at payne.org Thu Jul 17 13:31:42 2014 From: andy at payne.org (Andrew Payne) Date: Thu, 17 Jul 2014 13:31:42 -0400 Subject: [IPython-dev] Memory consumption of running notebook In-Reply-To: <CAOvn4qib4BjMZFK63vcRNoRsik3FLt+WvcuLSQwKPQO1F49x1g@mail.gmail.com> References: <1404983943.13472.1.camel@archi> <CAPET0ywvRQthgDtkX7M9Q5OdneZo+6eG_y0=nOuUZtAWdKp97w@mail.gmail.com> <CAHNn8BW1M=bG6t3STfzoXwqSEj95NRh5PV9p=Kk86WZ8yqMzbQ@mail.gmail.com> <CABbuyuW9Qy6N77so5sPWMOk8ggt=pcqP3qw-ACA+bZ1yOg+j=g@mail.gmail.com> <CAOvn4qib4BjMZFK63vcRNoRsik3FLt+WvcuLSQwKPQO1F49x1g@mail.gmail.com> Message-ID: <CABbuyuUyBtJSbfPa41cB+3t_d1Uo3trvtdJF+pSgm-S7X7-7mQ@mail.gmail.com> On Sun, Jul 13, 2014 at 10:48 PM, Thomas Kluyver <takowl at gmail.com> wrote: > I think this should mostly be in the server, not the kernel - it's > something that would be useful for all kernels, but there's no need to > reimplement it in each language. > > What could be useful in the kernel is a way to discover what objects are > using most memory. > This is the original direction I was thinking (sharing kernel-specific things, like object memory usage, GC issues, threads, resource leaks, etc.) But now that I think about it, that can probably be done with a kernel-specific widget that you can put somewhere in your notebook just like any other widget/cell. If I can get some free cycles over the next few days, I will try to prototype something up. -andy -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140717/551ecf6f/attachment.html> From ASchneiderman at asha.org Thu Jul 17 17:08:28 2014 From: ASchneiderman at asha.org (Anders Schneiderman) Date: Thu, 17 Jul 2014 17:08:28 -0400 Subject: [IPython-dev] How to display really long strings? In-Reply-To: <CAJJEUTLXCJBsZ3w1Xc9X-MyKwebE1mHfHkt9EvwCOSrPRVtrKg@mail.gmail.com> References: <CAJJEUTLXCJBsZ3w1Xc9X-MyKwebE1mHfHkt9EvwCOSrPRVtrKg@mail.gmail.com> Message-ID: <93268EE5694C0A4BBB888C2EEFEEEC22B3EDC4408D@EXCH2008.hq.asha.org> Thanks, Will! That solved the problem - and as an added bonus, I've got a few more useful techniques courtesy of set_option. Anders > ---------- Forwarded message ---------- > From: Anders Schneiderman <ASchneiderman at asha.org> > To: "ipython-dev at scipy.org" <ipython-dev at scipy.org> > Cc: > Date: Tue, 15 Jul 2014 11:18:48 -0400 > Subject: [IPython-dev] How to display really long strings? > > I need to do a series of transformations to a column in a pandas data frame that contains very long strings. When I try to display the column via head, etc, IPython Notebook truncates it - a totally understandable approach for most long strings, but it means I can't see whether the transformations were done properly. Any thoughts about a one-off workaround? I took a look at the documentation but couldn't figure out how to do it. Have you tried changing the following pandas output display options? pandas.set_option('display.width', 1000) pandas.set_option('display.max_colwidth', 100) Regards, Will _______________________________________________ IPython-dev mailing list IPython-dev at scipy.org http://mail.scipy.org/mailman/listinfo/ipython-dev From nathan.faggian at gmail.com Thu Jul 17 19:38:09 2014 From: nathan.faggian at gmail.com (Nathan Faggian) Date: Fri, 18 Jul 2014 09:38:09 +1000 Subject: [IPython-dev] Aynchronously displaying stdout from parallel engines In-Reply-To: <loom.20140717T123608-581@post.gmane.org> References: <CAJXewOmeO6+zhtTeyK5TXEWPry1U19ns+zBumYLJKR5vL_1iUg@mail.gmail.com> <loom.20140717T123608-581@post.gmane.org> Message-ID: <CAN1J6jXfSicAyhAYc-NxJMSF=P_ucCpA+NzDkTXpuSYrJdQ9YA@mail.gmail.com> Hi, A while ago I wrote a task watcher: https://github.com/nfaggian/ipcluster_tools I will probably have a sprint on it at the Australian PyCon in August. Regards, Nathan On 17 July 2014 20:37, Dave Hirschfeld <dave.hirschfeld at gmail.com> wrote: > Nathan Goldbaum <nathan12343 <at> gmail.com> writes: > > > > > Hi all, > > I'm finding myself dealing with a lengthy computation using an IPython > parallel cluster and MPI4py. > > > > I'd like to be able to see what my workers are doing while they are doing > it. In particular, I'd like to be able to get the stdout stream from each > engine and display it somehow in the output of a client notebook. > > > > > > So far I've used AsyncResult.wait_interactive() to see what my workers > are > doing, but this only shows that my computations haven't completed yet - not > what they are doing at any given moment. > > > > > > Is it possible to set up something similar to wait_interactive that can > asynchronously stream stdout from each of the workers? > > > > Thanks for your help, > > > > Nathan > > > > Fortunately @minrk has a time machine! > > > https://github.com/ipython/ipython/blob/master/examples/Parallel%20Computing > /iopubwatcher.py > > HTH, > Dave > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/6ab3a340/attachment.html> From nathan.faggian at gmail.com Thu Jul 17 19:38:09 2014 From: nathan.faggian at gmail.com (Nathan Faggian) Date: Fri, 18 Jul 2014 09:38:09 +1000 Subject: [IPython-dev] Aynchronously displaying stdout from parallel engines In-Reply-To: <loom.20140717T123608-581@post.gmane.org> References: <CAJXewOmeO6+zhtTeyK5TXEWPry1U19ns+zBumYLJKR5vL_1iUg@mail.gmail.com> <loom.20140717T123608-581@post.gmane.org> Message-ID: <CAN1J6jXfSicAyhAYc-NxJMSF=P_ucCpA+NzDkTXpuSYrJdQ9YA@mail.gmail.com> Hi, A while ago I wrote a task watcher: https://github.com/nfaggian/ipcluster_tools I will probably have a sprint on it at the Australian PyCon in August. Regards, Nathan On 17 July 2014 20:37, Dave Hirschfeld <dave.hirschfeld at gmail.com> wrote: > Nathan Goldbaum <nathan12343 <at> gmail.com> writes: > > > > > Hi all, > > I'm finding myself dealing with a lengthy computation using an IPython > parallel cluster and MPI4py. > > > > I'd like to be able to see what my workers are doing while they are doing > it. In particular, I'd like to be able to get the stdout stream from each > engine and display it somehow in the output of a client notebook. > > > > > > So far I've used AsyncResult.wait_interactive() to see what my workers > are > doing, but this only shows that my computations haven't completed yet - not > what they are doing at any given moment. > > > > > > Is it possible to set up something similar to wait_interactive that can > asynchronously stream stdout from each of the workers? > > > > Thanks for your help, > > > > Nathan > > > > Fortunately @minrk has a time machine! > > > https://github.com/ipython/ipython/blob/master/examples/Parallel%20Computing > /iopubwatcher.py > > HTH, > Dave > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/6ab3a340/attachment-0001.html> From akim at lrde.epita.fr Fri Jul 18 03:25:23 2014 From: akim at lrde.epita.fr (Akim Demaille) Date: Fri, 18 Jul 2014 09:25:23 +0200 Subject: [IPython-dev] Interactive magic cells Message-ID: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> [Resend: I sent the message without having subscribed, and my message never showed up, and I never received a message telling me that I needed to be member to post. The info page of the list does not mention that either, I think it should.] Hi all, I'm working on an interactive (textual) means to edit an automaton in the notebooks. It looks like this: I'm using a TextareaWidget to let the user type in her automaton, and an HTMLWidget for te SVG output from dot. It is interactive in that I use on_trait_change on the text area to decide whether to update the output. I have two questions: is there a simple means to control the frequency of the updates? When the user is typing, I don't need to receive all the updates, waiting for a quiet period should be enough. But this I guess I can't do by myself, don't worry. My real question is: I'd like to avoid the text area and rather have a cell magic that would look like: I can easily do that with usual cell magic functions, but I'd like to have auto evaluation, so that we don't have to wait for the user to hit shift-enter. Is there a means to do that? Thanks in advance! -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/dad35624/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: PastedGraphic-5.png Type: image/png Size: 45383 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/dad35624/attachment.png> -------------- next part -------------- A non-text attachment was scrubbed... Name: PastedGraphic-2.png Type: image/png Size: 37240 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/dad35624/attachment-0001.png> From jr at sun.ac.za Wed Jul 16 10:19:06 2014 From: jr at sun.ac.za (Johann Rohwer) Date: Wed, 16 Jul 2014 16:19:06 +0200 Subject: [IPython-dev] test from where a module is imported Message-ID: <2579592.dN55qOG1A5@bc433789> Hi all, Say I'm developing a Python module and would like to know from where the user imports this module, i.e. from a regular Python shell, an IPython shell, an IPython qtconsole, or an IPython notebook. I would like to enable additional features in my module depending on e.g. useful stuff that is available in the notebook. But I want the module also to be able to be imported and run in any of the other environments, so it's really more like a test from where we are imported. I can think of various hacks on how to achieve this but would like to know if there is The Right Way (TM) and if so, what it is. Thanks, Johann The integrity and confidentiality of this email is governed by these terms / Hierdie terme bepaal die integriteit en vertroulikheid van hierdie epos. http://www.sun.ac.za/emaildisclaimer From bussonniermatthias at gmail.com Fri Jul 18 06:25:57 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Fri, 18 Jul 2014 12:25:57 +0200 Subject: [IPython-dev] test from where a module is imported In-Reply-To: <2579592.dN55qOG1A5@bc433789> References: <2579592.dN55qOG1A5@bc433789> Message-ID: <92BFA949-950C-43DB-97C8-77A6ADE2DF16@gmail.com> Le 16 juil. 2014 ? 16:19, Johann Rohwer a ?crit : > Hi all, > > Say I'm developing a Python module and would like to know from where the user > imports this module, i.e. > from a regular Python shell, an IPython shell, in main namesapace, that's easy check fro __IPYTHON__ or even get_ipython() to get a handle in current runnig process. > an > IPython qtconsole, or an IPython notebook. You cannot distinguish, and it does not make sense to try to distinguish theses. Hence we do not plan to add capability do distinguish. (Plenty of description on why on the ML archive) > I would like to enable additional > features in my module depending on e.g. useful stuff that is available in the > notebook. But I want the module also to be able to be imported and run in any > of the other environments, so it's really more like a test from where we are > imported. What are you exactly trying to do ? > > I can think of various hacks on how to achieve this but would like to know if > there is The Right Way (TM) and if so, what it is. isn't the _repr_*_ enough ? -- Matthias > > Thanks, > Johann > > > The integrity and confidentiality of this email is governed by these terms / Hierdie terme bepaal die integriteit en vertroulikheid van hierdie epos. http://www.sun.ac.za/emaildisclaimer > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From jr at sun.ac.za Fri Jul 18 06:41:39 2014 From: jr at sun.ac.za (Johann Rohwer) Date: Fri, 18 Jul 2014 12:41:39 +0200 Subject: [IPython-dev] test from where a module is imported In-Reply-To: <92BFA949-950C-43DB-97C8-77A6ADE2DF16@gmail.com> References: <2579592.dN55qOG1A5@bc433789> <92BFA949-950C-43DB-97C8-77A6ADE2DF16@gmail.com> Message-ID: <2973002.HnDFVIZY3J@bc433789> Hi Matthias Thanks for your reply! On Friday 18 July 2014 12:25:57 Matthias Bussonnier wrote: > Le 16 juil. 2014 ? 16:19, Johann Rohwer a ?crit : > > Hi all, > > > > Say I'm developing a Python module and would like to know from where the > > user imports this module, i.e. > > > > from a regular Python shell, an IPython shell, > > in main namesapace, that's easy check fro __IPYTHON__ > or even get_ipython() to get a handle in current runnig process. Thanks, I had come across these as well, good to know that this is the way to go. > > an > > IPython qtconsole, or an IPython notebook. > > You cannot distinguish, and it does not make sense to try to distinguish > theses. Hence we do not plan to add capability do distinguish. (Plenty of > description on why on the ML archive) OK good to know. > > I would like to enable additional > > > > features in my module depending on e.g. useful stuff that is available in > > the notebook. But I want the module also to be able to be imported and > > run in any of the other environments, so it's really more like a test > > from where we are imported. > > What are you exactly trying to do ? We are developing an application that uses Notebook widgets to interactively manipulate matplotlib graphs (turn lines on and off, etc.). When not running the notebook, these widgets are therefore not available, but the graph should nevertheless be displayed, perhaps with a warning to the user to call the underlying class methods directly since the widget buttons are not there. Here the qtconsole would be fundamentally different from the notebook: although you can have the matplotlib graphs inline there would not be widgets available to manipulate them. Johann The integrity and confidentiality of this email is governed by these terms / Hierdie terme bepaal die integriteit en vertroulikheid van hierdie epos. http://www.sun.ac.za/emaildisclaimer From doug.blank at gmail.com Fri Jul 18 07:50:52 2014 From: doug.blank at gmail.com (Doug Blank) Date: Fri, 18 Jul 2014 07:50:52 -0400 Subject: [IPython-dev] Interactive magic cells In-Reply-To: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> References: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> Message-ID: <CAAusYCii0rjcKX6CK3jNfpcBw6Sir6M3Qa+tvD5m7uwN2tzB=Q@mail.gmail.com> On Fri, Jul 18, 2014 at 3:25 AM, Akim Demaille <akim at lrde.epita.fr> wrote: > [Resend: I sent the message without having subscribed, and my > message never showed up, and I never received a message telling > me that I needed to be member to post. The info page of the list > does not mention that either, I think it should.] > > Hi all, > > I'm working on an interactive (textual) means to edit an automaton > in the notebooks. It looks like this: > > > I'm using a TextareaWidget to let the user type in her automaton, > and an HTMLWidget for te SVG output from dot. It is interactive > in that I use on_trait_change on the text area to decide whether > to update the output. > > I have two questions: is there a simple means to control the frequency > of the updates? When the user is typing, I don't need to receive all > the updates, waiting for a quiet period should be enough. But this > I guess I can't do by myself, don't worry. > > My real question is: I'd like to avoid the text area and rather > have a cell magic that would look like: > > > I can easily do that with usual cell magic functions, but I'd like > to have auto evaluation, so that we don't have to wait for the user > to hit shift-enter. Is there a means to do that? > Cool project! "Live coding" for Finite State Machines! There probably a few places you could insert JavaScript into the keypress handling process. Perhaps an easy way would be to add a CodeMirror overlay [1]. You could not only fire your code to check to see if you want to re-render the dot output, but could also add some custom parsing for your language. When you have a complete description, you can probably call something like the JavaScript IPython.notebook.get_cell(n).execute(). Hope that helps, -Doug [1] http://stackoverflow.com/questions/12343922/codemirror-with-spell-checker - the last answer I just added which works inside an notebook. > > Thanks in advance! > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/7a95a2c0/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: PastedGraphic-2.png Type: image/png Size: 37240 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/7a95a2c0/attachment.png> -------------- next part -------------- A non-text attachment was scrubbed... Name: PastedGraphic-5.png Type: image/png Size: 45383 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/7a95a2c0/attachment-0001.png> From paddy at paddymullen.com Fri Jul 18 10:37:53 2014 From: paddy at paddymullen.com (Paddy Mullen) Date: Fri, 18 Jul 2014 10:37:53 -0400 Subject: [IPython-dev] How to use notebooks with teams Message-ID: <CAFpY3ufsV+T-oytcMX8KFZRVM0MatxiwLPuxFpdJtd0HDxz2dg@mail.gmail.com> I'm a developer supporting a group of non-technical business analysts. We want to use the IPython notebook, but we are running into some problems. I was hoping to hear some best practices and other people's experiences. Maybe there is a product that makes the IPython notebook easier to use for teams. Currently each business user is running their own notebook server that points at a shared directory. This lets us distribute code to all business users relatively easily. We run into problems when two users are working on the same notebook at the same time, their changes clobber each other. Is there a way to make notebooks parameterizeable? I would like to build notebooks that performs some common analysis, and I want the business user to be able to tweak a couple of parameters, then re-run the notebook and see the new report. If users aren't writing new code, just changing parameters, there will be fewer opportunities for merging and merge conflicts or file clobbering. In short what experiences do people have with teams of non-technical users collaborating on IPython notebooks. Thanks, Paddy -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/4045f386/attachment.html> From andy at payne.org Fri Jul 18 11:35:04 2014 From: andy at payne.org (Andrew Payne) Date: Fri, 18 Jul 2014 11:35:04 -0400 Subject: [IPython-dev] How to use notebooks with teams In-Reply-To: <CAFpY3ufsV+T-oytcMX8KFZRVM0MatxiwLPuxFpdJtd0HDxz2dg@mail.gmail.com> References: <CAFpY3ufsV+T-oytcMX8KFZRVM0MatxiwLPuxFpdJtd0HDxz2dg@mail.gmail.com> Message-ID: <CABbuyuUeXxUVcRb4+gQFRo7qfUCgbpj7Ua2z3P9NzVvX+oaiKw@mail.gmail.com> Addressing part of your question, you wrote: Is there a way to make notebooks parameterizeable? I would like to > build notebooks that performs some common analysis, and I want the > business user to be able to tweak a couple of parameters, then re-run > the notebook and see the new report. If users aren't writing new code, > just changing parameters, there will be fewer opportunities for merging and > merge conflicts or file clobbering. > You might consider using widgets for this. See: http://nbviewer.ipython.org/github/ipython/ipython/blob/master/examples/Interactive%20Widgets/Index.ipynb You could have a set of widgets at the top of the notebook that capture the tweakable parameters. Your business user would set those, and run the notebook. -andy -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/219df65a/attachment.html> From takowl at gmail.com Fri Jul 18 13:20:48 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 18 Jul 2014 10:20:48 -0700 Subject: [IPython-dev] ijulia? In-Reply-To: <CAK=Phk46nCw-W6-u9tczVj3QQRv=9cm1vesVgKrhEyf+BpT-jw@mail.gmail.com> References: <CACLE5GDudtHNhivKxQCBodjvF-A0GHDfW4hCwj1rJmje6J85+w@mail.gmail.com> <B3D16462-DF0D-4263-8FA4-C8529C00DDA7@gmail.com> <CAK=Phk46nCw-W6-u9tczVj3QQRv=9cm1vesVgKrhEyf+BpT-jw@mail.gmail.com> Message-ID: <CAOvn4qjhtB3w2RD-yY9rir-BxL9OccSmrR5tJrP2vNY4subhRw@mail.gmail.com> On 13 July 2014 11:28, Sylvain Corlay <sylvain.corlay at gmail.com> wrote: > I agree that it would be relevant to have some language information in the > metadata of the ipynb file, but not directly the backend name, to allow > concurrent backends to coexist for a given language. > This would be very useful to people developing kernels. > The different backends could be registered in ipython_notebook_config.py > -the executable > -the name of the corresponding language > -a short user-friendly name for the backend . > This is pretty much what we're doing, though it's not stored in the config file - there's a directory where kernels can install information about themselves. See IPEP 25 for more details: https://github.com/ipython/ipython/wiki/IPEP-25:-Registry-of-installed-kernels > When opening a notebook from the dashboard, a warning could be triggered > or a choice could be given depending on whether multiple or no backend is > available. > For now, it will only try to start the kernel that the notebook was last used with. The language field is saved in the notebook metadata, so it would be possible to write a mechanism to fall back to another kernel for the relevant language, but I think that's unnecessary complexity for the moment. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/9139e7ef/attachment.html> From bussonniermatthias at gmail.com Fri Jul 18 13:29:37 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Fri, 18 Jul 2014 19:29:37 +0200 Subject: [IPython-dev] %%markdown or %loadmarkdown ? In-Reply-To: <CAEX=yabtsT02nFTa41k5N30_uCpqh14oeWaRwxaMSByUOvvUSw@mail.gmail.com> References: <CAEX=yabtsT02nFTa41k5N30_uCpqh14oeWaRwxaMSByUOvvUSw@mail.gmail.com> Message-ID: <DA8448EE-EC24-4EFB-8CAA-56F66CB752CC@gmail.com> Le 13 juil. 2014 ? 22:27, Mark Bakker a ?crit : > I was wondering whether there is something like a %% markdown magic that changes a code cell to markdown. Magics are kernel-side function, and the kernel does not know about the frontend. THe only thing the kernel can say is : "hey, put that in place where the user will type next" no more no less. %%laodmarkdown is thus not possible though you can write something that **display** markdown, but does not put it in the input of a cell. -- M > > I want to use this with the %load command. So actually, a %loadmarkdown would be even better > > Usage: In class assignments I want the students to load exercises (written in markdown) from a server. > Sure, I can let them do a %load and then manually change the cell to markdown, but it would be much nicer if it changes automatically. > > And I think others will find use for such functionality. > > Thanks, > > Mark > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From takowl at gmail.com Fri Jul 18 13:29:33 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 18 Jul 2014 10:29:33 -0700 Subject: [IPython-dev] %%markdown or %loadmarkdown ? In-Reply-To: <CAEX=yabtsT02nFTa41k5N30_uCpqh14oeWaRwxaMSByUOvvUSw@mail.gmail.com> References: <CAEX=yabtsT02nFTa41k5N30_uCpqh14oeWaRwxaMSByUOvvUSw@mail.gmail.com> Message-ID: <CAOvn4qhUoW3NWGwNeRV0QHUzrsXvSMhmp3GzHw0d5R0em+oFEw@mail.gmail.com> On 13 July 2014 13:27, Mark Bakker <markbak at gmail.com> wrote: > I was wondering whether there is something like a %% markdown magic that > changes a code cell to markdown. > There isn't, and it doesn't really make sense in our model. Magics change how code is executed, while code cells vs. markdown cells is part of the notebook document structure. The kernel, which executes the code, doesn't know about the document. > I want to use this with the %load command. So actually, a %loadmarkdown > would be even better > > Usage: In class assignments I want the students to load exercises (written > in markdown) from a server. > Sure, I can let them do a %load and then manually change the cell to > markdown, but it would be much nicer if it changes automatically. > I think the more common way of doing this is to provide the students with notebooks which describe the exercises, and leave blank cells where they fill in their answers. It would be possible to write a %loadmarkdown magic, but it feels like the wrong approach - the notebook is built around the idea of separating the document structure from code execution. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/3ad00479/attachment.html> From takowl at gmail.com Fri Jul 18 13:43:28 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 18 Jul 2014 10:43:28 -0700 Subject: [IPython-dev] Step-by-step debugging with IPython In-Reply-To: <CAD4ivxVa3SV8PGYFOrM3oavAyWU+7h4BE2S_pUihAJS4zzdExA@mail.gmail.com> References: <CAD4ivxVa3SV8PGYFOrM3oavAyWU+7h4BE2S_pUihAJS4zzdExA@mail.gmail.com> Message-ID: <CAOvn4qjk2upEVemfhP7xCovFgo=EuCBd+6q9Km4MM=UEHCFcXw@mail.gmail.com> On 15 July 2014 06:02, Josh Wasserstein <ribonucleico at gmail.com> wrote: > This makes me wonder if: > > 1) I am doing things wrong > 2) The current status of IPython does not provide the debugging > functionality stated in the OP. > > And the reason behind 2) could be: > a. Limitations of Python / execution model that make this inviable > b. There is not enough interest to justify an effort to improve the > debugging model / the relatively high complexity required to have Python / > IPython support this workflow > There's a distinct possibility that the answer is 2c: The effort is justified, but no-one has done it yet. I know several of us on the core team routinely just scatter print statements around the code when we want to debug something. Even using a post-mortem debugger to go up and down the stack, with no way to step through code, seems advanced to me. My personal take on it is that the effort necessary to learn and use a command-line debugger isn't really worth it for writing Python code, where uncaught errors automatically give you quite a bit of detail on what went wrong. I suspect that a good graphical debugger could be useful (I've used the JS debugger in Firefox, for instance). Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/224430d1/attachment.html> From tarun.gaba7 at gmail.com Fri Jul 18 14:16:24 2014 From: tarun.gaba7 at gmail.com (TARUN GABA) Date: Fri, 18 Jul 2014 23:46:24 +0530 Subject: [IPython-dev] HTML display does not works when using Widgets Message-ID: <CAHAono0sHQoozXzLFgWuGiKTrHvVMzRzHtB4GGuwSngSQ28spA@mail.gmail.com> Thanks a lot for all the replies. I got it working with a call to `display` method for my HTML content. Although Now, I have decided to create a ContainerWidget, and use HTMLWidget instead of HTML(). This seems a more viable option, since I have other widgets too, and they all can be combined in a container. So something like: def my_new_method(): container = ContainerWidget() html_widget = HTMLWidget("html content here!") other_widgets = OtherWidgets() container.children = [ .., .. ] display(container) Havent tested it though! -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/1b71fb34/attachment.html> From ellisonbg at gmail.com Fri Jul 18 14:56:51 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Fri, 18 Jul 2014 11:56:51 -0700 Subject: [IPython-dev] IPython circuit editing widget In-Reply-To: <CAOTD34Y6qfiafjayEtS=SqUEvbZfRwvbHBqpCmZf8Xg9uHRx6g@mail.gmail.com> References: <E1061BD3-C522-4D06-A5CE-DC66DFAD92C5@stanford.edu> <CAOTD34Y6qfiafjayEtS=SqUEvbZfRwvbHBqpCmZf8Xg9uHRx6g@mail.gmail.com> Message-ID: <CAH4pYpRn45BD5Reiw=P96-pta5Mn4EAtB0ckOV8QRkb0am=oQQ@mail.gmail.com> Erik, Are you familiar with the quantum computing stuff in sympy? Cheers, Brian On Mon, Jul 14, 2014 at 3:14 PM, Erik Bray <erik.m.bray at gmail.com> wrote: > On Thu, Jul 10, 2014 at 5:11 PM, Nikolas Tezak <ntezak at stanford.edu> wrote: >> Hi everybody, >> >> here's a link to the visual circuit editing / schematic capture widget in the notebook I presented at SciPy today. >> It?s still pretty rough and I?m not exactly proud of my JS skills but it already works pretty well! >> >> Maybe someone else can reuse this if they are creating a complex SVG based interactive widget. >> >> The repo >> https://github.com/ntezak/cirq >> >> The talk >> https://conference.scipy.org/scipy2014/schedule/presentation/1743/ >> >> If anybody is interested I can make my slides available somewhere, too. >> Best, > > That looks very cool! I don't know how I missed this at SciPy. I > will have to see if I can adapt this for use in my PyQC package [1] > where interactive circuit editing is a big want (currently circuits > are just displayed as static images rendered from LaTeX. I'll let you > know how it goes once I get around to it. > > Thanks, > > Erik > > > [1] https://bitbucket.org/embray/pyqc > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From darcamo at gmail.com Fri Jul 18 15:06:33 2014 From: darcamo at gmail.com (Darlan Cavalcante Moreira) Date: Fri, 18 Jul 2014 16:06:33 -0300 Subject: [IPython-dev] Step-by-step debugging with IPython In-Reply-To: <CAOvn4qjk2upEVemfhP7xCovFgo=EuCBd+6q9Km4MM=UEHCFcXw@mail.gmail.com> References: <CAD4ivxVa3SV8PGYFOrM3oavAyWU+7h4BE2S_pUihAJS4zzdExA@mail.gmail.com> <CAOvn4qjk2upEVemfhP7xCovFgo=EuCBd+6q9Km4MM=UEHCFcXw@mail.gmail.com> Message-ID: <87zjg67ah2.fsf@gmail.com> takowl at gmail.com writes: > On 15 July 2014 06:02, Josh Wasserstein <ribonucleico at gmail.com> wrote: > >> This makes me wonder if: >> >> 1) I am doing things wrong >> 2) The current status of IPython does not provide the debugging >> functionality stated in the OP. >> >> And the reason behind 2) could be: >> a. Limitations of Python / execution model that make this inviable >> b. There is not enough interest to justify an effort to improve the >> debugging model / the relatively high complexity required to have Python / >> IPython support this workflow >> > > There's a distinct possibility that the answer is 2c: The effort is > justified, but no-one has done it yet. > > I know several of us on the core team routinely just scatter print > statements around the code when we want to debug something. Even using a > post-mortem debugger to go up and down the stack, with no way to step > through code, seems advanced to me. > > My personal take on it is that the effort necessary to learn and use a > command-line debugger isn't really worth it for writing Python code, where > uncaught errors automatically give you quite a bit of detail on what went > wrong. I suspect that a good graphical debugger could be useful (I've used > the JS debugger in Firefox, for instance). > > Thomas > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev Debugging in python was annoying to me until I discovered pudb. https://pypi.python.org/pypi/pudb Install it through pip and then add the line below at some point in your program import pudb; pudb.set_trace() and run it as usual. Or you don't add anything and run you program with pudb my_program.py The advantages of pudb when compared with standard pdb or ipdb is that it is graphical and much easier to work with. You can step throgh code with the 'n' key, step inside a function with the 's' key, go up or down in the stack with 'd' and 'u', etc. But the killer feature is the integration with IPython. At any point you can press '!' to go to an IPython terminal with the current variables (use Ctrl+D when you are finished to go back to pudb). From there you can do any test you want. Note that if in pudb you go up in the stack with the 'u' key and then start IPython with '!' you will have the variables from that stack. There are ther noce features too, such as conditional breakpoints, etc. -- Darlan Cavalcante Moreira darcamo at gmail.com From franz.bergesund at gmail.com Fri Jul 18 15:50:54 2014 From: franz.bergesund at gmail.com (Francesco Montesano) Date: Fri, 18 Jul 2014 21:50:54 +0200 Subject: [IPython-dev] How to use notebooks with teams In-Reply-To: <CAFpY3ufsV+T-oytcMX8KFZRVM0MatxiwLPuxFpdJtd0HDxz2dg@mail.gmail.com> References: <CAFpY3ufsV+T-oytcMX8KFZRVM0MatxiwLPuxFpdJtd0HDxz2dg@mail.gmail.com> Message-ID: <CAOCdBK+AC3qkVYqZP2fQzENbM68ufBC596e8EJA-kDEhCT0HDA@mail.gmail.com> Hi, 2014-07-18 16:37 GMT+02:00 Paddy Mullen <paddy at paddymullen.com>: > Currently each business user is running their own notebook server > that points at a shared directory. This lets us distribute code to > all business users relatively easily. We run into problems when two > users are working on the same notebook at the same time, their > changes clobber each other. > The plans for Ipython 3.0 is to add multi-user support: https://github.com/ipython/ipython/wiki/Roadmap:-IPython#release-30-fall-2014 Fra -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/2b7181db/attachment.html> From rgbkrk at gmail.com Fri Jul 18 18:37:24 2014 From: rgbkrk at gmail.com (Kyle Kelley) Date: Fri, 18 Jul 2014 17:37:24 -0500 Subject: [IPython-dev] =?utf-8?q?Vulnerability_in_IPython_Notebook_?= =?utf-8?b?4omkIDEuMQ==?= In-Reply-To: <53C6C22C.9050009@googlemail.com> References: <CA+tbMaVhkrHm85T=jKL31=6avhNh5-=mQ+h-XkNaWN8_5hbBEg@mail.gmail.com> <CA+tbMaVRpHiiH5yAMTwWfCqDZT5=4iPrwh5E5nDTCkqvsMZfpA@mail.gmail.com> <53C6C22C.9050009@googlemail.com> Message-ID: <CA+tbMaWE_M-4wOe5r7g6LAC3hYXbTAHRXSK4sMGcb7F25fVdBQ@mail.gmail.com> Julian, I agree. One hard lesson we've learned on this is that we should have sent a notice to oss-security first, to disseminate straight to package maintainers (it was good to see the fast response). Going through MITRE directly was letting it languish. We should have done a better job communicating this and timed it right with the release of 1.2. The CVE process was new to everyone on the team. Would you like to help us with this in the future? Regards, Kyle Kelley On Wed, Jul 16, 2014 at 1:19 PM, Julian Taylor < jtaylor.debian at googlemail.com> wrote: > Why wasn't this disclosed on the appropriate channels 6 month ago when > it was fixed? > It didn't even get a proper changelog entry nor did distribution > maintainers get informed at all. > > Remote execution on localhost notebooks is really really bad, even if > you do need the kernel id. > This should have been posted to oss-security at the latest when 1.2.0 > was released ... > > On 14.07.2014 17:20, Kyle Kelley wrote: > > Whoops! > > > > Correction, CVE ID was truncated. It should read: > > > > The CVE ID is CVE-2014-3429 > > (http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-3429). > > > > > > > > On Sun, Jul 13, 2014 at 3:56 PM, Kyle Kelley <rgbkrk at gmail.com > > <mailto:rgbkrk at gmail.com>> wrote: > > > > Everyone, > > > > On IPython ? 1.1, a remote site could have exploited a vulnerability > > in cross origin websocket handling to execute code on an IPython > > kernel, with knowledge of the kernel id (which requires user > > intervention). > > > > This vulnerability was patched > > in https://github.com/ipython/ipython/pull/4845 and reported to the > > CVE (Common Vulnerabilities and Exposure) database. > > > > Summary given to the CVE database: The origin of websocket requests > > was not verified within the IPython notebook server. If an attacker > > has knowledge of an IPython kernel id they can run arbitrary code on > > a user's machine when the client visits a crafted malicious page. > > > > The CVE ID is CVE-2014-342 > > (http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-342). > > > > If you were at SciPy and watched the final round of lightning talks, > > you already know about this vulnerability (as much as you can within > > a 5 minute talk that is). > > > > I wrote a more detailed explanation > > at http://lambdaops.com/cross-origin-websocket-hijacking-of-ipython > > > > Feel free to ask us (the IPython team) any questions! > > > > Regards, > > > > Kyle Kelley > > > > > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140718/c4687ad5/attachment.html> From bussonniermatthias at gmail.com Sat Jul 19 08:27:18 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Sat, 19 Jul 2014 14:27:18 +0200 Subject: [IPython-dev] How to use notebooks with teams In-Reply-To: <CAOCdBK+AC3qkVYqZP2fQzENbM68ufBC596e8EJA-kDEhCT0HDA@mail.gmail.com> References: <CAFpY3ufsV+T-oytcMX8KFZRVM0MatxiwLPuxFpdJtd0HDxz2dg@mail.gmail.com> <CAOCdBK+AC3qkVYqZP2fQzENbM68ufBC596e8EJA-kDEhCT0HDA@mail.gmail.com> Message-ID: <F0A944DE-EF69-4FA3-9B4C-C731C3101ED1@gmail.com> I would also have a look at runipy[1] that allow for templates variable on headless running. You can thus have a "template" notebook, and generate report for many data sources. Multiuser support is on its way faith IPython, you might wan tho have a look at Google/jupyter colaboratory[2] that allow to live collaborate on IPython notebook on google drive. (still pretty young though) -- M [1]: https://github.com/paulgb/runipy [2]: https://github.com/jupyter/colaboratory Le 18 juil. 2014 ? 21:50, Francesco Montesano a ?crit : > Hi, > 2014-07-18 16:37 GMT+02:00 Paddy Mullen <paddy at paddymullen.com>: > Currently each business user is running their own notebook server > that points at a shared directory. This lets us distribute code to > all business users relatively easily. We run into problems when two > users are working on the same notebook at the same time, their > changes clobber each other. > > The plans for Ipython 3.0 is to add multi-user support: > https://github.com/ipython/ipython/wiki/Roadmap:-IPython#release-30-fall-2014 > > Fra > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From jason-sage at creativetrax.com Sat Jul 19 09:08:55 2014 From: jason-sage at creativetrax.com (Jason Grout) Date: Sat, 19 Jul 2014 09:08:55 -0400 Subject: [IPython-dev] How to use notebooks with teams In-Reply-To: <CAFpY3ufsV+T-oytcMX8KFZRVM0MatxiwLPuxFpdJtd0HDxz2dg@mail.gmail.com> References: <CAFpY3ufsV+T-oytcMX8KFZRVM0MatxiwLPuxFpdJtd0HDxz2dg@mail.gmail.com> Message-ID: <53CA6DE7.7090300@creativetrax.com> On 7/18/14, 10:37, Paddy Mullen wrote: > > I'm a developer supporting a group of non-technical business analysts. > We want to use the IPython notebook, but we are running into some > problems. I was hoping to hear some best practices and other people's > experiences. Maybe there is a product that makes the IPython > notebook easier to use for teams. > > Currently each business user is running their own notebook server > that points at a shared directory. This lets us distribute code to > all business users relatively easily. We run into problems when two > users are working on the same notebook at the same time, their > changes clobber each other. The Sage Math Cloud (https://cloud.sagemath.com) has fully collaborative IPython notebooks, just like Google Docs. Multiple people with multiple cursors, in real time. If I recall correctly, when one person adjusts a slider, everyone else sees the same slider moving. Or are you asking about an easy way to distribute and update notebooks to many users (but have each user run/tweak the notebook independently)? I think you could use version control for that, but updates would overwrite changes the users made. You could also make the notebook running depend on a configuration file containing parameters, or environment variables. Users change the config file and rerun the notebook. It would be great to figure out a good way to do this. I can see this being a common use-case (sharing a library of notebooks, and having the notebooks update automatically and also having the user be able to make small changes). Thanks, Jason From kaptanmf at gmail.com Sat Jul 19 09:41:21 2014 From: kaptanmf at gmail.com (Mustafa Kaptan) Date: Sat, 19 Jul 2014 16:41:21 +0300 Subject: [IPython-dev] Flushing the message buffer of a Widget Message-ID: <CAN7r33MXaAkSwj9LKMQnT+cTZz_=WyGdw6a=L_dQgsBWPqT2vA@mail.gmail.com> Hi, We want to "flush" the message buffer of a Widget model. What is the best way of this when using `this.send()`? Here is the reason why: We are trying to do some sort of VNC backend with Vispy and IPython notebook. We are sending captured Javascript events to backend and send back PNGs to frontend. For `mouse move` event, dragging is too slow. Basically, when we send too many events from the notebook to the kernel, and when the kernel takes too much time for each event, the event queue becomes too long. So we want to flush the queue whenever it becomes too long. Here is an example of dragging: https://imgflip.com/gif/adwf6 Here is the .js code sample: https://gist.github.com/mfkaptan/eb12cc91ee9d49f348d9 Thanks, Kaptan -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140719/6c36b42a/attachment.html> From akim at lrde.epita.fr Sun Jul 20 06:34:09 2014 From: akim at lrde.epita.fr (Akim Demaille) Date: Sun, 20 Jul 2014 12:34:09 +0200 Subject: [IPython-dev] Interactive magic cells In-Reply-To: <CAAusYCii0rjcKX6CK3jNfpcBw6Sir6M3Qa+tvD5m7uwN2tzB=Q@mail.gmail.com> References: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> <CAAusYCii0rjcKX6CK3jNfpcBw6Sir6M3Qa+tvD5m7uwN2tzB=Q@mail.gmail.com> Message-ID: <62E7B7A0-9E61-4A98-9B64-351EDE06D39C@lrde.epita.fr> hi Doug, Le 18 juil. 2014 ? 13:50, Doug Blank <doug.blank at gmail.com> a ?crit : > Cool project! "Live coding" for Finite State Machines! Thanks! > There probably a few places you could insert JavaScript into the keypress handling process. Perhaps an easy way would be to add a CodeMirror overlay [1]. You could not only fire your code to check to see if you want to re-render the dot output, This is already the case: I perform the attempt the conversion to SVG at each key stroke to see if it's ok, and if this is correct, then I do update the widget, and if it is not, I paste the error message in the error widget. So I always have the image even when while typing, my input is momentarily invalid. > but could also add some custom parsing for your language. Ah!!! Of course! Then I realize that I needs to write something like what was done for %%script. I'd be very happy to provide syntactic highlighting, for instance. Is there a place with documentation on how to write extensions such as %%bash and the like? From akim at lrde.epita.fr Sun Jul 20 11:51:34 2014 From: akim at lrde.epita.fr (Akim Demaille) Date: Sun, 20 Jul 2014 17:51:34 +0200 Subject: [IPython-dev] Interactive magic cells In-Reply-To: <62E7B7A0-9E61-4A98-9B64-351EDE06D39C@lrde.epita.fr> References: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> <CAAusYCii0rjcKX6CK3jNfpcBw6Sir6M3Qa+tvD5m7uwN2tzB=Q@mail.gmail.com> <62E7B7A0-9E61-4A98-9B64-351EDE06D39C@lrde.epita.fr> Message-ID: <AACF9EED-3727-421F-A263-9FA11C3FF08F@lrde.epita.fr> Le 20 juil. 2014 ? 12:34, Akim Demaille <akim at lrde.epita.fr> a ?crit : >> but could also add some custom parsing for your language. > > Ah!!! Of course! Then I realize that I needs to write something > like what was done for %%script. I'd be very happy to provide > syntactic highlighting, for instance. > > Is there a place with documentation on how to write extensions > such as %%bash and the like? Well, really, I have not seen anything about having a means to make a magic cell interactive. If someone has an idea, I'd be happy to learn from it! From neil.rabinowitz at nyu.edu Sun Jul 20 21:45:13 2014 From: neil.rabinowitz at nyu.edu (neil rabinowitz) Date: Sun, 20 Jul 2014 21:45:13 -0400 Subject: [IPython-dev] custom.js broken Message-ID: <CADWk=7Q2HXbXxPNVv8Wufnq_GnhNdw+EdHQDAq=Ah+Q4ha=e_Q@mail.gmail.com> i just pulled the latest ipython master from github, and i'm having difficulties with custom.js in the profile_.../static/custom/ directory. i hadn't updated for a few weeks, so it seems there have been some syntax changes during this time. my previous version of custom.js began with the line: $([IPython.events]).on("app_initialized.NotebookApp", function () { according to the browser console, this raises: "Uncaught ReferenceError: $ is not defined" i see there's a new syntax listed in the example custom.js, which suggests i should change this to: IPython.events.on("app_initialized.NotebookApp", function () { but according to the browser console, this raises: "Uncaught ReferenceError: IPython is not defined" any ideas? also should i expect all my extensions to require reworking for other syntax changes? neil (apologies for any response delays... will be away for a few days this week) -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140720/572261d4/attachment.html> From pierre.gerold at laposte.net Mon Jul 21 06:40:13 2014 From: pierre.gerold at laposte.net (pierre.gerold) Date: Mon, 21 Jul 2014 12:40:13 +0200 Subject: [IPython-dev] custom.js broken In-Reply-To: <CADWk=7Q2HXbXxPNVv8Wufnq_GnhNdw+EdHQDAq=Ah+Q4ha=e_Q@mail.gmail.com> References: <CADWk=7Q2HXbXxPNVv8Wufnq_GnhNdw+EdHQDAq=Ah+Q4ha=e_Q@mail.gmail.com> Message-ID: <53CCEE0D.7020907@laposte.net> Yey, I have the same problem with the current dev 3.0.0. It seems the javascript code is currently highly refactored. ( all extensions broken ... no API for MathJax and CodeMirror exposed ...). Usually, it is not a good idea to pull during summer time, because of several Python events that makes the dev broking many things. (Scipy for instance ...) What I have done is to revert from a previous version, and wait until the end of the tempest to see what will be finally broken, and what will not. From bussonniermatthias at gmail.com Mon Jul 21 06:54:15 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 21 Jul 2014 12:54:15 +0200 Subject: [IPython-dev] custom.js broken In-Reply-To: <53CCEE0D.7020907@laposte.net> References: <CADWk=7Q2HXbXxPNVv8Wufnq_GnhNdw+EdHQDAq=Ah+Q4ha=e_Q@mail.gmail.com> <53CCEE0D.7020907@laposte.net> Message-ID: <1D50124B-ABED-4DEE-92DB-562AADFE73B2@gmail.com> Le 21 juil. 2014 ? 12:40, pierre.gerold a ?crit : > Yey, I have the same problem with the current dev 3.0.0. It seems the > javascript code is currently highly refactored. ( all extensions broken > ... no API for MathJax and CodeMirror exposed ...). > > Usually, it is not a good idea to pull during summer time, because of > several Python events that makes the dev broking many things. (Scipy for > instance ...) > > What I have done is to revert from a previous version, and wait until > the end of the tempest to see what will be finally broken, and what will > not. Can you have a look at https://github.com/ipython/ipython/pull/6119 -- M > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140721/562c2661/attachment.html> From hemmecke at gmail.com Mon Jul 21 08:02:48 2014 From: hemmecke at gmail.com (Ralf Hemmecke) Date: Mon, 21 Jul 2014 14:02:48 +0200 Subject: [IPython-dev] kernel wrapper example Message-ID: <53CD0168.3090007@gmail.com> Hello, The site http://ipython.org/ipython-doc/dev/development/wrapperkernels.html makes a little echokernel.py example. But how exactly am I supposed to run this? I don't understand what I should do with the following part. ======================= Here?s the Kernel spec kernel.json file for this: {"argv":["python","-m","echokernel", "-f", "{connection_file}"], "display_name":"Echo", "language":"no-op" } ======================= My questions: 1) Into which directory should I put echokernel.py? 2) where should I put this kernel.json snippet? 3) I'd expect that then (when I simply call "ipython") it would automatically use "echokernel.py". Is this true? I'm probably not done with this, since the echokernel example is probably too simple as a real-world-example. I'd really appreciate an example that demonstrates the connection to bash as an example. Any chance that someone would write a tutorial for how to do this with the new kernelwrapper mechanism? I wonder how the bash process would actually be started and kept alive. Thank you in advance. Ralf From bussonniermatthias at gmail.com Mon Jul 21 10:22:32 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 21 Jul 2014 16:22:32 +0200 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <53CD0168.3090007@gmail.com> References: <53CD0168.3090007@gmail.com> Message-ID: <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> Hi Ralf, Thanks a lot for your questions. Le 21 juil. 2014 ? 14:02, Ralf Hemmecke a ?crit : > Hello, > > The site > > http://ipython.org/ipython-doc/dev/development/wrapperkernels.html > > makes a little echokernel.py example. But how exactly am I supposed to > run this? This is extremely recent on IPython, so the documentation is a little short. > I don't understand what I should do with the following part. > > ======================= > Here?s the Kernel spec kernel.json file for this: > > {"argv":["python","-m","echokernel", "-f", "{connection_file}"], > "display_name":"Echo", > "language":"no-op" > } > ======================= > > My questions: > > 1) Into which directory should I put echokernel.py? > 2) where should I put this kernel.json snippet? > 3) I'd expect that then (when I simply call "ipython") it would > automatically use "echokernel.py". Is this true? > > I'm probably not done with this, since the echokernel example is > probably too simple as a real-world-example. I'd really appreciate an > example that demonstrates the connection to bash as an example. > Any chance that someone would write a tutorial for how to do this with > the new kernelwrapper mechanism? I wonder how the bash process would > actually be started and kept alive. > I know there is an example of bash kernel that uses this process here : https://github.com/takluyver/bash_kernel We will try to expand the docs to at least link to the example. You can also help us by contributing docs about the process, in particular on this file : https://github.com/ipython/ipython/blob/master/docs/source/development/wrapperkernels.rst Thanks a lot ! -- Matthias -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140721/7de962fc/attachment.html> From tarun.gaba7 at gmail.com Mon Jul 21 14:21:04 2014 From: tarun.gaba7 at gmail.com (TARUN GABA) Date: Mon, 21 Jul 2014 23:51:04 +0530 Subject: [IPython-dev] custom.js broken Message-ID: <CAHAono0UJOmRh3YjtJ_nRyLz0dNc60PdYXfHVGdbO+orPU8Bvg@mail.gmail.com> Hi neil, You can try this: require(["jquery"], function($) { $([IPython.events]).on("app_initialized.NotebookApp", function () { // Add your extenstions here using $.getscript }); }); or: require([ "base/js/namespace", "jquery" ], function(IPython, $) { IPython.events.on("app_initialized.NotebookApp", function () { // Add your extenstions here using $.getscript }); }); Since all the javascript variables are being called by require.js now, there is no `$` or 'IPython' in the global scope. [Most probably], one of the scripts mentioned above should work for you. I dont have much time today to test them though! Tarun -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140721/498db741/attachment.html> From takowl at gmail.com Mon Jul 21 14:44:50 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 21 Jul 2014 11:44:50 -0700 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <53CD0168.3090007@gmail.com> References: <53CD0168.3090007@gmail.com> Message-ID: <CAOvn4qjsBaYZ-QfSqcigT4MLStJEpLik2xPQ9SK=zpPbDejncg@mail.gmail.com> On 21 July 2014 05:02, Ralf Hemmecke <hemmecke at gmail.com> wrote: > 1) Into which directory should I put echokernel.py? > Anywhere that you could import it. For testing, having it in the working directory when you start IPython should work. > 2) where should I put this kernel.json snippet? > Make a directory ~/.ipython/kernels/echo/ , and save kernel.json in there. As Matthias said, this is a new mechanism - you will need the development version of IPython to use it - and it's not properly documented yet. I will write some docs. > 3) I'd expect that then (when I simply call "ipython") it would > automatically use "echokernel.py". Is this true? > Not quite. Firstly, the idea is that you can have several of these kernel specifications, so you need to tell it which one to use. For 'ipython console' and 'ipython qtconsole', you can start them with a '--kernel echo' argument. The name is the last part of the directory path where you saved kernel.json. In the notebook, there will be a dropdown menu to select from the available kernels - that's in development in PR 6126: https://github.com/ipython/ipython/pull/6126 If you just type 'ipython', it's a single process running your code, not a frontend communicating with a kernel, so it can't use a different kernel. You can use 'ipython console' to get a similar terminal interface which does talk to a kernel. Matthias already pointed you to my bash_kernel, which I wrote partly as an example of how to do this kind of thing. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140721/f1c4e592/attachment.html> From hemmecke at gmail.com Mon Jul 21 15:43:14 2014 From: hemmecke at gmail.com (Ralf Hemmecke) Date: Mon, 21 Jul 2014 21:43:14 +0200 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> References: <53CD0168.3090007@gmail.com> <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> Message-ID: <53CD6D52.5050507@gmail.com> > https://github.com/takluyver/bash_kernel Wonderful! Thanks! However... it says Python3. Any big reason why it shouldn't also work with python 2.6 or 2.7? Ralf From takowl at gmail.com Mon Jul 21 15:59:43 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 21 Jul 2014 12:59:43 -0700 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <53CD6D52.5050507@gmail.com> References: <53CD0168.3090007@gmail.com> <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> <53CD6D52.5050507@gmail.com> Message-ID: <CAOvn4qgFjzCLW-GpvbAYUS1seY69aYO7fb=LKRRx3KB-viobAQ@mail.gmail.com> On 21 July 2014 12:43, Ralf Hemmecke <hemmecke at gmail.com> wrote: > However... it says Python3. Any big reason why it shouldn't also work > with python 2.6 or 2.7? It would probably work, but I was testing it with Python 3, as I generally do with new projects. As the user will be using bash, not Python, the Python version it runs on shouldn't matter. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140721/fbc5f80d/attachment.html> From hemmecke at gmail.com Mon Jul 21 17:51:06 2014 From: hemmecke at gmail.com (Ralf Hemmecke) Date: Mon, 21 Jul 2014 23:51:06 +0200 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <CAOvn4qgFjzCLW-GpvbAYUS1seY69aYO7fb=LKRRx3KB-viobAQ@mail.gmail.com> References: <53CD0168.3090007@gmail.com> <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> <53CD6D52.5050507@gmail.com> <CAOvn4qgFjzCLW-GpvbAYUS1seY69aYO7fb=LKRRx3KB-viobAQ@mail.gmail.com> Message-ID: <53CD8B4A.3080303@gmail.com> Hello, and thank you for your answers. I could run the echokernel.py example. > It would probably work, but I was testing it with Python 3 OK, but see attachment. Log is generated via... bash ipython-bash.install > ipython-bash.log 2>&1 Maybe I'm doing something wrong, but being inexperienced with python, I don't see what. That script was executed in a rather vanilla Debian 7 VM with python-dev installed. $ type bash bash is hashed (/bin/bash) $ which bash /bin/bash Any idea? Ralf -------------- next part -------------- #!/bin/bash #$ cat /etc/issue ## Debian GNU/Linux 7 \n \l #$ python --version ## Python 2.7.3 # installation directory I=$HOME/ipython/programs export PATH=$I/bin:$PATH # source directory S=$HOME/ipython/sources # virtualenv mkdir -p $S cd $S git clone git://github.com/pypa/virtualenv.git cd virtualenv git checkout master python virtualenv.py $I cd $S git clone https://github.com/ipython/ipython.git cd ipython pip install -e ".[notebook]" pip install pexpect cd $S git clone https://github.com/takluyver/bash_kernel.git cd bash_kernel mkdir -p $HOME/.ipython/kernels/bash cp kernelspec/kernel.json $HOME/.ipython/kernels/bash sed -i 's/python3/python/' $HOME/.ipython/kernels/bash/kernel.json ipython console --kernel bash -------------- next part -------------- A non-text attachment was scrubbed... Name: ipython-bash.log Type: text/x-log Size: 29882 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140721/db590513/attachment.bin> From takowl at gmail.com Mon Jul 21 18:01:58 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 21 Jul 2014 15:01:58 -0700 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <53CD8B4A.3080303@gmail.com> References: <53CD0168.3090007@gmail.com> <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> <53CD6D52.5050507@gmail.com> <CAOvn4qgFjzCLW-GpvbAYUS1seY69aYO7fb=LKRRx3KB-viobAQ@mail.gmail.com> <53CD8B4A.3080303@gmail.com> Message-ID: <CAOvn4qj+f+EOdMz_8jMe0BEQAjSh5tZijFbep6x8dUMHMnwbXw@mail.gmail.com> On 21 July 2014 14:51, Ralf Hemmecke <hemmecke at gmail.com> wrote: > That script was executed in a rather vanilla Debian 7 VM with python-dev > installed. > Did you customise the bash prompt at all? It looks like it's failing to find the prompt when it starts bash. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140721/bc97ad81/attachment.html> From hemmecke at gmail.com Mon Jul 21 19:12:37 2014 From: hemmecke at gmail.com (Ralf Hemmecke) Date: Tue, 22 Jul 2014 01:12:37 +0200 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <CAOvn4qj+f+EOdMz_8jMe0BEQAjSh5tZijFbep6x8dUMHMnwbXw@mail.gmail.com> References: <53CD0168.3090007@gmail.com> <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> <53CD6D52.5050507@gmail.com> <CAOvn4qgFjzCLW-GpvbAYUS1seY69aYO7fb=LKRRx3KB-viobAQ@mail.gmail.com> <53CD8B4A.3080303@gmail.com> <CAOvn4qj+f+EOdMz_8jMe0BEQAjSh5tZijFbep6x8dUMHMnwbXw@mail.gmail.com> Message-ID: <53CD9E65.1030301@gmail.com> > Did you customise the bash prompt at all? Oh, yes. That's the first thing I do in my .bashrc. > It looks like it's failing to find the prompt when it starts bash. I can confirm that after removing my .bashrc everything seems to work. Thanks. That brings me quite a big step forward. As an example, your bash_kernel is OK, but that someone customizes his/her PS1 should be expected. Either you should clearly document the prerequisite of a certain prompt or tell the user that he/she should customize bash_kernel.py to the respective prompt. OK, OK, I know that everything is way too fresh to be already perfect. Anyway, I'd like to thank you. Now having a working example just half a day after my question is more than I expected. Ralf From hemmecke at gmail.com Mon Jul 21 19:49:51 2014 From: hemmecke at gmail.com (Ralf Hemmecke) Date: Tue, 22 Jul 2014 01:49:51 +0200 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <CAOvn4qj+f+EOdMz_8jMe0BEQAjSh5tZijFbep6x8dUMHMnwbXw@mail.gmail.com> References: <53CD0168.3090007@gmail.com> <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> <53CD6D52.5050507@gmail.com> <CAOvn4qgFjzCLW-GpvbAYUS1seY69aYO7fb=LKRRx3KB-viobAQ@mail.gmail.com> <53CD8B4A.3080303@gmail.com> <CAOvn4qj+f+EOdMz_8jMe0BEQAjSh5tZijFbep6x8dUMHMnwbXw@mail.gmail.com> Message-ID: <53CDA71F.4020601@gmail.com> Oh, more questions to this wrapper stuff. 1) What happens to the % and %% magic mechanism? Would I be able to use that also if the underlying kernel is bash? In fact, I actually don't want it or rather want it optional since the language I'm going to connect to uses % and %% to refer to the previous and previous-previous expression, so I'd rather like nobody to take away that meaning before I get access to the input. 2) ipython notebook --kernel bash does not work because ipython notebook does not understand the kernel option. How would I go about starting a new notebook with my kernel? 3) Of course, a notebook should know about which kernel it is written for. Can I assume that the design is such that the notebook contains this information or what is the overall picture? Ralf From takowl at gmail.com Mon Jul 21 19:56:04 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 21 Jul 2014 16:56:04 -0700 Subject: [IPython-dev] kernel wrapper example In-Reply-To: <53CD9E65.1030301@gmail.com> References: <53CD0168.3090007@gmail.com> <20902FDD-E1D0-4098-814F-A40290984B57@gmail.com> <53CD6D52.5050507@gmail.com> <CAOvn4qgFjzCLW-GpvbAYUS1seY69aYO7fb=LKRRx3KB-viobAQ@mail.gmail.com> <53CD8B4A.3080303@gmail.com> <CAOvn4qj+f+EOdMz_8jMe0BEQAjSh5tZijFbep6x8dUMHMnwbXw@mail.gmail.com> <53CD9E65.1030301@gmail.com> Message-ID: <CAOvn4qhcOZkgyJmR35uDKhKnE5oAAVb6fQrkGRDfdv=ivQkDzA@mail.gmail.com> On 21 July 2014 16:12, Ralf Hemmecke <hemmecke at gmail.com> wrote: > As an example, your bash_kernel is OK, but that someone customizes > his/her PS1 should be expected. Either you should clearly document the > prerequisite of a certain prompt or tell the user that he/she should > customize bash_kernel.py to the respective prompt. > There are flags for bash, --noprofile and --norc, that we could use to disable these customisations and start more reliably. However, then you also wouldn't get any customisations that you presumably want in the bash kernel, like your aliases. I think that's probably the right thing to do, and I've made an issue on Pexpect for it: https://github.com/pexpect/pexpect/issues/94 > 1) What happens to the % and %% magic mechanism? Would I be able to use that also if the underlying kernel is bash? No, they're implemented in the IPython kernel. Other kernels may choose to add some similar interactive conveniences to their language, but the bash kernel doesn't do anything like that. > How would I go about starting a new notebook with my kernel? The mechanisms to do that aren't finished yet, but if you want to be the early bird catching the bugs, run my PR: https://github.com/ipython/ipython/pull/6126 > 3) Of course, a notebook should know about which kernel it is written for. Can I assume that the design is such that the notebook contains this information or what is the overall picture? Yes, this information is (in that PR) stored in the notebook metadata, and it starts the correct kernel when you open a notebook if the relevant metadata is there. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140721/aa06f6c4/attachment.html> From bussonniermatthias at gmail.com Tue Jul 22 02:40:43 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 22 Jul 2014 08:40:43 +0200 Subject: [IPython-dev] custom.js broken In-Reply-To: <CAHAono0UJOmRh3YjtJ_nRyLz0dNc60PdYXfHVGdbO+orPU8Bvg@mail.gmail.com> References: <CAHAono0UJOmRh3YjtJ_nRyLz0dNc60PdYXfHVGdbO+orPU8Bvg@mail.gmail.com> Message-ID: <01ADAD04-9BE8-4964-92F1-7727B478843C@gmail.com> Le 21 juil. 2014 ? 20:21, TARUN GABA a ?crit : > Hi neil, > > You can try this: > > require(["jquery"], function($) { > > $([IPython.events]).on("app_initialized.NotebookApp", function () { > // Add your extenstions here using $.getscript > }); > }); > > > or: > > require([ > "base/js/namespace", > "jquery" > ], function(IPython, $) { > > IPython.events.on("app_initialized.NotebookApp", function () { > // Add your extenstions here using $.getscript > }); > }); > > > Since all the javascript variables are being called by require.js now, there is no `$` or 'IPython' in the global scope. [Most probably], one of the scripts mentioned above should work for you. I dont have much time today to test them though! > There are IPython and $ globals, custom.js is just loaded too early. We are trying to keep the transition for custom.js smooth and are doing our be to have old version still working. -- M > > Tarun > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From r.gom1977 at gmail.com Tue Jul 22 09:16:57 2014 From: r.gom1977 at gmail.com (Robert Gomulka) Date: Tue, 22 Jul 2014 15:16:57 +0200 Subject: [IPython-dev] IPython goes crazy when redirecting stdout on windows Message-ID: <CAMb=YrOpvUSEqUdV9wpeeEqtwX+oLSNZSLwhV23VEXj+-e10wg@mail.gmail.com> Hi all, I've recently performed several updates on my Windows machine. After that, when I redirect sys.stdout readline stops working and command line prompt (in cmd.exe or conemu) starts printing raw characters instead of interpreting ANSI codes: C:\git\CTTrunk8>ipython Python 2.7.8 (default, Jun 30 2014, 16:03:49) [MSC v.1500 32 bit (Intel)] Type "copyright", "credits" or "license" for more information. IPython 2.1.0 -- An enhanced Interactive Python. ? -> Introduction and overview of IPython's features. %quickref -> Quick reference. help -> Python's own help system. object? -> Details about 'object', use 'object??' for extra details. In [1]: print "xxx" xxx In [2]: import stdout_tst ??In [??3??]: ??print "yyy" yyy ??In [??4??]: ?? (stdout_tst redirects output to file and old stdout). How could I narrow down the reason (offending package/change)? I'd appreciate your help. Regards, Robert -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/43d6ff7d/attachment.html> From takowl at gmail.com Tue Jul 22 12:30:20 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 22 Jul 2014 09:30:20 -0700 Subject: [IPython-dev] IPython goes crazy when redirecting stdout on windows In-Reply-To: <CAMb=YrOpvUSEqUdV9wpeeEqtwX+oLSNZSLwhV23VEXj+-e10wg@mail.gmail.com> References: <CAMb=YrOpvUSEqUdV9wpeeEqtwX+oLSNZSLwhV23VEXj+-e10wg@mail.gmail.com> Message-ID: <CAOvn4qi-AbWLdU8wcpnZbSEzNn_ycPYkgDJyKsVawsEpktqgKw@mail.gmail.com> On 22 July 2014 06:16, Robert Gomulka <r.gom1977 at gmail.com> wrote: > After that, when I redirect sys.stdout readline stops working and command > line prompt (in cmd.exe or conemu) starts printing raw characters instead > of interpreting ANSI codes: I guess this will be something you need to work out in pyreadline: https://github.com/pyreadline/pyreadline -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/15a512c1/attachment.html> From r.gom1977 at gmail.com Tue Jul 22 15:24:08 2014 From: r.gom1977 at gmail.com (Robert Gomulka) Date: Tue, 22 Jul 2014 21:24:08 +0200 Subject: [IPython-dev] IPython goes crazy when redirecting stdout on windows In-Reply-To: <CAOvn4qi-AbWLdU8wcpnZbSEzNn_ycPYkgDJyKsVawsEpktqgKw@mail.gmail.com> References: <CAMb=YrOpvUSEqUdV9wpeeEqtwX+oLSNZSLwhV23VEXj+-e10wg@mail.gmail.com> <CAOvn4qi-AbWLdU8wcpnZbSEzNn_ycPYkgDJyKsVawsEpktqgKw@mail.gmail.com> Message-ID: <CAMb=YrM+fhTzwLf4wm8RisJhyBmq8G5cURYexOOfTWVa2sofWg@mail.gmail.com> Thank you for your input. I've double (triple?) checked my installation, even reinstalled ipython and pyreadline, but to no avail. To my surprise, when invoking "ipython console" instead of "ipython" (as before) works fine - I don't know why. I've spotted some information on colorama, which was recently updated on my system. But I couldn't disable it for testing - after removing site-packages/colorama ipython output was still full of colors, so I couldn't verify that. (Using older versions gave the same results - bad). I have a workaround for now, but still would appreciate further feedback. Robert On 22 July 2014 18:30, Thomas Kluyver <takowl at gmail.com> wrote: > On 22 July 2014 06:16, Robert Gomulka <r.gom1977 at gmail.com> wrote: > >> After that, when I redirect sys.stdout readline stops working and command >> line prompt (in cmd.exe or conemu) starts printing raw characters instead >> of interpreting ANSI codes: > > > I guess this will be something you need to work out in pyreadline: > https://github.com/pyreadline/pyreadline > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/7bcd3142/attachment.html> From r.gom1977 at gmail.com Tue Jul 22 15:34:29 2014 From: r.gom1977 at gmail.com (Robert Gomulka) Date: Tue, 22 Jul 2014 21:34:29 +0200 Subject: [IPython-dev] IPython goes crazy when redirecting stdout on windows In-Reply-To: <CAMb=YrM+fhTzwLf4wm8RisJhyBmq8G5cURYexOOfTWVa2sofWg@mail.gmail.com> References: <CAMb=YrOpvUSEqUdV9wpeeEqtwX+oLSNZSLwhV23VEXj+-e10wg@mail.gmail.com> <CAOvn4qi-AbWLdU8wcpnZbSEzNn_ycPYkgDJyKsVawsEpktqgKw@mail.gmail.com> <CAMb=YrM+fhTzwLf4wm8RisJhyBmq8G5cURYexOOfTWVa2sofWg@mail.gmail.com> Message-ID: <CAMb=YrPOrch+7y8VAFEQ=SMaWAzpTRk=M_CDgHHyD1pF7twPkw@mail.gmail.com> It has something to do with colorama :\ When I invoke ipython and write: import colorama colorama.init() My prompt becomes garbled and tab completion stops working. When I call colorama.deinit() they start working (and I still have colored output). But when I remove colorama folder and start ipython, I have colors, but prompt is garbled after import stdout_tst. Is there any hidden dependency? I'm lost at this point ... On 22 July 2014 21:24, Robert Gomulka <r.gom1977 at gmail.com> wrote: > Thank you for your input. > I've double (triple?) checked my installation, even reinstalled ipython > and pyreadline, but to no avail. > To my surprise, when invoking "ipython console" instead of "ipython" (as > before) works fine - I don't know why. > I've spotted some information on colorama, which was recently updated on > my system. > But I couldn't disable it for testing - after removing > site-packages/colorama ipython output was still full of colors, so I > couldn't verify that. (Using older versions gave the same results - bad). > > I have a workaround for now, but still would appreciate further feedback. > > Robert > > > On 22 July 2014 18:30, Thomas Kluyver <takowl at gmail.com> wrote: > >> On 22 July 2014 06:16, Robert Gomulka <r.gom1977 at gmail.com> wrote: >> >>> After that, when I redirect sys.stdout readline stops working and >>> command line prompt (in cmd.exe or conemu) starts printing raw characters >>> instead of interpreting ANSI codes: >> >> >> I guess this will be something you need to work out in pyreadline: >> https://github.com/pyreadline/pyreadline >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/0d8652c6/attachment.html> From briford.wylie at gmail.com Tue Jul 22 15:59:40 2014 From: briford.wylie at gmail.com (Brian Wylie) Date: Tue, 22 Jul 2014 13:59:40 -0600 Subject: [IPython-dev] automatic quoting in interactive shell Message-ID: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> Hi All, My googling is failing me.. I have the following issue... I'm using the IPython Interactive Shell (which is super awesome BTW).. and I'm playing around with configuration... cfg.InteractiveShellEmbed.autocall = 2 is spiffy as it will try to automatically add parenthesis.. the thing that I can't find is how to turn on 'automatic quoting' by default (see below)... it works if I put a comma at the beginning of the line but obviously you don't want to require users to do/know that.. So any pointers to docs/issues or 'do this you dork' are happily accepted :) Workbench[6]> help --------------> help() Welcome to Workbench Help: - workbench.help(topic) -- where topic can be a help, command or worker - workbench.help('basic') -- for getting started help ... - Workbench[7]> ,help meta <--- notice the tiny comma at the beginning meta This worker computes meta data for any file type. Input: [u'sample'] - Workbench[8]> help meta --------------> help(meta) NameError Traceback (most recent call last) -bri -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/1458fff1/attachment.html> From takowl at gmail.com Tue Jul 22 16:26:45 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 22 Jul 2014 13:26:45 -0700 Subject: [IPython-dev] IPython goes crazy when redirecting stdout on windows In-Reply-To: <CAMb=YrPOrch+7y8VAFEQ=SMaWAzpTRk=M_CDgHHyD1pF7twPkw@mail.gmail.com> References: <CAMb=YrOpvUSEqUdV9wpeeEqtwX+oLSNZSLwhV23VEXj+-e10wg@mail.gmail.com> <CAOvn4qi-AbWLdU8wcpnZbSEzNn_ycPYkgDJyKsVawsEpktqgKw@mail.gmail.com> <CAMb=YrM+fhTzwLf4wm8RisJhyBmq8G5cURYexOOfTWVa2sofWg@mail.gmail.com> <CAMb=YrPOrch+7y8VAFEQ=SMaWAzpTRk=M_CDgHHyD1pF7twPkw@mail.gmail.com> Message-ID: <CAOvn4qg8EKAOGczu1v1vy9BN1kbNqiqDUv4ecXG5Vi9oJw+s1Q@mail.gmail.com> On 22 July 2014 12:34, Robert Gomulka <r.gom1977 at gmail.com> wrote: > import colorama > colorama.init() > My prompt becomes garbled and tab completion stops working. > When I call colorama.deinit() they start working (and I still have colored > output). > > But when I remove colorama folder and start ipython, I have colors, but > prompt is garbled after import stdout_tst. > Is there any hidden dependency? I'm lost at this point ... IPython doesn't use colorama at all, but I believe it and pyreadline (which IPython does use) both try to interpret ANSI escape codes and do the appropriate operations (e.g. changing colours) in the Windows console. Presumably if they're both active and trying to do the same thing, they conflict in some way. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/3f0b01c0/attachment.html> From takowl at gmail.com Tue Jul 22 16:31:35 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 22 Jul 2014 13:31:35 -0700 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> Message-ID: <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> On 22 July 2014 12:59, Brian Wylie <briford.wylie at gmail.com> wrote: > the thing that I can't find is how to turn on 'automatic quoting' by > default (see below)... it works if I put a comma at the beginning of the > line but obviously you don't want to require users to do/know that.. > I don't think that's a feature we have, and I don't think we especially want to extend the functionality of autocall - it was disabled by default because it's too liable to confuse people new to Python. If you want to do it yourself as an extension, I think this is the best place to start looking at the code: https://github.com/ipython/ipython/blob/master/IPython/core/prefilter.py#L604 Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/be6d7312/attachment.html> From fperez.net at gmail.com Tue Jul 22 17:40:18 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 22 Jul 2014 14:40:18 -0700 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> Message-ID: <CAHAreOpQtQgcKUJz8OsHJa8O4RnYCL7+jM=KP1Ft5SfS55DHUg@mail.gmail.com> And the point is that, even for users who do want autocall to be on, in most cases they *don't* want it to always auto-quote, since there are many valid use cases where you want to call functions on non-string arguments. So as Thomas says, this sounds like a fairly narrowly-targeted extension that you should write as custom code for a profile you use in scenarios where such functionality makes sense for you. But it's not a generic feature for all of IPython. Cheers f On Tue, Jul 22, 2014 at 1:31 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 22 July 2014 12:59, Brian Wylie <briford.wylie at gmail.com> wrote: > >> the thing that I can't find is how to turn on 'automatic quoting' by >> default (see below)... it works if I put a comma at the beginning of the >> line but obviously you don't want to require users to do/know that.. >> > > I don't think that's a feature we have, and I don't think we especially > want to extend the functionality of autocall - it was disabled by default > because it's too liable to confuse people new to Python. If you want to do > it yourself as an extension, I think this is the best place to start > looking at the code: > > > https://github.com/ipython/ipython/blob/master/IPython/core/prefilter.py#L604 > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/2ff8c5ec/attachment.html> From briford.wylie at gmail.com Tue Jul 22 17:54:50 2014 From: briford.wylie at gmail.com (Brian Wylie) Date: Tue, 22 Jul 2014 15:54:50 -0600 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> Message-ID: <CAOp_npAb08dsy5F0LfMAdW1h2=sxBEG4hymxnmnnZMpEWfKcJw@mail.gmail.com> When you say you don't want to extend the functionality of autocall.. I'm assuming you mean you don't want to put in a flag for the option as the functionality is already there. So extending the functionality will be a good learning exercise for me... so I'll probably do it this way unless someone else has a better suggestion. 1) Make a simple 'transformer' 2) register_transformer(my_trans) 3) sort_transformers() Seem like a reasonable approach? My dev experience with IPython is a few days old.. so any guidance is appreciated :) Cheers, -bri On Tue, Jul 22, 2014 at 2:31 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 22 July 2014 12:59, Brian Wylie <briford.wylie at gmail.com> wrote: > >> the thing that I can't find is how to turn on 'automatic quoting' by >> default (see below)... it works if I put a comma at the beginning of the >> line but obviously you don't want to require users to do/know that.. >> > > I don't think that's a feature we have, and I don't think we especially > want to extend the functionality of autocall - it was disabled by default > because it's too liable to confuse people new to Python. If you want to do > it yourself as an extension, I think this is the best place to start > looking at the code: > > > https://github.com/ipython/ipython/blob/master/IPython/core/prefilter.py#L604 > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/26ac270f/attachment.html> From briford.wylie at gmail.com Tue Jul 22 18:30:02 2014 From: briford.wylie at gmail.com (Brian Wylie) Date: Tue, 22 Jul 2014 16:30:02 -0600 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOp_npAb08dsy5F0LfMAdW1h2=sxBEG4hymxnmnnZMpEWfKcJw@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> <CAOp_npAb08dsy5F0LfMAdW1h2=sxBEG4hymxnmnnZMpEWfKcJw@mail.gmail.com> Message-ID: <CAOp_npCJ3DkZQ5BkbNBGSNWtpvhu0Wnw9YWppXwFiZeaN9z9sQ@mail.gmail.com> Okay, the transformer approach worked amazingly well. It's a bit of a hack the transformer simply adds a ',' to the beginning of lines where I'm calling commands that need to be 'auto-quoted'.. but certainly speaks well of the IPython design that my hack worked so quickly. :) Again I just guessed on using the transformer approach, I might also dive into doing a custom completer just for fun... so let me know if you guys/gals have alternative suggestions. Cheers.. keep up the great work..! -bri On Tue, Jul 22, 2014 at 3:54 PM, Brian Wylie <briford.wylie at gmail.com> wrote: > When you say you don't want to extend the functionality of autocall.. I'm > assuming you mean you don't want to put in a flag for the option as the > functionality is already there. > > So extending the functionality will be a good learning exercise for me... > so I'll probably do it this way unless someone else has a better suggestion. > > 1) Make a simple 'transformer' > 2) register_transformer(my_trans) > 3) sort_transformers() > > Seem like a reasonable approach? My dev experience with IPython is a few > days old.. so any guidance is appreciated :) > > Cheers, > -bri > > > On Tue, Jul 22, 2014 at 2:31 PM, Thomas Kluyver <takowl at gmail.com> wrote: > >> On 22 July 2014 12:59, Brian Wylie <briford.wylie at gmail.com> wrote: >> >>> the thing that I can't find is how to turn on 'automatic quoting' by >>> default (see below)... it works if I put a comma at the beginning of the >>> line but obviously you don't want to require users to do/know that.. >>> >> >> I don't think that's a feature we have, and I don't think we especially >> want to extend the functionality of autocall - it was disabled by default >> because it's too liable to confuse people new to Python. If you want to do >> it yourself as an extension, I think this is the best place to start >> looking at the code: >> >> >> https://github.com/ipython/ipython/blob/master/IPython/core/prefilter.py#L604 >> >> Thomas >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/42ec856c/attachment.html> From takowl at gmail.com Tue Jul 22 18:34:56 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 22 Jul 2014 15:34:56 -0700 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOp_npCJ3DkZQ5BkbNBGSNWtpvhu0Wnw9YWppXwFiZeaN9z9sQ@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> <CAOp_npAb08dsy5F0LfMAdW1h2=sxBEG4hymxnmnnZMpEWfKcJw@mail.gmail.com> <CAOp_npCJ3DkZQ5BkbNBGSNWtpvhu0Wnw9YWppXwFiZeaN9z9sQ@mail.gmail.com> Message-ID: <CAOvn4qj8=eha7Cu-4Nsp3H9R5EjeVwXoWOpD72eqJvoxs4kROQ@mail.gmail.com> On 22 July 2014 15:30, Brian Wylie <briford.wylie at gmail.com> wrote: > Okay, the transformer approach worked amazingly well. It's a bit of a hack > the transformer simply adds a ',' to the beginning of lines where I'm > calling commands that need to be 'auto-quoted'.. but certainly speaks well > of the IPython design that my hack worked so quickly. :) Well, I'm glad it worked. How are you deciding which lines need that treatment? There are two bits of machinery transforming input in IPython. Input transformers handle things where you can tell just from looking at the line, like %magic and !shell commands. Then the prefilter machinery changes things that depend on what's in the current namespace, like autocall. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/86408710/attachment.html> From briford.wylie at gmail.com Tue Jul 22 18:44:58 2014 From: briford.wylie at gmail.com (Brian Wylie) Date: Tue, 22 Jul 2014 16:44:58 -0600 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOvn4qj8=eha7Cu-4Nsp3H9R5EjeVwXoWOpD72eqJvoxs4kROQ@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> <CAOp_npAb08dsy5F0LfMAdW1h2=sxBEG4hymxnmnnZMpEWfKcJw@mail.gmail.com> <CAOp_npCJ3DkZQ5BkbNBGSNWtpvhu0Wnw9YWppXwFiZeaN9z9sQ@mail.gmail.com> <CAOvn4qj8=eha7Cu-4Nsp3H9R5EjeVwXoWOpD72eqJvoxs4kROQ@mail.gmail.com> Message-ID: <CAOp_npDM+QwkRXe0zVOLzD-SjBTrQ7uoQNdhC2p3R_gu9Ztfdw@mail.gmail.com> class my_transformer(IPython.core.prefilter.PrefilterTransformer): def transform(self, line, continue_prompt): if line.startswith('help'): return ','+line else: return line I have a custom interactive shell where I want the help to be 'roll face on keyboard' simple.... > help > help load > help meta > help view I have cfg.InteractiveShellEmbed.autocall = 2 so these all expand out to a form like.. workbench.help("load") .... I can see after some experimenting that my 'hack' may be quite a PITA if it gets invoked when people don't want it.. which I'm sure is why you guys/gals don't really want it in the main IPython. I'll poke around inside the prefilter code and also look at doing a custom completer. Probably at some point the hack above will piss me off and I'll rip it out :) Thanks again for all the info, -bri On Tue, Jul 22, 2014 at 4:34 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 22 July 2014 15:30, Brian Wylie <briford.wylie at gmail.com> wrote: > >> Okay, the transformer approach worked amazingly well. It's a bit of a >> hack the transformer simply adds a ',' to the beginning of lines where I'm >> calling commands that need to be 'auto-quoted'.. but certainly speaks well >> of the IPython design that my hack worked so quickly. :) > > > Well, I'm glad it worked. How are you deciding which lines need that > treatment? > > There are two bits of machinery transforming input in IPython. Input > transformers handle things where you can tell just from looking at the > line, like %magic and !shell commands. Then the prefilter machinery changes > things that depend on what's in the current namespace, like autocall. > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/2f4f6c31/attachment.html> From takowl at gmail.com Tue Jul 22 18:56:34 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 22 Jul 2014 15:56:34 -0700 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOp_npDM+QwkRXe0zVOLzD-SjBTrQ7uoQNdhC2p3R_gu9Ztfdw@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> <CAOp_npAb08dsy5F0LfMAdW1h2=sxBEG4hymxnmnnZMpEWfKcJw@mail.gmail.com> <CAOp_npCJ3DkZQ5BkbNBGSNWtpvhu0Wnw9YWppXwFiZeaN9z9sQ@mail.gmail.com> <CAOvn4qj8=eha7Cu-4Nsp3H9R5EjeVwXoWOpD72eqJvoxs4kROQ@mail.gmail.com> <CAOp_npDM+QwkRXe0zVOLzD-SjBTrQ7uoQNdhC2p3R_gu9Ztfdw@mail.gmail.com> Message-ID: <CAOvn4qjndeE8a+TFtp5k_OkL2qGXgzCtN4gu+M2KhhtpBOr-DA@mail.gmail.com> On 22 July 2014 15:44, Brian Wylie <briford.wylie at gmail.com> wrote: > I have a custom interactive shell Is this shell still for the user to write Python code, or are you treating the input as something else? Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/e2be2cb1/attachment.html> From briford.wylie at gmail.com Tue Jul 22 20:34:40 2014 From: briford.wylie at gmail.com (Brian Wylie) Date: Tue, 22 Jul 2014 18:34:40 -0600 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOvn4qjndeE8a+TFtp5k_OkL2qGXgzCtN4gu+M2KhhtpBOr-DA@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> <CAOp_npAb08dsy5F0LfMAdW1h2=sxBEG4hymxnmnnZMpEWfKcJw@mail.gmail.com> <CAOp_npCJ3DkZQ5BkbNBGSNWtpvhu0Wnw9YWppXwFiZeaN9z9sQ@mail.gmail.com> <CAOvn4qj8=eha7Cu-4Nsp3H9R5EjeVwXoWOpD72eqJvoxs4kROQ@mail.gmail.com> <CAOp_npDM+QwkRXe0zVOLzD-SjBTrQ7uoQNdhC2p3R_gu9Ztfdw@mail.gmail.com> <CAOvn4qjndeE8a+TFtp5k_OkL2qGXgzCtN4gu+M2KhhtpBOr-DA@mail.gmail.com> Message-ID: <CAOp_npB+5aCfhvRKksDm-AiQP4f1W9wYO5OqV9RkatX5urpipQ@mail.gmail.com> Oh, definitely will be used to write python code.. the whole code base for the project that I work on 'workbench' is python... I just wanted help to be super 'roll face on keyboard' and something good happens.. was mostly a fun experiment.. as I go forward I'll probably have to think deeper on exactly what we want to do. Like I said it's definitely good that IPython has the flexibility to let me try these things out.. The workbench project is all client/server so I might do a custom completer so that people can tab complete the commands in a meaningful way, as part of that work I might rethink how to do help and some of the other stuff. -bri On Tue, Jul 22, 2014 at 4:56 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 22 July 2014 15:44, Brian Wylie <briford.wylie at gmail.com> wrote: > >> I have a custom interactive shell > > > Is this shell still for the user to write Python code, or are you treating > the input as something else? > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/1e89f5ea/attachment.html> From takowl at gmail.com Tue Jul 22 20:47:04 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 22 Jul 2014 17:47:04 -0700 Subject: [IPython-dev] automatic quoting in interactive shell In-Reply-To: <CAOp_npB+5aCfhvRKksDm-AiQP4f1W9wYO5OqV9RkatX5urpipQ@mail.gmail.com> References: <CAOp_npCSSbbUmajFyiC01g3G9STuOCBFz63Fdrn5z4dH5-_ngg@mail.gmail.com> <CAOvn4qgHnNDZcnr-RRjHmZj4C_MTX8Fs=x6hzAYkHEw1ybyYxQ@mail.gmail.com> <CAOp_npAb08dsy5F0LfMAdW1h2=sxBEG4hymxnmnnZMpEWfKcJw@mail.gmail.com> <CAOp_npCJ3DkZQ5BkbNBGSNWtpvhu0Wnw9YWppXwFiZeaN9z9sQ@mail.gmail.com> <CAOvn4qj8=eha7Cu-4Nsp3H9R5EjeVwXoWOpD72eqJvoxs4kROQ@mail.gmail.com> <CAOp_npDM+QwkRXe0zVOLzD-SjBTrQ7uoQNdhC2p3R_gu9Ztfdw@mail.gmail.com> <CAOvn4qjndeE8a+TFtp5k_OkL2qGXgzCtN4gu+M2KhhtpBOr-DA@mail.gmail.com> <CAOp_npB+5aCfhvRKksDm-AiQP4f1W9wYO5OqV9RkatX5urpipQ@mail.gmail.com> Message-ID: <CAOvn4qiXoYSmJGP-P-ZU+nmcm8gXfszJg3n1R2Att5dSfNLsBA@mail.gmail.com> On 22 July 2014 17:34, Brian Wylie <briford.wylie at gmail.com> wrote: > I just wanted help to be super 'roll face on keyboard' and something good > happens You've probably already seen that IPython lets you add ? on the end (or start) of any name for help (e.g. all?). It doesn't help if that name isn't present, though, which I think is what you're going for. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140722/7d300627/attachment.html> From ericgalloway at gmail.com Wed Jul 23 11:50:18 2014 From: ericgalloway at gmail.com (Eric Galloway) Date: Wed, 23 Jul 2014 08:50:18 -0700 Subject: [IPython-dev] newtabmagic Message-ID: <CAAXMK1=v72jwjXR6OO5fB5wKsYOSkp-MEyEhYe5MjwOyWaq_qg@mail.gmail.com> Hi folks, newtabmagic is a magic for opening help pages in new browser tabs. In IPython, the operators ? and ?? display help in text form. newtabmagic runs the pydoc server as a background process, providing access to help pages in HTML. There are two ways of opening new browser tabs. By dotted reference In [1]: %newtab IPython.core.debugger.Tracer which opens the url http://127.0.0.1:8888/IPython.core.debugger.Tracer.html (for a pydoc server port of 8888). Or by providing the name of an object. Here we need to do an import first: In [1]: import IPython In [2]: tracer = IPython.core.debugger.Tracer In [3]: %newtab tracer See https://github.com/etgalloway/newtabmagic for more. -Eric From takowl at gmail.com Wed Jul 23 15:12:43 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 23 Jul 2014 12:12:43 -0700 Subject: [IPython-dev] newtabmagic In-Reply-To: <CAAXMK1=v72jwjXR6OO5fB5wKsYOSkp-MEyEhYe5MjwOyWaq_qg@mail.gmail.com> References: <CAAXMK1=v72jwjXR6OO5fB5wKsYOSkp-MEyEhYe5MjwOyWaq_qg@mail.gmail.com> Message-ID: <CAOvn4qjd2s8AxbAVZVrg0NJnC_nGgdgOYrBY6kC6-hBpP8SA0A@mail.gmail.com> Thanks Eric. Please do add this to the IPython extensions index as well: https://github.com/ipython/ipython/wiki/Extensions-Index Best wishes, Thomas On 23 July 2014 08:50, Eric Galloway <ericgalloway at gmail.com> wrote: > Hi folks, > > newtabmagic is a magic for opening help pages in new browser tabs. > In IPython, the operators ? and ?? display help in text form. > newtabmagic runs the pydoc server as a background process, > providing access to help pages in HTML. > > There are two ways of opening new browser tabs. By > dotted reference > > In [1]: %newtab IPython.core.debugger.Tracer > > which opens the url > http://127.0.0.1:8888/IPython.core.debugger.Tracer.html > (for a pydoc server port of 8888). > > Or by providing the name of an object. Here > we need to do an import first: > > In [1]: import IPython > In [2]: tracer = IPython.core.debugger.Tracer > In [3]: %newtab tracer > > See https://github.com/etgalloway/newtabmagic for more. > > -Eric > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140723/19d9c07c/attachment.html> From fperez.net at gmail.com Wed Jul 23 17:30:54 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 23 Jul 2014 14:30:54 -0700 Subject: [IPython-dev] Interactive magic cells In-Reply-To: <AACF9EED-3727-421F-A263-9FA11C3FF08F@lrde.epita.fr> References: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> <CAAusYCii0rjcKX6CK3jNfpcBw6Sir6M3Qa+tvD5m7uwN2tzB=Q@mail.gmail.com> <62E7B7A0-9E61-4A98-9B64-351EDE06D39C@lrde.epita.fr> <AACF9EED-3727-421F-A263-9FA11C3FF08F@lrde.epita.fr> Message-ID: <CAHAreOrSC45+k5WZshCvrLNHePdsf-RQpNHHYncxuhTccDzFsg@mail.gmail.com> I don't think we expose anything at the single-keystroke level. All that happens client-side in the CodeMirror editor instance, so you'd have to hook into that event handling loop to trigger execution requests at your desired points (every keystroke, or every period, etc). Cheers f On Sun, Jul 20, 2014 at 8:51 AM, Akim Demaille <akim at lrde.epita.fr> wrote: > > Le 20 juil. 2014 ? 12:34, Akim Demaille <akim at lrde.epita.fr> a ?crit : > > >> but could also add some custom parsing for your language. > > > > Ah!!! Of course! Then I realize that I needs to write something > > like what was done for %%script. I'd be very happy to provide > > syntactic highlighting, for instance. > > > > Is there a place with documentation on how to write extensions > > such as %%bash and the like? > > Well, really, I have not seen anything about having a means to > make a magic cell interactive. If someone has an idea, I'd be happy > to learn from it! > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140723/132fb32a/attachment.html> From fperez.net at gmail.com Wed Jul 23 17:33:40 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 23 Jul 2014 14:33:40 -0700 Subject: [IPython-dev] Step-by-step debugging with IPython In-Reply-To: <87zjg67ah2.fsf@gmail.com> References: <CAD4ivxVa3SV8PGYFOrM3oavAyWU+7h4BE2S_pUihAJS4zzdExA@mail.gmail.com> <CAOvn4qjk2upEVemfhP7xCovFgo=EuCBd+6q9Km4MM=UEHCFcXw@mail.gmail.com> <87zjg67ah2.fsf@gmail.com> Message-ID: <CAHAreOqUAY4wtXtKSiXRrhdv3ucNgY3dzaOze7veyfc7juM08A@mail.gmail.com> In addition to the above, keep in mind that you can also use '%run -d' to run your code under the control of the debugger with stepping. See %run? for details. Cheers, f On Fri, Jul 18, 2014 at 12:06 PM, Darlan Cavalcante Moreira < darcamo at gmail.com> wrote: > > takowl at gmail.com writes: > > > On 15 July 2014 06:02, Josh Wasserstein <ribonucleico at gmail.com> wrote: > > > >> This makes me wonder if: > >> > >> 1) I am doing things wrong > >> 2) The current status of IPython does not provide the debugging > >> functionality stated in the OP. > >> > >> And the reason behind 2) could be: > >> a. Limitations of Python / execution model that make this inviable > >> b. There is not enough interest to justify an effort to improve the > >> debugging model / the relatively high complexity required to have > Python / > >> IPython support this workflow > >> > > > > There's a distinct possibility that the answer is 2c: The effort is > > justified, but no-one has done it yet. > > > > I know several of us on the core team routinely just scatter print > > statements around the code when we want to debug something. Even using a > > post-mortem debugger to go up and down the stack, with no way to step > > through code, seems advanced to me. > > > > My personal take on it is that the effort necessary to learn and use a > > command-line debugger isn't really worth it for writing Python code, > where > > uncaught errors automatically give you quite a bit of detail on what went > > wrong. I suspect that a good graphical debugger could be useful (I've > used > > the JS debugger in Firefox, for instance). > > > > Thomas > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > Debugging in python was annoying to me until I discovered pudb. > https://pypi.python.org/pypi/pudb > > Install it through pip and then add the line below at some point in your > program > import pudb; pudb.set_trace() > and run it as usual. > > Or you don't add anything and run you program with > pudb my_program.py > > > The advantages of pudb when compared with standard pdb or ipdb is that > it is graphical and much easier to work with. You can step throgh code > with the 'n' key, step inside a function with the 's' key, go up or down > in the stack with 'd' and 'u', etc. > > But the killer feature is the integration with IPython. At any point you > can press '!' to go to an IPython terminal with the current variables > (use Ctrl+D when you are finished to go back to pudb). From there you > can do any test you want. Note that if in pudb you go up in the stack > with the 'u' key and then start IPython with '!' you will have the > variables from that stack. > > There are ther noce features too, such as conditional breakpoints, etc. > > -- > Darlan Cavalcante Moreira > darcamo at gmail.com > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140723/c9f9b4bb/attachment.html> From cyrille.rossant at gmail.com Wed Jul 23 18:50:46 2014 From: cyrille.rossant at gmail.com (Cyrille Rossant) Date: Thu, 24 Jul 2014 00:50:46 +0200 Subject: [IPython-dev] Flushing the message buffer of a Widget In-Reply-To: <CAN7r33MXaAkSwj9LKMQnT+cTZz_=WyGdw6a=L_dQgsBWPqT2vA@mail.gmail.com> References: <CAN7r33MXaAkSwj9LKMQnT+cTZz_=WyGdw6a=L_dQgsBWPqT2vA@mail.gmail.com> Message-ID: <CA+-1RQSq0kD+5NSc=34zrT3Nhg2Bxi-mRE8HrytYofeUB_pECA@mail.gmail.com> > We want to "flush" the message buffer of a Widget model. What is the best > way of this when using `this.send()`? Here is the reason why: > We are trying to do some sort of VNC backend with Vispy and IPython > notebook. We are sending captured Javascript events to backend and send back > PNGs to frontend. For `mouse move` event, dragging is too slow. Basically, > when we send too many events from the notebook to the kernel, and when the > kernel takes too much time for each event, the event queue becomes too long. > So we want to flush the queue whenever it becomes too long. > > Here is an example of dragging: https://imgflip.com/gif/adwf6 > Here is the .js code sample: > https://gist.github.com/mfkaptan/eb12cc91ee9d49f348d9 To elaborate on this: is this the right way of implementing a live server-side visualization backend (streaming PNG images to the browser) with IPython? What we want is to send messages back and forth between Python and the browser, using the widget machinery rather than comms. The throttling mechanism doesn't seem to work here (the message queue saturates). Also, performance-wise, it would be better if we could avoid going through base64, and instead using binary messages directly for the PNG images. From fperez.net at gmail.com Wed Jul 23 19:28:30 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 23 Jul 2014 16:28:30 -0700 Subject: [IPython-dev] test from where a module is imported In-Reply-To: <1851667.fXX6ETTmBj@bc433789> References: <1851667.fXX6ETTmBj@bc433789> Message-ID: <CAHAreOq9earEoHhkLLgxY8go_W3CnySU5mqA-Pf2zDoEbkvM8Q@mail.gmail.com> On Thu, Jul 17, 2014 at 1:19 AM, Johann Rohwer <jr at sun.ac.za> wrote: > I can think of various hacks on how to achieve this but would like to know > if > there is The Right Way (TM) and if so, what it is. > There is no 'right way' to do this, because the question is in a sense ill-posed, given the design of IPython: any given IPython kernel can be *simultaneously* connected to a notebook, a Qt console and a text console (or more than one). So a python process can't really answer 'am I in a Qt console?', since the answer can be simultaneously yes, no, or both, and it can change at any point in time during the life of the process (since clients can connect and disconnect). Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140723/6b4eda8b/attachment.html> From fperez.net at gmail.com Wed Jul 23 19:33:13 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 23 Jul 2014 16:33:13 -0700 Subject: [IPython-dev] test from where a module is imported In-Reply-To: <CAHAreOq9earEoHhkLLgxY8go_W3CnySU5mqA-Pf2zDoEbkvM8Q@mail.gmail.com> References: <1851667.fXX6ETTmBj@bc433789> <CAHAreOq9earEoHhkLLgxY8go_W3CnySU5mqA-Pf2zDoEbkvM8Q@mail.gmail.com> Message-ID: <CAHAreOox3JTCEsuMHP5gN8vfnE6EfqazFfE8QDxEdRPaYQSLhw@mail.gmail.com> oops, sorry. I just saw your other copy and that this had been addressed in that thread. We can continue any further discussion in that other thread. On Wed, Jul 23, 2014 at 4:28 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Thu, Jul 17, 2014 at 1:19 AM, Johann Rohwer <jr at sun.ac.za> wrote: > >> I can think of various hacks on how to achieve this but would like to >> know if >> there is The Right Way (TM) and if so, what it is. >> > > There is no 'right way' to do this, because the question is in a sense > ill-posed, given the design of IPython: any given IPython kernel can be > *simultaneously* connected to a notebook, a Qt console and a text console > (or more than one). > > So a python process can't really answer 'am I in a Qt console?', since the > answer can be simultaneously yes, no, or both, and it can change at any > point in time during the life of the process (since clients can connect and > disconnect). > > Cheers > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140723/c486c749/attachment.html> From akim at lrde.epita.fr Thu Jul 24 05:11:38 2014 From: akim at lrde.epita.fr (Akim Demaille) Date: Thu, 24 Jul 2014 11:11:38 +0200 Subject: [IPython-dev] Interactive magic cells In-Reply-To: <CAHAreOrSC45+k5WZshCvrLNHePdsf-RQpNHHYncxuhTccDzFsg@mail.gmail.com> References: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> <CAAusYCii0rjcKX6CK3jNfpcBw6Sir6M3Qa+tvD5m7uwN2tzB=Q@mail.gmail.com> <62E7B7A0-9E61-4A98-9B64-351EDE06D39C@lrde.epita.fr> <AACF9EED-3727-421F-A263-9FA11C3FF08F@lrde.epita.fr> <CAHAreOrSC45+k5WZshCvrLNHePdsf-RQpNHHYncxuhTccDzFsg@mail.gmail.com> Message-ID: <3A152F24-6ABB-4827-A8AD-FCF64FD0992D@lrde.epita.fr> Le 23 juil. 2014 ? 23:30, Fernando Perez <fperez.net at gmail.com> a ?crit : > I don't think we expose anything at the single-keystroke level. All that happens client-side in the CodeMirror editor instance, so you'd have to hook into that event handling loop to trigger execution requests at your desired points (every keystroke, or every period, etc). So maybe a better option would be a timer? WDYT? I don't expect that there would be many such cells in the notebook, so I don't think there's a high scalability issue. I have no idea what CodeMirror is, and I'm afraid to dive in too many details I don't grasp :) What in your opinion would be the easiest way? Thanks in advance! From bussonniermatthias at gmail.com Thu Jul 24 05:26:30 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Thu, 24 Jul 2014 11:26:30 +0200 Subject: [IPython-dev] Interactive magic cells In-Reply-To: <3A152F24-6ABB-4827-A8AD-FCF64FD0992D@lrde.epita.fr> References: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> <CAAusYCii0rjcKX6CK3jNfpcBw6Sir6M3Qa+tvD5m7uwN2tzB=Q@mail.gmail.com> <62E7B7A0-9E61-4A98-9B64-351EDE06D39C@lrde.epita.fr> <AACF9EED-3727-421F-A263-9FA11C3FF08F@lrde.epita.fr> <CAHAreOrSC45+k5WZshCvrLNHePdsf-RQpNHHYncxuhTccDzFsg@mail.gmail.com> <3A152F24-6ABB-4827-A8AD-FCF64FD0992D@lrde.epita.fr> Message-ID: <57F65A90-FD5B-427F-8A9B-62CF12A1C614@gmail.com> Cells magic a pure kernel side stuff, they have no idea that they are coming from the notebook. You will have to write javascript to do what you ask. CodeMirror is the js library we use in which you type code in notebook. Right now it is configured to send the code only wine you press Shift-Enter, you would have to configure it to send code more often. Timer will be useless at the kernel as no way of knowing you are actually typing in the cell. -- M Le 24 juil. 2014 ? 11:11, Akim Demaille a ?crit : > > Le 23 juil. 2014 ? 23:30, Fernando Perez <fperez.net at gmail.com> a ?crit : > >> I don't think we expose anything at the single-keystroke level. All that happens client-side in the CodeMirror editor instance, so you'd have to hook into that event handling loop to trigger execution requests at your desired points (every keystroke, or every period, etc). > > So maybe a better option would be a timer? WDYT? I don't > expect that there would be many such cells in the notebook, > so I don't think there's a high scalability issue. > > I have no idea what CodeMirror is, and I'm afraid to dive > in too many details I don't grasp :) What in your opinion > would be the easiest way? > > Thanks in advance! > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From akim at lrde.epita.fr Thu Jul 24 05:25:25 2014 From: akim at lrde.epita.fr (Akim Demaille) Date: Thu, 24 Jul 2014 11:25:25 +0200 Subject: [IPython-dev] Interactive magic cells In-Reply-To: <57F65A90-FD5B-427F-8A9B-62CF12A1C614@gmail.com> References: <8DC59D08-4669-4DFD-9CC8-E41773083AAC@lrde.epita.fr> <CAAusYCii0rjcKX6CK3jNfpcBw6Sir6M3Qa+tvD5m7uwN2tzB=Q@mail.gmail.com> <62E7B7A0-9E61-4A98-9B64-351EDE06D39C@lrde.epita.fr> <AACF9EED-3727-421F-A263-9FA11C3FF08F@lrde.epita.fr> <CAHAreOrSC45+k5WZshCvrLNHePdsf-RQpNHHYncxuhTccDzFsg@mail.gmail.com> <3A152F24-6ABB-4827-A8AD-FCF64FD0992D@lrde.epita.fr> <57F65A90-FD5B-427F-8A9B-62CF12A1C614@gmail.com> Message-ID: <0BEB11FB-9111-4573-9719-5C4B5A6D51A1@lrde.epita.fr> Le 24 juil. 2014 ? 11:26, Matthias Bussonnier <bussonniermatthias at gmail.com> a ?crit : > Cells magic a pure kernel side stuff, they have no idea that they are coming from the notebook. > You will have to write javascript to do what you ask. > > > CodeMirror is the js library we use in which you type code in notebook. > Right now it is configured to send the code only wine you press Shift-Enter, you would have to configure it to send code more often. > > Timer will be useless at the kernel as no way of knowing you are actually typing in the cell. Thanks, that really helps! From treddy at dal.ca Thu Jul 24 05:52:53 2014 From: treddy at dal.ca (Tyler Reddy) Date: Thu, 24 Jul 2014 10:52:53 +0100 Subject: [IPython-dev] CodeMirror and vim Message-ID: <CAHPuU_bLNip0r7jMdkR84e-NLueBtKSbzn3YxYm+orDF8DHGdA@mail.gmail.com> Hi, I've noticed that some of the features enabled for vim bindings in a recent release of CodeMirror (see the demo instance: http://codemirror.net/demo/vim.html) do not appear to work in IPython 2.0 notebook cells for which vim bindings have been enabled in the profile in the usual way. The main thing I notice is that I can't use the search "/" and substitution ":%s/find/replace/gc" commands, which bring up a nice little command line at the bottom of the cell in the example linked above. Many vim features *can* be enabled in IPython notebooks--including line numbers and wrapping of long lines, etc. But I'm wondering if the above limitations are primarily a result of the version of CodeMirror that is distributed with IPython, or the way that subsets of CodeMirror features interact with IPython notebooks? Cheers, Tyler -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140724/f335ceb4/attachment.html> From doug.blank at gmail.com Thu Jul 24 13:06:01 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 24 Jul 2014 13:06:01 -0400 Subject: [IPython-dev] CodeMirror overlay for spell checking Message-ID: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> I have successfully created and registered a CodeMirror overlay (for spell checking), but two questions: 1) Which of the modes is used for Markdown cells? I guess that will be the mode that I overlay. 2) How do I make it so that my new mode will be used on Markdown cells? I guess that I need to associate the mime type of Markdown cells with my new mode, but having some trouble finding where to connect this in the IPython JavaScript. Thanks for any suggestions, -Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140724/b1df1ffe/attachment.html> From bussonniermatthias at gmail.com Thu Jul 24 14:30:19 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Thu, 24 Jul 2014 20:30:19 +0200 Subject: [IPython-dev] CodeMirror overlay for spell checking In-Reply-To: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> References: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> Message-ID: <4974AEFF-2A79-48C3-87F3-ADFF793110B5@gmail.com> Le 24 juil. 2014 ? 19:06, Doug Blank a ?crit : > I have successfully created and registered a CodeMirror overlay (for spell checking), but two questions: > > 1) Which of the modes is used for Markdown cells? I guess that will be the mode that I overlay. JSconsole : > IPython.TextCell.options_default.cm_config.mode "htmlmixed" > > 2) How do I make it so that my new mode will be used on Markdown cells? IPython.TextCell.options_default.cm_config.mode = yourmode + loop on all cell and set IPython.notebook.get_cell(0).code_mirror.setOption('mode',yourmode) might need to require your mode first though, maybe with code_mirrorm.getMode cf julia custom.js https://github.com/JuliaLang/IJulia.jl/blob/master/deps/custom.js#L66-L90 > > I guess that I need to associate the mime type of Markdown cells with my new mode, but having some trouble finding where to connect this in the IPython JavaScript. I'm interested to see the code. -- M > > Thanks for any suggestions, > > -Doug > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From damianavila at gmail.com Thu Jul 24 14:31:40 2014 From: damianavila at gmail.com (=?UTF-8?Q?Dami=C3=A1n_Avila?=) Date: Thu, 24 Jul 2014 15:31:40 -0300 Subject: [IPython-dev] CodeMirror overlay for spell checking In-Reply-To: <4974AEFF-2A79-48C3-87F3-ADFF793110B5@gmail.com> References: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> <4974AEFF-2A79-48C3-87F3-ADFF793110B5@gmail.com> Message-ID: <CAH+mRR2L6jgNcL0Ci-VnFkpPAKmMNBxWtbcpujFOWnmVTnF72g@mail.gmail.com> > I'm interested to see the code. Me too ;-) 2014-07-24 15:30 GMT-03:00 Matthias Bussonnier <bussonniermatthias at gmail.com >: > > Le 24 juil. 2014 ? 19:06, Doug Blank a ?crit : > > > I have successfully created and registered a CodeMirror overlay (for > spell checking), but two questions: > > > > 1) Which of the modes is used for Markdown cells? I guess that will be > the mode that I overlay. > > JSconsole : > > > IPython.TextCell.options_default.cm_config.mode > "htmlmixed" > > > > > > > 2) How do I make it so that my new mode will be used on Markdown cells? > > IPython.TextCell.options_default.cm_config.mode = yourmode > + > loop on all cell and set > IPython.notebook.get_cell(0).code_mirror.setOption('mode',yourmode) > > might need to require your mode first though, maybe with > code_mirrorm.getMode > > cf julia custom.js > > https://github.com/JuliaLang/IJulia.jl/blob/master/deps/custom.js#L66-L90 > > > > > I guess that I need to associate the mime type of Markdown cells with my > new mode, but having some trouble finding where to connect this in the > IPython JavaScript. > > I'm interested to see the code. > -- > M > > > > > Thanks for any suggestions, > > > > -Doug > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- *Dami?n* -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140724/93bc4a7f/attachment.html> From doug.blank at gmail.com Thu Jul 24 16:52:23 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 24 Jul 2014 16:52:23 -0400 Subject: [IPython-dev] CodeMirror overlay for spell checking In-Reply-To: <CAH+mRR2L6jgNcL0Ci-VnFkpPAKmMNBxWtbcpujFOWnmVTnF72g@mail.gmail.com> References: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> <4974AEFF-2A79-48C3-87F3-ADFF793110B5@gmail.com> <CAH+mRR2L6jgNcL0Ci-VnFkpPAKmMNBxWtbcpujFOWnmVTnF72g@mail.gmail.com> Message-ID: <CAAusYCg3sNU0Ygj_tOfKmFNounxp7p871ioVAPYXA8=TTMxTXQ@mail.gmail.com> On Thu, Jul 24, 2014 at 2:31 PM, Dami?n Avila <damianavila at gmail.com> wrote: > > I'm interested to see the code. > > Me too ;-) > Thanks for the hints and links... Oh, we'll make this available to all... no more misspellings in notebooks! -Doug > > > 2014-07-24 15:30 GMT-03:00 Matthias Bussonnier < > bussonniermatthias at gmail.com>: > > >> Le 24 juil. 2014 ? 19:06, Doug Blank a ?crit : >> >> > I have successfully created and registered a CodeMirror overlay (for >> spell checking), but two questions: >> > >> > 1) Which of the modes is used for Markdown cells? I guess that will be >> the mode that I overlay. >> >> JSconsole : >> >> > IPython.TextCell.options_default.cm_config.mode >> "htmlmixed" >> >> >> >> > >> > 2) How do I make it so that my new mode will be used on Markdown cells? >> >> IPython.TextCell.options_default.cm_config.mode = yourmode >> + >> loop on all cell and set >> IPython.notebook.get_cell(0).code_mirror.setOption('mode',yourmode) >> >> might need to require your mode first though, maybe with >> code_mirrorm.getMode >> >> cf julia custom.js >> >> https://github.com/JuliaLang/IJulia.jl/blob/master/deps/custom.js#L66-L90 >> >> > >> > I guess that I need to associate the mime type of Markdown cells with >> my new mode, but having some trouble finding where to connect this in the >> IPython JavaScript. >> >> I'm interested to see the code. >> -- >> M >> >> > >> > Thanks for any suggestions, >> > >> > -Doug >> > >> > _______________________________________________ >> > IPython-dev mailing list >> > IPython-dev at scipy.org >> > http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > > -- > *Dami?n* > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140724/58fc3a88/attachment.html> From doug.blank at gmail.com Thu Jul 24 21:59:17 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 24 Jul 2014 21:59:17 -0400 Subject: [IPython-dev] CodeMirror overlay for spell checking In-Reply-To: <CAAusYCg3sNU0Ygj_tOfKmFNounxp7p871ioVAPYXA8=TTMxTXQ@mail.gmail.com> References: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> <4974AEFF-2A79-48C3-87F3-ADFF793110B5@gmail.com> <CAH+mRR2L6jgNcL0Ci-VnFkpPAKmMNBxWtbcpujFOWnmVTnF72g@mail.gmail.com> <CAAusYCg3sNU0Ygj_tOfKmFNounxp7p871ioVAPYXA8=TTMxTXQ@mail.gmail.com> Message-ID: <CAAusYCiWRBXvBU+e-0T0onzokUCWuide_OB9zt-HYJSGb3Pfag@mail.gmail.com> Success; we now have a working IPython notebook with spelling checking in Markdown cells! I'll try to package this up over the next few days to make a notebook extension for all kernels. Currently, I have this all in one custom.js file [1] ... check out the toggle_spell_check function and code loaded on app_initialized. The way that is currently works is as a toggle "spell check" button: click it once, and it turns on a spell check overlay over the "markdown" mode on all Markdown cells (see attached picture). Press the button again, and it turns it off. I'm currently using Typo.js, but any JavaScript spell check library could work. Typo isn't bad... may need to adjust what gets checked (need to remove single quotes, and maybe add HTML tag names to dictionary). Possible options/limitations: 1) Should markdown cells be the only cells spell checked? 2) doesn't currently allow for right-click suggestion fixes; important? 3) English only. Just need to provide more dictionaries and an API to change the dictionary. 4) Should the spell checking be on all of the time? Other options/suggestions welcomed! -Doug [1] - https://bitbucket.org/ipre/calico/src/master/notebooks/profile/static/custom/custom.js This custom.js has a few things in it that we'll break into extensions: two-column mode, bibtex references, tabbed in/out cells, heading numbering, table of contents, and spelling checking. On Thu, Jul 24, 2014 at 4:52 PM, Doug Blank <doug.blank at gmail.com> wrote: > On Thu, Jul 24, 2014 at 2:31 PM, Dami?n Avila <damianavila at gmail.com> > wrote: > >> > I'm interested to see the code. >> >> Me too ;-) >> > > Thanks for the hints and links... > > Oh, we'll make this available to all... no more misspellings in notebooks! > > -Doug > > >> >> >> 2014-07-24 15:30 GMT-03:00 Matthias Bussonnier < >> bussonniermatthias at gmail.com>: >> >> >>> Le 24 juil. 2014 ? 19:06, Doug Blank a ?crit : >>> >>> > I have successfully created and registered a CodeMirror overlay (for >>> spell checking), but two questions: >>> > >>> > 1) Which of the modes is used for Markdown cells? I guess that will be >>> the mode that I overlay. >>> >>> JSconsole : >>> >>> > IPython.TextCell.options_default.cm_config.mode >>> "htmlmixed" >>> >>> >>> >>> > >>> > 2) How do I make it so that my new mode will be used on Markdown cells? >>> >>> IPython.TextCell.options_default.cm_config.mode = yourmode >>> + >>> loop on all cell and set >>> IPython.notebook.get_cell(0).code_mirror.setOption('mode',yourmode) >>> >>> might need to require your mode first though, maybe with >>> code_mirrorm.getMode >>> >>> cf julia custom.js >>> >>> https://github.com/JuliaLang/IJulia.jl/blob/master/deps/custom.js#L66-L90 >>> >>> > >>> > I guess that I need to associate the mime type of Markdown cells with >>> my new mode, but having some trouble finding where to connect this in the >>> IPython JavaScript. >>> >>> I'm interested to see the code. >>> -- >>> M >>> >>> > >>> > Thanks for any suggestions, >>> > >>> > -Doug >>> > >>> > _______________________________________________ >>> > IPython-dev mailing list >>> > IPython-dev at scipy.org >>> > http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >> >> >> >> -- >> *Dami?n* >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140724/96d52177/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot from 2014-07-24 21:55:22.png Type: image/png Size: 41426 bytes Desc: not available URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140724/96d52177/attachment.png> From damianavila at gmail.com Thu Jul 24 22:07:57 2014 From: damianavila at gmail.com (=?UTF-8?Q?Dami=C3=A1n_Avila?=) Date: Thu, 24 Jul 2014 23:07:57 -0300 Subject: [IPython-dev] CodeMirror overlay for spell checking In-Reply-To: <CAAusYCiWRBXvBU+e-0T0onzokUCWuide_OB9zt-HYJSGb3Pfag@mail.gmail.com> References: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> <4974AEFF-2A79-48C3-87F3-ADFF793110B5@gmail.com> <CAH+mRR2L6jgNcL0Ci-VnFkpPAKmMNBxWtbcpujFOWnmVTnF72g@mail.gmail.com> <CAAusYCg3sNU0Ygj_tOfKmFNounxp7p871ioVAPYXA8=TTMxTXQ@mail.gmail.com> <CAAusYCiWRBXvBU+e-0T0onzokUCWuide_OB9zt-HYJSGb3Pfag@mail.gmail.com> Message-ID: <CAH+mRR2WabFTFmcMdSnYd8h=x74WmJ4-rG8cM8BB47F9FjKbfw@mail.gmail.com> Super interesting custom.js ;-) Btw, make sure the Codemirror community knows about this layout... they will be very interested on this example... 2014-07-24 22:59 GMT-03:00 Doug Blank <doug.blank at gmail.com>: > Success; we now have a working IPython notebook with spelling checking in > Markdown cells! > > I'll try to package this up over the next few days to make a notebook > extension for all kernels. Currently, I have this all in one custom.js file > [1] ... check out the toggle_spell_check function and code loaded on > app_initialized. > > The way that is currently works is as a toggle "spell check" button: click > it once, and it turns on a spell check overlay over the "markdown" mode on > all Markdown cells (see attached picture). Press the button again, and it > turns it off. > > I'm currently using Typo.js, but any JavaScript spell check library could > work. Typo isn't bad... may need to adjust what gets checked (need to > remove single quotes, and maybe add HTML tag names to dictionary). > > Possible options/limitations: > > 1) Should markdown cells be the only cells spell checked? > > 2) doesn't currently allow for right-click suggestion fixes; important? > > 3) English only. Just need to provide more dictionaries and an API to > change the dictionary. > > 4) Should the spell checking be on all of the time? > > Other options/suggestions welcomed! > > -Doug > > [1] - > https://bitbucket.org/ipre/calico/src/master/notebooks/profile/static/custom/custom.js > > This custom.js has a few things in it that we'll break into extensions: > two-column mode, bibtex references, tabbed in/out cells, heading numbering, > table of contents, and spelling checking. > > > > On Thu, Jul 24, 2014 at 4:52 PM, Doug Blank <doug.blank at gmail.com> wrote: > >> On Thu, Jul 24, 2014 at 2:31 PM, Dami?n Avila <damianavila at gmail.com> >> wrote: >> >>> > I'm interested to see the code. >>> >>> Me too ;-) >>> >> >> Thanks for the hints and links... >> >> Oh, we'll make this available to all... no more misspellings in notebooks! >> >> -Doug >> >> >>> >>> >>> 2014-07-24 15:30 GMT-03:00 Matthias Bussonnier < >>> bussonniermatthias at gmail.com>: >>> >>> >>>> Le 24 juil. 2014 ? 19:06, Doug Blank a ?crit : >>>> >>>> > I have successfully created and registered a CodeMirror overlay (for >>>> spell checking), but two questions: >>>> > >>>> > 1) Which of the modes is used for Markdown cells? I guess that will >>>> be the mode that I overlay. >>>> >>>> JSconsole : >>>> >>>> > IPython.TextCell.options_default.cm_config.mode >>>> "htmlmixed" >>>> >>>> >>>> >>>> > >>>> > 2) How do I make it so that my new mode will be used on Markdown >>>> cells? >>>> >>>> IPython.TextCell.options_default.cm_config.mode = yourmode >>>> + >>>> loop on all cell and set >>>> IPython.notebook.get_cell(0).code_mirror.setOption('mode',yourmode) >>>> >>>> might need to require your mode first though, maybe with >>>> code_mirrorm.getMode >>>> >>>> cf julia custom.js >>>> >>>> >>>> https://github.com/JuliaLang/IJulia.jl/blob/master/deps/custom.js#L66-L90 >>>> >>>> > >>>> > I guess that I need to associate the mime type of Markdown cells with >>>> my new mode, but having some trouble finding where to connect this in the >>>> IPython JavaScript. >>>> >>>> I'm interested to see the code. >>>> -- >>>> M >>>> >>>> > >>>> > Thanks for any suggestions, >>>> > >>>> > -Doug >>>> > >>>> > _______________________________________________ >>>> > IPython-dev mailing list >>>> > IPython-dev at scipy.org >>>> > http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>> >>> >>> >>> -- >>> *Dami?n* >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- *Dami?n* -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140724/a9edfdaf/attachment.html> From simoncropper at fossworkflowguides.com Thu Jul 24 22:08:27 2014 From: simoncropper at fossworkflowguides.com (Simon Cropper) Date: Fri, 25 Jul 2014 12:08:27 +1000 Subject: [IPython-dev] CodeMirror overlay for spell checking In-Reply-To: <CAAusYCiWRBXvBU+e-0T0onzokUCWuide_OB9zt-HYJSGb3Pfag@mail.gmail.com> References: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> <4974AEFF-2A79-48C3-87F3-ADFF793110B5@gmail.com> <CAH+mRR2L6jgNcL0Ci-VnFkpPAKmMNBxWtbcpujFOWnmVTnF72g@mail.gmail.com> <CAAusYCg3sNU0Ygj_tOfKmFNounxp7p871ioVAPYXA8=TTMxTXQ@mail.gmail.com> <CAAusYCiWRBXvBU+e-0T0onzokUCWuide_OB9zt-HYJSGb3Pfag@mail.gmail.com> Message-ID: <53D1BC1B.2070500@fossworkflowguides.com> > 1) Should markdown cells be the only cells spell checked? Yes > 2) doesn't currently allow for right-click suggestion fixes; important? I think this is important. It wastes time if you need to consult and third-party resource to clarify the spelling. > 3) English only. Just need to provide more dictionaries and an API to > change the dictionary. In most dictionaries variants of English dictionaries exist -- English-UK, English-USA, English-Australian... Access to these would be good. Alternatively documenting how people could create appropriate dictionaries would be satisfactory. > 4) Should the spell checking be on all of the time? I think a preference that allowed the spelling to be turned on and off would be good. On 25/07/14 11:59, Doug Blank wrote: > Success; we now have a working IPython notebook with spelling checking > in Markdown cells! > > I'll try to package this up over the next few days to make a notebook > extension for all kernels. Currently, I have this all in one custom.js > file [1] ... check out the toggle_spell_check function and code loaded > on app_initialized. > > The way that is currently works is as a toggle "spell check" button: > click it once, and it turns on a spell check overlay over the "markdown" > mode on all Markdown cells (see attached picture). Press the button > again, and it turns it off. > > I'm currently using Typo.js, but any JavaScript spell check library > could work. Typo isn't bad... may need to adjust what gets checked (need > to remove single quotes, and maybe add HTML tag names to dictionary). > > Possible options/limitations: > > 1) Should markdown cells be the only cells spell checked? > > 2) doesn't currently allow for right-click suggestion fixes; important? > > 3) English only. Just need to provide more dictionaries and an API to > change the dictionary. > > 4) Should the spell checking be on all of the time? > > Other options/suggestions welcomed! > > -Doug > > [1] - > https://bitbucket.org/ipre/calico/src/master/notebooks/profile/static/custom/custom.js > > This custom.js has a few things in it that we'll break into extensions: > two-column mode, bibtex references, tabbed in/out cells, heading > numbering, table of contents, and spelling checking. > > > > On Thu, Jul 24, 2014 at 4:52 PM, Doug Blank <doug.blank at gmail.com > <mailto:doug.blank at gmail.com>> wrote: > > On Thu, Jul 24, 2014 at 2:31 PM, Dami?n Avila <damianavila at gmail.com > <mailto:damianavila at gmail.com>> wrote: > > > I'm interested to see the code. > > Me too ;-) > > > Thanks for the hints and links... > > Oh, we'll make this available to all... no more misspellings in > notebooks! > > -Doug > > > > 2014-07-24 15:30 GMT-03:00 Matthias Bussonnier > <bussonniermatthias at gmail.com > <mailto:bussonniermatthias at gmail.com>>: > > > Le 24 juil. 2014 ? 19:06, Doug Blank a ?crit : > > > I have successfully created and registered a CodeMirror > overlay (for spell checking), but two questions: > > > > 1) Which of the modes is used for Markdown cells? I guess > that will be the mode that I overlay. > > JSconsole : > > > IPython.TextCell.options_default.cm_config.mode > "htmlmixed" > > > > > > > 2) How do I make it so that my new mode will be used on > Markdown cells? > > IPython.TextCell.options_default.cm_config.mode = yourmode > + > loop on all cell and set > IPython.notebook.get_cell(0).code_mirror.setOption('mode',yourmode) > > might need to require your mode first though, maybe with > code_mirrorm.getMode > > cf julia custom.js > > https://github.com/JuliaLang/IJulia.jl/blob/master/deps/custom.js#L66-L90 > > > > > I guess that I need to associate the mime type of > Markdown cells with my new mode, but having some trouble > finding where to connect this in the IPython JavaScript. > > I'm interested to see the code. > -- > M > > > > > Thanks for any suggestions, > > > > -Doug > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > -- > */Dami?n/* > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org> > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Cheers Simon Simon Cropper - Open Content Creator Free and Open Source Software Workflow Guides ------------------------------------------------------------ Introduction http://www.fossworkflowguides.com GIS Packages http://www.fossworkflowguides.com/gis bash / Python http://www.fossworkflowguides.com/scripting From bussonniermatthias at gmail.com Fri Jul 25 05:02:00 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Fri, 25 Jul 2014 11:02:00 +0200 Subject: [IPython-dev] CodeMirror overlay for spell checking In-Reply-To: <CAAusYCiWRBXvBU+e-0T0onzokUCWuide_OB9zt-HYJSGb3Pfag@mail.gmail.com> References: <CAAusYCh7zeC2zJGe4HU1QU1kya-OsS62QgWaOFvJBaBRBLy3CQ@mail.gmail.com> <4974AEFF-2A79-48C3-87F3-ADFF793110B5@gmail.com> <CAH+mRR2L6jgNcL0Ci-VnFkpPAKmMNBxWtbcpujFOWnmVTnF72g@mail.gmail.com> <CAAusYCg3sNU0Ygj_tOfKmFNounxp7p871ioVAPYXA8=TTMxTXQ@mail.gmail.com> <CAAusYCiWRBXvBU+e-0T0onzokUCWuide_OB9zt-HYJSGb3Pfag@mail.gmail.com> Message-ID: <6E4AFD78-B1AA-4822-92FE-A44D887B029A@gmail.com> Le 25 juil. 2014 ? 03:59, Doug Blank a ?crit : > Success; we now have a working IPython notebook with spelling checking in Markdown cells! > > I'll try to package this up over the next few days to make a notebook extension for all kernels. Currently, I have this all in one custom.js file [1] ... check out the toggle_spell_check function and code loaded on app_initialized. > > The way that is currently works is as a toggle "spell check" button: click it once, and it turns on a spell check overlay over the "markdown" mode on all Markdown cells (see attached picture). Press the button again, and it turns it off. > > I'm currently using Typo.js, but any JavaScript spell check library could work. Typo isn't bad... may need to adjust what gets checked (need to remove single quotes, and maybe add HTML tag names to dictionary). > > Possible options/limitations: > > 1) Should markdown cells be the only cells spell checked? I suppose, unless you have a way to spellcheck only comment in the languages, which will be hard. > > 2) doesn't currently allow for right-click suggestion fixes; important? Would be good, but will prevent user to use normal right click which is super annoying. you won't be able to right-click copy, or lots of other stuff. Would suggest no-to. Or have an option to enable disable the menu. > > 3) English only. Just need to provide more dictionaries and an API to change the dictionary. > > 4) Should the spell checking be on all of the time? You can persist the state in cell metadata. (language in notebook level metadata). We have to see the overhead of spellchecking. > Other options/suggestions welcomed! Will work on fall in refactoring completer. Might use completer to quick-correct maybe. > > -Doug > > [1] - https://bitbucket.org/ipre/calico/src/master/notebooks/profile/static/custom/custom.js > > This custom.js has a few things in it that we'll break into extensions: two-column mode, bibtex references, tabbed in/out cells, heading numbering, table of contents, and spelling checking. Nice, I suppose you have seen this, which regroups a few extensions. https://github.com/ipython-contrib/IPython-notebook-extensions Your would be welcomed I guess. -- M > > > > On Thu, Jul 24, 2014 at 4:52 PM, Doug Blank <doug.blank at gmail.com> wrote: > On Thu, Jul 24, 2014 at 2:31 PM, Dami?n Avila <damianavila at gmail.com> wrote: > > I'm interested to see the code. > > Me too ;-) > > Thanks for the hints and links... > > Oh, we'll make this available to all... no more misspellings in notebooks! > > -Doug > > > > 2014-07-24 15:30 GMT-03:00 Matthias Bussonnier <bussonniermatthias at gmail.com>: > > > Le 24 juil. 2014 ? 19:06, Doug Blank a ?crit : > > > I have successfully created and registered a CodeMirror overlay (for spell checking), but two questions: > > > > 1) Which of the modes is used for Markdown cells? I guess that will be the mode that I overlay. > > JSconsole : > > > IPython.TextCell.options_default.cm_config.mode > "htmlmixed" > > > > > > > 2) How do I make it so that my new mode will be used on Markdown cells? > > IPython.TextCell.options_default.cm_config.mode = yourmode > + > loop on all cell and set > IPython.notebook.get_cell(0).code_mirror.setOption('mode',yourmode) > > might need to require your mode first though, maybe with code_mirrorm.getMode > > cf julia custom.js > > https://github.com/JuliaLang/IJulia.jl/blob/master/deps/custom.js#L66-L90 > > > > > I guess that I need to associate the mime type of Markdown cells with my new mode, but having some trouble finding where to connect this in the IPython JavaScript. > > I'm interested to see the code. > -- > M > > > > > Thanks for any suggestions, > > > > -Doug > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > -- > Dami?n > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > <Screenshot from 2014-07-24 21:55:22.png>_______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140725/e75bbef3/attachment.html> From tom at hackerschool.com Fri Jul 25 17:04:28 2014 From: tom at hackerschool.com (Thomas Ballinger) Date: Fri, 25 Jul 2014 17:04:28 -0400 Subject: [IPython-dev] ASCII Terminal IPython re-encodes bytes greater than 127 Message-ID: <CABb6=DXEiJLwir4wL_C4a=cRY9spvFZv4u1c7cV0Dh5HeiPquA@mail.gmail.com> I'm interested about why IPython (python 2) does ascii encoding the way it does. When I run ipython in a ascii terminal and enter a byte greater than 127, it appears to be decoded using latin-1 and re-encoded with utf8. In [1]: '<meta-a, or byte \xe1>' Out [1]: '\xef\xbf\xbd' In a ascii-encoded python file, this would be an error. In an ASCII vanilla Python interpreter, this would be just the byte entered, '\xe1'. In terminal ipython, just entering the byte (without quotes) gives ERROR - failed to write data to stream. In vanilla ascii python, this would be a syntax error. I'm interested in why this decision was made. I'm in the process of choosing a behavior for bpython, and so far can think of: 1) vanilla python 2 behavior - run source code as bytes when terminal is ascii encoded 2) vanilla python 3 behavior - syntax error on finding this character 3) ipython behavior - somehow figure out (guess? what happens in ipython?) which character is being represented on the user's terminal by this byte and decode it to unicode, then rencode it (all assuming it's in a string). I don't understand the specifics of this. I'm particularly interested in whether it's important functionality to users (maybe for localization? do some people's terminals say ASCII but really represent important characters they can enter with their keyboards?) Thanks very much for any thoughts, -Tom -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140725/62f9a50b/attachment.html> From takowl at gmail.com Fri Jul 25 17:34:51 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 25 Jul 2014 14:34:51 -0700 Subject: [IPython-dev] ASCII Terminal IPython re-encodes bytes greater than 127 In-Reply-To: <CABb6=DXEiJLwir4wL_C4a=cRY9spvFZv4u1c7cV0Dh5HeiPquA@mail.gmail.com> References: <CABb6=DXEiJLwir4wL_C4a=cRY9spvFZv4u1c7cV0Dh5HeiPquA@mail.gmail.com> Message-ID: <CAOvn4qi3-dt08fbRA09pbMT_OD5yKncxLky5pvRAc3T1GOT-+A@mail.gmail.com> Hi Tom, It's been a couple of years since I investigated this, but from what I remember, the trouble is that either the representation of bytes literals in a piece of code stored as unicode, or the representation of unicode literals in a piece of code stored as bytes, is ambiguous. That is, either of these can do the wrong thing, depending on your locale: exec(b"a = u'?'") exec(u"a = b'?'") The first one will be wrong in a UTF-8 terminal (i.e. modern Linux or Mac), and the second will be wrong in, IIRC, a non-UTF8 terminal (i.e. Windows). We decided that non-ascii characters in unicode strings were more important than non-ascii characters in byte strings, so we compile the code as a unicode string, so that unicode literals are handled correctly. The fact that Python 3 throws a syntax error for non-ascii characters in a bytes literal supports this choice: the case we get 'wrong' is not even allowed on Python 3. I have thought about how we could get this 'right', i.e. matching the plain Python shell, for non-ascii bytes literals in Python 2 in non-UTF-8 terminals, but all of the options seem worse than the current situation: - The Python shell itself seems to interface with the parser/compiler in a way that is not possible from pure Python programs - We could prepend a "# coding: foo" comment to each line of code before parsing it, inserting the terminal's encoding. But this messes up line numbers and tracebacks. - We could parse each piece of code *twice*, once as bytes and once as unicode, then walk the ASTs and copy bytes literals from the bytes-parsed tree to the unicode-parsed tree (or unicode literals the other way). That's filed under "ideas too clever for their own good". So it's certainly not a feature, but it's a flaw that very few people have seemed to run into. Before IPython 0.11, we treated code the other way, breaking unicode literals, which did result in bug reports and patches that appeared to fix the issue without really working out the details. I hope that helps, feel free to ask if you have any more questions about this, Thomas On 25 July 2014 14:04, Thomas Ballinger <tom at hackerschool.com> wrote: > I'm interested about why IPython (python 2) does ascii encoding the way it > does. > > When I run ipython in a ascii terminal and enter a byte greater than 127, > it appears to be decoded using latin-1 and re-encoded with utf8. > > In [1]: '<meta-a, or byte \xe1>' > Out [1]: '\xef\xbf\xbd' > > In a ascii-encoded python file, this would be an error. In an ASCII > vanilla Python interpreter, this would be just the byte entered, '\xe1'. In > terminal ipython, just entering the byte (without quotes) gives ERROR - > failed to write data to stream. In vanilla ascii python, this would be a > syntax error. > > I'm interested in why this decision was made. I'm in the process of > choosing a behavior for bpython, and so far can think of: > > 1) vanilla python 2 behavior - run source code as bytes when terminal is > ascii encoded > 2) vanilla python 3 behavior - syntax error on finding this character > 3) ipython behavior - somehow figure out (guess? what happens in ipython?) > which character is being represented on the user's terminal by this byte > and decode it to unicode, then rencode it (all assuming it's in a string). > I don't understand the specifics of this. > > I'm particularly interested in whether it's important functionality to > users (maybe for localization? do some people's terminals say ASCII but > really represent important characters they can enter with their keyboards?) > > Thanks very much for any thoughts, > > -Tom > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140725/5edba15f/attachment.html> From tom at hackerschool.com Sat Jul 26 14:31:09 2014 From: tom at hackerschool.com (Thomas Ballinger) Date: Sat, 26 Jul 2014 14:31:09 -0400 Subject: [IPython-dev] ASCII Terminal IPython re-encodes bytes greater than 127 In-Reply-To: <CAOvn4qi3-dt08fbRA09pbMT_OD5yKncxLky5pvRAc3T1GOT-+A@mail.gmail.com> References: <CABb6=DXEiJLwir4wL_C4a=cRY9spvFZv4u1c7cV0Dh5HeiPquA@mail.gmail.com> <CAOvn4qi3-dt08fbRA09pbMT_OD5yKncxLky5pvRAc3T1GOT-+A@mail.gmail.com> Message-ID: <CABb6=DWum2k-LHMg36w3nbW+3-3DL0gXoL6tKw3uR7Z1rpv+DQ@mail.gmail.com> Thanks Thomas. I've been grappling with just this dichotomy of ambiguous representations, so it's great to read it expressed so clearly. If I understand correctly, IPython is something like repr(eval(raw_input('>>> ').decode(sys.stdin.encoding, 'replace'))) and therefore b'?' in an ascii encoded terminal will end up being the unicode replacement character \ufffd because it can't be encoded in ascii, the reported encoding. When the code is evaluated, if it's not in a string literal it will be a syntax error (though in an ascii terminal this traceback can't be written to stdout). If it appears in a unicode literal, it's \ufffd, and it it's bytestring literal it's \xef\xbf\xdb, the utf8 encoding of the previous. This is simpler than the behavior I guessed was happening because I didn't look up what \ufffd was ( http://en.wikipedia.org/wiki/Specials_(Unicode_block) - I wrongly assumed ipython was decoding this byte with latin-1 and then re-encoding it with utf8). If one was in a position to reject keys on a byte-by-byte basis (as bpython is) might it make sense to simply reject these bytes? If they come from the keyboard, they're funny meta key presses (you pressed meta-a; it doesn't do anything) and if they come from a paste event, the terminal emulator is doing a terrible job encoding into the reported encoding. However a few bytes missing would be more confusing though than a few characters being replaced with \ufffd. I think I want to ignore these bytes individually, but replace them with \ufffd when they happen in paste events, but I'd love to hear comments on this (can take them off this list if they're off topic. Thanks very much for input (and for IPython, which is obviously awesome). -Tom On Fri, Jul 25, 2014 at 5:34 PM, Thomas Kluyver <takowl at gmail.com> wrote: > Hi Tom, > > It's been a couple of years since I investigated this, but from what I > remember, the trouble is that either the representation of bytes literals > in a piece of code stored as unicode, or the representation of unicode > literals in a piece of code stored as bytes, is ambiguous. That is, either > of these can do the wrong thing, depending on your locale: > > exec(b"a = u'?'") > exec(u"a = b'?'") > > The first one will be wrong in a UTF-8 terminal (i.e. modern Linux or > Mac), and the second will be wrong in, IIRC, a non-UTF8 terminal (i.e. > Windows). We decided that non-ascii characters in unicode strings were more > important than non-ascii characters in byte strings, so we compile the code > as a unicode string, so that unicode literals are handled correctly. The > fact that Python 3 throws a syntax error for non-ascii characters in a > bytes literal supports this choice: the case we get 'wrong' is not even > allowed on Python 3. > > I have thought about how we could get this 'right', i.e. matching the > plain Python shell, for non-ascii bytes literals in Python 2 in non-UTF-8 > terminals, but all of the options seem worse than the current situation: > - The Python shell itself seems to interface with the parser/compiler in a > way that is not possible from pure Python programs > - We could prepend a "# coding: foo" comment to each line of code before > parsing it, inserting the terminal's encoding. But this messes up line > numbers and tracebacks. > - We could parse each piece of code *twice*, once as bytes and once as > unicode, then walk the ASTs and copy bytes literals from the bytes-parsed > tree to the unicode-parsed tree (or unicode literals the other way). That's > filed under "ideas too clever for their own good". > > So it's certainly not a feature, but it's a flaw that very few people have > seemed to run into. Before IPython 0.11, we treated code the other way, > breaking unicode literals, which did result in bug reports and patches that > appeared to fix the issue without really working out the details. > > I hope that helps, feel free to ask if you have any more questions about > this, > Thomas > > > On 25 July 2014 14:04, Thomas Ballinger <tom at hackerschool.com> wrote: > >> I'm interested about why IPython (python 2) does ascii encoding the way >> it does. >> >> When I run ipython in a ascii terminal and enter a byte greater than 127, >> it appears to be decoded using latin-1 and re-encoded with utf8. >> >> In [1]: '<meta-a, or byte \xe1>' >> Out [1]: '\xef\xbf\xbd' >> >> In a ascii-encoded python file, this would be an error. In an ASCII >> vanilla Python interpreter, this would be just the byte entered, '\xe1'. In >> terminal ipython, just entering the byte (without quotes) gives ERROR - >> failed to write data to stream. In vanilla ascii python, this would be a >> syntax error. >> >> I'm interested in why this decision was made. I'm in the process of >> choosing a behavior for bpython, and so far can think of: >> >> 1) vanilla python 2 behavior - run source code as bytes when terminal is >> ascii encoded >> 2) vanilla python 3 behavior - syntax error on finding this character >> 3) ipython behavior - somehow figure out (guess? what happens in >> ipython?) which character is being represented on the user's terminal by >> this byte and decode it to unicode, then rencode it (all assuming it's in a >> string). I don't understand the specifics of this. >> >> I'm particularly interested in whether it's important functionality to >> users (maybe for localization? do some people's terminals say ASCII but >> really represent important characters they can enter with their keyboards?) >> >> Thanks very much for any thoughts, >> >> -Tom >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140726/d11f4def/attachment.html> From takowl at gmail.com Sat Jul 26 14:49:08 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Sat, 26 Jul 2014 11:49:08 -0700 Subject: [IPython-dev] ASCII Terminal IPython re-encodes bytes greater than 127 In-Reply-To: <CABb6=DWum2k-LHMg36w3nbW+3-3DL0gXoL6tKw3uR7Z1rpv+DQ@mail.gmail.com> References: <CABb6=DXEiJLwir4wL_C4a=cRY9spvFZv4u1c7cV0Dh5HeiPquA@mail.gmail.com> <CAOvn4qi3-dt08fbRA09pbMT_OD5yKncxLky5pvRAc3T1GOT-+A@mail.gmail.com> <CABb6=DWum2k-LHMg36w3nbW+3-3DL0gXoL6tKw3uR7Z1rpv+DQ@mail.gmail.com> Message-ID: <CAOvn4qjRyb2K=4dDPhw9diYgNxD6atJEXQfAwOspiANmWTEJJA@mail.gmail.com> On 26 July 2014 11:31, Thomas Ballinger <tom at hackerschool.com> wrote: > If I understand correctly, IPython is something like > > repr(eval(raw_input('>>> ').decode(sys.stdin.encoding, 'replace'))) > Yes, that's more or less correct in Python 2. In Python 3, input() returns unicode, which makes things easier > and therefore b'?' in an ascii encoded terminal will end up being the > unicode replacement character \ufffd because it can't be encoded in ascii, > the reported encoding. When the code is evaluated, if it's not in a string > literal it will be a syntax error (though in an ascii terminal this > traceback can't be written to stdout). If it appears in a unicode literal, > it's \ufffd, and it it's bytestring literal it's \xef\xbf\xdb, the utf8 > encoding of the previous. > If the terminal is really ascii encoded, b'?' is not even possible in the first place. If the terminal claims incorrectly to be ascii encoded, then it's not clear what bytes IPython sees when you type the character ?. The most likely candidates would be the single byte FE if it's really latin1 or cp1252, or the two bytes C3 BE if it's really UTF-8. So when IPython tries to decode it, it will become one or two \ufffd characters. > This is simpler than the behavior I guessed was happening because I didn't > look up what \ufffd was ( > http://en.wikipedia.org/wiki/Specials_(Unicode_block) - I wrongly assumed > ipython was decoding this byte with latin-1 and then re-encoding it with > utf8). > > If one was in a position to reject keys on a byte-by-byte basis (as > bpython is) might it make sense to simply reject these bytes? If they come > from the keyboard, they're funny meta key presses (you pressed meta-a; it > doesn't do anything) and if they come from a paste event, the terminal > emulator is doing a terrible job encoding into the reported encoding. > However a few bytes missing would be more confusing though than a few > characters being replaced with \ufffd. > > I think I want to ignore these bytes individually, but replace them with > \ufffd when they happen in paste events, but I'd love to hear comments on > this (can take them off this list if they're off topic. Thanks very much > for input (and for IPython, which is obviously awesome). > What system has a terminal that claims to be ASCII but isn't? In my experience, most terminals on recent systems report either that they are UTF-8, or one of the Windows code pages. If the terminal does actually claim to be ASCII when it isn't, I'd consider that a bug in the terminal, and probably wouldn't feel bad about rejecting non-ascii keypresses. If you get paste events as a separate thing, you may be able to retrieve a unicode string from the clipboard, and avoid going via the terminal's encoding. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140726/d84ba434/attachment.html> From tom at hackerschool.com Sat Jul 26 20:04:00 2014 From: tom at hackerschool.com (Thomas Ballinger) Date: Sat, 26 Jul 2014 20:04:00 -0400 Subject: [IPython-dev] ASCII Terminal IPython re-encodes bytes greater than 127 In-Reply-To: <CAOvn4qjRyb2K=4dDPhw9diYgNxD6atJEXQfAwOspiANmWTEJJA@mail.gmail.com> References: <CABb6=DXEiJLwir4wL_C4a=cRY9spvFZv4u1c7cV0Dh5HeiPquA@mail.gmail.com> <CAOvn4qi3-dt08fbRA09pbMT_OD5yKncxLky5pvRAc3T1GOT-+A@mail.gmail.com> <CABb6=DWum2k-LHMg36w3nbW+3-3DL0gXoL6tKw3uR7Z1rpv+DQ@mail.gmail.com> <CAOvn4qjRyb2K=4dDPhw9diYgNxD6atJEXQfAwOspiANmWTEJJA@mail.gmail.com> Message-ID: <CABb6=DW14ScF1RaNoY5aUkvc-NGSKbCESSLLoa1Yz6Z0dSV71w@mail.gmail.com> Since this isn't an edge case important to users who need characters like ? to write text, I'm going to ignore bytes 128-255 on ascii terminals. The system I've noticed this behavior on is iTerm2 on OSX 10.9, when I use old-style meta key (under preferences/profiles/keys) and ~ (chr(ord('~') + 128)) which is displayed as ?. (so display of these characters seems to be latin1) Anything pasted doesn't put these bytes in, instead making funny replacements happen like ????? -> thas?? By "paste event" I meant only that we read a bunch of bytes at once and infer that this was probably due to a paste. I'm going to ignore it either way. Thanks, excited to move forward with this knowing this solution is something that's already working for the large IPython community. Tom On Sat, Jul 26, 2014 at 2:49 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 26 July 2014 11:31, Thomas Ballinger <tom at hackerschool.com> wrote: > >> If I understand correctly, IPython is something like >> >> repr(eval(raw_input('>>> ').decode(sys.stdin.encoding, 'replace'))) >> > > Yes, that's more or less correct in Python 2. In Python 3, input() returns > unicode, which makes things easier > > >> and therefore b'?' in an ascii encoded terminal will end up being the >> unicode replacement character \ufffd because it can't be encoded in ascii, >> the reported encoding. When the code is evaluated, if it's not in a string >> literal it will be a syntax error (though in an ascii terminal this >> traceback can't be written to stdout). If it appears in a unicode literal, >> it's \ufffd, and it it's bytestring literal it's \xef\xbf\xdb, the utf8 >> encoding of the previous. >> > > If the terminal is really ascii encoded, b'?' is not even possible in the > first place. If the terminal claims incorrectly to be ascii encoded, then > it's not clear what bytes IPython sees when you type the character ?. The > most likely candidates would be the single byte FE if it's really latin1 or > cp1252, or the two bytes C3 BE if it's really UTF-8. So when IPython tries > to decode it, it will become one or two \ufffd characters. > > > >> This is simpler than the behavior I guessed was happening because I >> didn't look up what \ufffd was ( >> http://en.wikipedia.org/wiki/Specials_(Unicode_block) - I wrongly >> assumed ipython was decoding this byte with latin-1 and then re-encoding it >> with utf8). >> >> If one was in a position to reject keys on a byte-by-byte basis (as >> bpython is) might it make sense to simply reject these bytes? If they come >> from the keyboard, they're funny meta key presses (you pressed meta-a; it >> doesn't do anything) and if they come from a paste event, the terminal >> emulator is doing a terrible job encoding into the reported encoding. >> However a few bytes missing would be more confusing though than a few >> characters being replaced with \ufffd. >> >> I think I want to ignore these bytes individually, but replace them with >> \ufffd when they happen in paste events, but I'd love to hear comments on >> this (can take them off this list if they're off topic. Thanks very much >> for input (and for IPython, which is obviously awesome). >> > > What system has a terminal that claims to be ASCII but isn't? In my > experience, most terminals on recent systems report either that they are > UTF-8, or one of the Windows code pages. > > If the terminal does actually claim to be ASCII when it isn't, I'd > consider that a bug in the terminal, and probably wouldn't feel bad about > rejecting non-ascii keypresses. > > If you get paste events as a separate thing, you may be able to retrieve a > unicode string from the clipboard, and avoid going via the terminal's > encoding. > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140726/7968fa2c/attachment.html> From klonuo at gmail.com Sun Jul 27 00:07:55 2014 From: klonuo at gmail.com (klo uo) Date: Sun, 27 Jul 2014 06:07:55 +0200 Subject: [IPython-dev] Html object graph In-Reply-To: <CAA-8Ld_2MzHnN6p6wwdT6tn=SQu1AiqHDK7mNUD7NjGKW0C+bQ@mail.gmail.com> References: <CAA-8Ld_DHsN8ptHV30erT85wdNiAh4cMHm0yV6dW96qg+VxH0A@mail.gmail.com> <74CB9B8B-35F3-4435-BC1C-D70058DEDD30@gmail.com> <CAA-8Ld_2MzHnN6p6wwdT6tn=SQu1AiqHDK7mNUD7NjGKW0C+bQ@mail.gmail.com> Message-ID: <CAA-8Ld8VjaMsXCxRLGzKyMu-9VtsXY+K7wcbZt04LCjyw5_j8g@mail.gmail.com> I just watched a video about Databricks service, where they use Notebook very similar to IPython Notebook, and thought to share how they've made similar object as discussed above: https://www.youtube.com/watch?feature=player_detailpage&v=dJQ5lV5Tldw#t=1118 On Thu, May 8, 2014 at 12:57 PM, klo uo <klonuo at gmail.com> wrote: > Thanks Matthias for your reply. > > I agree that my mail was too general. > > I started learning .Net basics and one thing that attracted me most was > Linq. Not that it just simplifies SQL by avoiding redundancy and providing > shorcuts, but can be used the same way on XML documents, or general .Net > objects (that provide IEnumerable(Of T) Interface) or even GUI elements > that provide IObservable(T) Interface (RX extensions). > > Then using this LinqPad application as playground is a joy (compared to > other options), similarly as working in IPython, and plus making .Net > interpretable as Python is. I thought on how to connect both concepts but > wasn't much sure, as I still don't know much about IPython machinery, and > less about LinqPad, but that interactive Html table was IMHO worth > mentioning, even as general idea. > > Now that you wrote about Pandas Html tables - maybe that's the right place > for providing enhanced interactive object widget - on Pandas dataframe > object. Let me mention Linq again, that it is great, but can't be compared > to Pandas methods for data slicing for sure, and interfacing Pandas object > with rich widget would be really great step. > > I did search for extensions to Html table dumped in IPython when I first > saw it, as although it was interesting to see tabular data presented as > such it still looked too basic, but I didn't find any. > Cyrille Rossant's project that you wrote about looks interesting as it > allows interactive changes to Pandas dataframe, and I hope he'll continue > crafting it, by adding other possibilities. > > And as much as I would like to try to enhance IPython Html table myself, > I'm repulsed by JavaScript - it's just something I don't ever want to do, > unless I'm forced to. > > Hopefully that LinqPad table interface can inspire some developer one way > or another. > > > Cheers > > > > On Wed, May 7, 2014 at 11:56 AM, Matthias BUSSONNIER < > bussonniermatthias at gmail.com> wrote: > >> Hy, >> Le 3 mai 2014 ? 18:31, klo uo a ?crit : >> >> Hey guys, >> >> are you are familiar with LinqPad? >> <https://www.linqpad.net/CodeSnippetIDE.aspx> >> >> >> Thanks for the link. >> >> If not, just to say it's a lightweight code scratchpad, that can connect >> to various databases and allow immediate Linq execution. It can also >> interpret any kind of .Net code (although currently without >> IronPython/Ruby). >> >> I thought to ask you about main output result pane - it's a very >> interesting Html table representation of dumped object(s), that adapts on >> the object type - allows collapsible nested levels, navigable deep >> Exception tree, can display images, rawhtml, hyperlinqs - user defined >> lambda functions that are executed on user click, ? >> >> >> I suppose each of theses features should be discussed independently. Most >> should Imho be directly implemented by library, >> like cyrile rossant HandsonTable for panda dataframe. >> >> Some other like Traceback could definitively be integrate din the core, >> have already been discussed, but >> pushed to a later point by lack of manpower. >> >> Do you think something similar would fit in IPython? >> As object inspection magic, or Qtconsole output pane, or else?? >> >> >> The response will depend on the exact feature, but instead of targeting a >> specific frontend I would suggest to think on how to get this into the >> object _repr_*_ or >> in the message spec if it is really impossible to do otherwise. >> >> -- >> M >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140727/26bdd6bd/attachment.html> From doug.blank at gmail.com Sun Jul 27 01:50:41 2014 From: doug.blank at gmail.com (Doug Blank) Date: Sun, 27 Jul 2014 01:50:41 -0400 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools Message-ID: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> IPython notebook users, Looking for some beta testers to try out three new notebook extensions. These are browser extensions, so should work with any kernel. They are: 1. Spell check: this is implemented in JavaScript, not too big (~700k), and pretty fast. It is currently set up to work only for Markdown cells. It toggles on/off via the "check" button. Doesn't offer suggestions for misspelled words, but is a big help in writing. Currently, English only, but supports a range of dictionary types via Typo.js. 2. Cell tools: There are two formats for code cells: Input/Output Tabbed view, and Column view. The Tabbed view will cover the Input code cell with the Output of the code, and you can tab back and forth. The Column view will show the output in a column next to the input column. Both of these buttons toggle individual code cells, and remembers their state when you re-open the notebook. These don't show in nbviewer, however. 3. Document tools: There are three different extensions for handling documents: 1) Heading numbering, 2) Table of Contents generation, and 3) Bibliographic support. The first two are fairly straightforward in functionality: the first toggles heading numbering on/off, and the second creates a Table of Contents from the heading cells. The Bibliographic tool is a bit more complex, and still needs to be refined. It does two things: replaces citations in your Markdown with proper author/year, and creates a References section at the end of your notebook with cited sources (this part isn't complete yet). It uses Bibtex data stored in the notebook, or in a separate Bibliography.ipynb in your root dir. For more on this tool, see: http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Documentation/Reference%20Guide/Reference%20Guide.ipynb#4.-Bibliographic-Support (Documentation hasn't been refined yet; This is a temp version. We hope to have some demo videos next week.) To install, you can do something like: 1) Change to the profile you want to use: cd $(ipython locate)/profile_default/static/custom/ 2) Overwrite or edit your custom js and css: wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom_example.js -o custom.css wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom.css 3) Get the extensions that you want: Document tools: wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/bibtex.js wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/document-tools.js Cell tools: wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/cell-tools.js Spell checking: wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/spell-check.js wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/typo.zip unzip typo.zip We'd be glad to get feedback on any and all of these. We hope that you find them useful! -Doug (and the Bryn Mawr College digital humanities team) -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140727/80403759/attachment.html> From bussonniermatthias at gmail.com Sun Jul 27 06:07:06 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Sun, 27 Jul 2014 12:07:06 +0200 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools In-Reply-To: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> References: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> Message-ID: <6AC92164-D20A-4CAF-9B91-A5F30AA3882F@gmail.com> Le 27 juil. 2014 ? 07:50, Doug Blank a ?crit : > IPython notebook users, > > Looking for some beta testers to try out three new notebook extensions. These are browser extensions, so should work with any kernel. They are: > > 1. Spell check: this is implemented in JavaScript, not too big (~700k), and pretty fast. It is currently set up to work only for Markdown cells. It toggles on/off via the "check" button. Doesn't offer suggestions for misspelled words, but is a big help in writing. Currently, English only, but supports a range of dictionary types via Typo.js. > > 2. Cell tools: There are two formats for code cells: Input/Output Tabbed view, and Column view. The Tabbed view will cover the Input code cell with the Output of the code, and you can tab back and forth. The Column view will show the output in a column next to the input column. Both of these buttons toggle individual code cells, and remembers their state when you re-open the notebook. These don't show in nbviewer, however. > > 3. Document tools: There are three different extensions for handling documents: 1) Heading numbering, 2) Table of Contents generation, and 3) Bibliographic support. The first two are fairly straightforward in functionality: the first toggles heading numbering on/off, and the second creates a Table of Contents from the heading cells. > > The Bibliographic tool is a bit more complex, and still needs to be refined. It does two things: replaces citations in your Markdown with proper author/year, and creates a References section at the end of your notebook with cited sources (this part isn't complete yet). It uses Bibtex data stored in the notebook, or in a separate Bibliography.ipynb in your root dir. For more on this tool, see: > > http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Documentation/Reference%20Guide/Reference%20Guide.ipynb#4.-Bibliographic-Support Nice, > > (Documentation hasn't been refined yet; This is a temp version. We hope to have some demo videos next week.) > > To install, you can do something like: > > 1) Change to the profile you want to use: > cd $(ipython locate)/profile_default/static/custom/ > > 2) Overwrite or edit your custom js and css: > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom_example.js -o custom.css > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom.css > > 3) Get the extensions that you want: > Sice 2.0 IPython has a /nbextension folder were you can put things like that and have access cross profiles. You just have to use requirejs in each custom.js to load them. Will try and do an more extensive explanation. -- M > Document tools: > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/bibtex.js > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/document-tools.js > > Cell tools: > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/cell-tools.js > > Spell checking: > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/spell-check.js > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/typo.zip > unzip typo.zip > > > We'd be glad to get feedback on any and all of these. We hope that you find them useful! > > -Doug (and the Bryn Mawr College digital humanities team) > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From python at elbonia.de Sun Jul 27 06:54:07 2014 From: python at elbonia.de (Juergen Hasch) Date: Sun, 27 Jul 2014 12:54:07 +0200 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools In-Reply-To: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> References: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> Message-ID: <53D4DA4F.9090905@elbonia.de> Hi Doug, nice work. I am glad you found a Javascript solution for the spell checker. I'll happily retire my aspell-based version. I think it would be a good idea to move to the nbextension location, as Matthias suggested. Also, the CSS stuff for the spellchecker extension should probably be in a separate spell-check.css file . Matthias: One can use "IPython.load_extensions('spell-check')" or "require(['nbextensions/spell-check'])" to load an extension. The first options seems nicer to me, what do you say ? Juergen Am 27.07.2014 07:50, schrieb Doug Blank: > IPython notebook users, > > Looking for some beta testers to try out three new notebook extensions. These are browser extensions, so should work > with any kernel. They are: > > 1. Spell check: this is implemented in JavaScript, not too big (~700k), and pretty fast. It is currently set up to work > only for Markdown cells. It toggles on/off via the "check" button. Doesn't offer suggestions for misspelled words, but > is a big help in writing. Currently, English only, but supports a range of dictionary types via Typo.js. > > 2. Cell tools: There are two formats for code cells: Input/Output Tabbed view, and Column view. The Tabbed view will > cover the Input code cell with the Output of the code, and you can tab back and forth. The Column view will show the > output in a column next to the input column. Both of these buttons toggle individual code cells, and remembers their > state when you re-open the notebook. These don't show in nbviewer, however. > > 3. Document tools: There are three different extensions for handling documents: 1) Heading numbering, 2) Table of > Contents generation, and 3) Bibliographic support. The first two are fairly straightforward in functionality: the first > toggles heading numbering on/off, and the second creates a Table of Contents from the heading cells. > > The Bibliographic tool is a bit more complex, and still needs to be refined. It does two things: replaces citations in > your Markdown with proper author/year, and creates a References section at the end of your notebook with cited sources > (this part isn't complete yet). It uses Bibtex data stored in the notebook, or in a separate Bibliography.ipynb in your > root dir. For more on this tool, see: > > http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Documentation/Reference%20Guide/Reference%20Guide.ipynb#4.-Bibliographic-Support > > (Documentation hasn't been refined yet; This is a temp version. We hope to have some demo videos next week.) > > To install, you can do something like: > > 1) Change to the profile you want to use: > cd $(ipython locate)/profile_default/static/custom/ > > 2) Overwrite or edit your custom js and css: > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom_example.js -o custom.css > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom.css > > 3) Get the extensions that you want: > > Document tools: > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/bibtex.js > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/document-tools.js > > Cell tools: > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/cell-tools.js > > Spell checking: > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/spell-check.js > wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/typo.zip > unzip typo.zip > > > We'd be glad to get feedback on any and all of these. We hope that you find them useful! > > -Doug (and the Bryn Mawr College digital humanities team) > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From bussonniermatthias at gmail.com Sun Jul 27 06:59:35 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Sun, 27 Jul 2014 12:59:35 +0200 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools In-Reply-To: <53D4DA4F.9090905@elbonia.de> References: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> <53D4DA4F.9090905@elbonia.de> Message-ID: <141E3132-18B5-49D3-ABAD-BD9A24E48B15@gmail.com> Le 27 juil. 2014 ? 12:54, Juergen Hasch a ?crit : > Hi Doug, > nice work. I am glad you found a Javascript solution for the spell checker. I'll happily retire my aspell-based version. > > I think it would be a good idea to move to the nbextension location, as Matthias suggested. > Also, the CSS stuff for the spellchecker extension should probably be in a separate spell-check.css file . > > Matthias: > One can use "IPython.load_extensions('spell-check')" or "require(['nbextensions/spell-check'])" to load an extension. > The first options seems nicer to me, what do you say ? Yes, I just never remember how to use it :-) Writing My PhD have made a lot of holes in my usage of IPython. We should really write documentation for Javascript stuff. -- M > Juergen > > > Am 27.07.2014 07:50, schrieb Doug Blank: >> IPython notebook users, >> >> Looking for some beta testers to try out three new notebook extensions. These are browser extensions, so should work >> with any kernel. They are: >> >> 1. Spell check: this is implemented in JavaScript, not too big (~700k), and pretty fast. It is currently set up to work >> only for Markdown cells. It toggles on/off via the "check" button. Doesn't offer suggestions for misspelled words, but >> is a big help in writing. Currently, English only, but supports a range of dictionary types via Typo.js. >> >> 2. Cell tools: There are two formats for code cells: Input/Output Tabbed view, and Column view. The Tabbed view will >> cover the Input code cell with the Output of the code, and you can tab back and forth. The Column view will show the >> output in a column next to the input column. Both of these buttons toggle individual code cells, and remembers their >> state when you re-open the notebook. These don't show in nbviewer, however. >> >> 3. Document tools: There are three different extensions for handling documents: 1) Heading numbering, 2) Table of >> Contents generation, and 3) Bibliographic support. The first two are fairly straightforward in functionality: the first >> toggles heading numbering on/off, and the second creates a Table of Contents from the heading cells. >> >> The Bibliographic tool is a bit more complex, and still needs to be refined. It does two things: replaces citations in >> your Markdown with proper author/year, and creates a References section at the end of your notebook with cited sources >> (this part isn't complete yet). It uses Bibtex data stored in the notebook, or in a separate Bibliography.ipynb in your >> root dir. For more on this tool, see: >> >> http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Documentation/Reference%20Guide/Reference%20Guide.ipynb#4.-Bibliographic-Support >> >> (Documentation hasn't been refined yet; This is a temp version. We hope to have some demo videos next week.) >> >> To install, you can do something like: >> >> 1) Change to the profile you want to use: >> cd $(ipython locate)/profile_default/static/custom/ >> >> 2) Overwrite or edit your custom js and css: >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom_example.js -o custom.css >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom.css >> >> 3) Get the extensions that you want: >> >> Document tools: >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/bibtex.js >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/document-tools.js >> >> Cell tools: >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/cell-tools.js >> >> Spell checking: >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/spell-check.js >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/typo.zip >> unzip typo.zip >> >> >> We'd be glad to get feedback on any and all of these. We hope that you find them useful! >> >> -Doug (and the Bryn Mawr College digital humanities team) >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From doug.blank at gmail.com Sun Jul 27 08:41:21 2014 From: doug.blank at gmail.com (Doug Blank) Date: Sun, 27 Jul 2014 08:41:21 -0400 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools In-Reply-To: <141E3132-18B5-49D3-ABAD-BD9A24E48B15@gmail.com> References: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> <53D4DA4F.9090905@elbonia.de> <141E3132-18B5-49D3-ABAD-BD9A24E48B15@gmail.com> Message-ID: <CAAusYCjd3NbOf-dLDQzVpSOAKdoYPHj_ho0X9SW=6q2SyLSb+g@mail.gmail.com> Thanks Mattias and Juergen... I didn't know about the new way of doing things. As a result, I had to put the Spell Check and Tabbed CSS in the toplevel custom.ss. But now that I know, I'll properly put them in the right places. (It looks like the way that it works now is the way that I was trying to invent, so... perfect!) Speaking of this: is there a magic that acts as a type of Notebook JavaScript package manager? With the new system, it seems like it wouldn't be too hard to make a small installer that could keep track of dependencies, versioning, and file copying. -Doug On Sun, Jul 27, 2014 at 6:59 AM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > > Le 27 juil. 2014 ? 12:54, Juergen Hasch a ?crit : > > > Hi Doug, > > nice work. I am glad you found a Javascript solution for the spell checker. I'll happily retire my aspell-based version. > > > > I think it would be a good idea to move to the nbextension location, as Matthias suggested. > > Also, the CSS stuff for the spellchecker extension should probably be in a separate spell-check.css file . > > > > Matthias: > > One can use "IPython.load_extensions('spell-check')" or "require(['nbextensions/spell-check'])" to load an extension. > > The first options seems nicer to me, what do you say ? > > Yes, I just never remember how to use it :-) > Writing My PhD have made a lot of holes in my usage of IPython. > We should really write documentation for Javascript stuff. > -- > M > > > > Juergen > > > > > > Am 27.07.2014 07:50, schrieb Doug Blank: > >> IPython notebook users, > >> > >> Looking for some beta testers to try out three new notebook extensions. These are browser extensions, so should work > >> with any kernel. They are: > >> > >> 1. Spell check: this is implemented in JavaScript, not too big (~700k), and pretty fast. It is currently set up to work > >> only for Markdown cells. It toggles on/off via the "check" button. Doesn't offer suggestions for misspelled words, but > >> is a big help in writing. Currently, English only, but supports a range of dictionary types via Typo.js. > >> > >> 2. Cell tools: There are two formats for code cells: Input/Output Tabbed view, and Column view. The Tabbed view will > >> cover the Input code cell with the Output of the code, and you can tab back and forth. The Column view will show the > >> output in a column next to the input column. Both of these buttons toggle individual code cells, and remembers their > >> state when you re-open the notebook. These don't show in nbviewer, however. > >> > >> 3. Document tools: There are three different extensions for handling documents: 1) Heading numbering, 2) Table of > >> Contents generation, and 3) Bibliographic support. The first two are fairly straightforward in functionality: the first > >> toggles heading numbering on/off, and the second creates a Table of Contents from the heading cells. > >> > >> The Bibliographic tool is a bit more complex, and still needs to be refined. It does two things: replaces citations in > >> your Markdown with proper author/year, and creates a References section at the end of your notebook with cited sources > >> (this part isn't complete yet). It uses Bibtex data stored in the notebook, or in a separate Bibliography.ipynb in your > >> root dir. For more on this tool, see: > >> > >> http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Documentation/Reference%20Guide/Reference%20Guide.ipynb#4.-Bibliographic-Support > >> > >> (Documentation hasn't been refined yet; This is a temp version. We hope to have some demo videos next week.) > >> > >> To install, you can do something like: > >> > >> 1) Change to the profile you want to use: > >> cd $(ipython locate)/profile_default/static/custom/ > >> > >> 2) Overwrite or edit your custom js and css: > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom_example.js -o custom.css > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom.css > >> > >> 3) Get the extensions that you want: > >> > >> Document tools: > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/bibtex.js > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/document-tools.js > >> > >> Cell tools: > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/cell-tools.js > >> > >> Spell checking: > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/spell-check.js > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/typo.zip > >> unzip typo.zip > >> > >> > >> We'd be glad to get feedback on any and all of these. We hope that you find them useful! > >> > >> -Doug (and the Bryn Mawr College digital humanities team) > >> > >> > >> > >> _______________________________________________ > >> IPython-dev mailing list > >> IPython-dev at scipy.org > >> http://mail.scipy.org/mailman/listinfo/ipython-dev > >> > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140727/b06519a3/attachment.html> From bussonniermatthias at gmail.com Sun Jul 27 08:48:44 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Sun, 27 Jul 2014 14:48:44 +0200 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools In-Reply-To: <CAAusYCjd3NbOf-dLDQzVpSOAKdoYPHj_ho0X9SW=6q2SyLSb+g@mail.gmail.com> References: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> <53D4DA4F.9090905@elbonia.de> <141E3132-18B5-49D3-ABAD-BD9A24E48B15@gmail.com> <CAAusYCjd3NbOf-dLDQzVpSOAKdoYPHj_ho0X9SW=6q2SyLSb+g@mail.gmail.com> Message-ID: <94A4C38A-129C-4AE5-8AAB-871FF22CF662@gmail.com> Le 27 juil. 2014 ? 14:41, Doug Blank a ?crit : > Speaking of this: is there a magic that acts as a type of Notebook JavaScript package manager? With the new system, it seems like it wouldn't be too hard to make a small installer that could keep track of dependencies, versioning, and file copying. Hum, no, and it is slightly more complicated than that. It is "relatively" easy for pure js/css modules, but for things that require kernel-side there are some challenges. I even suspect that you should be able to develop/register extensions with bower/npm and "just" install them in nbextensions. -- M > > -Doug > > > On Sun, Jul 27, 2014 at 6:59 AM, Matthias Bussonnier <bussonniermatthias at gmail.com> wrote: > > > > > > Le 27 juil. 2014 ? 12:54, Juergen Hasch a ?crit : > > > > > Hi Doug, > > > nice work. I am glad you found a Javascript solution for the spell checker. I'll happily retire my aspell-based version. > > > > > > I think it would be a good idea to move to the nbextension location, as Matthias suggested. > > > Also, the CSS stuff for the spellchecker extension should probably be in a separate spell-check.css file . > > > > > > Matthias: > > > One can use "IPython.load_extensions('spell-check')" or "require(['nbextensions/spell-check'])" to load an extension. > > > The first options seems nicer to me, what do you say ? > > > > Yes, I just never remember how to use it :-) > > Writing My PhD have made a lot of holes in my usage of IPython. > > We should really write documentation for Javascript stuff. > > -- > > M > > > > > > > Juergen > > > > > > > > > Am 27.07.2014 07:50, schrieb Doug Blank: > > >> IPython notebook users, > > >> > > >> Looking for some beta testers to try out three new notebook extensions. These are browser extensions, so should work > > >> with any kernel. They are: > > >> > > >> 1. Spell check: this is implemented in JavaScript, not too big (~700k), and pretty fast. It is currently set up to work > > >> only for Markdown cells. It toggles on/off via the "check" button. Doesn't offer suggestions for misspelled words, but > > >> is a big help in writing. Currently, English only, but supports a range of dictionary types via Typo.js. > > >> > > >> 2. Cell tools: There are two formats for code cells: Input/Output Tabbed view, and Column view. The Tabbed view will > > >> cover the Input code cell with the Output of the code, and you can tab back and forth. The Column view will show the > > >> output in a column next to the input column. Both of these buttons toggle individual code cells, and remembers their > > >> state when you re-open the notebook. These don't show in nbviewer, however. > > >> > > >> 3. Document tools: There are three different extensions for handling documents: 1) Heading numbering, 2) Table of > > >> Contents generation, and 3) Bibliographic support. The first two are fairly straightforward in functionality: the first > > >> toggles heading numbering on/off, and the second creates a Table of Contents from the heading cells. > > >> > > >> The Bibliographic tool is a bit more complex, and still needs to be refined. It does two things: replaces citations in > > >> your Markdown with proper author/year, and creates a References section at the end of your notebook with cited sources > > >> (this part isn't complete yet). It uses Bibtex data stored in the notebook, or in a separate Bibliography.ipynb in your > > >> root dir. For more on this tool, see: > > >> > > >> http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Documentation/Reference%20Guide/Reference%20Guide.ipynb#4.-Bibliographic-Support > > >> > > >> (Documentation hasn't been refined yet; This is a temp version. We hope to have some demo videos next week.) > > >> > > >> To install, you can do something like: > > >> > > >> 1) Change to the profile you want to use: > > >> cd $(ipython locate)/profile_default/static/custom/ > > >> > > >> 2) Overwrite or edit your custom js and css: > > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom_example.js -o custom.css > > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom.css > > >> > > >> 3) Get the extensions that you want: > > >> > > >> Document tools: > > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/bibtex.js > > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/document-tools.js > > >> > > >> Cell tools: > > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/cell-tools.js > > >> > > >> Spell checking: > > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/spell-check.js > > >> wget https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/typo.zip > > >> unzip typo.zip > > >> > > >> > > >> We'd be glad to get feedback on any and all of these. We hope that you find them useful! > > >> > > >> -Doug (and the Bryn Mawr College digital humanities team) > > >> > > >> > > >> > > >> _______________________________________________ > > >> IPython-dev mailing list > > >> IPython-dev at scipy.org > > >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > >> > > > > > > _______________________________________________ > > > IPython-dev mailing list > > > IPython-dev at scipy.org > > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From doug.blank at gmail.com Sun Jul 27 08:56:57 2014 From: doug.blank at gmail.com (Doug Blank) Date: Sun, 27 Jul 2014 08:56:57 -0400 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools In-Reply-To: <94A4C38A-129C-4AE5-8AAB-871FF22CF662@gmail.com> References: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> <53D4DA4F.9090905@elbonia.de> <141E3132-18B5-49D3-ABAD-BD9A24E48B15@gmail.com> <CAAusYCjd3NbOf-dLDQzVpSOAKdoYPHj_ho0X9SW=6q2SyLSb+g@mail.gmail.com> <94A4C38A-129C-4AE5-8AAB-871FF22CF662@gmail.com> Message-ID: <CAAusYCiUAAmjjpuptdx18uVv1gt-LyC6W7v=EHFBk5PtBK+vEQ@mail.gmail.com> On Sun, Jul 27, 2014 at 8:48 AM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 27 juil. 2014 ? 14:41, Doug Blank a ?crit : > > > Speaking of this: is there a magic that acts as a type of Notebook > JavaScript package manager? With the new system, it seems like it wouldn't > be too hard to make a small installer that could keep track of > dependencies, versioning, and file copying. > > Hum, no, and it is slightly more complicated than that. It is "relatively" > easy for pure js/css modules, but for things > that require kernel-side there are some challenges. > Right, definitely talking about just the Notebook-side of things at this point. The kernel-side will probably have to be specific to that language/system. (I guess there is a third category that are JavaScript, but kernel specific.) Making this distinction is important as Jupyter unfolds as many of the notebook extensions could work for all kernels. Extension writers need to make it clear which they are writing. > I even suspect that you should be able to develop/register extensions with > bower/npm and "just" install > them in nbextensions. > I don't know these tools, but if there is a way to not reinvent the wheel, sounds great! -Doug > -- > M > > > > > > > -Doug > > > > > > On Sun, Jul 27, 2014 at 6:59 AM, Matthias Bussonnier < > bussonniermatthias at gmail.com> wrote: > > > > > > > > > Le 27 juil. 2014 ? 12:54, Juergen Hasch a ?crit : > > > > > > > Hi Doug, > > > > nice work. I am glad you found a Javascript solution for the spell > checker. I'll happily retire my aspell-based version. > > > > > > > > I think it would be a good idea to move to the nbextension location, > as Matthias suggested. > > > > Also, the CSS stuff for the spellchecker extension should probably > be in a separate spell-check.css file . > > > > > > > > Matthias: > > > > One can use "IPython.load_extensions('spell-check')" or > "require(['nbextensions/spell-check'])" to load an extension. > > > > The first options seems nicer to me, what do you say ? > > > > > > Yes, I just never remember how to use it :-) > > > Writing My PhD have made a lot of holes in my usage of IPython. > > > We should really write documentation for Javascript stuff. > > > -- > > > M > > > > > > > > > > Juergen > > > > > > > > > > > > Am 27.07.2014 07:50, schrieb Doug Blank: > > > >> IPython notebook users, > > > >> > > > >> Looking for some beta testers to try out three new notebook > extensions. These are browser extensions, so should work > > > >> with any kernel. They are: > > > >> > > > >> 1. Spell check: this is implemented in JavaScript, not too big > (~700k), and pretty fast. It is currently set up to work > > > >> only for Markdown cells. It toggles on/off via the "check" button. > Doesn't offer suggestions for misspelled words, but > > > >> is a big help in writing. Currently, English only, but supports a > range of dictionary types via Typo.js. > > > >> > > > >> 2. Cell tools: There are two formats for code cells: Input/Output > Tabbed view, and Column view. The Tabbed view will > > > >> cover the Input code cell with the Output of the code, and you can > tab back and forth. The Column view will show the > > > >> output in a column next to the input column. Both of these buttons > toggle individual code cells, and remembers their > > > >> state when you re-open the notebook. These don't show in nbviewer, > however. > > > >> > > > >> 3. Document tools: There are three different extensions for > handling documents: 1) Heading numbering, 2) Table of > > > >> Contents generation, and 3) Bibliographic support. The first two > are fairly straightforward in functionality: the first > > > >> toggles heading numbering on/off, and the second creates a Table of > Contents from the heading cells. > > > >> > > > >> The Bibliographic tool is a bit more complex, and still needs to be > refined. It does two things: replaces citations in > > > >> your Markdown with proper author/year, and creates a References > section at the end of your notebook with cited sources > > > >> (this part isn't complete yet). It uses Bibtex data stored in the > notebook, or in a separate Bibliography.ipynb in your > > > >> root dir. For more on this tool, see: > > > >> > > > >> > http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Documentation/Reference%20Guide/Reference%20Guide.ipynb#4.-Bibliographic-Support > > > >> > > > >> (Documentation hasn't been refined yet; This is a temp version. We > hope to have some demo videos next week.) > > > >> > > > >> To install, you can do something like: > > > >> > > > >> 1) Change to the profile you want to use: > > > >> cd $(ipython locate)/profile_default/static/custom/ > > > >> > > > >> 2) Overwrite or edit your custom js and css: > > > >> wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom_example.js > -o custom.css > > > >> wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom.css > > > >> > > > >> 3) Get the extensions that you want: > > > >> > > > >> Document tools: > > > >> wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/bibtex.js > > > >> wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/document-tools.js > > > >> > > > >> Cell tools: > > > >> wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/cell-tools.js > > > >> > > > >> Spell checking: > > > >> wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/spell-check.js > > > >> wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/typo.zip > > > >> unzip typo.zip > > > >> > > > >> > > > >> We'd be glad to get feedback on any and all of these. We hope that > you find them useful! > > > >> > > > >> -Doug (and the Bryn Mawr College digital humanities team) > > > >> > > > >> > > > >> > > > >> _______________________________________________ > > > >> IPython-dev mailing list > > > >> IPython-dev at scipy.org > > > >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > >> > > > > > > > > _______________________________________________ > > > > IPython-dev mailing list > > > > IPython-dev at scipy.org > > > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > > _______________________________________________ > > > IPython-dev mailing list > > > IPython-dev at scipy.org > > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140727/6eb2f734/attachment.html> From doug.blank at gmail.com Sun Jul 27 13:24:46 2014 From: doug.blank at gmail.com (Doug Blank) Date: Sun, 27 Jul 2014 13:24:46 -0400 Subject: [IPython-dev] How to make a notebook extension Message-ID: <CAAusYCiM3JsKxRpDk=FMVOZPzfu6RE_21HUjZ-yq6a8Y=hzPpw@mail.gmail.com> Ok, I think I have this figured out, and if the following is right, and best practice, I'd be glad to put in the docs. First, write your JavaScript programs. There should be a main JS file. The JavaScript file should generally take the form: ``` define( function () { var load_ipython_extension = function () { ... }; return { load_ipython_extension : load_ipython_extension, }; }); ``` This function will return a JS object with "load_ipython_extension" defined to be a function that is called when loading the extension. Name this JS file with a unique name that won't collide with other extensions. For example, use "jones-feature-name.js" where "jones" is the name of your group, and "feature-name" is the name of what the feature you are adding/enhancing. If there is only the single .js file, then you can easily make a download for it. If more than one file is needed for your extension (additional libraries, css, etc) it is advised to make a zip file for easy install. The zip file should have your main JS file in the root. To install the zip or js file, use: ipython install-nbextension URL The files are saved to $(ipython locale)/nbextensions/ At this point, you can use your extension by interactively loading it in a notebook (regardless of kernel, as long as your kernel supports running javascript); in the native kernel, that is: ``` %%javascript IPython.load_extensions("jones-feature-name") ``` Your feature is now active, and will be loaded automatically each time you open this notebook if you leave this cell in the notebook. [Is that right? How does it work?] What if you have an associated CSS file? It is not loaded automatically. Add this to your defined JS object: ``` var load_css = function () { var link = document.createElement("link"); link.type = "text/css"; link.rel = "stylesheet"; link.href = require.toUrl("/nbextensions/jones-feature-name.css"); console.log(link); document.getElementsByTagName("head")[0].appendChild(link); }; ``` and call it in load_ipython_extension. Finally, if you want to load your extension automatically (or need to have your script loaded earlier to handle opening functions) then you can add this single line to your $(ipython locale)/profile_XXX/static/custom/custom.js: IPython.load_extensions("jones-feature-name"); There are more options (having things execute on notebook open, adding toolbar buttons, menu items), and those are explain here ... How does that sound? Did I miss anything? -Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140727/3859348d/attachment.html> From doug.blank at gmail.com Sun Jul 27 14:42:15 2014 From: doug.blank at gmail.com (Doug Blank) Date: Sun, 27 Jul 2014 14:42:15 -0400 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools In-Reply-To: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> References: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> Message-ID: <CAAusYCie6yL8ncOzSR7F8Jb7vZaKq9UUDOA31QkjV6fE8tomsw@mail.gmail.com> Updated with new instructions: On Sun, Jul 27, 2014 at 1:50 AM, Doug Blank <doug.blank at gmail.com> wrote: > IPython notebook users, > > Looking for some beta testers to try out three new notebook extensions. > These are browser extensions, so should work with any kernel. They are: > > 1. Spell check: this is implemented in JavaScript, not too big (~700k), > and pretty fast. It is currently set up to work only for Markdown cells. It > toggles on/off via the "check" button. Doesn't offer suggestions for > misspelled words, but is a big help in writing. Currently, English only, > but supports a range of dictionary types via Typo.js. > > 2. Cell tools: There are two formats for code cells: Input/Output Tabbed > view, and Column view. The Tabbed view will cover the Input code cell with > the Output of the code, and you can tab back and forth. The Column view > will show the output in a column next to the input column. Both of these > buttons toggle individual code cells, and remembers their state when you > re-open the notebook. These don't show in nbviewer, however. > > 3. Document tools: There are three different extensions for handling > documents: 1) Heading numbering, 2) Table of Contents generation, and 3) > Bibliographic support. The first two are fairly straightforward in > functionality: the first toggles heading numbering on/off, and the second > creates a Table of Contents from the heading cells. > > The Bibliographic tool is a bit more complex, and still needs to be > refined. It does two things: replaces citations in your Markdown with > proper author/year, and creates a References section at the end of your > notebook with cited sources (this part isn't complete yet). It uses Bibtex > data stored in the notebook, or in a separate Bibliography.ipynb in your > root dir. For more on this tool, see: > > > http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Documentation/Reference%20Guide/Reference%20Guide.ipynb#4.-Bibliographic-Support > > (Documentation hasn't been refined yet; This is a temp version. We hope to > have some demo videos next week.) > > To install, you can do something like: > ipython install-nbextension https://bitbucket.org/ipre/calico/downloads/calico-spell-check-1.0.zip ipython install-nbextension https://bitbucket.org/ipre/calico/downloads/calico-document-tools-1.0.zip ipython install-nbextension https://bitbucket.org/ipre/calico/downloads/calico-cell-tools-1.0.zip You can then begin to use them in your notebooks by loading them dynamically. In the native and Calico kernels (and perhaps others that support the %%javascript magic): ``` %%javascript IPython.load_extensions("calico-spell-check", "calico-document-tools", "calico-cell-tools"); ``` You can include only the ones you want in that list. Or, if you want to load them always, or use the auto cell formatting on opening a notebook), put that line in your: $(ipython locale)/profile_XXX/static/custom/custom.js where XXX is "default" or another profile name. That's it! Please feel free to make suggestions, or report bugs. We have an issue tracker here: https://bitbucket.org/ipre/calico/issues?status=new&status=open -Doug > > 1) Change to the profile you want to use: > cd $(ipython locate)/profile_default/static/custom/ > > 2) Overwrite or edit your custom js and css: > wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom_example.js > -o custom.css > wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/custom.css > > > 3) Get the extensions that you want: > > Document tools: > wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/bibtex.js > wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/document-tools.js > > Cell tools: > wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/cell-tools.js > > Spell checking: > wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/spell-check.js > wget > https://bitbucket.org/ipre/calico/raw/master/notebooks/profile/static/custom/typo.zip > unzip typo.zip > > > We'd be glad to get feedback on any and all of these. We hope that you > find them useful! > > -Doug (and the Bryn Mawr College digital humanities team) > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140727/3401c66e/attachment.html> From takowl at gmail.com Mon Jul 28 13:26:49 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 28 Jul 2014 10:26:49 -0700 Subject: [IPython-dev] New Notebook extensions: Spell checking, document tools, cell tools In-Reply-To: <CAAusYCiUAAmjjpuptdx18uVv1gt-LyC6W7v=EHFBk5PtBK+vEQ@mail.gmail.com> References: <CAAusYCi5kaVyGcuzU4dVyx10m_u+J2VyJ6AkNG5i+eXpkBnkLA@mail.gmail.com> <53D4DA4F.9090905@elbonia.de> <141E3132-18B5-49D3-ABAD-BD9A24E48B15@gmail.com> <CAAusYCjd3NbOf-dLDQzVpSOAKdoYPHj_ho0X9SW=6q2SyLSb+g@mail.gmail.com> <94A4C38A-129C-4AE5-8AAB-871FF22CF662@gmail.com> <CAAusYCiUAAmjjpuptdx18uVv1gt-LyC6W7v=EHFBk5PtBK+vEQ@mail.gmail.com> Message-ID: <CAOvn4qisq259=-vKnycpfjKKD9XMpByn0gAzobMi+3vpV62zVg@mail.gmail.com> On 27 July 2014 05:56, Doug Blank <doug.blank at gmail.com> wrote: > Hum, no, and it is slightly more complicated than that. It is >> "relatively" easy for pure js/css modules, but for things >> that require kernel-side there are some challenges. >> > > Right, definitely talking about just the Notebook-side of things at this > point. The kernel-side will probably have to be specific to that > language/system. (I guess there is a third category that are JavaScript, > but kernel specific.) > For things designed to work with the Python kernel, you can include the JS parts as part of a Python package, and copy or symlink them into nbextensions at runtime. This is what I do for the turtle widget, for instance: https://github.com/takluyver/mobilechelonian/ In some ways, pure JS extensions are trickier, because you don't have the packaging system for the kernel's language to fall back on. I think we'll need to write some way that extensions can be installed and enabled from the notebook UI. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140728/01d837e5/attachment.html> From kikocorreoso at gmail.com Tue Jul 29 04:07:22 2014 From: kikocorreoso at gmail.com (Kiko) Date: Tue, 29 Jul 2014 10:07:22 +0200 Subject: [IPython-dev] Command line tool to publish a notebook on a wordpress blog Message-ID: <CAB-sx61fgyw_6Auv46aX3UWBHHroA-Zv3ypQCbd2iSXBhtiAiw@mail.gmail.com> Hi all, I made a small script to publish a notebook directly on a wordpress blog. The repo can be found here: https://github.com/Pybonacci/ipy2wp It uses nbconvert to convert the notebook to html (maybe I should explore a conversion to markdown instead of html). I use this to publish on http://pybonacci.org and it works great with simple notebooks (I have to check notebooks with more complex structure). It creates a draft on your wordpress blog so you can check the post before publishing. If someone uses the script please provide some feedback to improve the tool. If someone experience any problem, please, open an issue in the repo. If someone has something similar and want to share it would be great to see how others are solving that. If your wordpress blog is older than v 3.5 please check this link: http://codex.wordpress.org/XML-RPC_Support Kind regards. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/90bbcae9/attachment.html> From bussonniermatthias at gmail.com Tue Jul 29 05:00:57 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 29 Jul 2014 11:00:57 +0200 Subject: [IPython-dev] Command line tool to publish a notebook on a wordpress blog In-Reply-To: <CAB-sx61fgyw_6Auv46aX3UWBHHroA-Zv3ypQCbd2iSXBhtiAiw@mail.gmail.com> References: <CAB-sx61fgyw_6Auv46aX3UWBHHroA-Zv3ypQCbd2iSXBhtiAiw@mail.gmail.com> Message-ID: <A7DE3E51-9907-46FC-8E05-596688B550FF@gmail.com> Hi Le 29 juil. 2014 ? 10:07, Kiko a ?crit : > Hi all, > > I made a small script to publish a notebook directly on a wordpress blog. The repo can be found here: > https://github.com/Pybonacci/ipy2wp > > It uses nbconvert to convert the notebook to html (maybe I should explore a conversion to markdown instead of html). I use this to publish on http://pybonacci.org and it works great with simple notebooks (I have to check notebooks with more complex structure). It creates a draft on your wordpress blog so you can check the post before publishing. That's really nice, It is super agreeable to see people using it as a library and not using subprocess ! We've spent quite some time working on that so it make me glad to see people using it ! You should add it to the Wiki on project using IPython/Jupyter ! -- Matthias > > If someone uses the script please provide some feedback to improve the tool. If someone experience any problem, please, open an issue in the repo. If someone has something similar and want to share it would be great to see how others are solving that. > > If your wordpress blog is older than v 3.5 please check this link: http://codex.wordpress.org/XML-RPC_Support > > Kind regards. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/6d5ff5b0/attachment.html> From doug.blank at gmail.com Tue Jul 29 08:07:07 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 29 Jul 2014 08:07:07 -0400 Subject: [IPython-dev] Command line tool to publish a notebook on a wordpress blog In-Reply-To: <CAB-sx61fgyw_6Auv46aX3UWBHHroA-Zv3ypQCbd2iSXBhtiAiw@mail.gmail.com> References: <CAB-sx61fgyw_6Auv46aX3UWBHHroA-Zv3ypQCbd2iSXBhtiAiw@mail.gmail.com> Message-ID: <CAAusYCjK5NPx9_r7sX_JfOrrUDOHKzC-ONBXWpDMGb=_8EjFmg@mail.gmail.com> On Tue, Jul 29, 2014 at 4:07 AM, Kiko <kikocorreoso at gmail.com> wrote: > Hi all, > > I made a small script to publish a notebook directly on a wordpress blog. > The repo can be found here: > https://github.com/Pybonacci/ipy2wp > > It uses nbconvert to convert the notebook to html (maybe I should explore > a conversion to markdown instead of html). I use this to publish on > http://pybonacci.org and it works great with simple notebooks (I have to > check notebooks with more complex structure). It creates a draft on your > wordpress blog so you can check the post before publishing. > > If someone uses the script please provide some feedback to improve the > tool. If someone experience any problem, please, open an issue in the repo. > If someone has something similar and want to share it would be great to see > how others are solving that. > > If your wordpress blog is older than v 3.5 please check this link: > http://codex.wordpress.org/XML-RPC_Support > > Kind regards. > Very useful! Do you have any suggestions regarding how to get IPython's /static etc. installed so that everything needed (eg, javascript) will load? Also, looks like some HTML is being injected into <script> areas (note the <p> tag and >): <script> ... google.load('visualization', '1.0', {'callback': drawChart, 'packages':['corechart']}); });</p> <p>// ]]></script></p> Thanks for making this available! -Doug > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/8ab973c2/attachment.html> From doug.blank at gmail.com Tue Jul 29 09:06:35 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 29 Jul 2014 09:06:35 -0400 Subject: [IPython-dev] How to make a notebook extension In-Reply-To: <CAAusYCiM3JsKxRpDk=FMVOZPzfu6RE_21HUjZ-yq6a8Y=hzPpw@mail.gmail.com> References: <CAAusYCiM3JsKxRpDk=FMVOZPzfu6RE_21HUjZ-yq6a8Y=hzPpw@mail.gmail.com> Message-ID: <CAAusYCiETQvCTZKCz+e1sbzVsQJ3ugYd1ZQSgWwSn78OoVxjLA@mail.gmail.com> Follow-ups (suggestions, options, overall betterness) available in the associated issue tracker: https://github.com/ipython/ipython/issues/6229 Hopefully will lead to good documentation. -Doug On Sun, Jul 27, 2014 at 1:24 PM, Doug Blank <doug.blank at gmail.com> wrote: > Ok, I think I have this figured out, and if the following is right, and > best practice, I'd be glad to put in the docs. > > First, write your JavaScript programs. There should be a main JS file. The > JavaScript file should generally take the form: > > ``` > define( function () { > var load_ipython_extension = function () { > ... > }; > > return { > load_ipython_extension : load_ipython_extension, > }; > }); > ``` > > This function will return a JS object with "load_ipython_extension" > defined to be a function that is called when loading the extension. > > Name this JS file with a unique name that won't collide with other > extensions. For example, use "jones-feature-name.js" where "jones" is the > name of your group, and "feature-name" is the name of what the feature you > are adding/enhancing. > > If there is only the single .js file, then you can easily make a download > for it. > > If more than one file is needed for your extension (additional libraries, > css, etc) it is advised to make a zip file for easy install. The zip file > should have your main JS file in the root. > > To install the zip or js file, use: > > ipython install-nbextension URL > > The files are saved to $(ipython locale)/nbextensions/ > > At this point, you can use your extension by interactively loading it in a > notebook (regardless of kernel, as long as your kernel supports running > javascript); in the native kernel, that is: > > ``` > %%javascript > IPython.load_extensions("jones-feature-name") > ``` > > Your feature is now active, and will be loaded automatically each time you > open this notebook if you leave this cell in the notebook. [Is that right? > How does it work?] > > What if you have an associated CSS file? It is not loaded automatically. > > Add this to your defined JS object: > > ``` > var load_css = function () { > var link = document.createElement("link"); > link.type = "text/css"; > link.rel = "stylesheet"; > link.href = require.toUrl("/nbextensions/jones-feature-name.css"); > console.log(link); > document.getElementsByTagName("head")[0].appendChild(link); > }; > ``` > > and call it in load_ipython_extension. > > Finally, if you want to load your extension automatically (or need to have > your script loaded earlier to handle opening functions) then you can add > this single line to your $(ipython > locale)/profile_XXX/static/custom/custom.js: > > IPython.load_extensions("jones-feature-name"); > > There are more options (having things execute on notebook open, adding > toolbar buttons, menu items), and those are explain here ... > > How does that sound? Did I miss anything? > > -Doug > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/01631eea/attachment.html> From hughesadam87 at gmail.com Tue Jul 29 13:22:16 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 29 Jul 2014 13:22:16 -0400 Subject: [IPython-dev] HTML pandas issue (followup of twitter question) Message-ID: <CAMHV+dA_3ks-2Ohmt=YeyyyKdjY1Fehv95a2vsZHQk4H1B9GJQ@mail.gmail.com> Thanks for answering my twitter question about HTML representations of dataframes. https://twitter.com/hughesadam87 I have a composition class that stores a DataFrame, and uses __getattr__ to pass any attribute call down to the dataframe. Therefore, my object has a __repr__(), _repr_html_() etc... The difference is, if I do "print obj.df", I get the nice html output by default. However, if I do "print obj", I don't get this; I get the standard plain string output. This is weird because I am not overwriting anything. I can sucessfully get my object to print the dataframe html representation by doing: from IPython.core.display import HTML display(HTML(obj.to_html())) What I don't understand is how does the notebook know that a pandas dataframe should display as html by default? How are they communicating? When you print a dataframe, does the notebook look specifically for the _repr_html Since my object has all of the methods of a dataframe (although not publicized), I imagine the notebook might be looking for certain attributes or methods or something, to set this default HTML printing? Hope that makes some sense, sorry. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/6eab579e/attachment.html> From takowl at gmail.com Tue Jul 29 13:26:43 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 29 Jul 2014 10:26:43 -0700 Subject: [IPython-dev] HTML pandas issue (followup of twitter question) In-Reply-To: <CAMHV+dA_3ks-2Ohmt=YeyyyKdjY1Fehv95a2vsZHQk4H1B9GJQ@mail.gmail.com> References: <CAMHV+dA_3ks-2Ohmt=YeyyyKdjY1Fehv95a2vsZHQk4H1B9GJQ@mail.gmail.com> Message-ID: <CAOvn4qi=B2VOw-gsF6H+x8WnmjZ+rLEAzm+grOLzBChsG=UArg@mail.gmail.com> On 29 July 2014 10:22, Adam Hughes <hughesadam87 at gmail.com> wrote: > The difference is, if I do "print obj.df", I get the nice html output by > default. That's strange - print should only ever give you the plain string representation. If you just put 'obj.df' or 'obj' on a line by itself at the end of the cell, *without* print, it should display HTML reprs. If you want to display more than one thing per cell, then IPython.display.display(obj) is the rich-repr equivalent of print. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/04d523eb/attachment.html> From hughesadam87 at gmail.com Tue Jul 29 14:28:53 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 29 Jul 2014 14:28:53 -0400 Subject: [IPython-dev] HTML pandas issue (followup of twitter question) In-Reply-To: <CAOvn4qi=B2VOw-gsF6H+x8WnmjZ+rLEAzm+grOLzBChsG=UArg@mail.gmail.com> References: <CAMHV+dA_3ks-2Ohmt=YeyyyKdjY1Fehv95a2vsZHQk4H1B9GJQ@mail.gmail.com> <CAOvn4qi=B2VOw-gsF6H+x8WnmjZ+rLEAzm+grOLzBChsG=UArg@mail.gmail.com> Message-ID: <CAMHV+dAf8mQBSEPu5AgieVx_YykfACd9qLA=tXk63aj8wuhrVg@mail.gmail.com> I'm sorry you're right thomas. I didn't mean print; I meant if I leave it as the last statement in a cell. IE ... df vs. ... myobject In this case, it still just prints plain text for myobject. The only print method that myobject specifically overloads is: def __repr__(self): return self._df.__repr__() Since otherwise it would default to python objects' print statements. Could this be the problem? I can try to make a self-contained reproducible example if you think this is a bug of sorts. On Tue, Jul 29, 2014 at 1:26 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 29 July 2014 10:22, Adam Hughes <hughesadam87 at gmail.com> wrote: > >> The difference is, if I do "print obj.df", I get the nice html output by >> default. > > > That's strange - print should only ever give you the plain string > representation. If you just put 'obj.df' or 'obj' on a line by itself at > the end of the cell, *without* print, it should display HTML reprs. > > If you want to display more than one thing per cell, then > IPython.display.display(obj) is the rich-repr equivalent of print. > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/c596c51c/attachment.html> From takowl at gmail.com Tue Jul 29 14:32:14 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 29 Jul 2014 11:32:14 -0700 Subject: [IPython-dev] HTML pandas issue (followup of twitter question) In-Reply-To: <CAMHV+dAf8mQBSEPu5AgieVx_YykfACd9qLA=tXk63aj8wuhrVg@mail.gmail.com> References: <CAMHV+dA_3ks-2Ohmt=YeyyyKdjY1Fehv95a2vsZHQk4H1B9GJQ@mail.gmail.com> <CAOvn4qi=B2VOw-gsF6H+x8WnmjZ+rLEAzm+grOLzBChsG=UArg@mail.gmail.com> <CAMHV+dAf8mQBSEPu5AgieVx_YykfACd9qLA=tXk63aj8wuhrVg@mail.gmail.com> Message-ID: <CAOvn4qgU=Uqarjf8A3g2HG6dcL2fV7b7o6T6oYyzPY_8NMeqDA@mail.gmail.com> On 29 July 2014 11:28, Adam Hughes <hughesadam87 at gmail.com> wrote: > The only print method that myobject specifically overloads is: > > def __repr__(self): > Didn't you say you also define _repr_html_()? It's the presence of _repr_html_() on your object that lets IPython give it the HTML display. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/aab73668/attachment.html> From tritemio at gmail.com Tue Jul 29 14:36:49 2014 From: tritemio at gmail.com (Antonino Ingargiola) Date: Tue, 29 Jul 2014 11:36:49 -0700 Subject: [IPython-dev] IPython notebook widgets for interactive matplotlib figures Message-ID: <CANn2QUywv5npOdU5OjGHcYnOLJ0HEGv3ZVtJF=MB2rQ60c8isQ@mail.gmail.com> HI to all, I'm following up to this SO question: http://stackoverflow.com/questions/24961674/ipython-notebook-widgets-for-matplotlib-interactivity To summarize the problem is that I want to "modify" a plot via some notebook widgets, for example adding a cursor (however can can think about any plot tweak including adding/removing data). Putting the following code in a single cell: fig, ax = plt.subplots() ax.plot([3,1,2,4,0,5,3,2,0,2,4]) vline = ax.axvline(1) hline = ax.axhline(0.5) def set_cursor(x, y): vline.set_xdata((x, x)) hline.set_ydata((y, y)) display(fig) interact(set_cursor, x=(1, 9, 0.01), y=(0, 5, 0.01)) results in 2 figures being displayed: one by the standard notebook machinery in the Out field and one by the interact call in the widgets space (between the code cell and the output). Moving the slider makes the first plot to disappear. Is this the expected behavior? Am I doing something wrong? Is there a way I can inhibit the first figure display? Thanks, Antonio -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/8a3ab622/attachment.html> From hughesadam87 at gmail.com Tue Jul 29 15:03:15 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 29 Jul 2014 15:03:15 -0400 Subject: [IPython-dev] HTML pandas issue (followup of twitter question) In-Reply-To: <CAOvn4qgU=Uqarjf8A3g2HG6dcL2fV7b7o6T6oYyzPY_8NMeqDA@mail.gmail.com> References: <CAMHV+dA_3ks-2Ohmt=YeyyyKdjY1Fehv95a2vsZHQk4H1B9GJQ@mail.gmail.com> <CAOvn4qi=B2VOw-gsF6H+x8WnmjZ+rLEAzm+grOLzBChsG=UArg@mail.gmail.com> <CAMHV+dAf8mQBSEPu5AgieVx_YykfACd9qLA=tXk63aj8wuhrVg@mail.gmail.com> <CAOvn4qgU=Uqarjf8A3g2HG6dcL2fV7b7o6T6oYyzPY_8NMeqDA@mail.gmail.com> Message-ID: <CAMHV+dC6WRX2rxVuZJ=y93Lg1b=0XMCPrA+A=RLWomxUX_wXnw@mail.gmail.com> AHHHHHHHHH I FORGOT THE TRAILING UNDERSCORE!!!!!!!! Thanks Thomas. My life is complete now. On Tue, Jul 29, 2014 at 2:32 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 29 July 2014 11:28, Adam Hughes <hughesadam87 at gmail.com> wrote: > >> The only print method that myobject specifically overloads is: >> >> def __repr__(self): >> > > Didn't you say you also define _repr_html_()? It's the presence of > _repr_html_() on your object that lets IPython give it the HTML display. > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/d3bf65c1/attachment.html> From fperez.net at gmail.com Tue Jul 29 15:21:07 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 29 Jul 2014 12:21:07 -0700 Subject: [IPython-dev] IPython notebook widgets for interactive matplotlib figures In-Reply-To: <CANn2QUywv5npOdU5OjGHcYnOLJ0HEGv3ZVtJF=MB2rQ60c8isQ@mail.gmail.com> References: <CANn2QUywv5npOdU5OjGHcYnOLJ0HEGv3ZVtJF=MB2rQ60c8isQ@mail.gmail.com> Message-ID: <CAHAreOo67XFst6s=yZnyrUKu3+5S808zo7nq=XVApAxEu0Tm0g@mail.gmail.com> On Tue, Jul 29, 2014 at 11:36 AM, Antonino Ingargiola <tritemio at gmail.com> wrote: > > Is this the expected behavior? Am I doing something wrong? Is there a way > I can inhibit the first figure display? > It's an unfortunate side effect of IPython's internal logic that tries to auto-display plots so that simple calls like plot(x) work in an intuitive fashion. Since you're manually calling display(), both code paths kick in, and you end up with a duplicate figure. The simple answer is: in every instance where you're going to do manual figure displaying yourself, you can prevent the automatic display by putting plt.close(fig) at the end of your cell, if you have a handle on a specific figure, or more simply (if less elegant) plt.close('all') that will close every open figure regardless how many there are or whether you have a handle on them. We were never able to come up with a solution that would work well in all the naive/simple cases and yet also not have funny side effects in more advanced scenarios like this. In the end, we settled on making the simple cases work as best as possible, and having to make a manual close() call in other cases. It's possible that with a bit more thought a better solution can be found, this was done early on (before the notebook, all that logic was designed initially for the Qt console). We had so many things to do that we moved on with this current solution, but it may be worth revisiting to see if we can come up with better heuristics or ideas. Cheers, f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/057bc596/attachment.html> From tritemio at gmail.com Tue Jul 29 16:06:17 2014 From: tritemio at gmail.com (Antonino Ingargiola) Date: Tue, 29 Jul 2014 13:06:17 -0700 Subject: [IPython-dev] IPython notebook widgets for interactive matplotlib figures In-Reply-To: <CAHAreOo67XFst6s=yZnyrUKu3+5S808zo7nq=XVApAxEu0Tm0g@mail.gmail.com> References: <CANn2QUywv5npOdU5OjGHcYnOLJ0HEGv3ZVtJF=MB2rQ60c8isQ@mail.gmail.com> <CAHAreOo67XFst6s=yZnyrUKu3+5S808zo7nq=XVApAxEu0Tm0g@mail.gmail.com> Message-ID: <CANn2QUy6V9QMbCRW=Y9VAPydY1AN0TsA7ZBFAFzfhUrnVnOyjg@mail.gmail.com> On Tue, Jul 29, 2014 at 12:21 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Tue, Jul 29, 2014 at 11:36 AM, Antonino Ingargiola <tritemio at gmail.com> > wrote: > >> >> Is this the expected behavior? Am I doing something wrong? Is there a way >> I can inhibit the first figure display? >> > > It's an unfortunate side effect of IPython's internal logic that tries to > auto-display plots so that simple calls like > > plot(x) > > work in an intuitive fashion. Since you're manually calling display(), > both code paths kick in, and you end up with a duplicate figure. > > The simple answer is: in every instance where you're going to do manual > figure displaying yourself, you can prevent the automatic display by putting > > plt.close(fig) > > at the end of your cell, if you have a handle on a specific figure > Ouch! So simple! Thanks for the solution. I didn't tried close() because I though that closing the figure would destroy it. It turns out that it is not and the following interact call works as expected. > We were never able to come up with a solution that would work well in all > the naive/simple cases and yet also not have funny side effects in more > advanced scenarios like this. In the end, we settled on making the simple > cases work as best as possible, and having to make a manual close() call in > other cases. It's possible that with a bit more thought a better solution > can be found, this was done early on (before the notebook, all that logic > was designed initially for the Qt console). We had so many things to do > that we moved on with this current solution, but it may be worth revisiting > to see if we can come up with better heuristics or ideas. > Just my 2c: why don't providing an API function like "show_figure(False)". At this moment it will just call close(). In the future if you change implementation the API function will stay the same. Best, Antonio -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/e3dd7534/attachment.html> From msg2mw at gmail.com Tue Jul 29 16:24:20 2014 From: msg2mw at gmail.com (Mike Witt) Date: Tue, 29 Jul 2014 13:24:20 -0700 Subject: [IPython-dev] Problem using JSAnimation Message-ID: <1406665460.6801.58@Backie> I've never used JSAnimation before. I just tried installing it, and every time I try to do anything with it, it wants to import things from matplotlib.animation that don't seem to be there (at least on my system). I wonder, is there some piece of matplolib that I'm missing? I should mention that I've never used matplotlib.animation either. In the past I've created the frames by hand and put them together with convert, ffmpeg, or something like that. In [1]: from JSAnimation import IPython_display --------------------------------------------------------------------------- ImportError Traceback (most recent call last) <ipython-input-1-8205f5806e96> in <module>() ----> 1 from JSAnimation import IPython_display /usr/local/lib/python2.7/dist-packages/JSAnimation/__init__.py in <module>() ----> 1 from .html_writer import HTMLWriter /usr/local/lib/python2.7/dist-packages/JSAnimation/html_writer.py in <module>() 8 else: 9 from io import BytesIO as InMemory ---> 10 from matplotlib.animation import writers, FileMovieWriter 11 from base64 import b64encode 12 ImportError: cannot import name writers From fperez.net at gmail.com Tue Jul 29 16:41:36 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 29 Jul 2014 13:41:36 -0700 Subject: [IPython-dev] IPython notebook widgets for interactive matplotlib figures In-Reply-To: <CANn2QUy6V9QMbCRW=Y9VAPydY1AN0TsA7ZBFAFzfhUrnVnOyjg@mail.gmail.com> References: <CANn2QUywv5npOdU5OjGHcYnOLJ0HEGv3ZVtJF=MB2rQ60c8isQ@mail.gmail.com> <CAHAreOo67XFst6s=yZnyrUKu3+5S808zo7nq=XVApAxEu0Tm0g@mail.gmail.com> <CANn2QUy6V9QMbCRW=Y9VAPydY1AN0TsA7ZBFAFzfhUrnVnOyjg@mail.gmail.com> Message-ID: <CAHAreOpMnG-3WYbctW-po6RaB7xa0J-rncRN4dVq0urdtCiidg@mail.gmail.com> On Tue, Jul 29, 2014 at 1:06 PM, Antonino Ingargiola <tritemio at gmail.com> wrote: > Just my 2c: why don't providing an API function like "show_figure(False)". > At this moment it will just call close(). In the future if you change > implementation the API function will stay the same. Not a bad idea... I'd like to mull a little bit on the cleanest way to do this, but that's not a bad solution. If nothing else, you can add that to your local utils for now, and see if it works well enough. def showfig(f): plt.close(f) display(f) is easy enough to add at the top :) Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/f2f113f9/attachment.html> From fperez.net at gmail.com Tue Jul 29 16:42:58 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 29 Jul 2014 13:42:58 -0700 Subject: [IPython-dev] Problem using JSAnimation In-Reply-To: <1406665460.6801.58@Backie> References: <1406665460.6801.58@Backie> Message-ID: <CAHAreOqy7sAMXiOQzDMtCsRmcLyZbtxQAZAhZ76zMQBzdtAU_w@mail.gmail.com> Check your matplotlib version, it may be too old. I have 1.2.1 and those APIs are there, otherwise you may need to update mpl. On Tue, Jul 29, 2014 at 1:24 PM, Mike Witt <msg2mw at gmail.com> wrote: > I've never used JSAnimation before. I just tried installing it, > and every time I try to do anything with it, it wants to import > things from matplotlib.animation that don't seem to be there (at > least on my system). I wonder, is there some piece of matplolib > that I'm missing? > > I should mention that I've never used matplotlib.animation either. > In the past I've created the frames by hand and put them together > with convert, ffmpeg, or something like that. > > > In [1]: from JSAnimation import IPython_display > --------------------------------------------------------------------------- > ImportError Traceback (most recent call > last) > <ipython-input-1-8205f5806e96> in <module>() > ----> 1 from JSAnimation import IPython_display > > /usr/local/lib/python2.7/dist-packages/JSAnimation/__init__.py in > <module>() > ----> 1 from .html_writer import HTMLWriter > > /usr/local/lib/python2.7/dist-packages/JSAnimation/html_writer.py in > <module>() > 8 else: > 9 from io import BytesIO as InMemory > ---> 10 from matplotlib.animation import writers, FileMovieWriter > 11 from base64 import b64encode > 12 > > ImportError: cannot import name writers > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/28a8bf75/attachment.html> From msg2mw at gmail.com Tue Jul 29 16:54:09 2014 From: msg2mw at gmail.com (Mike Witt) Date: Tue, 29 Jul 2014 13:54:09 -0700 Subject: [IPython-dev] Problem using JSAnimation In-Reply-To: <CAHAreOqy7sAMXiOQzDMtCsRmcLyZbtxQAZAhZ76zMQBzdtAU_w@mail.gmail.com> (from fperez.net@gmail.com on Tue Jul 29 13:42:58 2014) References: <1406665460.6801.58@Backie> <CAHAreOqy7sAMXiOQzDMtCsRmcLyZbtxQAZAhZ76zMQBzdtAU_w@mail.gmail.com> Message-ID: <1406667249.6801.60@Backie> On 07/29/2014 01:42:58 PM, Fernando Perez wrote: > Check your matplotlib version, it may be too old. I have 1.2.1 and > those > APIs are there, otherwise you may need to update mpl. Mine is older. I'm updating. Thanks! -Mike From markbak at gmail.com Tue Jul 29 16:56:03 2014 From: markbak at gmail.com (Mark Bakker) Date: Tue, 29 Jul 2014 22:56:03 +0200 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing Message-ID: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> We have developed a series of 15 Notebooks for scientists and engineers who want to use Python programming for exploratory computing, scipting, data analysis, and visualization.The Notebooks were developed for an undergraduate class (sophomores) in Civil Engineering. No prior knowledge of computer programming is assumed. Each Notebook covers a specific topic and includes a number of exercises. The exercises should take less than 4 hours to complete for each Notebook. The Notebooks may be viewed at http://mbakker7.github.io/exploratory_computing_with_python/ A link to the GitHub repository is also shown on this page. Hope you find them useful, Mark Bakker TU Delft, The Netherlands -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/3d7ba15b/attachment.html> From tritemio at gmail.com Tue Jul 29 17:11:06 2014 From: tritemio at gmail.com (Antonino Ingargiola) Date: Tue, 29 Jul 2014 14:11:06 -0700 Subject: [IPython-dev] IPython notebook widgets for interactive matplotlib figures In-Reply-To: <CAHAreOpMnG-3WYbctW-po6RaB7xa0J-rncRN4dVq0urdtCiidg@mail.gmail.com> References: <CANn2QUywv5npOdU5OjGHcYnOLJ0HEGv3ZVtJF=MB2rQ60c8isQ@mail.gmail.com> <CAHAreOo67XFst6s=yZnyrUKu3+5S808zo7nq=XVApAxEu0Tm0g@mail.gmail.com> <CANn2QUy6V9QMbCRW=Y9VAPydY1AN0TsA7ZBFAFzfhUrnVnOyjg@mail.gmail.com> <CAHAreOpMnG-3WYbctW-po6RaB7xa0J-rncRN4dVq0urdtCiidg@mail.gmail.com> Message-ID: <CANn2QUx=1dXF+xCMiOEihJNoOaa6JLzi6yjoJZfwJ7TM4tctfg@mail.gmail.com> On Tue, Jul 29, 2014 at 1:41 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Tue, Jul 29, 2014 at 1:06 PM, Antonino Ingargiola <tritemio at gmail.com> > wrote: > >> Just my 2c: why don't providing an API function like >> "show_figure(False)". At this moment it will just call close(). In the >> future if you change implementation the API function will stay the same. > > > Not a bad idea... I'd like to mull a little bit on the cleanest way to do > this, but that's not a bad solution. > > If nothing else, you can add that to your local utils for now, and see if > it works well enough. > > def showfig(f): > plt.close(f) > display(f) > > is easy enough to add at the top :) > Yep, I'm doing also a step further. Since the problem was adding interactivity to inline matplotlib plots, I wrapped the necessary bits in a function like this: def add_cursor(fig, ax): plt.close() vline = ax.axvline(1, color='k') hline = ax.axhline(1, color='k') def set_cursor(x, y): vline.set_xdata((x, x)) hline.set_ydata((y, y)) display(fig) interact(set_cursor, x=ax.get_xlim(), y=ax.get_ylim()) and then simply add a call to add_cursor whenever is needed. In this case display() is called by interact(). I will probably write a couple of similar functions for various "interactivity needs". Thanks again, Antonio -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/604c9b5e/attachment.html> From satra at mit.edu Tue Jul 29 17:21:07 2014 From: satra at mit.edu (Satrajit Ghosh) Date: Tue, 29 Jul 2014 17:21:07 -0400 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> Message-ID: <CA+A4wOnxSQ-yELs0B5LjVYEVDf-6KZ54r4k_NrBmSK-7yAQ5NA@mail.gmail.com> thanks mark! this is great and came at an opportune time. i was just looking to create similar stats modules. some related questions to the larger community. - how could we disseminate or find such modules that can be used for teaching, without having to go through every single notebook? - how do we describe the prior knowledge required through a dependency structure? cheers, satra On Tue, Jul 29, 2014 at 4:56 PM, Mark Bakker <markbak at gmail.com> wrote: > We have developed a series of 15 Notebooks for scientists and engineers > who want to use Python programming for exploratory computing, scipting, > data analysis, and visualization.The Notebooks were developed for an > undergraduate class (sophomores) in Civil Engineering. No prior knowledge > of computer programming is assumed. Each Notebook covers a specific topic > and includes a number of exercises. The exercises should take less than 4 > hours to complete for each Notebook. > > The Notebooks may be viewed at > http://mbakker7.github.io/exploratory_computing_with_python/ > A link to the GitHub repository is also shown on this page. > > Hope you find them useful, > > Mark Bakker > TU Delft, The Netherlands > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/4357e254/attachment.html> From fperez.net at gmail.com Tue Jul 29 17:34:11 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 29 Jul 2014 14:34:11 -0700 Subject: [IPython-dev] IPython notebook widgets for interactive matplotlib figures In-Reply-To: <CANn2QUx=1dXF+xCMiOEihJNoOaa6JLzi6yjoJZfwJ7TM4tctfg@mail.gmail.com> References: <CANn2QUywv5npOdU5OjGHcYnOLJ0HEGv3ZVtJF=MB2rQ60c8isQ@mail.gmail.com> <CAHAreOo67XFst6s=yZnyrUKu3+5S808zo7nq=XVApAxEu0Tm0g@mail.gmail.com> <CANn2QUy6V9QMbCRW=Y9VAPydY1AN0TsA7ZBFAFzfhUrnVnOyjg@mail.gmail.com> <CAHAreOpMnG-3WYbctW-po6RaB7xa0J-rncRN4dVq0urdtCiidg@mail.gmail.com> <CANn2QUx=1dXF+xCMiOEihJNoOaa6JLzi6yjoJZfwJ7TM4tctfg@mail.gmail.com> Message-ID: <CAHAreOodW_5=L+NeCBFCoJ4PcKwCyZRzmsBuksftp6jzDv+NxQ@mail.gmail.com> On Tue, Jul 29, 2014 at 2:11 PM, Antonino Ingargiola <tritemio at gmail.com> wrote: > def add_cursor(fig, ax): > plt.close() > Make sure you call close on the fig object, so you don't rely on the implicit state management that pyplot does... -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/024528c7/attachment.html> From fperez.net at gmail.com Tue Jul 29 17:35:41 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 29 Jul 2014 14:35:41 -0700 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CA+A4wOnxSQ-yELs0B5LjVYEVDf-6KZ54r4k_NrBmSK-7yAQ5NA@mail.gmail.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> <CA+A4wOnxSQ-yELs0B5LjVYEVDf-6KZ54r4k_NrBmSK-7yAQ5NA@mail.gmail.com> Message-ID: <CAHAreOrSnqF=OZdMs_sapivHToOnH=ccVpfSWLLaQMkezYvJog@mail.gmail.com> On Tue, Jul 29, 2014 at 2:21 PM, Satrajit Ghosh <satra at mit.edu> wrote: > - how could we disseminate or find such modules that can be used for > teaching, without having to go through every single notebook? > For now, the gallery is the best we have. We plan on putting resources into making nbviewer a much richer platform, but Matthias keep having this silly notion of "finishing a PhD" that constantly gets in the way of real work ;) > - how do we describe the prior knowledge required through a dependency > structure? > Thant sounds like something a semantic web person would say... ;) -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/b6a40034/attachment.html> From tritemio at gmail.com Tue Jul 29 17:39:23 2014 From: tritemio at gmail.com (Antonino Ingargiola) Date: Tue, 29 Jul 2014 14:39:23 -0700 Subject: [IPython-dev] IPython notebook widgets for interactive matplotlib figures In-Reply-To: <CAHAreOodW_5=L+NeCBFCoJ4PcKwCyZRzmsBuksftp6jzDv+NxQ@mail.gmail.com> References: <CANn2QUywv5npOdU5OjGHcYnOLJ0HEGv3ZVtJF=MB2rQ60c8isQ@mail.gmail.com> <CAHAreOo67XFst6s=yZnyrUKu3+5S808zo7nq=XVApAxEu0Tm0g@mail.gmail.com> <CANn2QUy6V9QMbCRW=Y9VAPydY1AN0TsA7ZBFAFzfhUrnVnOyjg@mail.gmail.com> <CAHAreOpMnG-3WYbctW-po6RaB7xa0J-rncRN4dVq0urdtCiidg@mail.gmail.com> <CANn2QUx=1dXF+xCMiOEihJNoOaa6JLzi6yjoJZfwJ7TM4tctfg@mail.gmail.com> <CAHAreOodW_5=L+NeCBFCoJ4PcKwCyZRzmsBuksftp6jzDv+NxQ@mail.gmail.com> Message-ID: <CANn2QUyqmAsRhEonaV-YFOwS=b62SxpCLYeo-AKYif=iNrz_sw@mail.gmail.com> On Tue, Jul 29, 2014 at 2:34 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Tue, Jul 29, 2014 at 2:11 PM, Antonino Ingargiola <tritemio at gmail.com> > wrote: > >> def add_cursor(fig, ax): >> plt.close() >> > > Make sure you call close on the fig object, so you don't rely on the > implicit state management that pyplot does... > Right, thanks! Antonio -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140729/cd659a46/attachment.html> From bussonniermatthias at gmail.com Wed Jul 30 04:26:37 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 30 Jul 2014 10:26:37 +0200 Subject: [IPython-dev] [IPython-User] IPython Notebooks and Active Learning (Matthew Brett) In-Reply-To: <CAH6Pt5oU3nVgJt4uA6c3g0fXrAB5FW+bThm2bsXH8DDK-MZKAA@mail.gmail.com> References: <CAEX=yaaZ23V9cpBYdCMUnY8kttF_B4KNHfMPX9M99xr9+sytZw@mail.gmail.com> <CAH6Pt5oU3nVgJt4uA6c3g0fXrAB5FW+bThm2bsXH8DDK-MZKAA@mail.gmail.com> Message-ID: <CANJQusW5sYV=OmFgykyL8RO9uL3+bAfAtE_qMGo8jb=E3CuxYw@mail.gmail.com> If I may suggest too, please use header cell instead of hash in markdown. Header cell are used for section when converting to latex and do automatically generate anchors on nbviewer/html so that you can link to subpart: Example : http://nbviewer.ipython.org/url/jdj.mit.edu/~stevenj/IJulia%20Preview.ipynb#Multimedia-display-in-IJulia On Tue, Jul 29, 2014 at 11:16 PM, Matthew Brett <matthew.brett at gmail.com> wrote: > Hi, > > On Tue, Jul 29, 2014 at 4:50 PM, Mark Bakker <markbak at gmail.com> wrote: > > We have developed a series of 15 Notebooks for scientists and engineers > who > > want to use Python programming for exploratory computing, scipting, data > > analysis, and visualization. No prior knowledge of computer programming > is > > assumed. Each Notebook covers a specific topic and includes a number of > > exercises. The exercises should take less than 4 hours to complete for > each > > Notebook. > > > > We have developed these Notebooks for an undergraduate class > (sophomores) in > > Civil Engineering. A short survey of the students taking the class (~270 > of > > them) showed that the students really liked the class and learned a lot. > > > > The Notebooks may be viewed at > > http://mbakker7.github.io/exploratory_computing_with_python/ > > A link to the GitHub repository is also shown on this page. > > Thanks a lot for this. From our feedback, our students liked the > notebooks too - e.g. > > "I appreciate the downloadable iPython notebooks with explanations of > what the code is and does - will be a great reference" > > I think there's really no question that the notebooks make running > code examples easier and clearer for the teacher and the student. And > they are indeed a great reference. The question always is - what do > we want to teach? In some cases it's probably enough that the > students get the idea, and running / writing code in the notebooks > helps them get the idea. But the students also implicitly learn that > this is the standard way of working with code, and I personally don't > think we should be teaching that. So, for me at least, I am trying to > find a way to strike a balance between the ease of writing materials / > ease of getting students running code, and the need for teaching solid > working practice. For example, for the next iteration of our course, > I'm thinking of doing a flipped classroom format, with the tutorials > mostly in IPython notebooks, but doing the exercises in class using > text editor and terminal and git. I'd also like to try and teach the > IPython notebook as a great tool for sharing and explaining a > workflow, or developing a tutorial. > > Cheers, > > Matthew > _______________________________________________ > IPython-User mailing list > IPython-User at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-user > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/84ca2c87/attachment.html> From doug.blank at gmail.com Wed Jul 30 07:33:03 2014 From: doug.blank at gmail.com (Doug Blank) Date: Wed, 30 Jul 2014 07:33:03 -0400 Subject: [IPython-dev] [IPython-User] IPython Notebooks and Active Learning (Matthew Brett) In-Reply-To: <CANJQusW5sYV=OmFgykyL8RO9uL3+bAfAtE_qMGo8jb=E3CuxYw@mail.gmail.com> References: <CAEX=yaaZ23V9cpBYdCMUnY8kttF_B4KNHfMPX9M99xr9+sytZw@mail.gmail.com> <CAH6Pt5oU3nVgJt4uA6c3g0fXrAB5FW+bThm2bsXH8DDK-MZKAA@mail.gmail.com> <CANJQusW5sYV=OmFgykyL8RO9uL3+bAfAtE_qMGo8jb=E3CuxYw@mail.gmail.com> Message-ID: <CAAusYCiQ3WO0x56rzCd8r6y_YTMi5Q2qOQmOTOidp0wRX-HJ7g@mail.gmail.com> Excellent project! What is the license for these? It would be great if they were Creative Commons Share with Attribution, or similar: https://creativecommons.org/licenses/by-sa/4.0/ I can imagine using variations of these for a Physics curriculum. On Wed, Jul 30, 2014 at 4:26 AM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > If I may suggest too, please use header cell instead of hash in markdown. > Header cell are used for section when converting to latex and do > automatically generate anchors on nbviewer/html so that you can link to > subpart: > > Example : > > http://nbviewer.ipython.org/url/jdj.mit.edu/~stevenj/IJulia%20Preview.ipynb#Multimedia-display-in-IJulia > Being in the middle of writing similar notebooks, we found that using header cells can be quite painful when it comes to moving sections around. For example, if you want to move a section, one has to individually select, press up/down, for all cells in a section. So, we wrote "Move Section Up"/"Move Section Down" buttons and have included those in calico-document-tools. The tool will move all cells in a section/subsection up or down. You can install it: ipython install-nbextension https://bitbucket.org/ipre/calico/downloads/ calico-document-tools-1.0.zip You can then begin to use them in your notebooks by loading them dynamically: ``` %%javascript IPython.load_extensions("calico-document-tools"); ``` Or, if you want to load them always, put that line in your: $(ipython locate)/profile_default/static/custom/custom.js That collection of tools also contains: section numbering, table of contents, and a beta version of bibliographic support. -Doug > > > On Tue, Jul 29, 2014 at 11:16 PM, Matthew Brett <matthew.brett at gmail.com> > wrote: > >> Hi, >> >> On Tue, Jul 29, 2014 at 4:50 PM, Mark Bakker <markbak at gmail.com> wrote: >> > We have developed a series of 15 Notebooks for scientists and engineers >> who >> > want to use Python programming for exploratory computing, scipting, data >> > analysis, and visualization. No prior knowledge of computer programming >> is >> > assumed. Each Notebook covers a specific topic and includes a number of >> > exercises. The exercises should take less than 4 hours to complete for >> each >> > Notebook. >> > >> > We have developed these Notebooks for an undergraduate class >> (sophomores) in >> > Civil Engineering. A short survey of the students taking the class >> (~270 of >> > them) showed that the students really liked the class and learned a lot. >> > >> > The Notebooks may be viewed at >> > http://mbakker7.github.io/exploratory_computing_with_python/ >> > A link to the GitHub repository is also shown on this page. >> >> Thanks a lot for this. From our feedback, our students liked the >> notebooks too - e.g. >> >> "I appreciate the downloadable iPython notebooks with explanations of >> what the code is and does - will be a great reference" >> >> I think there's really no question that the notebooks make running >> code examples easier and clearer for the teacher and the student. And >> they are indeed a great reference. The question always is - what do >> we want to teach? In some cases it's probably enough that the >> students get the idea, and running / writing code in the notebooks >> helps them get the idea. But the students also implicitly learn that >> this is the standard way of working with code, and I personally don't >> think we should be teaching that. So, for me at least, I am trying to >> find a way to strike a balance between the ease of writing materials / >> ease of getting students running code, and the need for teaching solid >> working practice. For example, for the next iteration of our course, >> I'm thinking of doing a flipped classroom format, with the tutorials >> mostly in IPython notebooks, but doing the exercises in class using >> text editor and terminal and git. I'd also like to try and teach the >> IPython notebook as a great tool for sharing and explaining a >> workflow, or developing a tutorial. >> >> Cheers, >> >> Matthew >> _______________________________________________ >> IPython-User mailing list >> IPython-User at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-user >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/0fe0738d/attachment.html> From markbak at gmail.com Wed Jul 30 16:57:45 2014 From: markbak at gmail.com (Mark Bakker) Date: Wed, 30 Jul 2014 22:57:45 +0200 Subject: [IPython-dev] [IPython-User] IPython Notebooks and Active Learning (Matthew Brett) Message-ID: <CAEX=yaauchjKBw7fvEs3b-momjkdNsGVLJd=7jFB5K-amdRObw@mail.gmail.com> Thanks, Doug. Hope you find it useful. Just added the license to the website. And thanks for your pointers about moving header cells around. Will have to try out your tools. Definitely interested in the bibliographic support. Is there any other support around to handle bibliography stuff (I am thinking bibtex-like capabilities...). Keep me informed how your development goes, Mark From: Doug Blank <doug.blank at gmail.com> > > Excellent project! What is the license for these? It would be great if they > were Creative Commons Share with Attribution, or similar: > > https://creativecommons.org/licenses/by-sa/4.0/ > > I can imagine using variations of these for a Physics curriculum. > > On Wed, Jul 30, 2014 at 4:26 AM, Matthias Bussonnier < > bussonniermatthias at gmail.com> wrote: > > > If I may suggest too, please use header cell instead of hash in markdown. > > Header cell are used for section when converting to latex and do > > automatically generate anchors on nbviewer/html so that you can link to > > subpart: > > > > Example : > > > > > http://nbviewer.ipython.org/url/jdj.mit.edu/~stevenj/IJulia%20Preview.ipynb#Multimedia-display-in-IJulia > > > > Being in the middle of writing similar notebooks, we found that using > header cells can be quite painful when it comes to moving sections around. > For example, if you want to move a section, one has to individually select, > press up/down, for all cells in a section. > > So, we wrote "Move Section Up"/"Move Section Down" buttons and have > included those in calico-document-tools. The tool will move all cells in a > section/subsection up or down. You can install it: > > ipython install-nbextension https://bitbucket.org/ipre/calico/downloads/ > calico-document-tools-1.0.zip > > You can then begin to use them in your notebooks by loading them > dynamically: > > ``` > %%javascript > IPython.load_extensions("calico-document-tools"); > ``` > > Or, if you want to load them always, put that line in your: > > $(ipython locate)/profile_default/static/custom/custom.js > > That collection of tools also contains: section numbering, table of > contents, and a beta version of bibliographic support. > > -Doug > > > > > > > > On Tue, Jul 29, 2014 at 11:16 PM, Matthew Brett <matthew.brett at gmail.com > > > > wrote: > > > >> Hi, > >> > >> On Tue, Jul 29, 2014 at 4:50 PM, Mark Bakker <markbak at gmail.com> wrote: > >> > We have developed a series of 15 Notebooks for scientists and > engineers > >> who > >> > want to use Python programming for exploratory computing, scipting, > data > >> > analysis, and visualization. No prior knowledge of computer > programming > >> is > >> > assumed. Each Notebook covers a specific topic and includes a number > of > >> > exercises. The exercises should take less than 4 hours to complete for > >> each > >> > Notebook. > >> > > >> > We have developed these Notebooks for an undergraduate class > >> (sophomores) in > >> > Civil Engineering. A short survey of the students taking the class > >> (~270 of > >> > them) showed that the students really liked the class and learned a > lot. > >> > > >> > The Notebooks may be viewed at > >> > http://mbakker7.github.io/exploratory_computing_with_python/ > >> > A link to the GitHub repository is also shown on this page. > >> > >> Thanks a lot for this. From our feedback, our students liked the > >> notebooks too - e.g. > >> > >> "I appreciate the downloadable iPython notebooks with explanations of > >> what the code is and does - will be a great reference" > >> > >> I think there's really no question that the notebooks make running > >> code examples easier and clearer for the teacher and the student. And > >> they are indeed a great reference. The question always is - what do > >> we want to teach? In some cases it's probably enough that the > >> students get the idea, and running / writing code in the notebooks > >> helps them get the idea. But the students also implicitly learn that > >> this is the standard way of working with code, and I personally don't > >> think we should be teaching that. So, for me at least, I am trying to > >> find a way to strike a balance between the ease of writing materials / > >> ease of getting students running code, and the need for teaching solid > >> working practice. For example, for the next iteration of our course, > >> I'm thinking of doing a flipped classroom format, with the tutorials > >> mostly in IPython notebooks, but doing the exercises in class using > >> text editor and terminal and git. I'd also like to try and teach the > >> IPython notebook as a great tool for sharing and explaining a > >> workflow, or developing a tutorial. > >> > >> Cheers, > >> > >> Matthew > >> _______________________________________________ > >> IPython-User mailing list > >> IPython-User at scipy.org > >> http://mail.scipy.org/mailman/listinfo/ipython-user > >> > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > http://mail.scipy.org/pipermail/ipython-dev/attachments/20140730/0fe0738d/attachment-0001.html > > ------------------------------ > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > End of IPython-dev Digest, Vol 126, Issue 66 > ******************************************** > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/47e81511/attachment.html> From kikocorreoso at gmail.com Wed Jul 30 18:40:44 2014 From: kikocorreoso at gmail.com (Kiko) Date: Thu, 31 Jul 2014 00:40:44 +0200 Subject: [IPython-dev] Command line tool to publish a notebook on a wordpress blog In-Reply-To: <A7DE3E51-9907-46FC-8E05-596688B550FF@gmail.com> References: <CAB-sx61fgyw_6Auv46aX3UWBHHroA-Zv3ypQCbd2iSXBhtiAiw@mail.gmail.com> <A7DE3E51-9907-46FC-8E05-596688B550FF@gmail.com> Message-ID: <CAB-sx61chz-_fMv5bWxCAsAYqg3R14krZt16rQarYP8e1uZArQ@mail.gmail.com> 2014-07-29 11:00 GMT+02:00 Matthias Bussonnier <bussonniermatthias at gmail.com >: > Hi > Le 29 juil. 2014 ? 10:07, Kiko a ?crit : > > Hi all, > > I made a small script to publish a notebook directly on a wordpress blog. > The repo can be found here: > https://github.com/Pybonacci/ipy2wp > > It uses nbconvert to convert the notebook to html (maybe I should explore > a conversion to markdown instead of html). I use this to publish on > http://pybonacci.org and it works great with simple notebooks (I have to > check notebooks with more complex structure). It creates a draft on your > wordpress blog so you can check the post before publishing. > > Hi, Matthias. How can I change the basic template with a custom template? Is it possible? Should I use jinja2? markdown? Any thought about that will be very welcome. > > That's really nice, > > It is super agreeable to see people using it as a library and not using > subprocess ! > We've spent quite some time working on that so it make me glad to see > people using it ! > > You should add it to the Wiki on project using IPython/Jupyter ! > > -- > Matthias > > > If someone uses the script please provide some feedback to improve the > tool. If someone experience any problem, please, open an issue in the repo. > If someone has something similar and want to share it would be great to see > how others are solving that. > > If your wordpress blog is older than v 3.5 please check this link: > http://codex.wordpress.org/XML-RPC_Support > > Kind regards. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/8c670324/attachment.html> From kikocorreoso at gmail.com Wed Jul 30 18:44:54 2014 From: kikocorreoso at gmail.com (Kiko) Date: Thu, 31 Jul 2014 00:44:54 +0200 Subject: [IPython-dev] Command line tool to publish a notebook on a wordpress blog In-Reply-To: <CAAusYCjK5NPx9_r7sX_JfOrrUDOHKzC-ONBXWpDMGb=_8EjFmg@mail.gmail.com> References: <CAB-sx61fgyw_6Auv46aX3UWBHHroA-Zv3ypQCbd2iSXBhtiAiw@mail.gmail.com> <CAAusYCjK5NPx9_r7sX_JfOrrUDOHKzC-ONBXWpDMGb=_8EjFmg@mail.gmail.com> Message-ID: <CAB-sx60MAM8FR_KFSFBbX0WsAqY4Y9SV3tvwzjiTxF3VC6T5ug@mail.gmail.com> 2014-07-29 14:07 GMT+02:00 Doug Blank <doug.blank at gmail.com>: > On Tue, Jul 29, 2014 at 4:07 AM, Kiko <kikocorreoso at gmail.com> wrote: > >> Hi all, >> >> I made a small script to publish a notebook directly on a wordpress blog. >> The repo can be found here: >> https://github.com/Pybonacci/ipy2wp >> >> It uses nbconvert to convert the notebook to html (maybe I should explore >> a conversion to markdown instead of html). I use this to publish on >> http://pybonacci.org and it works great with simple notebooks (I have to >> check notebooks with more complex structure). It creates a draft on your >> wordpress blog so you can check the post before publishing. >> >> If someone uses the script please provide some feedback to improve the >> tool. If someone experience any problem, please, open an issue in the repo. >> If someone has something similar and want to share it would be great to see >> how others are solving that. >> >> If your wordpress blog is older than v 3.5 please check this link: >> http://codex.wordpress.org/XML-RPC_Support >> >> Kind regards. >> > > Very useful! > > Do you have any suggestions regarding how to get IPython's /static etc. > installed so that everything needed (eg, javascript) will load? > > Also, looks like some HTML is being injected into <script> areas (note the > <p> tag and >): > > <script> > ... > google.load('visualization', '1.0', {'callback': drawChart, > 'packages':['corechart']}); > });</p> > <p>// ]]></script></p> > > Well, wordpress change some html. One thing would be to use a plugin like 'raw html' or similar. But the basic idea of the tool would be to help in the publication of a notebook in a wordpress blog but some stuff are dependent of your wordpress install (javascript, iframes, code highlight,...). If someone have any ideas about how to improve it I'm all ears (eyes in this case) > Thanks for making this available! > > -Doug > > >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/79a695bf/attachment.html> From kikocorreoso at gmail.com Wed Jul 30 18:48:40 2014 From: kikocorreoso at gmail.com (Kiko) Date: Thu, 31 Jul 2014 00:48:40 +0200 Subject: [IPython-dev] Command line tool to publish a notebook on a wordpress blog In-Reply-To: <CAB-sx60MAM8FR_KFSFBbX0WsAqY4Y9SV3tvwzjiTxF3VC6T5ug@mail.gmail.com> References: <CAB-sx61fgyw_6Auv46aX3UWBHHroA-Zv3ypQCbd2iSXBhtiAiw@mail.gmail.com> <CAAusYCjK5NPx9_r7sX_JfOrrUDOHKzC-ONBXWpDMGb=_8EjFmg@mail.gmail.com> <CAB-sx60MAM8FR_KFSFBbX0WsAqY4Y9SV3tvwzjiTxF3VC6T5ug@mail.gmail.com> Message-ID: <CAB-sx627w8mHiNr-NzFGZxYxkZZr=Xv1SjO3NzDDDzLww6Ejug@mail.gmail.com> 2014-07-31 0:44 GMT+02:00 Kiko <kikocorreoso at gmail.com>: > > > > 2014-07-29 14:07 GMT+02:00 Doug Blank <doug.blank at gmail.com>: > > On Tue, Jul 29, 2014 at 4:07 AM, Kiko <kikocorreoso at gmail.com> wrote: >> >>> Hi all, >>> >>> I made a small script to publish a notebook directly on a wordpress >>> blog. The repo can be found here: >>> https://github.com/Pybonacci/ipy2wp >>> >>> It uses nbconvert to convert the notebook to html (maybe I should >>> explore a conversion to markdown instead of html). I use this to publish on >>> http://pybonacci.org and it works great with simple notebooks (I have >>> to check notebooks with more complex structure). It creates a draft on your >>> wordpress blog so you can check the post before publishing. >>> >>> If someone uses the script please provide some feedback to improve the >>> tool. If someone experience any problem, please, open an issue in the repo. >>> If someone has something similar and want to share it would be great to see >>> how others are solving that. >>> >>> If your wordpress blog is older than v 3.5 please check this link: >>> http://codex.wordpress.org/XML-RPC_Support >>> >>> Kind regards. >>> >> >> By the way, I changed some stuff and the inline images now are uploaded to your wordpress (wp-content/uploads) and then linked in the html uploaded. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/7e8040b6/attachment.html> From fperez.net at gmail.com Wed Jul 30 19:30:04 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 30 Jul 2014 16:30:04 -0700 Subject: [IPython-dev] [IPython-User] IPython Notebooks and Active Learning (Matthew Brett) In-Reply-To: <CAAusYCiQ3WO0x56rzCd8r6y_YTMi5Q2qOQmOTOidp0wRX-HJ7g@mail.gmail.com> References: <CAEX=yaaZ23V9cpBYdCMUnY8kttF_B4KNHfMPX9M99xr9+sytZw@mail.gmail.com> <CAH6Pt5oU3nVgJt4uA6c3g0fXrAB5FW+bThm2bsXH8DDK-MZKAA@mail.gmail.com> <CANJQusW5sYV=OmFgykyL8RO9uL3+bAfAtE_qMGo8jb=E3CuxYw@mail.gmail.com> <CAAusYCiQ3WO0x56rzCd8r6y_YTMi5Q2qOQmOTOidp0wRX-HJ7g@mail.gmail.com> Message-ID: <CAHAreOp9ar0zys+g9m6OOkYx2FTokK3LzUxffPzXcTFXPMzH2w@mail.gmail.com> On Wed, Jul 30, 2014 at 4:33 AM, Doug Blank <doug.blank at gmail.com> wrote: > Being in the middle of writing similar notebooks, we found that using > header cells can be quite painful when it comes to moving sections around. > For example, if you want to move a section, one has to individually select, > press up/down, for all cells in a section. That is really a big pain point in managing any kind of complex/long notebook. Paul Ivanov recently protoyped out a solution for this: https://github.com/ivanov/nb-cccp I've been using it and it works fairly well, even though it's not really production-ready yet. We in the core team are really trying to get 3.0 out the door, so I'm not sure how much bandwidth Paul will have for this in the coming weeks. But it would be a great tool to finish up, because it's *super* useful. If anyone can pitch in to help Paul out with this code, it would be a great contribution that would make everyone's life a lot easier... Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/d30b0127/attachment.html> From lstagner at uci.edu Wed Jul 30 20:29:41 2014 From: lstagner at uci.edu (Luke Stagner) Date: Wed, 30 Jul 2014 17:29:41 -0700 Subject: [IPython-dev] IDL/GDL kernel Message-ID: <53D98DF5.7000100@uci.edu> Hello All, I am a graduate student studying plasma physics. I have made a mostly functional IDL/GDL(just GDL for now) kernel <https://github.com/lstagner/idl_kernel> using the new wrapper kernel feature. I borrowed heavily from the bash_kernel <https://github.com/takluyver/bash_kernel> example. If it is not too much trouble I need some help with two things. 1. IPython doesn't kill GDL process when shutting down or restarting the kernel. I have defined the do_shutdown <https://github.com/lstagner/idl_kernel/blob/master/gdl_kernel.py#L130> to kill the process but that doesn't seem to do anything. 2. Inline Plots: My current method <https://github.com/lstagner/idl_kernel/blob/master/gdl_kernel.py#L91> is to have GDL make pngs of the plots and then publishing them. Unfortunately this is not working and I am not sure why. Plasma physics is very much stuck using IDL because of all the legacy software. My hope is that this kernel will act as a gateway drug towards more open programming languages. When IPython 3/Jupyter comes out I am going to try to convince the computer staff at the DIII-D National Ignition Facility to install the multi-user notebook server with many different kernels installed. Thanks for your time -Luke Stagner -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/15a93f2b/attachment.html> From mmckerns at caltech.edu Wed Jul 30 20:40:31 2014 From: mmckerns at caltech.edu (Michael McKerns) Date: Wed, 30 Jul 2014 20:40:31 -0400 (EDT) Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <53D98DF5.7000100@uci.edu> References: <53D98DF5.7000100@uci.edu> Message-ID: <59944.67.186.183.87.1406767231.squirrel@webmail.caltech.edu> Luke, I know it's not what you are asking? but just to throw this into the mix. you might be able to bridge some gaps with one of my old packages, pyIDL. I'm just putting it out there in case you haven't come across it. It's unmaintained, but was fairly feature complete a few years back. I just stopped using IDL. https://pypi.python.org/pypi/pyIDL/ http://www.cacr.caltech.edu/~mmckerns/pyIDL.html http://sourceforge.net/projects/pyidl/ I'm guessing that you could see what I did to stop the IDL processes in my IDL bindings, and maybe then leverage that. > Hello All, > > I am a graduate student studying plasma physics. I have made a mostly > functional IDL/GDL(just GDL for now) kernel > <https://github.com/lstagner/idl_kernel> using the new wrapper kernel > feature. I borrowed heavily from the bash_kernel > <https://github.com/takluyver/bash_kernel> example. If it is not too > much trouble I need some help with two things. > > 1. IPython doesn't kill GDL process when shutting down or restarting the > kernel. I have defined the do_shutdown > <https://github.com/lstagner/idl_kernel/blob/master/gdl_kernel.py#L130> > to kill the process but that doesn't seem to do anything. > 2. Inline Plots: My current method > <https://github.com/lstagner/idl_kernel/blob/master/gdl_kernel.py#L91> > is to have GDL make pngs of the plots and then publishing them. > Unfortunately this is not working and I am not sure why. > > Plasma physics is very much stuck using IDL because of all the legacy > software. My hope is that this kernel will act as a gateway drug towards > more open programming languages. When IPython 3/Jupyter comes out I am > going to try to convince the computer staff at the DIII-D National > Ignition Facility to install the multi-user notebook server with many > different kernels installed. > > Thanks for your time > > -Luke Stagner > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > --- Mike McKerns California Institute of Technology http://www.its.caltech.edu/~mmckerns From doug.blank at gmail.com Wed Jul 30 20:42:11 2014 From: doug.blank at gmail.com (Doug Blank) Date: Wed, 30 Jul 2014 20:42:11 -0400 Subject: [IPython-dev] [IPython-User] IPython Notebooks and Active Learning (Matthew Brett) In-Reply-To: <CAHAreOp9ar0zys+g9m6OOkYx2FTokK3LzUxffPzXcTFXPMzH2w@mail.gmail.com> References: <CAEX=yaaZ23V9cpBYdCMUnY8kttF_B4KNHfMPX9M99xr9+sytZw@mail.gmail.com> <CAH6Pt5oU3nVgJt4uA6c3g0fXrAB5FW+bThm2bsXH8DDK-MZKAA@mail.gmail.com> <CANJQusW5sYV=OmFgykyL8RO9uL3+bAfAtE_qMGo8jb=E3CuxYw@mail.gmail.com> <CAAusYCiQ3WO0x56rzCd8r6y_YTMi5Q2qOQmOTOidp0wRX-HJ7g@mail.gmail.com> <CAHAreOp9ar0zys+g9m6OOkYx2FTokK3LzUxffPzXcTFXPMzH2w@mail.gmail.com> Message-ID: <CAAusYChOStaxSUYBL51qOxE52gfX_93p+rikyJ+hgOcmC4VF7Q@mail.gmail.com> On Wed, Jul 30, 2014 at 7:30 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Wed, Jul 30, 2014 at 4:33 AM, Doug Blank <doug.blank at gmail.com> wrote: > >> Being in the middle of writing similar notebooks, we found that using >> header cells can be quite painful when it comes to moving sections around. >> For example, if you want to move a section, one has to individually select, >> press up/down, for all cells in a section. > > > That is really a big pain point in managing any kind of complex/long > notebook. Paul Ivanov recently protoyped out a solution for this: > > https://github.com/ivanov/nb-cccp > > I've been using it and it works fairly well, even though it's not really > production-ready yet. We in the core team are really trying to get 3.0 out > the door, so I'm not sure how much bandwidth Paul will have for this in the > coming weeks. But it would be a great tool to finish up, because it's > *super* useful. > > If anyone can pitch in to help Paul out with this code, it would be a > great contribution that would make everyone's life a lot easier... > Yes, many problems can be solved by being able to select multiple cells, and operate on them. One should be able to make many of the operations that can work on a selected cell to work on a set of selected cells. This extension is really only a temporary workaround for that kind of functionality. And, once there is a method to select multiple cells, it would be really handy to be able to drag and drop those cells where you want them. But, I am really looking forward to a server-based Jupyter setup, with selectable kernels, so I don't want to distract from the big picture :) With the set of extension tools we have now, we are confident that this will work well for a writing course this fall. -Doug > > Cheers > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/6742363c/attachment.html> From takowl at gmail.com Wed Jul 30 20:54:42 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 30 Jul 2014 17:54:42 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <53D98DF5.7000100@uci.edu> References: <53D98DF5.7000100@uci.edu> Message-ID: <CAOvn4qg=ez5eydhB1-e1koaJNEO1djSbyVwcKcaL1dXi4rg7vw@mail.gmail.com> Hi Luke, On 30 July 2014 17:29, Luke Stagner <lstagner at uci.edu> wrote: > I am a graduate student studying plasma physics. I have made a mostly > functional IDL/GDL(just GDL for now) kernel > <https://github.com/lstagner/idl_kernel> using the new wrapper kernel > feature. I borrowed heavily from the bash_kernel > <https://github.com/takluyver/bash_kernel> example. If it is not too much > trouble I need some help with two things. > Cool, I'm glad to hear that the API and the example are useful. > 1. IPython doesn't kill GDL process when shutting down or restarting the > kernel. I have defined the do_shutdown > <https://github.com/lstagner/idl_kernel/blob/master/gdl_kernel.py#L130> > to kill the process but that doesn't seem to do anything. > That's strange. I've just tried with my bash kernel, which doesn't implement do_shutdown at all, and it does stop the process correctly (the server stops the wrapper process, and that automatically causes the child process to die). I don't know exactly what could be interfering with that, but I'll keep thinking. > 2. Inline Plots: My current method > <https://github.com/lstagner/idl_kernel/blob/master/gdl_kernel.py#L91> is > to have GDL make pngs of the plots and then publishing them. Unfortunately > this is not working and I am not sure why. > It should work. Looking at your code, you should switch back to the commented out line that opens and reads the image files, rather than displaying the filenames. If you comment out the rmtree(plot_dir) line, are the images being written as you expect? Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/0ed4b32f/attachment.html> From fperez.net at gmail.com Wed Jul 30 21:20:03 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 30 Jul 2014 18:20:03 -0700 Subject: [IPython-dev] [IPython-User] IPython Notebooks and Active Learning (Matthew Brett) In-Reply-To: <CAAusYChOStaxSUYBL51qOxE52gfX_93p+rikyJ+hgOcmC4VF7Q@mail.gmail.com> References: <CAEX=yaaZ23V9cpBYdCMUnY8kttF_B4KNHfMPX9M99xr9+sytZw@mail.gmail.com> <CAH6Pt5oU3nVgJt4uA6c3g0fXrAB5FW+bThm2bsXH8DDK-MZKAA@mail.gmail.com> <CANJQusW5sYV=OmFgykyL8RO9uL3+bAfAtE_qMGo8jb=E3CuxYw@mail.gmail.com> <CAAusYCiQ3WO0x56rzCd8r6y_YTMi5Q2qOQmOTOidp0wRX-HJ7g@mail.gmail.com> <CAHAreOp9ar0zys+g9m6OOkYx2FTokK3LzUxffPzXcTFXPMzH2w@mail.gmail.com> <CAAusYChOStaxSUYBL51qOxE52gfX_93p+rikyJ+hgOcmC4VF7Q@mail.gmail.com> Message-ID: <CAHAreOouW3mMdMDti+G2n-eSE3ZyBWYbJbsrVjpZ01id07EJyA@mail.gmail.com> On Wed, Jul 30, 2014 at 5:42 PM, Doug Blank <doug.blank at gmail.com> wrote: > Yes, many problems can be solved by being able to select multiple cells, > and operate on them. One should be able to make many of the operations that > can work on a selected cell to work on a set of selected cells. This > extension is really only a temporary workaround for that kind of > functionality. > > And, once there is a method to select multiple cells, it would be really > handy to be able to drag and drop those cells where you want them. > Yup, ultimately that's the UI work that needs to be done. > > But, I am really looking forward to a server-based Jupyter setup, with > selectable kernels, so I don't want to distract from the big picture :) > With the set of extension tools we have now, we are confident that this > will work well for a writing course this fall. > Thanks for your patience, and kudos on the great work you've been doing on your side! Cheers, f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/7ef6b361/attachment.html> From lstagner at uci.edu Wed Jul 30 21:32:13 2014 From: lstagner at uci.edu (Luke Stagner) Date: Wed, 30 Jul 2014 18:32:13 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> Message-ID: <53D99C9D.4070900@uci.edu> Thomas, I am glad I am not the only one stumped by this. I have done what you have suggested and I verified that it is producing the .png files. If I were to hazard a guess I would say that publish_display_data is not connecting to the notebook. -Luke On 07/30/2014 05:41 PM, ipython-dev-request at scipy.org wrote: > ------------------------------ > > Message: 6 > Date: Wed, 30 Jul 2014 17:54:42 -0700 > From: Thomas Kluyver<takowl at gmail.com> > Subject: Re: [IPython-dev] IDL/GDL kernel > To: IPython developers list<ipython-dev at scipy.org> > Message-ID: > <CAOvn4qg=ez5eydhB1-e1koaJNEO1djSbyVwcKcaL1dXi4rg7vw at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > Hi Luke, > > On 30 July 2014 17:29, Luke Stagner<lstagner at uci.edu> wrote: > >> >I am a graduate student studying plasma physics. I have made a mostly >> >functional IDL/GDL(just GDL for now) kernel >> ><https://github.com/lstagner/idl_kernel> using the new wrapper kernel >> >feature. I borrowed heavily from the bash_kernel >> ><https://github.com/takluyver/bash_kernel> example. If it is not too much >> >trouble I need some help with two things. >> > > Cool, I'm glad to hear that the API and the example are useful. > > >> > 1. IPython doesn't kill GDL process when shutting down or restarting the >> >kernel. I have defined the do_shutdown >> ><https://github.com/lstagner/idl_kernel/blob/master/gdl_kernel.py#L130> >> >to kill the process but that doesn't seem to do anything. >> > > That's strange. I've just tried with my bash kernel, which doesn't > implement do_shutdown at all, and it does stop the process correctly (the > server stops the wrapper process, and that automatically causes the child > process to die). I don't know exactly what could be interfering with that, > but I'll keep thinking. > > >> >2. Inline Plots: My current method >> ><https://github.com/lstagner/idl_kernel/blob/master/gdl_kernel.py#L91> is >> >to have GDL make pngs of the plots and then publishing them. Unfortunately >> >this is not working and I am not sure why. >> > > It should work. Looking at your code, you should switch back to the > commented out line that opens and reads the image files, rather than > displaying the filenames. If you comment out the rmtree(plot_dir) line, are > the images being written as you expect? > > Thomas > -------------- next part -------------- > An HTML attachment was scrubbed... > URL:http://mail.scipy.org/pipermail/ipython-dev/attachments/20140730/0ed4b32f/attachment.html > > ------------------------------ From takowl at gmail.com Wed Jul 30 22:30:18 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 30 Jul 2014 19:30:18 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <53D99C9D.4070900@uci.edu> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> Message-ID: <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> On 30 July 2014 18:32, Luke Stagner <lstagner at uci.edu> wrote: > I have done what you have suggested and I verified that it is producing > the .png files. If I were to hazard a guess I would say that > publish_display_data is not connecting to the notebook. > Ah, digging into the code, you're right. publish_display_data depends on the IPython shell machinery, which is not being spun up for non-IPython kernels. You should be able to do it like this: self.send_response(self.iopub_socket, 'display_data', {'image/png': data}) Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/4d1599ca/attachment.html> From takowl at gmail.com Wed Jul 30 22:47:13 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 30 Jul 2014 19:47:13 -0700 Subject: [IPython-dev] Public-domain browser terminal interface In-Reply-To: <CACLE5GBfDfV4aZMtErwMXNYORUMfmtqft0zOiYwu=DaUPGLbgQ@mail.gmail.com> References: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> <CACLE5GCsu1p5ZSP+rpKhY+DawSy4-5m76naujQMNOjYbO3MnVg@mail.gmail.com> <CAHAreOrsYkyficMxW5b-qQQLEVcgJNO5=FdfhL-PDpGR+qUKhg@mail.gmail.com> <CACLE5GBfDfV4aZMtErwMXNYORUMfmtqft0zOiYwu=DaUPGLbgQ@mail.gmail.com> Message-ID: <CAOvn4qjGazD7PQXanHq33pssGNMeCbNA6Y7K9hjfJtmzEyKpFQ@mail.gmail.com> The author of GraphTerm has just contacted me to say that he's pulled out the plain web terminal component - a combination of frontend stuff from term.js and updated Python code on the backend (so we don't have to handle more JS than we have to). It's BSD licensed, based on Tornado, uses websockets and appears to support Python 3, and Dr. Saravanan says he'd be happy to help us integrate it into IPython. https://github.com/mitotic/pyxterm Thomas On 8 July 2014 13:42, William Stein <wstein at gmail.com> wrote: > On Tue, Jul 8, 2014 at 1:31 PM, Fernando Perez <fperez.net at gmail.com> > wrote: > > > > On Tue, Jul 8, 2014 at 3:26 PM, William Stein <wstein at gmail.com> wrote: > >> > >> What about term.js? It's MIT licensed (partly due to me asking > >> nicely), and is what many online IDE projects (including > >> SageMathCloud) use: > >> > >> https://github.com/chjj/term.js/ > > > > > > Thanks, that's the link I had in mind!! > > > >> > >> Maybe it isn't an option for you because the backend is Node.js > >> instead of Python. I just wanted to double check, just in case. > > > > > > Not a problem at all. We're thinking of this for the multiuser server, > which > > has a Node component as well, so it's perfect. > > > > We might take you up on your 'pile of code' offer later, but we'll let > you > > know if we have the bandwidth for it. To start with, we'll probably be OK > > with the plain vanilla code as-is. > > > > Thanks again! > > One particular thing I added was resizing the backend pty in response > to changing the terminal size. This involved a little bit of new > tricky node.js code. > It works in node 0.8.x, but didn't work _last time I tried_ with Node > 0.10.x, which is why all SageMathCloud projects are still running > 0.8.x. > > Anyway, if you guys go with term.js you'll inevitably run into the > same issue, so keep me posted. > > -- W/illiam > > > > > f > > > > > > -- > > Fernando Perez (@fperez_org; http://fperez.org) > > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > > fernando.perez-at-berkeley: contact me here for any direct mail > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > > -- > William Stein > Professor of Mathematics > University of Washington > http://wstein.org > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/c63282b5/attachment.html> From ellisonbg at gmail.com Wed Jul 30 22:50:52 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Wed, 30 Jul 2014 19:50:52 -0700 Subject: [IPython-dev] Public-domain browser terminal interface In-Reply-To: <CAOvn4qjGazD7PQXanHq33pssGNMeCbNA6Y7K9hjfJtmzEyKpFQ@mail.gmail.com> References: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> <CACLE5GCsu1p5ZSP+rpKhY+DawSy4-5m76naujQMNOjYbO3MnVg@mail.gmail.com> <CAHAreOrsYkyficMxW5b-qQQLEVcgJNO5=FdfhL-PDpGR+qUKhg@mail.gmail.com> <CACLE5GBfDfV4aZMtErwMXNYORUMfmtqft0zOiYwu=DaUPGLbgQ@mail.gmail.com> <CAOvn4qjGazD7PQXanHq33pssGNMeCbNA6Y7K9hjfJtmzEyKpFQ@mail.gmail.com> Message-ID: <CAH4pYpTOw3+HCTv7w3hGPz-Wc+k1BSskdYdXNVDg1c0O9T-X5Q@mail.gmail.com> Yes, that is really great! That will make it much easier to offer the terminal in contexts where node.js isn't in the backend. Fantastic! On Wed, Jul 30, 2014 at 7:47 PM, Thomas Kluyver <takowl at gmail.com> wrote: > The author of GraphTerm has just contacted me to say that he's pulled out > the plain web terminal component - a combination of frontend stuff from > term.js and updated Python code on the backend (so we don't have to handle > more JS than we have to). It's BSD licensed, based on Tornado, uses > websockets and appears to support Python 3, and Dr. Saravanan says he'd be > happy to help us integrate it into IPython. > > https://github.com/mitotic/pyxterm > > Thomas > > > On 8 July 2014 13:42, William Stein <wstein at gmail.com> wrote: >> >> On Tue, Jul 8, 2014 at 1:31 PM, Fernando Perez <fperez.net at gmail.com> >> wrote: >> > >> > On Tue, Jul 8, 2014 at 3:26 PM, William Stein <wstein at gmail.com> wrote: >> >> >> >> What about term.js? It's MIT licensed (partly due to me asking >> >> nicely), and is what many online IDE projects (including >> >> SageMathCloud) use: >> >> >> >> https://github.com/chjj/term.js/ >> > >> > >> > Thanks, that's the link I had in mind!! >> > >> >> >> >> Maybe it isn't an option for you because the backend is Node.js >> >> instead of Python. I just wanted to double check, just in case. >> > >> > >> > Not a problem at all. We're thinking of this for the multiuser server, >> > which >> > has a Node component as well, so it's perfect. >> > >> > We might take you up on your 'pile of code' offer later, but we'll let >> > you >> > know if we have the bandwidth for it. To start with, we'll probably be >> > OK >> > with the plain vanilla code as-is. >> > >> > Thanks again! >> >> One particular thing I added was resizing the backend pty in response >> to changing the terminal size. This involved a little bit of new >> tricky node.js code. >> It works in node 0.8.x, but didn't work _last time I tried_ with Node >> 0.10.x, which is why all SageMathCloud projects are still running >> 0.8.x. >> >> Anyway, if you guys go with term.js you'll inevitably run into the >> same issue, so keep me posted. >> >> -- W/illiam >> >> > >> > f >> > >> > >> > -- >> > Fernando Perez (@fperez_org; http://fperez.org) >> > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> > fernando.perez-at-berkeley: contact me here for any direct mail >> > >> > _______________________________________________ >> > IPython-dev mailing list >> > IPython-dev at scipy.org >> > http://mail.scipy.org/mailman/listinfo/ipython-dev >> > >> >> >> >> -- >> William Stein >> Professor of Mathematics >> University of Washington >> http://wstein.org >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From fperez.net at gmail.com Wed Jul 30 23:10:53 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 30 Jul 2014 20:10:53 -0700 Subject: [IPython-dev] Public-domain browser terminal interface In-Reply-To: <CAH4pYpTOw3+HCTv7w3hGPz-Wc+k1BSskdYdXNVDg1c0O9T-X5Q@mail.gmail.com> References: <CAOvn4qjCN0p+qS--n5uf34-UBi48tGZZ5_7t5KaHHXpXWowGvw@mail.gmail.com> <CACLE5GCsu1p5ZSP+rpKhY+DawSy4-5m76naujQMNOjYbO3MnVg@mail.gmail.com> <CAHAreOrsYkyficMxW5b-qQQLEVcgJNO5=FdfhL-PDpGR+qUKhg@mail.gmail.com> <CACLE5GBfDfV4aZMtErwMXNYORUMfmtqft0zOiYwu=DaUPGLbgQ@mail.gmail.com> <CAOvn4qjGazD7PQXanHq33pssGNMeCbNA6Y7K9hjfJtmzEyKpFQ@mail.gmail.com> <CAH4pYpTOw3+HCTv7w3hGPz-Wc+k1BSskdYdXNVDg1c0O9T-X5Q@mail.gmail.com> Message-ID: <CAHAreOqhj=sqQFR_5nOSydiAu=nsg1SG0gK7JGkYfuWC6UdRjA@mail.gmail.com> On Wed, Jul 30, 2014 at 7:50 PM, Brian Granger <ellisonbg at gmail.com> wrote: > Yes, that is really great! That will make it much easier to offer the > terminal in contexts where node.js isn't in the backend. Fantastic! > +lots!! Very happy to hear this, thanks Thomas for following up... -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/cf63d723/attachment.html> From lstagner at uci.edu Wed Jul 30 23:27:28 2014 From: lstagner at uci.edu (Luke Stagner) Date: Wed, 30 Jul 2014 20:27:28 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> Message-ID: <53D9B7A0.5050309@uci.edu> Hmm, that didn't seem to work. I now get the following error <http://0bin.net/paste/BDU0f44gGw+PeZNa#zty1WLi79r-Tbzt2hoRGVWdg00fskTIDiam3U2X7D3A> with the following revision <https://github.com/lstagner/idl_kernel/commit/31b4f03b82db38a582aea264451cdaa3da8d2373>. I must be doing something wrong. -Luke On 07/30/2014 07:30 PM, Thomas Kluyver wrote: > On 30 July 2014 18:32, Luke Stagner <lstagner at uci.edu > <mailto:lstagner at uci.edu>> wrote: > > I have done what you have suggested and I verified that it is > producing > the .png files. If I were to hazard a guess I would say that > publish_display_data is not connecting to the notebook. > > > Ah, digging into the code, you're right. publish_display_data depends > on the IPython shell machinery, which is not being spun up for > non-IPython kernels. > > You should be able to do it like this: > self.send_response(self.iopub_socket, 'display_data', {'image/png': data}) > > Thomas > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/56b6d4eb/attachment.html> From takowl at gmail.com Wed Jul 30 23:40:35 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 30 Jul 2014 20:40:35 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <53D9B7A0.5050309@uci.edu> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> <53D9B7A0.5050309@uci.edu> Message-ID: <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> On 30 July 2014 20:27, Luke Stagner <lstagner at uci.edu> wrote: > Hmm, that didn't seem to work. I now get the following error > <http://0bin.net/paste/BDU0f44gGw+PeZNa#zty1WLi79r-Tbzt2hoRGVWdg00fskTIDiam3U2X7D3A> > with the following revision > <https://github.com/lstagner/idl_kernel/commit/31b4f03b82db38a582aea264451cdaa3da8d2373>. > I must be doing something wrong. > Oh yes, using that lower level interface, you'll need to base64 encode the data yourself. JSON can only handle text, not arbitrary bytes. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/8b201b15/attachment.html> From lstagner at uci.edu Thu Jul 31 00:04:45 2014 From: lstagner at uci.edu (Luke Stagner) Date: Wed, 30 Jul 2014 21:04:45 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> <53D9B7A0.5050309@uci.edu> <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> Message-ID: <53D9C05D.1030204@uci.edu> Good news no more error. Bad news still no inline plot. I even set it so that it reads some random png I have every time and still no go. Luke On 07/30/2014 08:40 PM, Thomas Kluyver wrote: > On 30 July 2014 20:27, Luke Stagner <lstagner at uci.edu > <mailto:lstagner at uci.edu>> wrote: > > Hmm, that didn't seem to work. I now get the following error > <http://0bin.net/paste/BDU0f44gGw+PeZNa#zty1WLi79r-Tbzt2hoRGVWdg00fskTIDiam3U2X7D3A> > with the following revision > <https://github.com/lstagner/idl_kernel/commit/31b4f03b82db38a582aea264451cdaa3da8d2373>. > I must be doing something wrong. > > > Oh yes, using that lower level interface, you'll need to base64 encode > the data yourself. JSON can only handle text, not arbitrary bytes. > > Thomas > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/69edaf02/attachment.html> From lstagner at uci.edu Thu Jul 31 02:52:10 2014 From: lstagner at uci.edu (Luke Stagner) Date: Wed, 30 Jul 2014 23:52:10 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> <53D9B7A0.5050309@uci.edu> <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> Message-ID: <53D9E79A.1070603@uci.edu> In regards to the kernel not shutting down the GDL process. It seems that kernel.do_shutdown is not being overridden by GDLKernel.do_shutdown. To check this I threw in an assert that will fail if GDLKernel.do_shutdown gets called. Suffice to say that assert is never thrown. -Luke On 07/30/2014 08:40 PM, Thomas Kluyver wrote: > On 30 July 2014 20:27, Luke Stagner <lstagner at uci.edu > <mailto:lstagner at uci.edu>> wrote: > > Hmm, that didn't seem to work. I now get the following error > <http://0bin.net/paste/BDU0f44gGw+PeZNa#zty1WLi79r-Tbzt2hoRGVWdg00fskTIDiam3U2X7D3A> > with the following revision > <https://github.com/lstagner/idl_kernel/commit/31b4f03b82db38a582aea264451cdaa3da8d2373>. > I must be doing something wrong. > > > Oh yes, using that lower level interface, you'll need to base64 encode > the data yourself. JSON can only handle text, not arbitrary bytes. > > Thomas > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140730/22fa7f10/attachment.html> From p.f.moore at gmail.com Thu Jul 31 03:00:38 2014 From: p.f.moore at gmail.com (Paul Moore) Date: Thu, 31 Jul 2014 08:00:38 +0100 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <53D9E79A.1070603@uci.edu> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> <53D9B7A0.5050309@uci.edu> <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> <53D9E79A.1070603@uci.edu> Message-ID: <CACac1F-Wm9QQoec=DE+ycKnWjZFaJ6353WDhRiFNCmsTR6=jfQ@mail.gmail.com> On 31 July 2014 07:52, Luke Stagner <lstagner at uci.edu> wrote: > In regards to the kernel not shutting down the GDL process. It seems that > kernel.do_shutdown is not being overridden by GDLKernel.do_shutdown. To > check this I threw in an assert that will fail if GDLKernel.do_shutdown gets > called. Suffice to say that assert is never thrown. >From visual inspection, it appears to me that do_shutdown is indented too far, making it a local function of do_execute, rather than a method of the class. Paul From lstagner at uci.edu Thu Jul 31 03:07:05 2014 From: lstagner at uci.edu (Luke Stagner) Date: Thu, 31 Jul 2014 00:07:05 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <CACac1F-Wm9QQoec=DE+ycKnWjZFaJ6353WDhRiFNCmsTR6=jfQ@mail.gmail.com> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> <53D9B7A0.5050309@uci.edu> <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> <53D9E79A.1070603@uci.edu> <CACac1F-Wm9QQoec=DE+ycKnWjZFaJ6353WDhRiFNCmsTR6=jfQ@mail.gmail.com> Message-ID: <53D9EB19.70104@uci.edu> I always suspected that I had no idea what I was doing. Its nice to finally have proof. On 07/31/2014 12:00 AM, Paul Moore wrote: > On 31 July 2014 07:52, Luke Stagner <lstagner at uci.edu> wrote: >> In regards to the kernel not shutting down the GDL process. It seems that >> kernel.do_shutdown is not being overridden by GDLKernel.do_shutdown. To >> check this I threw in an assert that will fail if GDLKernel.do_shutdown gets >> called. Suffice to say that assert is never thrown. > >From visual inspection, it appears to me that do_shutdown is indented > too far, making it a local function of do_execute, rather than a > method of the class. > > Paul > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From ingolf.becker at googlemail.com Thu Jul 31 06:18:42 2014 From: ingolf.becker at googlemail.com (Ingolf Becker) Date: Thu, 31 Jul 2014 11:18:42 +0100 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> Message-ID: <CAPET0yw=L2NiaD06VrCR+W0L_YF8O8S0x4ad6OEux+4CnxtHfQ@mail.gmail.com> Dear Mark very nice notebooks! I particularl On 29 July 2014 21:56, Mark Bakker <markbak at gmail.com> wrote: > We have developed a series of 15 Notebooks for scientists and engineers > who want to use Python programming for exploratory computing, scipting, > data analysis, and visualization.The Notebooks were developed for an > undergraduate class (sophomores) in Civil Engineering. No prior knowledge > of computer programming is assumed. Each Notebook covers a specific topic > and includes a number of exercises. The exercises should take less than 4 > hours to complete for each Notebook. > > The Notebooks may be viewed at > http://mbakker7.github.io/exploratory_computing_with_python/ > A link to the GitHub repository is also shown on this page. > > Hope you find them useful, > > Mark Bakker > TU Delft, The Netherlands > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/9f821bd6/attachment.html> From ingolf.becker at googlemail.com Thu Jul 31 06:25:08 2014 From: ingolf.becker at googlemail.com (Ingolf Becker) Date: Thu, 31 Jul 2014 11:25:08 +0100 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CAPET0yw=L2NiaD06VrCR+W0L_YF8O8S0x4ad6OEux+4CnxtHfQ@mail.gmail.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> <CAPET0yw=L2NiaD06VrCR+W0L_YF8O8S0x4ad6OEux+4CnxtHfQ@mail.gmail.com> Message-ID: <CAPET0yxrYe0cy-DE9+-UTR0ky9zAndDsxsn8XkiRH+_V5ScP9w@mail.gmail.com> Sorry about that - I particularly like the notebooks on water management and the time series analysis. Just a remark though: I would avoid using %pylab inline - it has some hideous side effects [1] (and there was talk of it being removed entirely in future versions) `%matplotlib inline from matplotlib import pyplot as plt` should be preferred. [1] https://carreau.github.io/posts/10-No-PyLab-Thanks.ipynb.html Thank you for sharing! On 31 July 2014 11:18, Ingolf Becker <ingolf.becker at googlemail.com> wrote: > Dear Mark > > very nice notebooks! I particularl > > > On 29 July 2014 21:56, Mark Bakker <markbak at gmail.com> wrote: > >> We have developed a series of 15 Notebooks for scientists and engineers >> who want to use Python programming for exploratory computing, scipting, >> data analysis, and visualization.The Notebooks were developed for an >> undergraduate class (sophomores) in Civil Engineering. No prior >> knowledge of computer programming is assumed. Each Notebook covers a >> specific topic and includes a number of exercises. The exercises should >> take less than 4 hours to complete for each Notebook. >> >> The Notebooks may be viewed at >> http://mbakker7.github.io/exploratory_computing_with_python/ >> A link to the GitHub repository is also shown on this page. >> >> Hope you find them useful, >> >> Mark Bakker >> TU Delft, The Netherlands >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/4ff463eb/attachment.html> From gelonida at gmail.com Thu Jul 31 07:30:31 2014 From: gelonida at gmail.com (Gelonida) Date: Thu, 31 Jul 2014 13:30:31 +0200 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> Message-ID: <53DA28D7.3040404@gmail.com> Hi Mark, Small suggestion to add some clarifying information to your link. On 7/29/2014 10:56 PM, Mark Bakker wrote: > We have developed a series of 15 Notebooks for scientists and > engineers who want to use Python programming for exploratory > computing, scipting, data analysis, and visualization.The Notebooks > were developed for an undergraduate class (sophomores) in Civil > Engineering. No prior knowledge of computer programming is assumed. > Each Notebook covers a specific topic and includes a number of > exercises. The exercises should take less than 4 hours to complete for > each Notebook. > > The Notebooks may be viewed at > http://mbakker7.github.io/exploratory_computing_with_python/ > A link to the GitHub repository is also shown on this page. > These links look interesting and I know a few persons who might enjoy learning a little about python this way. However as a notebook newbie (I only used ipython as interactive shell so far and did not read more about notebooks) I am a little confused. The web page seems to be aimed at newbies. It gives the impression, that I just have to go to http://mbakker7.github.io/exploratory_computing_with_python/ and then to click on notebook 1 ( http://nbviewer.ipython.org/github/mbakker7/exploratory_computing_with_python/blob/master/notebook1/py_exploratory_comp_1_sol.ipynb ) and that I could then change the contents of the input field, press shift-enter and then see the new result. But it seems, that this is just a static version of the ipython notebook. Only when - downloading the file - installing all package dependencies (IMHO very difficult for python newbies at least on windows) , - starting a cmd window - and running C:\Python27\Scripts\ipython notebook <notenookfile> I was able to use the notebook as described. I assume, that with above procedure you'd loose about 99% of the newbies who could have been interested in trying out python/notebooks. Wouldn't it be possible to add a more explicit link which mentions at least, that the notebooks cannot be executed immediately or even better a link to a page trying to explain (even if not aimed for newbies) how to use/install ipython/notebooks? _ _ -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/1ed30c98/attachment.html> From gvwilson at third-bit.com Thu Jul 31 13:56:47 2014 From: gvwilson at third-bit.com (Greg Wilson) Date: Thu, 31 Jul 2014 13:56:47 -0400 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CA+A4wOnxSQ-yELs0B5LjVYEVDf-6KZ54r4k_NrBmSK-7yAQ5NA@mail.gmail.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> <CA+A4wOnxSQ-yELs0B5LjVYEVDf-6KZ54r4k_NrBmSK-7yAQ5NA@mail.gmail.com> Message-ID: <53DA835F.7050000@third-bit.com> Mark Bakker <markbak at gmail.com <mailto:markbak at gmail.com>> wrote: We have developed a series of 15 Notebooks for scientists and engineers who want to use Python programming for exploratory computing, scipting, data analysis, and visualization.... Satrajit Ghosh wrote: > - how could we disseminate or find such modules that can be used for > teaching, without having to go through every single notebook? > - how do we describe the prior knowledge required through a dependency > structure? Greg Wilson writes: During our sprint last week, R?mi Emonet and Raniere Silva started exploring the idea of using off-the-shelf package managers to manage lesson material [1,2] so that something like: $ conda install barba-12-steps-navier-stokes will do what it should. I'm really excited by the idea, and hope to put some time into it once September rolls around - if people are interested, I'll send a note to this list once work gets under way. Thanks, Greg Wilson [1] https://softwarecarpentrylessonmanager.github.io/lesson-manager/04-howto.html [2] http://blog.rgaiacs.com/2014/07/27/sprint.html -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/27c0666b/attachment.html> From markbak at gmail.com Thu Jul 31 15:44:58 2014 From: markbak at gmail.com (Mark Bakker) Date: Thu, 31 Jul 2014 21:44:58 +0200 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing Message-ID: <CAEX=yaYj+_T9PFKOnsKgAXPs4Us0C8wGQCamdowaQFzsfX9gRA@mail.gmail.com> Yeah, good point about the %matplotlib inline. That is much better. The thing is that I am using Canopy in class and when you start an IPython Notebook in Canopy I think it starts by default in what used to be pylab mode. I wonder what it does now, as the --pylab flag is gone. Should try that, as this was the behavior in the class last year. From: Ingolf Becker <ingolf.becker at googlemail.com> > > I particularly like the notebooks on water management and the time series > analysis. Just a remark though: > I would avoid using %pylab inline - it has some hideous side effects [1] > (and there was talk of it being removed entirely in future versions) > `%matplotlib inline > from matplotlib import pyplot as plt` > should be preferred. > > [1] https://carreau.github.io/posts/10-No-PyLab-Thanks.ipynb.html > > Thank you for sharing! > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/ad29dfcf/attachment.html> From markbak at gmail.com Thu Jul 31 15:49:53 2014 From: markbak at gmail.com (Mark Bakker) Date: Thu, 31 Jul 2014 21:49:53 +0200 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing Message-ID: <CAEX=yaY_ne6VHE7tFR7=4bUZSP+E34ufqWd6qYSuGmAqUeFQrQ@mail.gmail.com> Good point. For the class I obviously had installation instructions. They are quite easy when you install a packaged bundle (Canopy Express, PythonXY, Anaconda). We used Canopy Express in the class and that worked well. All Notebooks were also accompanied by 10-15 minute videos outlining the new features that were used in the Notebook. I will have to redo some of those videos and will add links to them in the next few weeks. For now I will add some information about installing and getting started. That is indeed a very good idea and should get newbies up and running, Mark On Thu, Jul 31, 2014 at 7:00 PM, <ipython-dev-request at scipy.org> wrote: > From: Gelonida <gelonida at gmail.com> > Hi Mark, > > > Small suggestion to add some clarifying information to your link. > > These links look interesting and I know a few persons who might enjoy > learning a little about python this way. > However as a notebook newbie (I only used ipython as interactive shell > so far and did not read more about notebooks) I am a little confused. > > The web page seems to be aimed at newbies. > It gives the impression, that I just have to go to > http://mbakker7.github.io/exploratory_computing_with_python/ > and then to click on notebook 1 ( > > http://nbviewer.ipython.org/github/mbakker7/exploratory_computing_with_python/blob/master/notebook1/py_exploratory_comp_1_sol.ipynb > ) > and that I could then change the contents of the input field, press > shift-enter and then see the new result. > > But it seems, that this is just a static version of the ipython notebook. > > Only when > - downloading the file > - installing all package dependencies (IMHO very difficult for python > newbies at least on windows) , > - starting a cmd window > - and running C:\Python27\Scripts\ipython notebook <notenookfile> > > I was able to use the notebook as described. > > I assume, that with above procedure you'd loose about 99% of the newbies > who could have been interested in trying out python/notebooks. > > Wouldn't it be possible to add a more explicit link which mentions at > least, that the notebooks cannot be executed immediately or even better > a link to a page trying to explain (even if not aimed for newbies) > how to use/install ipython/notebooks? > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/f680a9fd/attachment.html> From takowl at gmail.com Thu Jul 31 18:55:01 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 31 Jul 2014 15:55:01 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <53D9C05D.1030204@uci.edu> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> <53D9B7A0.5050309@uci.edu> <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> <53D9C05D.1030204@uci.edu> Message-ID: <CAOvn4qiquFYsO_V0n-DvL4Y+WtwkGdj-Qt7DXYpkQjhgNYRWug@mail.gmail.com> On 30 July 2014 21:04, Luke Stagner <lstagner at uci.edu> wrote: > Good news no more error. Bad news still no inline plot. I even set it so > that it reads some random png I have every time and still no go. > Sorry, I got the message structure wrong when I gave you an example without trying it. This time, here's an example that I have tested and ensured that it works: with open('foo.png', 'rb') as f: import base64 imgdata = base64.b64encode(f.read()) self.send_response(self.iopub_socket, 'display_data', {'data':{'image/png': imgdata.decode('ascii')}}) -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/7763842b/attachment.html> From fperez.net at gmail.com Thu Jul 31 19:01:29 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Thu, 31 Jul 2014 16:01:29 -0700 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <53DA835F.7050000@third-bit.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> <CA+A4wOnxSQ-yELs0B5LjVYEVDf-6KZ54r4k_NrBmSK-7yAQ5NA@mail.gmail.com> <53DA835F.7050000@third-bit.com> Message-ID: <CAHAreOrxSxmsN=w=UmQnFD_MYRV41MPWwT3KCZwAS6w23rHifg@mail.gmail.com> On Thu, Jul 31, 2014 at 10:56 AM, Greg Wilson <gvwilson at third-bit.com> wrote: > During our sprint last week, R?mi Emonet and Raniere Silva started > exploring the idea of using off-the-shelf package managers to manage lesson > material [1,2] so that something like: > > $ conda install barba-12-steps-navier-stokes > > will do what it should. I'm really excited by the idea, and hope to put > some time into it once September rolls around - if people are interested, > I'll send a note to this list once work gets under way. > Please do so! I've been thinking lately a lot along those lines as well, the 'code and data (up to some size limits) as a package'. I think there's a lot of potential in that line of thinking, and we may be able to leverage a lot of existing technology to make it easier to reuse bundles of material that focus on a specific teaching or research context, making both education and reproducible research easier. The fact that there are valid limits to the above with enormous data sizes shouldn't deter us from making progress on the many use cases where that won't be an issue. Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/eca908ed/attachment.html> From fperez.net at gmail.com Thu Jul 31 19:02:46 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Thu, 31 Jul 2014 16:02:46 -0700 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CAEX=yaYj+_T9PFKOnsKgAXPs4Us0C8wGQCamdowaQFzsfX9gRA@mail.gmail.com> References: <CAEX=yaYj+_T9PFKOnsKgAXPs4Us0C8wGQCamdowaQFzsfX9gRA@mail.gmail.com> Message-ID: <CAHAreOq3_BYpbZoOjWntMLF2jqo7-QuraTjAyuMWTiNuwVtcYg@mail.gmail.com> On Thu, Jul 31, 2014 at 12:44 PM, Mark Bakker <markbak at gmail.com> wrote: > Yeah, good point about the %matplotlib inline. That is much better. The > thing is that I am using Canopy in class and when you start an IPython > Notebook in Canopy I think it starts by default in what used to be pylab > mode. I wonder what it does now, as the --pylab flag is gone. Should try > that, as this was the behavior in the class last year. Just ignore that: if you add the explicit %matplotlib call and the manual imports, the code will still work in canopy, and it will *also* work for anyone who starts without the global --pylab flag. So just do the 'new right thing' manually with %matplotlib, and it will work fine transparently. Cheers, f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/2dede5e4/attachment.html> From fperez.net at gmail.com Thu Jul 31 19:08:14 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Thu, 31 Jul 2014 16:08:14 -0700 Subject: [IPython-dev] IDL/GDL kernel In-Reply-To: <CAOvn4qiquFYsO_V0n-DvL4Y+WtwkGdj-Qt7DXYpkQjhgNYRWug@mail.gmail.com> References: <mailman.1976.1406767312.14095.ipython-dev@scipy.org> <53D99C9D.4070900@uci.edu> <CAOvn4qgV6m+uKufyYwdQhRsOhPh6VzA+BVUphZ7AxqFsmcFF_A@mail.gmail.com> <53D9B7A0.5050309@uci.edu> <CAOvn4qim71sK+u5t0xe+SOTh6KaBPWsYQv2WZ2RS2S_V_svv+w@mail.gmail.com> <53D9C05D.1030204@uci.edu> <CAOvn4qiquFYsO_V0n-DvL4Y+WtwkGdj-Qt7DXYpkQjhgNYRWug@mail.gmail.com> Message-ID: <CAHAreOrDwg3w0Sh6eJnHDCNr4nwnfL_f=9fL+Stdv_+U9Yy43w@mail.gmail.com> Do you think it's worth adding this to the base class as a utility method(s)? On Thu, Jul 31, 2014 at 3:55 PM, Thomas Kluyver <takowl at gmail.com> wrote: > On 30 July 2014 21:04, Luke Stagner <lstagner at uci.edu> wrote: > >> Good news no more error. Bad news still no inline plot. I even set it so >> that it reads some random png I have every time and still no go. >> > > Sorry, I got the message structure wrong when I gave you an example > without trying it. This time, here's an example that I have tested and > ensured that it works: > > with open('foo.png', 'rb') as f: > > import base64 > > imgdata = base64.b64encode(f.read()) > > self.send_response(self.iopub_socket, 'display_data', > {'data':{'image/png': imgdata.decode('ascii')}}) > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/957b1725/attachment.html> From doug.blank at gmail.com Thu Jul 31 20:36:51 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 31 Jul 2014 20:36:51 -0400 Subject: [IPython-dev] Install and Demo Videos of Notebook Extensions Message-ID: <CAAusYCiPsVEdEiA7mQbZhTJeF8cwX+7--h1-GD6=aYPRD1nqUA@mail.gmail.com> Here are some new videos showing installation and demonstration of the Spell Check, Document Tools, and Cell Tools. Document Tools includes section movers, heading numbering, table of contents, and bibliographic tools (biblio not demoed yet) Cell Tools includes Input/Output tabs, and two column view. Installation videos: 1) Jupyter Notebook Cell Tools Extension Installation (Windows) https://www.youtube.com/watch?v=WwoTzvOkEJQ 2) Jupyter Notebook Document Tools Extension Installation (Windows) https://www.youtube.com/watch?v=YbM8rrj-Bms 3) Jupyter Notebook Spell Check Extension Installation (Windows) https://www.youtube.com/watch?v=Km3AtRynWFQ Demonstration videos: 4) Jupyter Notebook Cell Tools Extension Demonstration https://www.youtube.com/watch?v=dBB1TCWQgBg 5) Jupyter Notebook Document Tools Extension Demonstration https://www.youtube.com/watch?v=LRzUSilYEks 6) Jupyter Notebook Spell Check Extension Demonstration https://www.youtube.com/watch?v=o4xCp3b4oCw -Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/308f0416/attachment.html> From satra at mit.edu Thu Jul 31 20:58:27 2014 From: satra at mit.edu (Satrajit Ghosh) Date: Thu, 31 Jul 2014 20:58:27 -0400 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CAHAreOrxSxmsN=w=UmQnFD_MYRV41MPWwT3KCZwAS6w23rHifg@mail.gmail.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> <CA+A4wOnxSQ-yELs0B5LjVYEVDf-6KZ54r4k_NrBmSK-7yAQ5NA@mail.gmail.com> <53DA835F.7050000@third-bit.com> <CAHAreOrxSxmsN=w=UmQnFD_MYRV41MPWwT3KCZwAS6w23rHifg@mail.gmail.com> Message-ID: <CA+A4wOn4N69cd6mYRyS_2Fqk1fk3Sr=5w9BDsyMuEXjf7pK9mA@mail.gmail.com> hi greg and fernando, along these both git-annex [1] and ipfs [2] might be solutions for the near future, and would offer easy flexibility across data sizes. cheers, satra [1] https://git-annex.branchable.com/ [2] http://ipfs.io On Thu, Jul 31, 2014 at 7:01 PM, Fernando Perez <fperez.net at gmail.com> wrote: > > On Thu, Jul 31, 2014 at 10:56 AM, Greg Wilson <gvwilson at third-bit.com> > wrote: > >> During our sprint last week, R?mi Emonet and Raniere Silva started >> exploring the idea of using off-the-shelf package managers to manage lesson >> material [1,2] so that something like: >> >> $ conda install barba-12-steps-navier-stokes >> >> will do what it should. I'm really excited by the idea, and hope to put >> some time into it once September rolls around - if people are interested, >> I'll send a note to this list once work gets under way. >> > > Please do so! I've been thinking lately a lot along those lines as well, > the 'code and data (up to some size limits) as a package'. I think there's > a lot of potential in that line of thinking, and we may be able to leverage > a lot of existing technology to make it easier to reuse bundles of material > that focus on a specific teaching or research context, making both > education and reproducible research easier. > > The fact that there are valid limits to the above with enormous data sizes > shouldn't deter us from making progress on the many use cases where that > won't be an issue. > > Cheers > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/d2171c4c/attachment.html> From nathan12343 at gmail.com Thu Jul 31 21:11:30 2014 From: nathan12343 at gmail.com (Nathan Goldbaum) Date: Thu, 31 Jul 2014 18:11:30 -0700 Subject: [IPython-dev] Install and Demo Videos of Notebook Extensions In-Reply-To: <CAAusYCiPsVEdEiA7mQbZhTJeF8cwX+7--h1-GD6=aYPRD1nqUA@mail.gmail.com> References: <CAAusYCiPsVEdEiA7mQbZhTJeF8cwX+7--h1-GD6=aYPRD1nqUA@mail.gmail.com> Message-ID: <CAJXewOk3ijaqF+jQABYb8XkYmLgQBSPET0xJx+fipJxH0D1neQ@mail.gmail.com> Thanks very much for forwarding the videos - it was very nice to have the demo to see what your extensions look like in practice. I believe this was already discussed in an earlier thread, but it would be very nice if there were a way to select suggestions for misspelled words. I do this all time time using chrome's spell-checker, so it's a bit of a habit to right-click on words that have squiggly red underlines. I guess some people don't like messing with the right-click menu, so maybe it could be toggled somehow? In any case, having indicators about misspelled words at all is a huge improvement. Thanks for sharing the extension. -Nathan On Thu, Jul 31, 2014 at 5:36 PM, Doug Blank <doug.blank at gmail.com> wrote: > Here are some new videos showing installation and demonstration of the > Spell Check, Document Tools, and Cell Tools. > > Document Tools includes section movers, heading numbering, table of > contents, and bibliographic tools (biblio not demoed yet) > > Cell Tools includes Input/Output tabs, and two column view. > > Installation videos: > > 1) Jupyter Notebook Cell Tools Extension Installation (Windows) > https://www.youtube.com/watch?v=WwoTzvOkEJQ > > 2) Jupyter Notebook Document Tools Extension Installation (Windows) > https://www.youtube.com/watch?v=YbM8rrj-Bms > > 3) Jupyter Notebook Spell Check Extension Installation (Windows) > https://www.youtube.com/watch?v=Km3AtRynWFQ > > Demonstration videos: > > 4) Jupyter Notebook Cell Tools Extension Demonstration > https://www.youtube.com/watch?v=dBB1TCWQgBg > > 5) Jupyter Notebook Document Tools Extension Demonstration > https://www.youtube.com/watch?v=LRzUSilYEks > > 6) Jupyter Notebook Spell Check Extension Demonstration > https://www.youtube.com/watch?v=o4xCp3b4oCw > > -Doug > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/29421a8a/attachment.html> From gvwilson at third-bit.com Thu Jul 31 21:39:47 2014 From: gvwilson at third-bit.com (Greg Wilson) Date: Thu, 31 Jul 2014 21:39:47 -0400 Subject: [IPython-dev] Announcement: Set of IPython Notebooks to learn Python for Exploratory Computing In-Reply-To: <CAHAreOrxSxmsN=w=UmQnFD_MYRV41MPWwT3KCZwAS6w23rHifg@mail.gmail.com> References: <CAEX=yaYBytT5jBKC16HkWT1-7KLCapgyRniSftf_p1xj9jXUBA@mail.gmail.com> <CA+A4wOnxSQ-yELs0B5LjVYEVDf-6KZ54r4k_NrBmSK-7yAQ5NA@mail.gmail.com> <53DA835F.7050000@third-bit.com> <CAHAreOrxSxmsN=w=UmQnFD_MYRV41MPWwT3KCZwAS6w23rHifg@mail.gmail.com> Message-ID: <53DAEFE3.3000005@third-bit.com> On Thu, Jul 31, 2014 at 10:56 AM, Greg Wilson <gvwilson at third-bit.com <mailto:gvwilson at third-bit.com>> wrote: During our sprint last week, R?mi Emonet and Raniere Silva started exploring the idea of using off-the-shelf package managers to manage lesson material [1,2] so that something like: $ conda install barba-12-steps-navier-stokes will do what it should. I'm really excited by the idea, and hope to put some time into it once September rolls around - if people are interested, I'll send a note to this list once work gets under way. On 2014-07-31 7:01 PM, Fernando Perez wrote: > Please do so! I've been thinking lately a lot along those lines as > well, the 'code and data (up to some size limits) as a package'. I > think there's a lot of potential in that line of thinking, and we may > be able to leverage a lot of existing technology to make it easier to > reuse bundles of material that focus on a specific teaching or > research context, making both education and reproducible research easier. Yeah - what I *actually* want to be able to do is: $ conda install doi://10.1371/journal.pone.0103452 and get the source of the paper, the code, the libraries the code depends on (in a safely sandboxed environment), and either the data or links to the data (or torrent files for the data). Lessons are then just a special case... Thanks, Greg -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/e7f94f3a/attachment.html> From doug.blank at gmail.com Thu Jul 31 21:46:16 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 31 Jul 2014 21:46:16 -0400 Subject: [IPython-dev] Install and Demo Videos of Notebook Extensions In-Reply-To: <CAJXewOk3ijaqF+jQABYb8XkYmLgQBSPET0xJx+fipJxH0D1neQ@mail.gmail.com> References: <CAAusYCiPsVEdEiA7mQbZhTJeF8cwX+7--h1-GD6=aYPRD1nqUA@mail.gmail.com> <CAJXewOk3ijaqF+jQABYb8XkYmLgQBSPET0xJx+fipJxH0D1neQ@mail.gmail.com> Message-ID: <CAAusYCh3s6SVaMp6KtRGhktmPVmkB-1OF0vVnPa2D9qLHT=3wg@mail.gmail.com> On Thu, Jul 31, 2014 at 9:11 PM, Nathan Goldbaum <nathan12343 at gmail.com> wrote: > Thanks very much for forwarding the videos - it was very nice to have the > demo to see what your extensions look like in practice. > You are welcomed, and I agree! Sometimes it is hard to see what an extension really is, and there isn't currently an uninstall. > > I believe this was already discussed in an earlier thread, but it would be > very nice if there were a way to select suggestions for misspelled words. > I do this all time time using chrome's spell-checker, so it's a bit of a > habit to right-click on words that have squiggly red underlines. I guess > some people don't like messing with the right-click menu, so maybe it could > be toggled somehow? > > In any case, having indicators about misspelled words at all is a huge > improvement. Thanks for sharing the extension. > I agree that we should eventually add that functionality. I'm going to be using the notebooks to teach writing this Fall. I'll explain that this current method (no suggestions) fits the philosophy of the system... it doesn't do everything for you, but tries to help along the way. And, just perhaps, students might actually learn how to spell :) But yes, in the long run, it should make suggestions on right-click. Someone in the issue tracker even suggested that we could hook up functionality to do tab word completion... that would be even more in the spirit of the system :) Might as well take advantage of the dictionary, if you've got it. -Doug > > -Nathan > > > On Thu, Jul 31, 2014 at 5:36 PM, Doug Blank <doug.blank at gmail.com> wrote: > >> Here are some new videos showing installation and demonstration of the >> Spell Check, Document Tools, and Cell Tools. >> >> Document Tools includes section movers, heading numbering, table of >> contents, and bibliographic tools (biblio not demoed yet) >> >> Cell Tools includes Input/Output tabs, and two column view. >> >> Installation videos: >> >> 1) Jupyter Notebook Cell Tools Extension Installation (Windows) >> https://www.youtube.com/watch?v=WwoTzvOkEJQ >> >> 2) Jupyter Notebook Document Tools Extension Installation (Windows) >> https://www.youtube.com/watch?v=YbM8rrj-Bms >> >> 3) Jupyter Notebook Spell Check Extension Installation (Windows) >> https://www.youtube.com/watch?v=Km3AtRynWFQ >> >> Demonstration videos: >> >> 4) Jupyter Notebook Cell Tools Extension Demonstration >> https://www.youtube.com/watch?v=dBB1TCWQgBg >> >> 5) Jupyter Notebook Document Tools Extension Demonstration >> https://www.youtube.com/watch?v=LRzUSilYEks >> >> 6) Jupyter Notebook Spell Check Extension Demonstration >> https://www.youtube.com/watch?v=o4xCp3b4oCw >> >> -Doug >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140731/f23a9cbc/attachment.html>