From kevin.buchs at gmail.com Tue Aug 2 16:05:36 2011 From: kevin.buchs at gmail.com (Kevin Buchs) Date: Tue, 2 Aug 2011 15:05:36 -0500 Subject: [IPython-dev] cpaste behavior wrt history Message-ID: One thing I am missing with 0.11 (unless I just have bad memory and this was always true) is the commands pasted via cpaste being added to the history. I just get the cpaste command entered in the history. No difference when using -o, -p, -r or -t options. This seems like a needed improvement. -------------- next part -------------- An HTML attachment was scrubbed... URL: From pivanov314 at gmail.com Tue Aug 2 18:05:22 2011 From: pivanov314 at gmail.com (Paul Ivanov) Date: Tue, 2 Aug 2011 15:05:22 -0700 Subject: [IPython-dev] vim-ipython integration's back In-Reply-To: References: <20110729175052.GE4623@ykcyc> Message-ID: <20110802220522.GB2726@ykcyc> G?khan Sever, on 2011-07-30 10:02, wrote: > Great job again Paul. I should overcome my tendency to open two > seperate unconnected Ipython and GVim windows, and force myself to > upgrade to the new IPython with this change. > > What is your next feat? Mind controlled Ipython and Vim interaction? already done, or did you not see my MindControl mode patch for vim? ;) But I actually have an update: vim-ipython now has a 'shell' where you get feedback of In[] Out[] and exception prompts and their contents in a vim buffer. It's the second video on the previously cited post: http://pirsquared.org/blog/2011/07/28/vim-ipython/ My plan is to keep brewing vim-ipython in it's own git, (http://github.com/ivanov/vim-ipython) and periodically pushing it to IPython trunk, does that sound alright? -- Paul Ivanov 314 address only used for lists, off-list direct email at: http://pirsquared.org | GPG/PGP key id: 0x0F3E28F7 -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 198 bytes Desc: Digital signature URL: From fperez.net at gmail.com Wed Aug 3 03:40:46 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 3 Aug 2011 00:40:46 -0700 Subject: [IPython-dev] [ANN] IPython 0.11 is officially out In-Reply-To: References: Message-ID: On Sun, Jul 31, 2011 at 10:19 AM, Fernando Perez wrote: > Please see our release notes for the full details on everything about > this release: https://github.com/ipython/ipython/zipball/rel-0.11 And embarrassingly, that URL was for a zip download instead (copy/paste error), the detailed release notes are here: http://ipython.org/ipython-doc/rel-0.11/whatsnew/version0.11.html Sorry about the mistake... Cheers, f From fperez.net at gmail.com Wed Aug 3 03:49:01 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 3 Aug 2011 00:49:01 -0700 Subject: [IPython-dev] vim-ipython integration's back In-Reply-To: <20110802220522.GB2726@ykcyc> References: <20110729175052.GE4623@ykcyc> <20110802220522.GB2726@ykcyc> Message-ID: On Tue, Aug 2, 2011 at 3:05 PM, Paul Ivanov wrote: > > My plan is to keep brewing vim-ipython in it's own git, > (http://github.com/ivanov/vim-ipython) and periodically pushing > it to IPython trunk, does that sound alright? Perfect plan. I shouldn't tell you this, because I'll never hear the end of it, but today on the long Miami-SFO flight once I was too tired to finish refereeing papers I fired up vimtutor and made my way through the first few lessons. All your fault... Cheers, f From tomspur at fedoraproject.org Wed Aug 3 04:41:10 2011 From: tomspur at fedoraproject.org (Thomas Spura) Date: Wed, 3 Aug 2011 10:41:10 +0200 Subject: [IPython-dev] vim-ipython integration's back In-Reply-To: References: <20110729175052.GE4623@ykcyc> <20110802220522.GB2726@ykcyc> Message-ID: <20110803104110.0be11b0a@fedoraproject.com> On Wed, 3 Aug 2011 00:49:01 -0700 Fernando Perez wrote: > On Tue, Aug 2, 2011 at 3:05 PM, Paul Ivanov > wrote: > > > > My plan is to keep brewing vim-ipython in it's own git, > > (http://github.com/ivanov/vim-ipython) and periodically pushing > > it to IPython trunk, does that sound alright? > > Perfect plan. > > I shouldn't tell you this, because I'll never hear the end of it, but > today on the long Miami-SFO flight once I was too tired to finish > refereeing papers I fired up vimtutor and made my way through the > first few lessons. All your fault... Good decision :) Tom From gael.varoquaux at normalesup.org Wed Aug 3 04:43:32 2011 From: gael.varoquaux at normalesup.org (Gael Varoquaux) Date: Wed, 3 Aug 2011 10:43:32 +0200 Subject: [IPython-dev] vim-ipython integration's back In-Reply-To: <20110803104110.0be11b0a@fedoraproject.com> References: <20110729175052.GE4623@ykcyc> <20110802220522.GB2726@ykcyc> <20110803104110.0be11b0a@fedoraproject.com> Message-ID: <20110803084332.GA32377@phare.normalesup.org> On Wed, Aug 03, 2011 at 10:41:10AM +0200, Thomas Spura wrote: > On Wed, 3 Aug 2011 00:49:01 -0700 Fernando Perez wrote: > > I fired up vimtutor and made my way through the > > first few lessons. All your fault... Wow, Fernando trying out vim. The world is coming to an end! :) From gokhansever at gmail.com Wed Aug 3 10:58:00 2011 From: gokhansever at gmail.com (=?UTF-8?Q?G=C3=B6khan_Sever?=) Date: Wed, 3 Aug 2011 08:58:00 -0600 Subject: [IPython-dev] vim-ipython integration's back In-Reply-To: References: <20110729175052.GE4623@ykcyc> <20110802220522.GB2726@ykcyc> Message-ID: Another fun Vim learning resource: http://stackoverflow.com/questions/95072/what-are-your-favorite-vim-tricks On Wed, Aug 3, 2011 at 1:49 AM, Fernando Perez wrote: > On Tue, Aug 2, 2011 at 3:05 PM, Paul Ivanov wrote: > > > > My plan is to keep brewing vim-ipython in it's own git, > > (http://github.com/ivanov/vim-ipython) and periodically pushing > > it to IPython trunk, does that sound alright? > > Perfect plan. > > I shouldn't tell you this, because I'll never hear the end of it, but > today on the long Miami-SFO flight once I was too tired to finish > refereeing papers I fired up vimtutor and made my way through the > first few lessons. All your fault... > > Cheers, > > f > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- G?khan -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Fri Aug 5 03:18:49 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Fri, 5 Aug 2011 00:18:49 -0700 Subject: [IPython-dev] Putting a kernel inside a GUI (WX or Qt) application so you can run external Qt consoles against it. Message-ID: Hi all, we knew this was in principle possible given the new architecture, but in working with a colleague today I had to actually implement it, so I've committed these as examples (they only need 0.11 to run, so you can just copy these files if you want to play with them, or pull from master): https://github.com/ipython/ipython/blob/master/docs/examples/lib/ipkernel_qtapp.py https://github.com/ipython/ipython/blob/master/docs/examples/lib/ipkernel_wxapp.py Those two both use the same common machinery: https://github.com/ipython/ipython/blob/master/docs/examples/lib/internal_ipkernel.py The idea is that you can have a full IPython kernel embedded in any GUI app (in this case, shown with either WX or Qt), and the app can then fire up a Qt console (or you can attach one externally). The GUI app is modifying variables (the Count++ button) and dumping the user namespace to the console via buttons, while the Qt console can plot variables, run code, etc, that's in the namespace dict. These examples show that it actually takes very little code, and that this extra code is fairly generic (I used the same code for both the Qt and the WX examples). In a real application it would be structured slightly differently, but the ideas should be clear from this simple example. I hope this is useful, since this is something that I've been asked *many* times over the years. Cheers, f From jorgen.stenarson at bostream.nu Thu Aug 11 04:29:38 2011 From: jorgen.stenarson at bostream.nu (=?ISO-8859-1?Q?J=F6rgen_Stenarson?=) Date: Thu, 11 Aug 2011 10:29:38 +0200 Subject: [IPython-dev] Is anyone going to euroscipy? In-Reply-To: References: <4E1CA1D0.8040101@bostream.nu> <20110714194957.GE15788@phare.normalesup.org> Message-ID: <4E4392F2.2010301@bostream.nu> Thomas Kluyver skrev 2011-07-25 01:36: > On 14 July 2011 20:49, Gael Varoquaux > wrote: > > On Thu, Jul 14, 2011 at 07:39:37AM -0500, Fernando Perez wrote: > > If it helps tip your decision, big +1 to you coming :) > > I'd love to meet you there! > > > So I am now registered to go to Euroscipy next month, and I'm looking > forward to meeting those of you who'll be there. Is there any interest > in having a little IPython sprint? There's rooms available on the 23rd & > 24th for sprints, if people are there by then. 0.11 should be out the > door soon, so we could put in some work towards 0.12. > That would be fun. I'm arriving on the 22nd so I could do both days. /J?rgen From takowl at gmail.com Thu Aug 11 06:13:13 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 11 Aug 2011 11:13:13 +0100 Subject: [IPython-dev] Is anyone going to euroscipy? In-Reply-To: <4E4392F2.2010301@bostream.nu> References: <4E1CA1D0.8040101@bostream.nu> <20110714194957.GE15788@phare.normalesup.org> <4E4392F2.2010301@bostream.nu> Message-ID: On 11 August 2011 09:29, J?rgen Stenarson wrote: > > So I am now registered to go to Euroscipy next month, and I'm looking > > forward to meeting those of you who'll be there. Is there any interest > > in having a little IPython sprint? There's rooms available on the 23rd & > > 24th for sprints, if people are there by then. 0.11 should be out the > > door soon, so we could put in some work towards 0.12. > > > That would be fun. I'm arriving on the 22nd so I could do both days. Sorry, I've now worked out that I won't be getting there until the 26th (I'm staying for a few days after the conference), so I can't make it to the sprint days. If there are rooms available on the conference days, maybe we could grab a couple of hours in the afternoon - in particular, I notice the last talk on Sunday is scheduled to finish at 15.30. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From allen.fowler at yahoo.com Thu Aug 11 09:35:09 2011 From: allen.fowler at yahoo.com (Allen Fowler) Date: Thu, 11 Aug 2011 06:35:09 -0700 (PDT) Subject: [IPython-dev] Look at this if u need an job! Message-ID: <1313069709.23005.YahooMailClassic@web114001.mail.gq1.yahoo.com> Hey. If you want to make money using the internet try http://www.ustimeswebsite.org/d7/9258 for an extraordinarily easy approach to make money using the internet. From fperez.net at gmail.com Thu Aug 11 14:52:01 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Thu, 11 Aug 2011 11:52:01 -0700 Subject: [IPython-dev] Is anyone going to euroscipy? In-Reply-To: References: <4E1CA1D0.8040101@bostream.nu> <20110714194957.GE15788@phare.normalesup.org> <4E4392F2.2010301@bostream.nu> Message-ID: Hi folks, On Thu, Aug 11, 2011 at 3:13 AM, Thomas Kluyver wrote: > Sorry, I've now worked out that I won't be getting there until the 26th (I'm > staying for a few days after the conference), so I can't make it to the > sprint days. If there are rooms available on the conference days, maybe we > could grab a couple of hours in the afternoon - in particular, I notice the > last talk on Sunday is scheduled to finish at 15.30. I create a page on the wiki where we can track info about arrival dates, sprint details, etc: http://wiki.ipython.org/EuroSciPy2011 Anyone who will be coming to EuroScipy2011 and is interested in working on IPython-related things, please add your name and availability there. Once we have a full picture of who's around and when, we'll organize what to do. Cheers, f From fperez.net at gmail.com Fri Aug 12 16:17:32 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Fri, 12 Aug 2011 13:17:32 -0700 Subject: [IPython-dev] [psychopy-dev] [jtaylor.debian@googlemail.com: Bug#636724: python-scrapy: provide ipython 0.11 compatibility] In-Reply-To: <4E403626.4050006@gmail.com> References: <20110805161454.GE5865@onerussian.com> <4E3FB6E9.8030501@nottingham.ac.uk> <20110808133958.GC5865@onerussian.com> <20110808180532.GP5865@onerussian.com> <4E403626.4050006@gmail.com> Message-ID: Hi Jonathan, I'm cc-ing IPython-dev so this is publicly recorded, in case we find other interested parties on that list who may want to help. For context, Jonathan is the lead of the PsychoPy project (http://www.psychopy.org) which used our old WX console that has not been ported to the 0.11 apis. On Mon, Aug 8, 2011 at 12:16 PM, Jonathan Peirce wrote: > Thanks fernando, > > I don't have time to handle this for now. PsychoPy does currently come as > either a standalone app, including its own python and batteries (on win32 > and osx) and for these we can just leave it for now and the users will have > to put up with 0.10.x ipython (which is provided). On linux we obviously > don't package up ipython underneath psychopy, so there I suggest we just > disable the ipython option in the shell and users can live with wx shell for > now. > > As it happens the windows package already includes pyqt and maybe I'll add > it to the OSX distribution. That presumably would allow us to follow your > suggestion of using the qt console within wx. The downside is that QT is > massive (and PsychoPy is already using wx throughout). Apart from anything > else it would be another thing that has to be initialised at the startup, > which is already becoming long. > > Well, maybe one day I'll dig around the previous wx ipython shell and see > what can be done, but don't have time for that anytime soon. I completely understand if you don't have time for this right now. If other users with WX expertise are willing/interested in porting the old ipython-wx code (currently in deathrow) to the new APIs, that would be great. It shouldn't be too hard, especially given that the Qt console can be used as a model for how the interaction needs to happen... Cheers, f From wardefar at iro.umontreal.ca Tue Aug 16 23:05:16 2011 From: wardefar at iro.umontreal.ca (David Warde-Farley) Date: Tue, 16 Aug 2011 23:05:16 -0400 Subject: [IPython-dev] (slightly OT) tags vs. branches Message-ID: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Gentlemen, I noticed you have both tags and branches related to releases. As I am currently in the midst of getting the Theano team up to speed on git (woohoo! we've switched!) and the GitHub pull request style of workflow (via gitwash and my various tl;dr cribbings from it), I wonder if you could enlighten me on why you have both, and what each might be useful for. Thanks in advance, David From asmeurer at gmail.com Tue Aug 16 23:14:22 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Tue, 16 Aug 2011 21:14:22 -0600 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: I can't speak for IPython, but this is how we use them with SymPy. As you know, the HEAD commit of a branch moves as the branch is updated, whereas a tag always points to the same commit. Therefore, you should always tag the commit that is used to make a release, so that people can recreate it exactly from the tag if they want to. With SymPy, when we get ready to release, we create a new branch with the name of the version (like 0.7.1), and prepare the release there. This lets development continue in master, even though that may be less stable than you would want preparing for a release. Once the release is done, I tag the commit, and merge the release branch back into master (btw, it's important to merge, not rebase). Generally, at this point, we delete the release branch, as it's useless and redundant, but I suppose this may not always happen. Aaron Meurer On Tue, Aug 16, 2011 at 9:05 PM, David Warde-Farley wrote: > Gentlemen, > > I noticed you have both tags and branches related to releases. As I am currently in the midst of getting the Theano team up to speed on git (woohoo! we've switched!) and the GitHub pull request style of workflow (via gitwash and my various tl;dr cribbings from it), I wonder if you could enlighten me on why you have both, and what each might be useful for. > > Thanks in advance, > > David > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From matthew.brett at gmail.com Tue Aug 16 23:22:36 2011 From: matthew.brett at gmail.com (Matthew Brett) Date: Tue, 16 Aug 2011 20:22:36 -0700 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: Hi, On Tue, Aug 16, 2011 at 8:14 PM, Aaron Meurer wrote: > I can't speak for IPython, but this is how we use them with SymPy. > > As you know, the HEAD commit of a branch moves as the branch is > updated, whereas a tag always points to the same commit. ?Therefore, > you should always tag the commit that is used to make a release, so > that people can recreate it exactly from the tag if they want to. > > With SymPy, when we get ready to release, we create a new branch with > the name of the version (like 0.7.1), and prepare the release there. > This lets development continue in master, even though that may be less > stable than you would want preparing for a release. ?Once the release > is done, I tag the commit, and merge the release branch back into > master (btw, it's important to merge, not rebase). ?Generally, at this > point, we delete the release branch, as it's useless and redundant, > but I suppose this may not always happen. > > Aaron Meurer > > On Tue, Aug 16, 2011 at 9:05 PM, David Warde-Farley > wrote: >> Gentlemen, >> >> I noticed you have both tags and branches related to releases. As I am currently in the midst of getting the Theano team up to speed on git (woohoo! we've switched!) and the GitHub pull request style of workflow (via gitwash and my various tl;dr cribbings from it), I wonder if you could enlighten me on why you have both, and what each might be useful for. And, for us nipy-ers - we tag the release something like 1.1.0, then form a maintenance branch 1.1.x for fixes to that series, in case we want to release 1.1.1, etc, while we're developing what will be 1.2.0. See you, Matthew From asmeurer at gmail.com Wed Aug 17 00:26:12 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Tue, 16 Aug 2011 22:26:12 -0600 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: So I guess it depends on how many branches you can handle at once, and how distributed your development model is. For example, do people commit new stuff directly to a branch in the official repo, like is being done with the htmlnotebook with IPython, or do they work on it in branches their individual branches and merge with master of the official repo when it's all ready? The ease of branching and the highly distributed nature of git lets you develop in any one of probably hundreds of different paradigms, so it really depends on how your community is laid out and what your development procedures look like (and don't be afraid to change these, too, especially if you are coming from a centralized background with something like svn). For example, in SymPy, we require all code to be reviewed (even from developers with commit access), so our process inevitably looks a little different from IPython's. I think you'll find that with GitHub, a highly distributed system works very well, because people can just submit pull requests to each other (that's right, to each other, not just to the official repo), and merge the work together very easily. Going back to the original question, though, I do highly recommend tagging the exact commit you do a release with, as this is a pretty standard practice. The rest will vary from project to project. Aaron Meurer On Tue, Aug 16, 2011 at 9:22 PM, Matthew Brett wrote: > Hi, > > On Tue, Aug 16, 2011 at 8:14 PM, Aaron Meurer wrote: >> I can't speak for IPython, but this is how we use them with SymPy. >> >> As you know, the HEAD commit of a branch moves as the branch is >> updated, whereas a tag always points to the same commit. ?Therefore, >> you should always tag the commit that is used to make a release, so >> that people can recreate it exactly from the tag if they want to. >> >> With SymPy, when we get ready to release, we create a new branch with >> the name of the version (like 0.7.1), and prepare the release there. >> This lets development continue in master, even though that may be less >> stable than you would want preparing for a release. ?Once the release >> is done, I tag the commit, and merge the release branch back into >> master (btw, it's important to merge, not rebase). ?Generally, at this >> point, we delete the release branch, as it's useless and redundant, >> but I suppose this may not always happen. >> >> Aaron Meurer >> >> On Tue, Aug 16, 2011 at 9:05 PM, David Warde-Farley >> wrote: >>> Gentlemen, >>> >>> I noticed you have both tags and branches related to releases. As I am currently in the midst of getting the Theano team up to speed on git (woohoo! we've switched!) and the GitHub pull request style of workflow (via gitwash and my various tl;dr cribbings from it), I wonder if you could enlighten me on why you have both, and what each might be useful for. > > And, for us nipy-ers - we tag the release something like 1.1.0, then > form a maintenance branch 1.1.x for fixes to that series, in case we > want to release 1.1.1, etc, while we're developing what will be 1.2.0. > > See you, > > Matthew > From fperez.net at gmail.com Wed Aug 17 01:26:56 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 16 Aug 2011 22:26:56 -0700 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: Hi David, On Tue, Aug 16, 2011 at 8:05 PM, David Warde-Farley wrote: > Gentlemen, > > I noticed you have both tags and branches related to releases. As I am currently in the midst of getting the Theano team up to speed on git (woohoo! we've switched!) and the GitHub pull request style of workflow (via gitwash and my various tl;dr cribbings from it), I wonder if you could enlighten me on why you have both, and what each might be useful for. As Aaron indicated, having tags for releases is important to be able to easily recover the exact commit that was used to make an official release. For this reason, it's important (as I've learned from screwing up multiple times) to tag *after* you've made the release, and you're sure that everything went up ok, uploaded to pypi, etc. At that point you create an annotated tag and push it to github, as explained here (copied from the ipython release process and updated): https://github.com/nipy/nitime/blob/master/doc/devel/how_to_release.rst An additional benefit of using tags is that github automatically creates downloadable tar/zipballs for any tag, so you get an automatic download website by the mere act of pushing a tag. Now, we only create numbered branches for cases when we do maintain a release series in parallel with the main development. That was the case for the 0.9.x and 0.10.x series, simply because what we now call 0.11 took forever to get into shape, and it was important to still provide users with fixes to the released IPython while we cooked 0.11. But now that those branches are finished, we can get rid of them (to keep the repo tidy) and simply leave the tags as reference points of when the release was made (Min is actually going to do that cleanup soon). The other case when we do create extra branches on the repo is when there is a major feature that requires extensive collaborative development where we may want multiple core devs to be able to write directly. We did that last summer with some of the work that led to 0.11, and now we have the htmlnotebook branch for the same reason. But once it gets merged, we'll delete the branch from the repo, as in this case it's strictly convenience. So in summary: branches to make development easy while things are changing, tags to mark the point where releases were made so that anyone can reconstruct the release later on (distributors, etc). I should add (re. Aaron's comment) that in IPython we do try to review most code, except for very small changes. We only commit directly typically things that fix a bug in a small, localized change and when the bug is nasty, such as one that Aaron happened to report yesterday that crashed IPython altogether. I whipped up a localized fix and committed it right away. But in general, even core devs with commit access submit all our work for review via pull requests, as you can see from the pulls page: https://github.com/ipython/ipython/pulls which has PRs from pretty much everyone. In my mind, review is always better than not, but with such a small team we also use some judgment in allowing occasional changes to go in directly when waiting for review would otherwise just paralyze things. We basically try to strike a balance between maximizing review (which pretty much always increases code quality) and maintaining good throughput. I hope this helps, feel free to ask further. And glad to see Theano on github! Best, f From asmeurer at gmail.com Wed Aug 17 02:03:04 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Wed, 17 Aug 2011 00:03:04 -0600 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: On Tue, Aug 16, 2011 at 11:26 PM, Fernando Perez wrote: > Hi David, > > On Tue, Aug 16, 2011 at 8:05 PM, David Warde-Farley > wrote: >> Gentlemen, >> >> I noticed you have both tags and branches related to releases. As I am currently in the midst of getting the Theano team up to speed on git (woohoo! we've switched!) and the GitHub pull request style of workflow (via gitwash and my various tl;dr cribbings from it), I wonder if you could enlighten me on why you have both, and what each might be useful for. > > As Aaron indicated, having tags for releases is important to be able > to easily recover the exact commit that was used to make an official > release. ?For this reason, it's important (as I've learned from > screwing up multiple times) to tag *after* you've made the release, > and you're sure that everything went up ok, uploaded to pypi, etc. ?At > that point you create an annotated tag and push it to github, as > explained here (copied from the ipython release process and updated): > > https://github.com/nipy/nitime/blob/master/doc/devel/how_to_release.rst > > An additional benefit of using tags is that github automatically > creates downloadable tar/zipballs for any tag, so you get an automatic > download website by the mere act of pushing a tag. > > Now, we only create numbered branches for cases when we do maintain a > release series in parallel with the main development. That was the > case for the 0.9.x and 0.10.x series, simply because what we now call > 0.11 took forever to get into shape, and it was important to still > provide users with fixes to the released IPython while we cooked 0.11. > ?But now that those branches are finished, we can get rid of them (to > keep the repo tidy) and simply leave the tags as reference points of > when the release was made (Min is actually going to do that cleanup > soon). > > The other case when we do create extra branches on the repo is when > there is a major feature that requires extensive collaborative > development where we may want multiple core devs to be able to write > directly. ?We did that last summer with some of the work that led to > 0.11, and now we have the htmlnotebook branch for the same reason. > But once it gets merged, we'll delete the branch from the repo, as in > this case it's strictly convenience. > > So in summary: branches to make development easy while things are > changing, tags to mark the point where releases were made so that > anyone can reconstruct the release later on (distributors, etc). > > I should add (re. Aaron's comment) that in IPython we do try to review > most code, except for very small changes. ?We only commit directly > typically things that fix a bug in a small, localized change and when > the bug is nasty, such as one that Aaron happened to report yesterday > that crashed IPython altogether. ?I whipped up a localized fix and > committed it right away. ?But in general, even core devs with commit > access submit all our work for review via pull requests, as you can > see from the pulls page: I see. In SymPy, literally everything goes through review, even small changes. This definitely has a positive effect on the resulting code, though I should note that one negative side effect is that a lot of branches sit around unreviewed for a long time. This situation has gotten much better with pull requests, and especially since they added the "Merge" button, but it's still a problem. So I would evaluate any reviewing policy not only against a potential gain in code quality but also against your reviewing manpower. Aaron Meurer > > https://github.com/ipython/ipython/pulls > > which has PRs from pretty much everyone. > > In my mind, review is always better than not, but with such a small > team we also use some judgment in allowing occasional changes to go in > directly when waiting for review would otherwise just paralyze things. > ?We basically try to strike a balance between maximizing review (which > pretty much always increases code quality) and maintaining good > throughput. > > I hope this helps, feel free to ask further. ?And glad to see Theano on github! > > Best, > > f > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From fperez.net at gmail.com Wed Aug 17 02:16:13 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 16 Aug 2011 23:16:13 -0700 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: On Tue, Aug 16, 2011 at 11:03 PM, Aaron Meurer wrote: > So I would evaluate any > reviewing policy not only against a potential gain in code quality but > also against your reviewing manpower. Yes, that's pretty much the balance we try to strike. We really try to avoid branches going stale, because there's a real risk they will stop merging cleanly if they diverge too much. With more manpower, ideally everything would get reviewed, and we do make a point of never bypassing review for really important, large or complex changes. And the codebase has certainly improved thanks to that policy, which is much easier to apply on github than it was on the nightmare that is the bzr/launchpad combo. Cheers, f From wardefar at iro.umontreal.ca Wed Aug 17 02:32:50 2011 From: wardefar at iro.umontreal.ca (David Warde-Farley) Date: Wed, 17 Aug 2011 02:32:50 -0400 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: On 2011-08-16, at 11:22 PM, Matthew Brett wrote: > And, for us nipy-ers - we tag the release something like 1.1.0, then > form a maintenance branch 1.1.x for fixes to that series, in case we > want to release 1.1.1, etc, while we're developing what will be 1.2.0. Thanks, this use case for branches definitely makes sense. It did seem that IPython had a branch for each release rather than just release series, which seemed odd, but yeah. I doubt we'll be backporting fixes that much with Theano as it's still too fast-moving to be pinned down too much API-wise. Thanks also for your excellent gitwash document, which I will be referring people to constantly over the next little while, hopefully eventually culminating in other devs actually *reading* it all the way through (I keep telling them that you kept it short by design, but somehow...;) ) David From wardefar at iro.umontreal.ca Wed Aug 17 02:33:22 2011 From: wardefar at iro.umontreal.ca (David Warde-Farley) Date: Wed, 17 Aug 2011 02:33:22 -0400 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: <0135F1F3-BCF9-481B-9069-5761A25F4DA6@iro.umontreal.ca> On 2011-08-17, at 12:26 AM, Aaron Meurer wrote: > I think you'll find that with GitHub, a highly distributed system > works very well, because people can just submit pull requests to each > other (that's right, to each other, not just to the official repo), > and merge the work together very easily. I haven't really played with it much, but is there actually a way to direct a pull request somewhere other than the repo you forked from? I didn't see any obvious way to do it in the UI, but it makes sense conceptually. > Going back to the original question, though, I do highly recommend > tagging the exact commit you do a release with, as this is a pretty > standard practice. The rest will vary from project to project. Yep. I just wondered if there was a reason for also having a "frozen in time" *branch* version, as there appeared to be in IPython. It seems the answer is no. David From fperez.net at gmail.com Wed Aug 17 02:36:05 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 16 Aug 2011 23:36:05 -0700 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: <0135F1F3-BCF9-481B-9069-5761A25F4DA6@iro.umontreal.ca> References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> <0135F1F3-BCF9-481B-9069-5761A25F4DA6@iro.umontreal.ca> Message-ID: On Tue, Aug 16, 2011 at 11:33 PM, David Warde-Farley wrote: > I haven't really played with it much, but is there actually a way to direct a pull request somewhere other than the repo you forked from? I didn't see any obvious way to do it in the UI, but it makes sense conceptually. > I think that you can click on the target branch labels and change them to something else, though I'm not 100% sure. >> Going back to the original question, though, I do highly recommend >> tagging the exact commit you do a release with, as this is a pretty >> standard practice. ?The rest will vary from project to project. > > Yep. I just wondered if there was a reason for also having a "frozen in time" *branch* version, as there appeared to be in IPython. It seems the answer is no. Nope, just lack of cleanup of old stuff, which we're now doing thanks to this conversation :) Cheers, f From asmeurer at gmail.com Wed Aug 17 02:36:58 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Wed, 17 Aug 2011 00:36:58 -0600 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: <0135F1F3-BCF9-481B-9069-5761A25F4DA6@iro.umontreal.ca> References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> <0135F1F3-BCF9-481B-9069-5761A25F4DA6@iro.umontreal.ca> Message-ID: On Wed, Aug 17, 2011 at 12:33 AM, David Warde-Farley wrote: > On 2011-08-17, at 12:26 AM, Aaron Meurer wrote: > >> I think you'll find that with GitHub, a highly distributed system >> works very well, because people can just submit pull requests to each >> other (that's right, to each other, not just to the official repo), >> and merge the work together very easily. > > I haven't really played with it much, but is there actually a way to direct a pull request somewhere other than the repo you forked from? I didn't see any obvious way to do it in the UI, but it makes sense conceptually. Yes, although everyone should fork from the official repo, as pull requests go there by default. When you are in the pull request form, click on "change commits" at the top, or click on the black branch name. > >> Going back to the original question, though, I do highly recommend >> tagging the exact commit you do a release with, as this is a pretty >> standard practice. ?The rest will vary from project to project. > > Yep. I just wondered if there was a reason for also having a "frozen in time" *branch* version, as there appeared to be in IPython. It seems the answer is no. > > David No, tags are frozen in time, and branches are not, so if you want something that's frozen, you should definitely use a tag. Aaron Meurer From wardefar at iro.umontreal.ca Wed Aug 17 02:38:57 2011 From: wardefar at iro.umontreal.ca (David Warde-Farley) Date: Wed, 17 Aug 2011 02:38:57 -0400 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: On 2011-08-17, at 2:03 AM, Aaron Meurer wrote: > I see. In SymPy, literally everything goes through review, even small > changes. This definitely has a positive effect on the resulting code, > though I should note that one negative side effect is that a lot of > branches sit around unreviewed for a long time. This situation has > gotten much better with pull requests, and especially since they added > the "Merge" button, but it's still a problem. So I would evaluate any > reviewing policy not only against a potential gain in code quality but > also against your reviewing manpower. It definitely has a seductive appeal, the "review every single character" strategy, but yes, I'm not entirely sure we have enough eyes for it ourselves. I'm glad that SymPy does it, though, and may offer my axe in that battle in some crazy version of the future where I have the time to learn the SymPy code base well enough. :) David From wardefar at iro.umontreal.ca Wed Aug 17 02:39:48 2011 From: wardefar at iro.umontreal.ca (David Warde-Farley) Date: Wed, 17 Aug 2011 02:39:48 -0400 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> Message-ID: <97CCA970-627A-4748-8C0F-10E046A2683E@iro.umontreal.ca> Fernando, Thanks for such a detailed reply and so quickly! On 2011-08-17, at 1:26 AM, Fernando Perez wrote: > An additional benefit of using tags is that github automatically > creates downloadable tar/zipballs for any tag, so you get an automatic > download website by the mere act of pushing a tag. Neat, I had forgotten about that. Although I notice you also have a (presumably setuptools-generated) tarball on PyPI. Does it complicate things any to have two similar-but-different source distributions? (I'm thinking in terms of any generated documentation, etc.) > Now, we only create numbered branches for cases when we do maintain a > release series in parallel with the main development. That was the > case for the 0.9.x and 0.10.x series, simply because what we now call > 0.11 took forever to get into shape, and it was important to still > provide users with fixes to the released IPython while we cooked 0.11. > But now that those branches are finished, we can get rid of them (to > keep the repo tidy) and simply leave the tags as reference points of > when the release was made (Min is actually going to do that cleanup > soon). Ah, okay. Got it. This was the part I wasn't clear on. > The other case when we do create extra branches on the repo is when > there is a major feature that requires extensive collaborative > development where we may want multiple core devs to be able to write > directly. We did that last summer with some of the work that led to > 0.11, and now we have the htmlnotebook branch for the same reason. > But once it gets merged, we'll delete the branch from the repo, as in > this case it's strictly convenience. Gotcha. Yes, that does seem like a good case for core-repo branches. > I should add (re. Aaron's comment) that in IPython we do try to review > most code, except for very small changes. We only commit directly > typically things that fix a bug in a small, localized change and when > the bug is nasty, such as one that Aaron happened to report yesterday > that crashed IPython altogether. I whipped up a localized fix and > committed it right away. But in general, even core devs with commit > access submit all our work for review via pull requests, as you can > see from the pulls page: > > https://github.com/ipython/ipython/pulls > > which has PRs from pretty much everyone. Yep, this is the model I have been quite impressed with in my interactions with IPython, and the model we're planning to follow for Theano. One of our core developers had set up an instance of ReviewBoard ( http://www.reviewboard.org/ ) but it was basically set up (via some hacks) to review code *after* it had gone into the trunk, which made little sense to a lot of us, and was a usability nightmare. We're hoping GitHub will help us get our reviewing house in order. > In my mind, review is always better than not, but with such a small > team we also use some judgment in allowing occasional changes to go in > directly when waiting for review would otherwise just paralyze things. > We basically try to strike a balance between maximizing review (which > pretty much always increases code quality) and maintaining good > throughput. > I hope this helps, feel free to ask further. It absolutely helps, thanks very much. > And glad to see Theano on github! So am I, very much so. :) David From fperez.net at gmail.com Wed Aug 17 03:01:36 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 17 Aug 2011 00:01:36 -0700 Subject: [IPython-dev] (slightly OT) tags vs. branches In-Reply-To: <97CCA970-627A-4748-8C0F-10E046A2683E@iro.umontreal.ca> References: <1D626656-1170-4B17-99ED-D3EB9438601B@iro.umontreal.ca> <97CCA970-627A-4748-8C0F-10E046A2683E@iro.umontreal.ca> Message-ID: On Tue, Aug 16, 2011 at 11:39 PM, David Warde-Farley wrote: > Thanks for such a detailed reply and so quickly! Glad to help! And this discussion got us to clean up house, so it's good for us too :) > On 2011-08-17, at 1:26 AM, Fernando Perez wrote: > >> An additional benefit of using tags is that github automatically >> creates downloadable tar/zipballs for any tag, so you get an automatic >> download website by the mere act of pushing a tag. > > Neat, I had forgotten about that. Although I notice you also have a (presumably setuptools-generated) tarball on PyPI. Does it complicate things any to have two similar-but-different source distributions? (I'm thinking in terms of any generated documentation, etc.) Well, pypi is good to have because that's what easy_install/pip pull from. The ones we push there are larger and have built docs. On github, the auto-generated ones are 'pure' source packages without any build operations on them, just the output of a git export. So they are perfect for distributors to pick up, since those tend to have their own policies on how to build/distribute docs (often in separate packages). So I'm actually happy to have both, as we automatically satisfy both end-users installing from pypi who get complete docs, and distributors who need pure source tarballs to start from for their packaging process. Cheers, f From takowl at gmail.com Thu Aug 18 07:52:09 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 18 Aug 2011 12:52:09 +0100 Subject: [IPython-dev] PythonAnywhere update, 18 August 2011 In-Reply-To: <4E4CF79B.6080208@pythonanywhere.com> References: <4E4CF79B.6080208@pythonanywhere.com> Message-ID: On 18 August 2011 12:29, PythonAnywhere Support wrote: > What else do you think we should be working on? > I see you've updated IPython to 0.11 now - thanks. I'll admit to being biased because I ported it, but I'd be keen to see our Python 3 version of IPython available as well. Also, I don't know how easy it is to add to the terminal emulation, but I notice that it's currently impossible to enter or paste a non-ascii character (e.g. ? or ?). Also, I'm still interested in the possibility you suggested of having a 'Try IPython online' kind of demo. Thanks, and keep up the good work! Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From grahame at angrygoats.net Sun Aug 21 05:18:11 2011 From: grahame at angrygoats.net (Grahame Bowland) Date: Sun, 21 Aug 2011 17:18:11 +0800 Subject: [IPython-dev] Announcing shrubbery Message-ID: Hi everyone I've spent the last few days coming up with a Python 3 distribution of iPython and friends for Mac OS X. It now works (mostly), and I thought I'd share it. The home page is here: https://github.com/grahame/shrubbery and I've put an experimental installer image here: https://github.com/downloads/grahame/shrubbery/shrubbery.pkg For a long time I've maintained my Python setup by hand, installing packages into /usr/local and eventually having a huge mess. Hence this project - a distribution of software for Mac OS to make it easier for people to get started with iPython. I've targeted Python 3 in the hope it'll encourage the porting of more software to the new version of the language. There's not too much Mac OS specific about this, except that on Linux you'd probably want to get packages from your distribution. If anyone wants to make it work on other platforms that'd be great. Cheers Grahame From takowl at gmail.com Sun Aug 21 07:58:06 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Sun, 21 Aug 2011 12:58:06 +0100 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: Thanks, Grahame. I notice you're including Matplotlib. Is that now out with Python 3 support? I know they were working on it, but I haven't heard anything about it recently. Best wishes, Thomas On 21 August 2011 10:18, Grahame Bowland wrote: > Hi everyone > > I've spent the last few days coming up with a Python 3 distribution of > iPython and friends for Mac OS X. It now works (mostly), and I thought > I'd share it. > > The home page is here: > https://github.com/grahame/shrubbery > and I've put an experimental installer image here: > https://github.com/downloads/grahame/shrubbery/shrubbery.pkg > > For a long time I've maintained my Python setup by hand, installing > packages into /usr/local and eventually having a huge mess. Hence this > project - a distribution of software for Mac OS to make it easier for > people to get started with iPython. > > I've targeted Python 3 in the hope it'll encourage the porting of more > software to the new version of the language. > > There's not too much Mac OS specific about this, except that on Linux > you'd probably want to get packages from your distribution. If anyone > wants to make it work on other platforms that'd be great. > > Cheers > Grahame > _______________________________________________ > 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: From takowl at gmail.com Sun Aug 21 08:45:58 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Sun, 21 Aug 2011 13:45:58 +0100 Subject: [IPython-dev] Fancy quotes in code blocks in PDF docs Message-ID: Hi all, Kevin has spotted a problem with our (IPython's) PDF documentation. In blocks of code embedded in the documentation, single quotes ' are getting transformed into fancy quotes ? for the PDF output. This messes up copying and pasting code from the PDF file. I think it had been overlooked until now because we usually use the HTML output, where the correct quotes are preserved. Sphinx people, is this a known issue? Is there a workaround to generate the PDF without transforming the quotes? Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From grahame at angrygoats.net Sun Aug 21 09:29:55 2011 From: grahame at angrygoats.net (Grahame Bowland) Date: Sun, 21 Aug 2011 21:29:55 +0800 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: Hi Thomas Yep, I'm including Matplotlib. I'm using the matplotlib-py3 branch from here: https://github.com/matplotlib/matplotlib-py3 with some changes of my own which I should send upstream, in my own branch https://github.com/grahame/matplotlib-py3 My changes fix some undefined symbols in the macosx backend, a few string encoding things. In shrubbery the qtconsole works out of the box, but it has quite a few problems with Python3. Looking at the ipython changelog it sounds like this will be in the pyzmq having trouble with string encoding. Should be easy enough to fix, I'll have a look. I must say the qtconsole is pretty swish. Installed it's currently over 400MB, I'll be able to cut this significantly but am focussing my time on other things at the moment :-) Cheers Grahame To reproduce the problems I'm seeing provoke a traceback: def blah(): 1/0 blah() Or try to do an inline plot in the 'ipython3 qtconsole pylab=inline' mode. On 21 August 2011 19:58, Thomas Kluyver wrote: > Thanks, Grahame. I notice you're including Matplotlib. Is that now out with > Python 3 support? I know they were working on it, but I haven't heard > anything about it recently. > > Best wishes, > Thomas > > On 21 August 2011 10:18, Grahame Bowland wrote: >> >> Hi everyone >> >> I've spent the last few days coming up with a Python 3 distribution of >> iPython and friends for Mac OS X. It now works (mostly), and I thought >> I'd share it. >> >> The home page is here: >> https://github.com/grahame/shrubbery >> and I've put an experimental installer image here: >> https://github.com/downloads/grahame/shrubbery/shrubbery.pkg >> >> For a long time I've maintained my Python setup by hand, installing >> packages into /usr/local and eventually having a huge mess. Hence this >> project - a distribution of software for Mac OS to make it easier for >> people to get started with iPython. >> >> I've targeted Python 3 in the hope it'll encourage the porting of more >> software to the new version of the language. >> >> There's not too much Mac OS specific about this, except that on Linux >> you'd probably want to get packages from your distribution. If anyone >> wants to make it work on other platforms that'd be great. >> >> Cheers >> Grahame >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > From grahame at angrygoats.net Sun Aug 21 09:37:00 2011 From: grahame at angrygoats.net (Grahame Bowland) Date: Sun, 21 Aug 2011 21:37:00 +0800 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: Whoops, I should have said, the first problem requires you to run %debug after generating the exception. On 21 August 2011 21:29, Grahame Bowland wrote: > Hi Thomas > > Yep, I'm including Matplotlib. I'm using the matplotlib-py3 branch from here: > ?https://github.com/matplotlib/matplotlib-py3 > with some changes of my own which I should send upstream, in my own branch > ?https://github.com/grahame/matplotlib-py3 > > My changes fix some undefined symbols in the macosx backend, a few > string encoding things. > > In shrubbery the qtconsole works out of the box, but it has quite a > few problems with Python3. Looking at the ipython changelog it sounds > like this will be in the pyzmq having trouble with string encoding. > Should be easy enough to fix, I'll have a look. I must say the > qtconsole is pretty swish. > > Installed it's currently over 400MB, I'll be able to cut this > significantly but am focussing my time on other things at the moment > :-) > > Cheers > Grahame > > To reproduce the problems I'm seeing provoke a traceback: > def blah(): 1/0 > blah() > > Or try to do an inline plot in the 'ipython3 qtconsole pylab=inline' mode. > > On 21 August 2011 19:58, Thomas Kluyver wrote: >> Thanks, Grahame. I notice you're including Matplotlib. Is that now out with >> Python 3 support? I know they were working on it, but I haven't heard >> anything about it recently. >> >> Best wishes, >> Thomas >> >> On 21 August 2011 10:18, Grahame Bowland wrote: >>> >>> Hi everyone >>> >>> I've spent the last few days coming up with a Python 3 distribution of >>> iPython and friends for Mac OS X. It now works (mostly), and I thought >>> I'd share it. >>> >>> The home page is here: >>> https://github.com/grahame/shrubbery >>> and I've put an experimental installer image here: >>> https://github.com/downloads/grahame/shrubbery/shrubbery.pkg >>> >>> For a long time I've maintained my Python setup by hand, installing >>> packages into /usr/local and eventually having a huge mess. Hence this >>> project - a distribution of software for Mac OS to make it easier for >>> people to get started with iPython. >>> >>> I've targeted Python 3 in the hope it'll encourage the porting of more >>> software to the new version of the language. >>> >>> There's not too much Mac OS specific about this, except that on Linux >>> you'd probably want to get packages from your distribution. If anyone >>> wants to make it work on other platforms that'd be great. >>> >>> Cheers >>> Grahame >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > From takowl at gmail.com Sun Aug 21 13:06:24 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Sun, 21 Aug 2011 18:06:24 +0100 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: On 21 August 2011 14:29, Grahame Bowland wrote: > > To reproduce the problems I'm seeing provoke a traceback: > def blah(): 1/0 > blah() > [%debug] Oops, yes, thanks for spotting this. Hopefully we'll be able to get it fixed for 0.12. The plan is to have the Python 3 version built from the same codebase, using 2to3. > Or try to do an inline plot in the 'ipython3 qtconsole pylab=inline' mode. OK, not having used matplotlib with Python 3, I can't test this. I'll try to get round to compiling it at some stage. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From asmeurer at gmail.com Sun Aug 21 14:03:40 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Sun, 21 Aug 2011 12:03:40 -0600 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: This is good. Mac OS X users are usually treated like Linux users in that they're expected to be command line savvy to install software (actually more than average, since Linux users at least have package managers). But really we should treat most of them the same as we do Windows users: people who may know Python, or at least are learning it, but aren't very comfortable with the "./configure;make;make install" process. By the way, if anyone's interested, I detailed the steps I took to install the qtconsole in Python 2 in Lion with the XCode 4 developer tools at https://github.com/sympy/sympy/wiki/Installing-the-IPython-qtconsole-in-Mac-OS-X. There's nothing too complicated; you just have to make sure that you get the right things from the right places. Some questions about shrubbery: First, how easy is it to add new packages? It looked to me like you have to edit several places throughout the file to do it, so that it's not trivial, especially if you don't know everywhere to edit the file. Second, I noticed that you are getting everything from git. Have you considered using git submodules? Third, are you considering to just include Python 3 with the installer? Aaron Meurer On Sun, Aug 21, 2011 at 3:18 AM, Grahame Bowland wrote: > Hi everyone > > I've spent the last few days coming up with a Python 3 distribution of > iPython and friends for Mac OS X. It now works (mostly), and I thought > I'd share it. > > The home page is here: > https://github.com/grahame/shrubbery > and I've put an experimental installer image here: > https://github.com/downloads/grahame/shrubbery/shrubbery.pkg > > For a long time I've maintained my Python setup by hand, installing > packages into /usr/local and eventually having a huge mess. Hence this > project - a distribution of software for Mac OS to make it easier for > people to get started with iPython. > > I've targeted Python 3 in the hope it'll encourage the porting of more > software to the new version of the language. > > There's not too much Mac OS specific about this, except that on Linux > you'd probably want to get packages from your distribution. If anyone > wants to make it work on other platforms that'd be great. > > Cheers > Grahame > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From benjaminrk at gmail.com Sun Aug 21 14:33:54 2011 From: benjaminrk at gmail.com (MinRK) Date: Sun, 21 Aug 2011 11:33:54 -0700 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: Aaron, Your pyzmq steps make it look more complicated than I think it is, if users want released versions. There are eggs for osx 2.6,2,7, and 3.2, so `easy_install pyzmq` works on osx under most circumstances, and includes 32+64b UB libzmq, so you don't need to build and install it separately. If you do want to build libzmq, you can use homebrew: `brew install zeromq --universal` (the universal flag for specifying 32+64b). Since this (as well as the default `./configure && make && make install`) put libzmq in /usr/local, then pyzmq *is* pip-installable at this point. -MinRK On Aug 21, 2011, at 11:03, Aaron Meurer wrote: > This is good. Mac OS X users are usually treated like Linux users in > that they're expected to be command line savvy to install software > (actually more than average, since Linux users at least have package > managers). But really we should treat most of them the same as we do > Windows users: people who may know Python, or at least are learning > it, but aren't very comfortable with the "./configure;make;make > install" process. > > By the way, if anyone's interested, I detailed the steps I took to > install the qtconsole in Python 2 in Lion with the XCode 4 developer > tools at https://github.com/sympy/sympy/wiki/Installing-the-IPython-qtconsole-in-Mac-OS-X. > There's nothing too complicated; you just have to make sure that you > get the right things from the right places. > > Some questions about shrubbery: > > First, how easy is it to add new packages? It looked to me like you > have to edit several places throughout the file to do it, so that it's > not trivial, especially if you don't know everywhere to edit the file. > > Second, I noticed that you are getting everything from git. Have you > considered using git submodules? > > Third, are you considering to just include Python 3 with the installer? > > Aaron Meurer > > On Sun, Aug 21, 2011 at 3:18 AM, Grahame Bowland wrote: >> Hi everyone >> >> I've spent the last few days coming up with a Python 3 distribution of >> iPython and friends for Mac OS X. It now works (mostly), and I thought >> I'd share it. >> >> The home page is here: >> https://github.com/grahame/shrubbery >> and I've put an experimental installer image here: >> https://github.com/downloads/grahame/shrubbery/shrubbery.pkg >> >> For a long time I've maintained my Python setup by hand, installing >> packages into /usr/local and eventually having a huge mess. Hence this >> project - a distribution of software for Mac OS to make it easier for >> people to get started with iPython. >> >> I've targeted Python 3 in the hope it'll encourage the porting of more >> software to the new version of the language. >> >> There's not too much Mac OS specific about this, except that on Linux >> you'd probably want to get packages from your distribution. If anyone >> wants to make it work on other platforms that'd be great. >> >> Cheers >> Grahame >> _______________________________________________ >> 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 asmeurer at gmail.com Sun Aug 21 14:51:42 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Sun, 21 Aug 2011 12:51:42 -0600 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: According to the guide, pip install pyzmq didn't work because I had to pass --zmq="/usr/local/" to the setup.py install command. This was a couple of weeks ago when I did this, so I don't remember the details (that's why I wrote it all down). I guess this is the result of compiling zeromq from git. I seem to remember `pip install pyzmq` not working without zeromq installed already, but I could be wrong. I did make the choice to install zeromq from git, when I'm sure that installing from a source tarball would have been easier (this is just because "git clone" is easier for me, and having the git clone will make things much easier in the future). And I used homebrew only as a last resort, where likely I could have gotten more done with it. Anyway, it's perhaps not the best way to do it, but it's the way that worked for me, and I wanted to document it publicly in case any of the tips were helpful to someone else. Aaron Meurer On Sun, Aug 21, 2011 at 12:33 PM, MinRK wrote: > Aaron, > > Your pyzmq steps make it look more complicated than I think it is, if > users want released versions. ?There are eggs for osx 2.6,2,7, and > 3.2, so `easy_install pyzmq` works on osx under most circumstances, > and includes 32+64b UB libzmq, so you don't need to build and install > it separately. > > If you do want to build libzmq, you can use homebrew: `brew install > zeromq --universal` (the universal flag for specifying 32+64b). ?Since > this (as well as the default `./configure && make && make install`) > put libzmq in /usr/local, then pyzmq *is* pip-installable at this > point. > > -MinRK > > On Aug 21, 2011, at 11:03, Aaron Meurer wrote: > >> This is good. ?Mac OS X users are usually treated like Linux users in >> that they're expected to be command line savvy to install software >> (actually more than average, since Linux users at least have package >> managers). ?But really we should treat most of them the same as we do >> Windows users: people who may know Python, or at least are learning >> it, but aren't very comfortable with the "./configure;make;make >> install" process. >> >> By the way, if anyone's interested, I detailed the steps I took to >> install the qtconsole in Python 2 in Lion with the XCode 4 developer >> tools at https://github.com/sympy/sympy/wiki/Installing-the-IPython-qtconsole-in-Mac-OS-X. >> There's nothing too complicated; you just have to make sure that you >> get the right things from the right places. >> >> Some questions about shrubbery: >> >> First, how easy is it to add new packages? ?It looked to me like you >> have to edit several places throughout the file to do it, so that it's >> not trivial, especially if you don't know everywhere to edit the file. >> >> Second, I noticed that you are getting everything from git. Have you >> considered using git submodules? >> >> Third, are you considering to just include Python 3 with the installer? >> >> Aaron Meurer >> >> On Sun, Aug 21, 2011 at 3:18 AM, Grahame Bowland wrote: >>> Hi everyone >>> >>> I've spent the last few days coming up with a Python 3 distribution of >>> iPython and friends for Mac OS X. It now works (mostly), and I thought >>> I'd share it. >>> >>> The home page is here: >>> https://github.com/grahame/shrubbery >>> and I've put an experimental installer image here: >>> https://github.com/downloads/grahame/shrubbery/shrubbery.pkg >>> >>> For a long time I've maintained my Python setup by hand, installing >>> packages into /usr/local and eventually having a huge mess. Hence this >>> project - a distribution of software for Mac OS to make it easier for >>> people to get started with iPython. >>> >>> I've targeted Python 3 in the hope it'll encourage the porting of more >>> software to the new version of the language. >>> >>> There's not too much Mac OS specific about this, except that on Linux >>> you'd probably want to get packages from your distribution. If anyone >>> wants to make it work on other platforms that'd be great. >>> >>> Cheers >>> Grahame >>> _______________________________________________ >>> 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 benjaminrk at gmail.com Sun Aug 21 15:23:55 2011 From: benjaminrk at gmail.com (MinRK) Date: Sun, 21 Aug 2011 12:23:55 -0700 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: On Sun, Aug 21, 2011 at 11:51, Aaron Meurer wrote: > According to the guide, pip install pyzmq didn't work because I had to > pass --zmq="/usr/local/" to the setup.py install command. This was a > couple of weeks ago when I did this, so I don't remember the details > (that's why I wrote it all down). I guess this is the result of > compiling zeromq from git. I seem to remember `pip install pyzmq` not > working without zeromq installed already, but I could be wrong. > You are right that pip won't work without libzmq because building from source needs libzmq headers and library, and pip always builds from source. You should only need to specify --zmq=prefix if libzmq is somewhere *other* than /usr/local. The two easiest ways to install libzmq+pyzmq release: 1. easy_install pyzmq 2. brew install zeromq --universal && pip install pyzmq > I did make the choice to install zeromq from git, when I'm sure that > installing from a source tarball would have been easier (this is just > because "git clone" is easier for me, and having the git clone will > make things much easier in the future). And I used homebrew only as a > last resort, where likely I could have gotten more done with it. > > Anyway, it's perhaps not the best way to do it, but it's the way that > worked for me, and I wanted to document it publicly in case any of the > tips were helpful to someone else. > Yes, this is definitely very helpful. I would probably just add a note on your pyzmq section that says " `easy_install pyzmq` should work, but if you want git versions...", and possibly remove the 'easy_install/pip won't work' note, since I don't believe that it is accurate when you install zeromq to /usr/local as you are doing. -MinRK > Aaron Meurer > > On Sun, Aug 21, 2011 at 12:33 PM, MinRK wrote: > > Aaron, > > > > Your pyzmq steps make it look more complicated than I think it is, if > > users want released versions. There are eggs for osx 2.6,2,7, and > > 3.2, so `easy_install pyzmq` works on osx under most circumstances, > > and includes 32+64b UB libzmq, so you don't need to build and install > > it separately. > > > > If you do want to build libzmq, you can use homebrew: `brew install > > zeromq --universal` (the universal flag for specifying 32+64b). Since > > this (as well as the default `./configure && make && make install`) > > put libzmq in /usr/local, then pyzmq *is* pip-installable at this > > point. > > > > -MinRK > > > > On Aug 21, 2011, at 11:03, Aaron Meurer wrote: > > > >> This is good. Mac OS X users are usually treated like Linux users in > >> that they're expected to be command line savvy to install software > >> (actually more than average, since Linux users at least have package > >> managers). But really we should treat most of them the same as we do > >> Windows users: people who may know Python, or at least are learning > >> it, but aren't very comfortable with the "./configure;make;make > >> install" process. > >> > >> By the way, if anyone's interested, I detailed the steps I took to > >> install the qtconsole in Python 2 in Lion with the XCode 4 developer > >> tools at > https://github.com/sympy/sympy/wiki/Installing-the-IPython-qtconsole-in-Mac-OS-X > . > >> There's nothing too complicated; you just have to make sure that you > >> get the right things from the right places. > >> > >> Some questions about shrubbery: > >> > >> First, how easy is it to add new packages? It looked to me like you > >> have to edit several places throughout the file to do it, so that it's > >> not trivial, especially if you don't know everywhere to edit the file. > >> > >> Second, I noticed that you are getting everything from git. Have you > >> considered using git submodules? > >> > >> Third, are you considering to just include Python 3 with the installer? > >> > >> Aaron Meurer > >> > >> On Sun, Aug 21, 2011 at 3:18 AM, Grahame Bowland < > grahame at angrygoats.net> wrote: > >>> Hi everyone > >>> > >>> I've spent the last few days coming up with a Python 3 distribution of > >>> iPython and friends for Mac OS X. It now works (mostly), and I thought > >>> I'd share it. > >>> > >>> The home page is here: > >>> https://github.com/grahame/shrubbery > >>> and I've put an experimental installer image here: > >>> https://github.com/downloads/grahame/shrubbery/shrubbery.pkg > >>> > >>> For a long time I've maintained my Python setup by hand, installing > >>> packages into /usr/local and eventually having a huge mess. Hence this > >>> project - a distribution of software for Mac OS to make it easier for > >>> people to get started with iPython. > >>> > >>> I've targeted Python 3 in the hope it'll encourage the porting of more > >>> software to the new version of the language. > >>> > >>> There's not too much Mac OS specific about this, except that on Linux > >>> you'd probably want to get packages from your distribution. If anyone > >>> wants to make it work on other platforms that'd be great. > >>> > >>> Cheers > >>> Grahame > >>> _______________________________________________ > >>> 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: From asmeurer at gmail.com Sun Aug 21 15:40:39 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Sun, 21 Aug 2011 13:40:39 -0600 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: OK, I edited the file. Aaron Meurer On Sun, Aug 21, 2011 at 1:23 PM, MinRK wrote: > > > On Sun, Aug 21, 2011 at 11:51, Aaron Meurer wrote: >> >> According to the guide, pip install pyzmq didn't work because I had to >> pass --zmq="/usr/local/" to the setup.py install command. ?This was a >> couple of weeks ago when I did this, so I don't remember the details >> (that's why I wrote it all down). ?I guess this is the result of >> compiling zeromq from git. ?I seem to remember `pip install pyzmq` not >> working without zeromq installed already, but I could be wrong. > > You are right that pip won't work without libzmq because building from > source needs libzmq headers and library, and pip always builds from source. > You should only need to specify --zmq=prefix if libzmq is somewhere *other* > than /usr/local. > The two easiest ways to install libzmq+pyzmq release: > 1. easy_install pyzmq > 2. brew install zeromq??--universal?&& pip install pyzmq >> >> I did make the choice to install zeromq from git, when I'm sure that >> installing from a source tarball would have been easier (this is just >> because "git clone" is easier for me, and having the git clone will >> make things much easier in the future). ?And I used homebrew only as a >> last resort, where likely I could have gotten more done with it. >> >> Anyway, it's perhaps not the best way to do it, but it's the way that >> worked for me, and I wanted to document it publicly in case any of the >> tips were helpful to someone else. > > Yes, this is definitely very helpful. ?I would probably just add a note on > your pyzmq section that says " `easy_install pyzmq` should work, but if you > want git versions...", > and possibly remove the 'easy_install/pip won't work' note, since I don't > believe that it is accurate when you install zeromq to /usr/local as you are > doing. > -MinRK >> >> Aaron Meurer >> >> On Sun, Aug 21, 2011 at 12:33 PM, MinRK wrote: >> > Aaron, >> > >> > Your pyzmq steps make it look more complicated than I think it is, if >> > users want released versions. ?There are eggs for osx 2.6,2,7, and >> > 3.2, so `easy_install pyzmq` works on osx under most circumstances, >> > and includes 32+64b UB libzmq, so you don't need to build and install >> > it separately. >> > >> > If you do want to build libzmq, you can use homebrew: `brew install >> > zeromq --universal` (the universal flag for specifying 32+64b). ?Since >> > this (as well as the default `./configure && make && make install`) >> > put libzmq in /usr/local, then pyzmq *is* pip-installable at this >> > point. >> > >> > -MinRK >> > >> > On Aug 21, 2011, at 11:03, Aaron Meurer wrote: >> > >> >> This is good. ?Mac OS X users are usually treated like Linux users in >> >> that they're expected to be command line savvy to install software >> >> (actually more than average, since Linux users at least have package >> >> managers). ?But really we should treat most of them the same as we do >> >> Windows users: people who may know Python, or at least are learning >> >> it, but aren't very comfortable with the "./configure;make;make >> >> install" process. >> >> >> >> By the way, if anyone's interested, I detailed the steps I took to >> >> install the qtconsole in Python 2 in Lion with the XCode 4 developer >> >> tools at >> >> https://github.com/sympy/sympy/wiki/Installing-the-IPython-qtconsole-in-Mac-OS-X. >> >> There's nothing too complicated; you just have to make sure that you >> >> get the right things from the right places. >> >> >> >> Some questions about shrubbery: >> >> >> >> First, how easy is it to add new packages? ?It looked to me like you >> >> have to edit several places throughout the file to do it, so that it's >> >> not trivial, especially if you don't know everywhere to edit the file. >> >> >> >> Second, I noticed that you are getting everything from git. Have you >> >> considered using git submodules? >> >> >> >> Third, are you considering to just include Python 3 with the installer? >> >> >> >> Aaron Meurer >> >> >> >> On Sun, Aug 21, 2011 at 3:18 AM, Grahame Bowland >> >> wrote: >> >>> Hi everyone >> >>> >> >>> I've spent the last few days coming up with a Python 3 distribution of >> >>> iPython and friends for Mac OS X. It now works (mostly), and I thought >> >>> I'd share it. >> >>> >> >>> The home page is here: >> >>> https://github.com/grahame/shrubbery >> >>> and I've put an experimental installer image here: >> >>> https://github.com/downloads/grahame/shrubbery/shrubbery.pkg >> >>> >> >>> For a long time I've maintained my Python setup by hand, installing >> >>> packages into /usr/local and eventually having a huge mess. Hence this >> >>> project - a distribution of software for Mac OS to make it easier for >> >>> people to get started with iPython. >> >>> >> >>> I've targeted Python 3 in the hope it'll encourage the porting of more >> >>> software to the new version of the language. >> >>> >> >>> There's not too much Mac OS specific about this, except that on Linux >> >>> you'd probably want to get packages from your distribution. If anyone >> >>> wants to make it work on other platforms that'd be great. >> >>> >> >>> Cheers >> >>> Grahame >> >>> _______________________________________________ >> >>> 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 takowl at gmail.com Sun Aug 21 16:07:12 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Sun, 21 Aug 2011 21:07:12 +0100 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: On 21 August 2011 14:29, Grahame Bowland wrote: > To reproduce the problems I'm seeing provoke a traceback: > def blah(): 1/0 > blah() > OK, I've tracked this down. Where we override raw_input() for the Qt console, we weren't updating that to input() in Python 3. It's fixed in my py3compat branch, which should land in master soon. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Sun Aug 21 16:27:27 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Sun, 21 Aug 2011 13:27:27 -0700 Subject: [IPython-dev] Announcing shrubbery In-Reply-To: References: Message-ID: Howdy, first, many thanks to Grahame for this! I've forwarded your post to matplotlib-dev, where I think there will also be a lot of interest. On Sun, Aug 21, 2011 at 11:03 AM, Aaron Meurer wrote: > By the way, if anyone's interested, I detailed the steps I took to > install the qtconsole in Python 2 in Lion with the XCode 4 developer > tools at https://github.com/sympy/sympy/wiki/Installing-the-IPython-qtconsole-in-Mac-OS-X. Very useful, thanks! Though it would be worth noting that the EPD alternative does exist for users who are OK with the prepackaging it offers and the fact that they get PySide instead of PyQt. While not as robust as your solution, it may be an easier alternative for users not too familiar with compilation machinery. Thanks to everyone for making this info available, it will greatly help newcomers! Cheers, f From takowl at gmail.com Mon Aug 22 08:01:12 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 22 Aug 2011 13:01:12 +0100 Subject: [IPython-dev] PythonAnywhere update, 18 August 2011 In-Reply-To: <4E52420B.4070907@pythonanywhere.com> References: <4E4CF79B.6080208@pythonanywhere.com> <4E4D3A29.60300@pythonanywhere.com> <4E52420B.4070907@pythonanywhere.com> Message-ID: On 22 August 2011 12:48, Giles Thomas wrote: > > Here you go: . > We use IPython with 2.7 for this one. If you're logged in to the main > PythonAnywhere pages, then it will display one of your IPython 2.7 consoles, > if you're not logged in then it will start a new one (which will then be > associated with your browser session and persist for at least a day). > > We've not put much text describing IPython yet, so if there's anything you > think we should say, we'd be glad to hear about it! Thanks, Giles. IPython people, take a look at the link above. I'd like to feature this as a link on the homepage, so new users can see what IPython does before they install it. Does this sound like a good idea? And what text would work next to it? I'm thinking along the lines of a brief list of things to try: - dict. (or a better example of tab completion) - Flipping through history - dict? - An easy to understand but clearly useful magic command. Maybe %time or %save. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Mon Aug 22 14:23:44 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 22 Aug 2011 11:23:44 -0700 Subject: [IPython-dev] PythonAnywhere update, 18 August 2011 In-Reply-To: References: <4E4CF79B.6080208@pythonanywhere.com> <4E4D3A29.60300@pythonanywhere.com> <4E52420B.4070907@pythonanywhere.com> Message-ID: On Mon, Aug 22, 2011 at 5:01 AM, Thomas Kluyver wrote: > > IPython people, take a look at the link above. I'd like to feature this as a > link on the homepage, so new users can see what IPython does before they > install it. Does this sound like a good idea? And what text would work next > to it? I'm thinking along the lines of a brief list of things to try: > - dict. (or a better example of tab completion) > - Flipping through history > - dict? > - An easy to understand but clearly useful magic command. Maybe %time or > %save. > Certainly! Thanks to the pythonanywhere team for this, it's very cool. Some more ideas (slightly more advanced): - %run, and further interactive exploration of the resulting variables. - %run, with an example script that has an error in it so they see tracebacks. - %debug I think the interplay between %run and interactive use is one of the key things people need to 'get' about using ipython productively.. Cheers, f From takowl at gmail.com Mon Aug 22 14:56:53 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 22 Aug 2011 19:56:53 +0100 Subject: [IPython-dev] IPython on PyPy Message-ID: Hi, We're looking at getting IPython running on PyPy, and readline doesn't appear to be working (tab completion, going through history, etc.). I see PyPy uses a readline module based on PyRepl. What's the status of this? Do we need to use the API differently? Do we need to help flesh out the implementation? If anyone would like to test this and lend a hand, please use this branch for the time being: https://github.com/takluyver/ipython/commits/pypy-compat Thanks, Thomas Kluyver -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Mon Aug 22 15:03:12 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 22 Aug 2011 12:03:12 -0700 Subject: [IPython-dev] IPython on PyPy In-Reply-To: References: Message-ID: Hey Thomas, On Mon, Aug 22, 2011 at 11:56 AM, Thomas Kluyver wrote: > > We're looking at getting IPython running on PyPy, and readline doesn't > appear to be working (tab completion, going through history, etc.). I see > PyPy uses a readline module based on PyRepl. What's the status of this? Do > we need to use the API differently? Do we need to help flesh out the > implementation? though for me, at least *some* parts of readline do work with 0.10.2. I've tested with pypy1.6 on a 0.10.2 virtualenv, and I get reasonable tab completion and arrows/cursor handling. History reverse search with Ctrl-r also works, though not the more basic up-arrow behavior we also enable. Just some more data. Cheers, f From takowl at gmail.com Mon Aug 22 15:15:12 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 22 Aug 2011 20:15:12 +0100 Subject: [IPython-dev] IPython on PyPy In-Reply-To: References: Message-ID: On 22 August 2011 20:03, Fernando Perez wrote: > though for me, at least *some* parts of readline do work with 0.10.2. > I've tested with pypy1.6 on a 0.10.2 virtualenv, and I get reasonable > tab completion and arrows/cursor handling. History reverse search > with Ctrl-r also works, though not the more basic up-arrow behavior we > also enable. > OK, that's interesting. My message to pypy-dev bounced (only subscribers can post), so I'll have a play around and see if I can work out where the difference comes from. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Mon Aug 22 16:57:39 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 22 Aug 2011 21:57:39 +0100 Subject: [IPython-dev] IPython on PyPy In-Reply-To: References: Message-ID: On 22 August 2011 20:15, Thomas Kluyver wrote: > On 22 August 2011 20:03, Fernando Perez wrote: > >> though for me, at least *some* parts of readline do work with 0.10.2. >> I've tested with pypy1.6 on a 0.10.2 virtualenv, and I get reasonable >> tab completion and arrows/cursor handling. History reverse search >> with Ctrl-r also works, though not the more basic up-arrow behavior we >> also enable. >> > > OK, that's interesting. My message to pypy-dev bounced (only subscribers > can post), so I'll have a play around and see if I can work out where the > difference comes from. > Worked it out, after some confusion. PyPy's readline module works by replacing the stock raw_input function, but that only happens after we've saved a reference to the unmodified raw_input, which we do precisely to defend against things replacing raw_input. I think the best way to do it is to move our saving of raw_input_original from import time to the instantiation of InteractiveShell, just after init_readline is called. I've just pushed a commit doing this to my pypy-compat branch (PR 722). Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From jorgen.stenarson at bostream.nu Tue Aug 23 09:52:49 2011 From: jorgen.stenarson at bostream.nu (=?ISO-8859-1?Q?J=F6rgen_Stenarson?=) Date: Tue, 23 Aug 2011 15:52:49 +0200 Subject: [IPython-dev] Is anyone going to euroscipy? In-Reply-To: References: <4E1CA1D0.8040101@bostream.nu> <20110714194957.GE15788@phare.normalesup.org> <4E4392F2.2010301@bostream.nu> Message-ID: <4E53B0B1.10108@bostream.nu> On 2011-08-11 20:52, Fernando Perez wrote: > Hi folks, > > On Thu, Aug 11, 2011 at 3:13 AM, Thomas Kluyver wrote: >> Sorry, I've now worked out that I won't be getting there until the 26th (I'm >> staying for a few days after the conference), so I can't make it to the >> sprint days. If there are rooms available on the conference days, maybe we >> could grab a couple of hours in the afternoon - in particular, I notice the >> last talk on Sunday is scheduled to finish at 15.30. > I create a page on the wiki where we can track info about arrival > dates, sprint details, etc: > > http://wiki.ipython.org/EuroSciPy2011 > > Anyone who will be coming to EuroScipy2011 and is interested in > working on IPython-related things, please add your name and > availability there. Once we have a full picture of who's around and > when, we'll organize what to do. > > Cheers, > > f I added my cellphone number to that page if you want to contact me before the conference. See you there. /J?rgen From fperez.net at gmail.com Tue Aug 23 11:02:15 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 23 Aug 2011 08:02:15 -0700 Subject: [IPython-dev] Is anyone going to euroscipy? In-Reply-To: <4E53B0B1.10108@bostream.nu> References: <4E1CA1D0.8040101@bostream.nu> <20110714194957.GE15788@phare.normalesup.org> <4E4392F2.2010301@bostream.nu> <4E53B0B1.10108@bostream.nu> Message-ID: On Tue, Aug 23, 2011 at 6:52 AM, J?rgen Stenarson wrote: > I added my cellphone number to that page if you want to contact me > before the conference. See you there. OK, leaving for the airport right now, barring any glitches I should be in around noon on Wednesday at 24 rue Lhomond. Cheers, f From carl.input at gmail.com Tue Aug 23 12:47:11 2011 From: carl.input at gmail.com (Carl Joseph Younger) Date: Tue, 23 Aug 2011 17:47:11 +0100 Subject: [IPython-dev] Python Anywhere Message-ID: They've just added IPython3, on version 0.11. Their's is more up to date than mine now. If you've not been on the site recently, you should take a look. It's getting very interesting. From fperez.net at gmail.com Tue Aug 23 13:26:52 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 23 Aug 2011 10:26:52 -0700 Subject: [IPython-dev] Is anyone going to euroscipy? In-Reply-To: References: <4E1CA1D0.8040101@bostream.nu> <20110714194957.GE15788@phare.normalesup.org> <4E4392F2.2010301@bostream.nu> <4E53B0B1.10108@bostream.nu> Message-ID: On Tue, Aug 23, 2011 at 8:02 AM, Fernando Perez wrote: > > OK, leaving for the airport right now, barring any glitches I should > be in around noon on Wednesday at 24 rue Lhomond. Argh, scratch that; glitch already happened. Bad weather in Chicago got me rerouted on a different flight. I'll only be arriving in Paris itself at 2pm (instead of 9am) so it will probably be late afternoon before I'm in town, checked in, etc. I'll ping via email from the hotel in case there's still activity, but it looks like I'll miss most, if not all, the activity of the day. Bummer. Cheers, f From fperez.net at gmail.com Tue Aug 23 13:29:50 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 23 Aug 2011 10:29:50 -0700 Subject: [IPython-dev] Python Anywhere In-Reply-To: References: Message-ID: On Tue, Aug 23, 2011 at 9:47 AM, Carl Joseph Younger wrote: > They've just added IPython3, on version 0.11. Their's is more up to > date than mine now. > > If you've not been on the site recently, you should take a look. It's > getting very interesting. Yes, we've been in touch with them; they've done a terrific job. We'll have a chance to talk to some of their team this week at Euroscipy. Cheers, f From takowl at gmail.com Tue Aug 23 17:07:53 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 23 Aug 2011 22:07:53 +0100 Subject: [IPython-dev] Doctests & Python 3 Message-ID: I'd like to get the doctests working on Python 3, but I'm not sure about the best way to do it. I think most of the problems are with print statements, and it seems distribute doesn't recognise IPython doctests in order to convert them during the build step (as it does with regular doctests). A few options: 1. Use a regex to transform print statements in the doctest parser. 2. Transform any doctests using print where they are defined, with a helper function/decorator. Slight performance penalty to starting IPython, because we'll be transforming a number of doctests as we import modules. On the plus side, examples in docstrings will automatically be correct in Python 3. Regex transform is a bit trickier than 1, because the source is mixed up with prompts etc. 3. Add print statements to doctests as the output of a doctest_print helper function (so doctest_print("x", file="outfile") returns "print >>outfile, x" on Python 2). Much the same pros and cons as 2. 4. Write all doctests with print as a function, and run them on Python 2 with "from __future__ import print_function". No performance penalty when loading IPython, but more confusing for anyone reading the code. I've not got a strong feeling about which is best. I'd probably lean towards 1 or 2, but I'd like some other opinions. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From asmeurer at gmail.com Tue Aug 23 17:33:14 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Tue, 23 Aug 2011 15:33:14 -0600 Subject: [IPython-dev] Doctests & Python 3 In-Reply-To: References: Message-ID: There is a -d option to 2to3 that should do the necessary transformations for you. Also, if you don't actually use the fact that it's a function, you don't have to import print_function from __future__ to use the print(1) syntax in Python 2. Aaron Meurer On Tue, Aug 23, 2011 at 3:07 PM, Thomas Kluyver wrote: > I'd like to get the doctests working on Python 3, but I'm not sure about the > best way to do it. I think most of the problems are with print statements, > and it seems distribute doesn't recognise IPython doctests in order to > convert them during the build step (as it does with regular doctests). A few > options: > > 1. Use a regex to transform print statements in the doctest parser. > 2. Transform any doctests using print where they are defined, with a helper > function/decorator. Slight performance penalty to starting IPython, because > we'll be transforming a number of doctests as we import modules. On the plus > side, examples in docstrings will automatically be correct in Python 3. > Regex transform is a bit trickier than 1, because the source is mixed up > with prompts etc. > 3. Add print statements to doctests as the output of a doctest_print helper > function (so doctest_print("x", file="outfile") returns "print >>outfile, x" > on Python 2). Much the same pros and cons as 2. > 4. Write all doctests with print as a function, and run them on Python 2 > with "from __future__ import print_function". No performance penalty when > loading IPython, but more confusing for anyone reading the code. > > I've not got a strong feeling about which is best. I'd probably lean towards > 1 or 2, but I'd like some other opinions. > > Thanks, > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > From takowl at gmail.com Tue Aug 23 18:24:17 2011 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 23 Aug 2011 23:24:17 +0100 Subject: [IPython-dev] Doctests & Python 3 In-Reply-To: References: Message-ID: On 23 August 2011 22:33, Aaron Meurer wrote: > There is a -d option to 2to3 that should do the necessary > transformations for you. > Indeed, and distribute should be doing that (albeit not via a command line flag) in the build process. But it seems like it doesn't recognise IPython doctests (with our "In [1]:" style prompts). If anyone knows of a way to extend it to pick that up, that would be the neatest solution, but I don't know if it's possible. > Also, if you don't actually use the fact that it's a function, you > don't have to import print_function from __future__ to use the > print(1) syntax in Python 2. > But print(1,2) will print a tuple, rather than "1 2". If we're going to go down the route of using the new syntax for doctests, it should be simple enough to use print_function. But it's not ideal to have to write all our Python 2 doctests using Python 3 syntax (although I've already tweaked a few minor bits, like list(range(n)) and a//b, for consistency). Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From asmeurer at gmail.com Tue Aug 23 18:38:07 2011 From: asmeurer at gmail.com (Aaron Meurer) Date: Tue, 23 Aug 2011 16:38:07 -0600 Subject: [IPython-dev] Doctests & Python 3 In-Reply-To: References: Message-ID: Ah, I didn't realize you used doctests like that. I'd recommend writing a program that runs 2to3 on the IPython doctests rather than rewriting the regular expressions yourself. Aaron Meurer On Tue, Aug 23, 2011 at 4:24 PM, Thomas Kluyver wrote: > On 23 August 2011 22:33, Aaron Meurer wrote: >> >> There is a -d option to 2to3 that should do the necessary >> transformations for you. > > Indeed, and distribute should be doing that (albeit not via a command line > flag) in the build process. But it seems like it doesn't recognise IPython > doctests (with our "In [1]:" style prompts). If anyone knows of a way to > extend it to pick that up, that would be the neatest solution, but I don't > know if it's possible. > >> >> Also, if you don't actually use the fact that it's a function, you >> don't have to import print_function from __future__ to use the >> print(1) syntax in Python 2. > > But print(1,2) will print a tuple, rather than "1 2". If we're going to go > down the route of using the new syntax for doctests, it should be simple > enough to use print_function. But it's not ideal to have to write all our > Python 2 doctests using Python 3 syntax (although I've already tweaked a few > minor bits, like list(range(n)) and a//b, for consistency). > > Thanks, > Thomas > > From gokhansever at gmail.com Wed Aug 24 14:57:26 2011 From: gokhansever at gmail.com (=?UTF-8?Q?G=C3=B6khan_Sever?=) Date: Wed, 24 Aug 2011 12:57:26 -0600 Subject: [IPython-dev] An issue using matplotlib in the new ipython Message-ID: Hi, Using the new IPython with --pylab option: Creating a simple plot via plt.plot(range(10)) then typing in the shell for example: plt.plot? and getting the help blocks the figure. Is this a known issue? I don't recall seeing this behavior in the previous IPython. matplotlib.__version__ '1.1.0' using Qt4Agg also confirmed with WXAgg Also noting a minor typo at https://github.com/matplotlib/matplotlib/blob/master/lib/matplotlib/axes.py line 4360: The loc "itslef" ->itself can be a 2-tuple giving x,y of the lower-left corner of Thanks -- G?khan From efiring at hawaii.edu Wed Aug 24 15:49:34 2011 From: efiring at hawaii.edu (Eric Firing) Date: Wed, 24 Aug 2011 09:49:34 -1000 Subject: [IPython-dev] An issue using matplotlib in the new ipython In-Reply-To: References: Message-ID: <4E5555CE.3000408@hawaii.edu> On 08/24/2011 08:57 AM, G?khan Sever wrote: > Hi, > > Using the new IPython with --pylab option: > > Creating a simple plot via > > plt.plot(range(10)) > > then typing in the shell for example: > > plt.plot? and getting the help blocks the figure. Is this a known > issue? I don't recall seeing this behavior in the previous IPython. It does result from the major change in how IPython handles the guis; it is now relying on PyOS_InputHook and leaving everything in a single thread instead of running the gui mainloop in a separate thread. Getting help shells out to the pager ("less" on linux), so nothing gets updated until that process is ended--the python process itself is waiting for it rather than checking for text input. I imagine the only ways to get around that without multi-threading would be if the external pager were replaced with python code, or if "less" could be run in the background. I suspect the latter would be difficult if not impossible, since "less" would still need console IO. The ipython qtconsole avoids this problem--but you have to have qt, of course. Eric > > matplotlib.__version__ > '1.1.0' > > using Qt4Agg also confirmed with WXAgg > > Also noting a minor typo at > > https://github.com/matplotlib/matplotlib/blob/master/lib/matplotlib/axes.py > line 4360: > > The loc "itslef" ->itself can be a 2-tuple giving x,y of the > lower-left corner of > > Thanks > > From gokhansever at gmail.com Wed Aug 24 16:14:17 2011 From: gokhansever at gmail.com (=?UTF-8?Q?G=C3=B6khan_Sever?=) Date: Wed, 24 Aug 2011 14:14:17 -0600 Subject: [IPython-dev] An issue using matplotlib in the new ipython In-Reply-To: <4E5555CE.3000408@hawaii.edu> References: <4E5555CE.3000408@hawaii.edu> Message-ID: On Wed, Aug 24, 2011 at 1:49 PM, Eric Firing wrote: > On 08/24/2011 08:57 AM, G?khan Sever wrote: >> Hi, >> >> Using the new IPython with --pylab option: >> >> Creating a simple plot via >> >> plt.plot(range(10)) >> >> then typing in the shell for example: >> >> plt.plot? and getting the help blocks the figure. Is this a known >> issue? I don't recall seeing this behavior in the previous IPython. > > It does result from the major change in how IPython handles the guis; it > is now relying on PyOS_InputHook and leaving everything in a single > thread instead of running the gui mainloop in a separate thread. > Getting help shells out to the pager ("less" on linux), so nothing gets > updated until that process is ended--the python process itself is > waiting for it rather than checking for text input. ?I imagine the only > ways to get around that without multi-threading would be if the external > pager were replaced with python code, or if "less" could be run in the > background. ?I suspect the latter would be difficult if not impossible, > since "less" would still need console IO. > > The ipython qtconsole avoids this problem--but you have to have qt, of > course. qtconsole works fine. Thanks for the tip. -- G?khan From allen.fowler at yahoo.com Fri Aug 26 07:15:08 2011 From: allen.fowler at yahoo.com (Allen Fowler) Date: Fri, 26 Aug 2011 04:15:08 -0700 (PDT) Subject: [IPython-dev] I am making 779.58$ every day from your computer! Message-ID: <1314357308.21191.YahooMailClassic@web114013.mail.gq1.yahoo.com> Hey hey if u would you like to gain a income from your computer go to www.localtimesnow.org/nk4tp/9377/8377 From fperez.net at gmail.com Fri Aug 26 11:49:55 2011 From: fperez.net at gmail.com (Fernando Perez) Date: Fri, 26 Aug 2011 17:49:55 +0200 Subject: [IPython-dev] I am making 779.58$ every day from your computer! In-Reply-To: <1314357308.21191.YahooMailClassic@web114013.mail.gq1.yahoo.com> References: <1314357308.21191.YahooMailClassic@web114013.mail.gq1.yahoo.com> Message-ID: Sorry folks, it looks like a hijacked account. I've disabled it from posting. On Fri, Aug 26, 2011 at 1:15 PM, Allen Fowler wrote: > Hey hey if u would you like to gain a income from your computer go to www.localtimesnow.org/nk4tp/9377/8377 > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From Nicolas.Rougier at inria.fr Fri Aug 26 13:30:52 2011 From: Nicolas.Rougier at inria.fr (Nicolas Rougier) Date: Fri, 26 Aug 2011 19:30:52 +0200 Subject: [IPython-dev] Experimental GLUT integration Message-ID: <08A5BCE9-54BB-4878-8C92-25CDEC87EF4E@inria.fr> Hi Folks, I've coded an experimental GLUT integration (thanks to Fernando's explanations) for the new input hook system. I would like to know if people could test it and review if the code's ok.There is also an integration example in the docs/examples/lib/gui-glut.py You should be able to type: In [5]: %gui glut In [6]: %run gui-glut.py At this point a small black window should appear In [7]: gl.glClearColor(1,1,1,1) The window color should change to white. Link: https://github.com/rougier/ipython/compare/master?glut Nicolas From Nicolas.Rougier at inria.fr Sat Aug 27 02:10:41 2011 From: Nicolas.Rougier at inria.fr (Nicolas Rougier) Date: Sat, 27 Aug 2011 08:10:41 +0200 Subject: [IPython-dev] Experimental pyglet integration Message-ID: <93D0BC53-C642-451F-B367-DFC9B9BF465B@inria.fr> I've also coded the pyglet version for the event loop integration. https://github.com/rougier/ipython/compare/master?pyglet (I posted the announce to pyglet users forum and waiting for some feedback before asking for merge). Nicolas From efiring at hawaii.edu Sat Aug 27 18:48:53 2011 From: efiring at hawaii.edu (Eric Firing) Date: Sat, 27 Aug 2011 12:48:53 -1000 Subject: [IPython-dev] An issue using matplotlib in the new ipython In-Reply-To: References: Message-ID: <4E597455.7010506@hawaii.edu> On 08/24/2011 08:57 AM, G?khan Sever wrote: > Hi, > > Using the new IPython with --pylab option: > > Creating a simple plot via > > plt.plot(range(10)) > > then typing in the shell for example: > > plt.plot? and getting the help blocks the figure. Is this a known > issue? I don't recall seeing this behavior in the previous IPython. See https://github.com/ipython/ipython/pull/741. Eric > > matplotlib.__version__ > '1.1.0' > > using Qt4Agg also confirmed with WXAgg > > Also noting a minor typo at > > https://github.com/matplotlib/matplotlib/blob/master/lib/matplotlib/axes.py > line 4360: > > The loc "itslef" ->itself can be a 2-tuple giving x,y of the > lower-left corner of > > Thanks > > From zachary.pincus at yale.edu Sun Aug 28 03:45:15 2011 From: zachary.pincus at yale.edu (Zachary Pincus) Date: Sun, 28 Aug 2011 02:45:15 -0500 Subject: [IPython-dev] Experimental pyglet integration In-Reply-To: <93D0BC53-C642-451F-B367-DFC9B9BF465B@inria.fr> References: <93D0BC53-C642-451F-B367-DFC9B9BF465B@inria.fr> Message-ID: Fantastic! I'll try to play with this when I next get a chance. Thanks a ton for working this up. Zach On Aug 27, 2011, at 1:10 AM, Nicolas Rougier wrote: > > > I've also coded the pyglet version for the event loop integration. > > https://github.com/rougier/ipython/compare/master?pyglet > > > (I posted the announce to pyglet users forum and waiting for some feedback before asking for merge). > > > Nicolas > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From srossross at gmail.com Mon Aug 29 14:18:47 2011 From: srossross at gmail.com (Sean Ross-Ross) Date: Mon, 29 Aug 2011 13:18:47 -0500 Subject: [IPython-dev] XREQ/XREP socets Message-ID: Hello, I've been playing around with the new socketed API and I have a few questions. My end goal is to create a simple javascript server. But for now I'm trying to see if I understand how the sockets work. In my testing I start an ipython kernel: $ ipython qtconsole [IPKernelApp] To connect another client to this kernel, use: [IPKernelApp] --existing --shell=49785 --iopub=49786 --stdin=49787 --hb=49788 Then, in another terminal I try to send a command manually to the shell socket (using python): import socket import json shell_sock = socket.create_connection(('localhost',49785)) header = { 'msg_id' : 'uuid-123', 'username': 'sean', 'session': '??', 'msg_type': 'connect_request', } msg = dict(parent_header=parent_header, header=header, content=content) msg_str = json.dumps(msg) shell_sock.send(msg_str) shell_sock.recv(1024**2) This does not work, and I do not get any response. Why? I would use zmq but the server is implemented in javascript. I also can not use ajax or jquery from the client-side html notebook app because this is on the server side. Thanks in advance. ~Sean -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Mon Aug 29 18:27:46 2011 From: ellisonbg at gmail.com (Brian Granger) Date: Mon, 29 Aug 2011 15:27:46 -0700 Subject: [IPython-dev] XREQ/XREP socets In-Reply-To: References: Message-ID: IPython uses PyZMQ/ZeroMQ for its sockets, so you will need to download them here: https://github.com/zeromq/pyzmq http://www.zeromq.org/intro:get-the-software Cheers, Brian On Mon, Aug 29, 2011 at 11:18 AM, Sean Ross-Ross wrote: > Hello, I've been playing around with the new socketed API and I have a few > questions. > My end goal is to create a simple javascript server. But for now I'm trying > to see if I understand how the sockets work. > In my testing I start an ipython kernel: > > $ ipython qtconsole > [IPKernelApp] To connect another client to this kernel, use: > [IPKernelApp] --existing --shell=49785 --iopub=49786 --stdin=49787 > --hb=49788 > > Then, in another terminal I try to send a command manually to the shell > socket (using python): > > import socket > import json > shell_sock = socket.create_connection(('localhost',49785)) > header = { 'msg_id' : 'uuid-123', 'username': 'sean', 'session': '??', > 'msg_type': 'connect_request', } > msg = dict(parent_header=parent_header, header=header, content=content) > msg_str = json.dumps(msg) > shell_sock.send(msg_str) > shell_sock.recv(1024**2) > > This does not work, and I do not get any response. Why? I would use zmq but > the server is implemented in javascript. ?I also can not use ajax or jquery > from the client-side html notebook app because this is on the server side. > Thanks in advance. > ~Sean > > _______________________________________________ > 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 bgranger at calpoly.edu and ellisonbg at gmail.com From srossross at gmail.com Wed Aug 31 11:41:31 2011 From: srossross at gmail.com (Sean Ross-Ross) Date: Wed, 31 Aug 2011 10:41:31 -0500 Subject: [IPython-dev] XREQ/XREP socets In-Reply-To: References: Message-ID: Thanks for the response Brian, I asked about avoiding the ZeroMQ layer because: 1) From the documentation It looks like the sending of JSON data across sockets is supposed to be technology independent. I this a correct assumption, or is ZMQ a hard dependency? 2) The javascript server already implements an asynchronous sockets layer, it seems like an unnecessary step to install the zmq/javascript bindings. On Aug 29, 2011, at 5:27 PM, Brian Granger wrote: > IPython uses PyZMQ/ZeroMQ for its sockets, so you will need to > download them here: > > https://github.com/zeromq/pyzmq > http://www.zeromq.org/intro:get-the-software > > Cheers, > > Brian > > On Mon, Aug 29, 2011 at 11:18 AM, Sean Ross-Ross wrote: >> Hello, I've been playing around with the new socketed API and I have a few >> questions. >> My end goal is to create a simple javascript server. But for now I'm trying >> to see if I understand how the sockets work. >> In my testing I start an ipython kernel: >> >> $ ipython qtconsole >> [IPKernelApp] To connect another client to this kernel, use: >> [IPKernelApp] --existing --shell=49785 --iopub=49786 --stdin=49787 >> --hb=49788 >> >> Then, in another terminal I try to send a command manually to the shell >> socket (using python): >> >> import socket >> import json >> shell_sock = socket.create_connection(('localhost',49785)) >> header = { 'msg_id' : 'uuid-123', 'username': 'sean', 'session': '??', >> 'msg_type': 'connect_request', } >> msg = dict(parent_header=parent_header, header=header, content=content) >> msg_str = json.dumps(msg) >> shell_sock.send(msg_str) >> shell_sock.recv(1024**2) >> >> This does not work, and I do not get any response. Why? I would use zmq but >> the server is implemented in javascript. I also can not use ajax or jquery >> from the client-side html notebook app because this is on the server side. >> Thanks in advance. >> ~Sean >> >> _______________________________________________ >> 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 > bgranger at calpoly.edu and ellisonbg at gmail.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Wed Aug 31 12:54:31 2011 From: ellisonbg at gmail.com (Brian Granger) Date: Wed, 31 Aug 2011 09:54:31 -0700 Subject: [IPython-dev] XREQ/XREP socets In-Reply-To: References: Message-ID: On Wed, Aug 31, 2011 at 8:41 AM, Sean Ross-Ross wrote: > Thanks for the response Brian, I asked about avoiding the ZeroMQ layer > because: > > 1) From the documentation It looks like the sending of JSON data across > sockets is supposed to be technology independent. I this a correct > assumption, ?or is ZMQ a hard dependency? ZMQ is definitely a hard dependency unless you want to implement the ZMQ framing procotol and queuing on top of raw TCP sockets. But I highly advise agains doing that for the following reasons: * There are binary installers for pyzmq that include zmq for most platforms. * With raw Python sockets You will quickly run into the limitations of the GIL. ZMQ does all of its send/recv/queue logic in C level threads with the GIL released, so it doesn't have that limitation. * ZMQ sockets "just work" so you won't have to reinvent wheel. * Reimplementing ZMQ on top of sockets in Python will be a huge project and maintaining it will be significant effort because ZMQ it evolving quickly. > 2) The javascript server already implements an asynchronous sockets layer, > it seems like an unnecessary step to install the zmq/javascript bindings. All ZMQ stuff is done using PyZMQ, and there is no zmq/javascript bindings. And all of the existing async socket layer in the notebook server is PyZMQ based sockets, not raw sockets. Can you describe more of what you are trying to do? Cheers, Brian > > On Aug 29, 2011, at 5:27 PM, Brian Granger wrote: > > IPython uses PyZMQ/ZeroMQ for its sockets, so you will need to > download them here: > > https://github.com/zeromq/pyzmq > http://www.zeromq.org/intro:get-the-software > > Cheers, > > Brian > > On Mon, Aug 29, 2011 at 11:18 AM, Sean Ross-Ross > wrote: > > Hello, I've been playing around with the new socketed API and I have a few > > questions. > > My end goal is to create a simple javascript server. But for now I'm trying > > to see if I understand how the sockets work. > > In my testing I start an ipython kernel: > > $ ipython qtconsole > > [IPKernelApp] To connect another client to this kernel, use: > > [IPKernelApp] --existing --shell=49785 --iopub=49786 --stdin=49787 > > --hb=49788 > > Then, in another terminal I try to send a command manually to the shell > > socket (using python): > > import socket > > import json > > shell_sock = socket.create_connection(('localhost',49785)) > > header = { 'msg_id' : 'uuid-123', 'username': 'sean', 'session': '??', > > 'msg_type': 'connect_request', } > > msg = dict(parent_header=parent_header, header=header, content=content) > > msg_str = json.dumps(msg) > > shell_sock.send(msg_str) > > shell_sock.recv(1024**2) > > This does not work, and I do not get any response. Why? I would use zmq but > > the server is implemented in javascript. ?I also can not use ajax or jquery > > from the client-side html notebook app because this is on the server side. > > Thanks in advance. > > ~Sean > > _______________________________________________ > > 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 > bgranger at calpoly.edu and ellisonbg at gmail.com > > -- Brian E. Granger Cal Poly State University, San Luis Obispo bgranger at calpoly.edu and ellisonbg at gmail.com