<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/2.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>Moderate Realism</title>
	<link>http://ramblings.timgolden.me.uk</link>
	<description>The ramblings of Tim Golden</description>
	<pubDate>Fri, 03 Feb 2012 11:28:33 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.2</generator>
	<language>en</language>
			<item>
		<title>We survived! A London Python Dojo without @ntoll</title>
		<link>http://ramblings.timgolden.me.uk/2012/02/03/we-survived-a-london-python-dojo-without-ntoll/</link>
		<comments>http://ramblings.timgolden.me.uk/2012/02/03/we-survived-a-london-python-dojo-without-ntoll/#comments</comments>
		<pubDate>Fri, 03 Feb 2012 11:09:02 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Dojo]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2012/02/03/we-survived-a-london-python-dojo-without-ntoll/</guid>
		<description><![CDATA[[Note to self: blog about things other than the London Dojo&#8230;]
Nicholas &#8220;@ntoll&#8221; Tollervey has been the London Python Dojo&#8217;s parent for all its young life. Once it achieved toddler status, he felt confident enough to start letting other people look after his baby, so over the past few Dojos various other people have run things [...]]]></description>
			<content:encoded><![CDATA[<p>[Note to self: blog about things other than the London Dojo&#8230;]</p>
<p>Nicholas &#8220;@ntoll&#8221; Tollervey has been the London Python Dojo&#8217;s parent for all its young life. Once it achieved toddler status, he felt confident enough to start letting other people look after his baby, so over the past few Dojos various other people have run things on the day, always with @ntoll in attendance. Yesterday was the first day on which he felt confident enough not to be there, leaving things in the hands of @tomviner (who could be seen consulting a trusty checklist throughout the evening).</p>
<p>As I re-read, I realise that it looks as though I&#8217;m accusing @ntoll of being over-possessive, which I most definitely am not. He&#8217;s done &#8212; and continues to do &#8212; a fantastic job at organising the Dojo and making it happen even when he&#8217;s not the evening&#8217;s MC. We&#8217;re just delighted, as Tom said last night, that he doesn&#8217;t feel that he needs to attend it every first Thursday for the rest of his life. (A little secret: the day before this month&#8217;s Dojo he was still sending mother-like emails to the rest of the organisers: don&#8217;t forget to &#8230; remember that &#8230; have you &#8230;?)</p>
<p>Last night&#8217;s Dojo was fun as usual: we were doing the famous <a href="http://en.wikipedia.org/wiki/Conway%27s_Game_of_Life">Game of Life</a> &#8212; probably a text book example of a text book example! Uniquely in my experience, every team had a working version to show after just an hour and a half. The team I was in managed to get something working while @john_chandler and I were still chatting in the background. We fiddled about with it a bit, adding a few preset forms to seed the board etc.</p>
<p>An unexpected visitor was @JohnPinner (of PyConUK fame). He was in London for a meeting and timed things so he could come along for the start of the Dojo, altho&#8217; he had to dash after about an hour to catch his train home. He gave a lightning talk at the beginning outlining various Python-related conferences and training sessions which in the offing. Including this year&#8217;s <a href="http://pyuk2012.pyconuk.org/">PyConUK</a>, once again in Coventry.</p>
<p>@tomviner&#8217;s novelty for this Dojo was the favourite-module question on the sign-up form, which was also used as part of the introduction session. Perhaps unsurprisingly, Kenneth Reitz&#8217;s <a href="http://docs.python-requests.org/en/latest/index.html">requests</a> module was the clear winner (the only one with more than one vote!). Other unsurprising entries included itertools and collections, but there was a variety of others. I was chatting with John Pinner about the line-up for PyConUK this year, and he pointed out that there&#8217;s some mileage for simple talks about a particular module, eg logging or itertools. I&#8217;m thinking of proposing such a thing for future Dojos&#8230;</p>
<p>There&#8217;s also been <a href="http://mail.python.org/pipermail/python-uk/2012-January/002399.html">talk on the python-uk mailing list</a> of a second London-based Dojo, or other Python event, on a Sunday. That might suit some people who can&#8217;t make a weekday evening in London but who could manage a weekend. And the more Python events in London the better!</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2012/02/03/we-survived-a-london-python-dojo-without-ntoll/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Boggle at the London Python Dojo</title>
		<link>http://ramblings.timgolden.me.uk/2011/12/02/boggle-at-the-london-python-dojo/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/12/02/boggle-at-the-london-python-dojo/#comments</comments>
		<pubDate>Fri, 02 Dec 2011 13:55:18 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Dojo]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/12/02/boggle-at-the-london-python-dojo/</guid>
		<description><![CDATA[(Yes, that is a deliberately ambiguous title offering two possible interpretations: as a description of what the programming challenge was at last night&#8217;s Dojo; or as an imperative to be awed at the might and wonder that is the London Python Dojo. You choose).
Last night was the first time I&#8217;ve actually run the London Dojo. [...]]]></description>
			<content:encoded><![CDATA[<p>(Yes, that is a deliberately ambiguous title offering two possible interpretations: as a description of what the programming challenge was at last night&#8217;s Dojo; or as an imperative to be awed at the might and wonder that is the London Python Dojo. You choose).</p>
<p>Last night was the first time I&#8217;ve actually run the London Dojo. For the two and more years since its inception, Nicholas Tollervey (<a href="http://twitter.com/ntoll">@ntoll</a> to his Twitter friends &#038; acquaintances) has indefatigably turned up every first Thursday to clear up the Fry-IT offices, order the pizza, buy the beer, put up signs, leave out sticky labels, request free books from O&#8217;Reilly and then drum up support, keep everyone happy and actually run the show, finishing off by organising everyone to clear up, move chairs, dump the rubbish outside, and finally catch the last train home to Sticksville, Northants. where his wife and children have long ago fallen asleep over their sheet music, having gone da Capo al Segno one time too many waiting for him to return home.</p>
<p>A few months ago, Nicholas asked for volunteers to help out, and a small group of us got together to share the burden. Since then, <a href="http://twitter.com/otfrom">Bruce</a>, <a href="http://twitter.com/tartley">Jonathan</a>, <a href="http://twitter.com/tomviner">Tom</a> and finally <a href="http://twitter.com/tjguk">I</a> have taken a turn at organising. And of course it&#8217;s not until you have to do it yourself that you realise how much work is involved&#8230; I was fortunate because Gautier (who actually works there) and Nicholas himself were both at Fry-IT for the day and were able to do some of the less proximate preparation, including ordering a dozen pizzas and buying three dozen bottles of beer. I was able to make a small contribution in the shape of a pack of sticky labels.</p>
<p>The Dojo itself was very slightly quieter than usual: just under 20 rather than just under 30. That&#8217;s not a bad thing in Fry&#8217;s offices which are not huge. There was a bit of an introduce-yourself session (which was made even more primary-school-like by the presence of big sticky labels on everyone&#8217;s chest with their names or cognomens). And then we had a lightning talk from Martin who has a sort of <a href="http://amon.cx/">cut-down Nagios for app developers</a>. (I hope I haven&#8217;t done it an injustice). And then a surprisingly straightforward vote on the evening&#8217;s programming challenge which gave us&#8230; Boggle. (Word game; 8&#215;8 grid of random letters; form words by moving like a chess king).</p>
<p>Four teams; four solutions, all more or less different. Only one team ended up with a working solution at the end of 90 minutes (and they appeared to be optimising by removing all vertical whitespace; or maybe that was an aesthetic choice - who knows?). Our team had visible activity (which is more than Team 1 managed!) but no solution. It&#8217;s up to each team how they want to manage their collaboration. We&#8217;d gone for the split-team approach, dividing the problem into its eminently decoupled parts: a mechanism to read in a dictionary of words and provide efficient searchability (using a Trie, in case you&#8217;re interested); and a structure to hold the board (a dictionary, keyed on coordinates), generate the letters into the grid, and search for all possible words, relying on the dictionary code to indicate success, failure, partial success, or success with more possibilities.</p>
<p>The tweets were still flying this morning as people tried to tweak their solution (or, indeed, get it to work at all) on the train, on their phone or at home overnight. A friend of mine who&#8217;s a C++ coder came along mainly because I&#8217;d talked so much about the Dojo. He&#8217;s not really into Python - in fact he&#8217;s not really a programmer: he does medical image analysis. But he enjoyed the atmosphere and made a few small suggestions before simply sitting back and watching the teams get to work.</p>
<p>Look out for the next Dojo at the beginning of January. It&#8217;ll be announced on the python-uk mailing list and we&#8217;ll tweet about it when we&#8217;ve fixed a date.</p>
<p><b>UPDATE</b> Dirk&#8217;s added a blog post of his own:<br />
<a href="http://elazungu.wordpress.com/2011/12/02/solving-boggle-with-python/">http://elazungu.wordpress.com/2011/12/02/solving-boggle-with-python/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/12/02/boggle-at-the-london-python-dojo/feed/</wfw:commentRss>
		</item>
		<item>
		<title>New place, new time, same great Dojo</title>
		<link>http://ramblings.timgolden.me.uk/2011/11/04/new-place-new-time-same-great-dojo/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/11/04/new-place-new-time-same-great-dojo/#comments</comments>
		<pubDate>Fri, 04 Nov 2011 08:42:09 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Dojo]]></category>

		<category><![CDATA[London]]></category>

		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/11/04/new-place-new-time-same-great-dojo/</guid>
		<description><![CDATA[Last night, the London Python Dojo were the guests of Mendeley on the Clerkenwell Road. I was pleased to discover while chatting over the pizza and beer that I wasn&#8217;t the only one to have wandered round the area a few times before hitting on the right spot. Although I had a map of some [...]]]></description>
			<content:encoded><![CDATA[<p>Last night, the London Python Dojo were the guests of <a href="http://www.mendeley.com/">Mendeley</a> on the Clerkenwell Road. I was pleased to discover while chatting over the pizza and beer that I wasn&#8217;t the only one to have wandered round the area a few times before hitting on the right spot. Although I had a map of some sort, I&#8217;d forgotten just how cluttered central London is: how many passageways, tucked-away building and unlabelled streets.</p>
<p>But it was worth it. Mendeley have larger offices than our usual host, <a href="http://fry-it.com">Fry-IT</a>. And while there were slightly fewer of us than normal (low 20s as opposed to the usual high 20s) it was still great to have a bit of breathing space. Thanks very much to the guys at Mendeley for hosting us (and providing pizza, drinks &#038; snacks).</p>
<p><a href="http://twitter.com/#!/tartley">Jonathan Hartley</a> was making his debut as compere and managed very effectively. Well&#8230; fairly effectively. (I shouldn&#8217;t laugh: it&#8217;s my turn next month). He&#8217;d lined up three &#8220;lightning&#8221; talks to kick off with. First up was Ian &#8212; who&#8217;d arranged for us to use the place. He explained what Mendeley does (a sort of social network for research students) and how they use Python (mostly as a scripting API) and demo-ed some fairly nifty visualisations and tools which people had built on top of their product. Jonathan himself spoke last to ask for help with a Django concurrency issue. Which he promptly got. In between was Robert Rees who showed-and-told very effectively the recently-added <a href="http://www.heroku.com/">Heroku</a> support for Python. This enlarged into a wider discussion of Heroku itself and of its competitors in the Django/Python world.</p>
<p>Then the Dojo itself. As usual, we had a whiteboard available beforehand for people to propose ideas which were then voted on. The Roman Numeral Calculator remained top of the list of unchosen ideas, but the surprising winner was Robert&#8217;s suggestion of an ASCII Art Streetfighter clone. (Chosen only after a second round of voting with a Multiple Transferrable Vote). Once this was settled, it was a simple matter of dividing into teams and hitting the editor.</p>
<p>Or almost. We initially failed to be able to count up to 5 in order to divide into teams. Having finally achieved this intellectual feat, we encountered the opposite problem to the one we normally face at Fry IT. There, the office is so small that you&#8217;re squeezing into space. At Mendeley, there&#8217;s so much space that you&#8217;re wandering around for ages trying to find the best spot. And then you&#8217;ve got to find the WiFi (which Ian had considerately explained about). And then you&#8217;ve got to manually set your DNS Servers to something (as the DHCP wasn&#8217;t handing out DNS). Slightly geekily, the WiFi password is mathematical making it easy to remember but still quite long.</p>
<p>And then, in our case, you had to find the <a href="http://inventwithpython.com/pygcurse/">Pygame curses emulation</a> which someone knows exists but can&#8217;t quite remember the name of. Having got there (with about 20 minutes left now to do the actual coding) you basically scramble your way through a stunted version of Streetfighter (whatever that is; I have no idea), getting a basic solution on which you layer colour and fonts in the manner of lipstick and pigs :)</p>
<p>Finally, the endgame; and it&#8217;s the usual hilarious collection of imaginative approaches, stylishly-designed code, and desperate hackery. We saw: elegant ASCII art; flying bullets; gratuitous use of decorators; and many entertaining attempts to achieve an equilibrium between using classy and best-practice code and actually coming up with a solution within the timeframe!</p>
<p>I don&#8217;t know where we&#8217;ll be next month, but stay tuned to the <a href="http://mail.python.org/mailman/listinfo/python-uk">python-uk</a> list where stuff is announced.</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/11/04/new-place-new-time-same-great-dojo/feed/</wfw:commentRss>
		</item>
		<item>
		<title>PyCon UK 2011</title>
		<link>http://ramblings.timgolden.me.uk/2011/07/28/pycon-uk-2011/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/07/28/pycon-uk-2011/#comments</comments>
		<pubDate>Thu, 28 Jul 2011 11:52:53 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/07/28/pycon-uk-2011/</guid>
		<description><![CDATA[Well, the West Midlands Python team have been busy&#8230; (at least, I assume it&#8217;s them). This year&#8217;s UK Python conference is taking place over the weekend of the 24th - 25th September in Coventry. (Which is fairly central in England, for those of you reading this in a foreign language). I&#8217;ve just booked my place [...]]]></description>
			<content:encoded><![CDATA[<p>Well, the <a href="http://www.pywm.eu/">West Midlands Python</a> team have been busy&#8230; (at least, I assume it&#8217;s them). This year&#8217;s <a href="http://pyconuk.org/">UK Python conference</a> is taking place over the weekend of the 24th - 25th September in Coventry. (Which is fairly central in England, for those of you reading this in a foreign language). I&#8217;ve just booked my place and a night in the hotel. I hope can rustle up a talk or workshop to make it even more worthwhile.</p>
<p>It looks to be a bit more casually organised than other conferences and I&#8217;m very much hoping that the always friendly atmosphere will be even more friendly&#8230; See you there, I hope!</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/07/28/pycon-uk-2011/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Python Testing Cookbook</title>
		<link>http://ramblings.timgolden.me.uk/2011/06/10/python-testing-cookbook/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/06/10/python-testing-cookbook/#comments</comments>
		<pubDate>Fri, 10 Jun 2011 08:29:30 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Books]]></category>

		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/06/10/python-testing-cookbook/</guid>
		<description><![CDATA[I blogged previously that I was having a look at the Python Testing Cookbook courtesy of the eager marketeers at Packt Publishing. Well I&#8217;ve finished reading it &#8212; in installments on the Tube &#8212; and I think I&#8217;ve come to a conclusion.
The short version is: I&#8217;m not mad about the layout; it&#8217;s not entirely what [...]]]></description>
			<content:encoded><![CDATA[<p>I <a href="http://ramblings.timgolden.me.uk/2011/06/07/python-testing-cookbook-having-a-look/">blogged previously</a> that I was having a look at the <a href="http://link.packtpub.com/Xh0pyu">Python Testing Cookbook</a> courtesy of the eager marketeers at <a href="http://www.packtpub.com/">Packt Publishing</a>. Well I&#8217;ve finished reading it &#8212; in installments on the Tube &#8212; and I think I&#8217;ve come to a conclusion.</p>
<p>The short version is: I&#8217;m not mad about the layout; it&#8217;s not entirely what I expected from a Cookbook; but I think it does what it does very well.</p>
<p>Since I&#8217;m overall positive, I&#8217;ll just pick up on the very slight negatives first. In a <a href="http://ramblings.timgolden.me.uk/2009/04/05/expert-python-programming/">previous Packt review</a> I commented (adversely) on the style of the layout and so on, and I&#8217;m afraid that it hasn&#8217;t really changed. Obviously, this is somewhat subjective, but I can&#8217;t be the only person who&#8217;s subconsciously affected by the font and layout choice. (Bear in mind that I was reading it via PDF which may make a difference). To be clear: it&#8217;s not awful; it&#8217;s not even bad; it&#8217;s just suboptimal.</p>
<p>The other slight negative is hardly a negative at all: that the &#8220;recipes&#8221; in this cookbook are far broader &#8212; in some cases, chapter-length &#8212; than I&#8217;d expected. Subjective expectation, to be sure. But I was a very little bit surprised.</p>
<p>Ok, that&#8217;s the downsides. Now the upsides:</p>
<p>* Nice division of chapters<br />
* The right pacing<br />
* Pretty much one example used throughout<br />
* &#8220;Why didn&#8217;t you do this?&#8221; question sections<br />
* Good re-use or alternative use of previous examples or approaches<br />
* Interesting spread and combination of toolsets</p>
<p>The chapter divisions are: unittest, nose, doctest, BDD, UAT, CI, coverage, load-testing, good habits. In broad terms, each chapter builds on previous ones, but thanks to the reuse of the a simple shopping cart example, repeated in nearly every chapter, you can take a chapter on its own without too much difficulty. In addition, different chapters sometimes offer alternative approaches to the same problem when it makes sense to illustrate one point rather than another. One chapter, for example, walks you through creating a nose plugin to show how to do it; the next chapter introduces you to a ready-made one since the focus of that chapter is not nose plugins.</p>
<p>And that brings me to the variety of toolkits &#038; modules mentioned throughout the text. This is not a book which simply uses stdlib code to perform various tasks (which I had rather thought it might be when I started). It introduces the ideas mentioned in the paragraph above. And puts forward Python modules (such as nose or mock) or external tools (such as Hudson / Jenkins or TeamCity) as best-of-breed or useful tools.</p>
<p>One final point which really put the icing on the cake is the occasional introduction of pull-out sections answering the very question which was occurring to me as a reader: &#8220;Why didn&#8217;t you use this technique here?&#8221; or &#8220;How is this different from that?&#8221;. Perhaps it&#8217;s just me, but I find this smoothes my progress through a book considerably which otherwise would be (mentally) jarred by my wondering &#8220;Now why did he do that?&#8221;.</p>
<p>I can&#8217;t but recommend this book. There&#8217;s a <a href="http://www.packtpub.com/sites/default/files/4668OS-Chapter-3-Creating-Testable-Documentation-with-doctest.pdf?utm_source=packtpub&#038;utm_medium=free&#038;utm_campaign=pdf">sample chapter here</a> if you want to have sniff. As a final note, it&#8217;s very slightly unfortunate that the timing of its production precluded the author from picking up on Michael Foord&#8217;s magnificent work in producing <a href="http://pypi.python.org/pypi/unittest2">unittest2</a> / <a href="http://docs.python.org/library/unittest.html">unittest for 2.7 &#038; 3.2</a>. Perhaps there&#8217;s a &#8220;missing chapter&#8221; opportunity in there for someone&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/06/10/python-testing-cookbook/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Python Testing Cookbook - having a look</title>
		<link>http://ramblings.timgolden.me.uk/2011/06/07/python-testing-cookbook-having-a-look/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/06/07/python-testing-cookbook-having-a-look/#comments</comments>
		<pubDate>Tue, 07 Jun 2011 07:56:38 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Books]]></category>

		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/06/07/python-testing-cookbook-having-a-look/</guid>
		<description><![CDATA[Thanks to the energetic folks in the Packt Publishing Marketing department, I&#8217;m currently looking at the Python Testing Cookbook with Python Web Development waiting in the wings. The copies I have are PDFs which are never my favourite, so I end up printing chunks out to read on the train or elsewhere, but it&#8217;s great [...]]]></description>
			<content:encoded><![CDATA[<p>Thanks to the energetic folks in the <a href="http://www.packtpub.com/">Packt Publishing</a> Marketing department, I&#8217;m currently looking at the <a href="http://link.packtpub.com/Xh0pyu">Python Testing Cookbook</a> with <a href="http://link.packtpub.com/o3viGr">Python Web Development</a> waiting in the wings. The copies I have are PDFs which are never my favourite, so I end up printing chunks out to read on the train or elsewhere, but it&#8217;s great to get to read other people&#8217;s insights and ideas. I&#8217;m about halfway through PTC so look out for a review soonish.</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/06/07/python-testing-cookbook-having-a-look/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Python3 support&#8230;?</title>
		<link>http://ramblings.timgolden.me.uk/2011/06/06/python3-support/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/06/06/python3-support/#comments</comments>
		<pubDate>Mon, 06 Jun 2011 13:35:50 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/06/06/python3-support/</guid>
		<description><![CDATA[Brian Jones, co-author of the upcoming edition of the Python Cookbook has just tweeted, asking why anyone would release a new module now without testing for Python 3. 
I sympathise, but for me the simple answer would be: because Python 3 support doesn&#8217;t solve a problem I have. It&#8217;s one more hurdle to leap over [...]]]></description>
			<content:encoded><![CDATA[<p>Brian Jones, co-author of the <a href="http://www.amazon.co.uk/Python-Cookbook-Brian-K-Jones/dp/1449378722">upcoming edition of the Python Cookbook</a> has <a href="https://twitter.com/#!/bkjones/status/77716752871600128">just tweeted</a>, asking why anyone would release a new module now without testing for Python 3. </p>
<p>I sympathise, but for me the simple answer would be: because Python 3 support doesn&#8217;t solve a problem I have. It&#8217;s one more hurdle to leap over in terms of developing, documenting and testing software. And if you&#8217;re still using 2.x for production purposes then you don&#8217;t need 3.x. Other users might, but there&#8217;s little enough time to scratch one&#8217;s own itches let alone scratch other people&#8217;s for them.</p>
<p>On the plus side, I&#8217;m trying to keep my own modules Python3-friendly, running Python 2.x with the -3 flag, making a few decisions which I know will help 2to3 out (or will remove the need to use it altogether). But at the end of the day, the things I write need to work for the environment I have &#8212; which at the moment is 2.7 &#8212; and not for the environment I&#8217;d like other people to be running.</p>
<p>[<strong>UPDATE:</strong> Thanks to Mike Driscoll for pointing out how to link to a tweet].</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/06/06/python3-support/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Too much code, too few releases&#8230;</title>
		<link>http://ramblings.timgolden.me.uk/2011/05/23/too-much-code-too-few-releases/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/05/23/too-much-code-too-few-releases/#comments</comments>
		<pubDate>Mon, 23 May 2011 12:43:57 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Active Directory]]></category>

		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/05/23/too-much-code-too-few-releases/</guid>
		<description><![CDATA[(or: release late, release seldom).
I don&#8217;t know about you, but I have sort of one-man sprints on some of my modules when for days on end I take my laptop on trains and squeeze in time at lunch or whenever to refactor or enhance modules. The only trouble is that I&#8217;m very (read: too) particular [...]]]></description>
			<content:encoded><![CDATA[<p>(or: release late, release seldom).</p>
<p>I don&#8217;t know about you, but I have sort of one-man sprints on some of my modules when for days on end I take my laptop on trains and squeeze in time at lunch or whenever to refactor or enhance modules. The only trouble is that I&#8217;m very (read: too) particular about the quality of the code I release to the public. I want to make a good impression. I want it to have good test coverage. (Or at least <em>some</em> test coverage). I want it to have good docs, with an overview, an API guide, and a cookbook. I want it to have a roadmap so people can see what to expect. (And what not to expect).</p>
<p>But of course all that takes time and energy from the limited pool of time and energy at my disposal. And I have several projects, all competing for that same time and energy, not all of them related to Python or programming at all. Like most developers, I suspect, I&#8217;d far rather be writing new code, juicing up existing code, refactoring code for the new generation of language features, breaking code out into nicely layered, suitably decoupled modules. It&#8217;s not that I don&#8217;t value docs, test, etc. I do. But someone&#8217;s got to write them. And that&#8217;s me.</p>
<p>Also I don&#8217;t want to go public with an underwhelming feature-set. I don&#8217;t want people saying, &#8220;Oh good&#8230; Oh no! Where&#8217;s&#8230;.?&#8221; So I go on extending the code forever and never actually releasing. The Perfect is the proverbial enemy of the Good.</p>
<p>The case in point at the moment is the rewrite of my active_directory module (cunningly entitled active_directory2). It&#8217;s more or less of a ground-up rewrite with a very similar API but more structure and layering etc. etc. The rewrite&#8217;s been on the go for well over a year in bits &#038; pieces. The trouble is that the original module works fine for most of what I want. Very occasionally I need something more sophisticated and I can usually cobble something suitable together for the occasion. So there&#8217;s only a low incentive level.</p>
<p>Testing it&#8217;s a bit of a &#8216;mare as I need an test AD rig. Obviously. So, courtesy of the PSF MSDN Subscription &#8212; which, it seems to me, was created for just this kind of situation &#8212; I&#8217;ve installed a VM containing Windows 2003 Small Business Server. This is about the smallest modern server which will host Active Directory. This setup has the slight advantage that it forces me to test AD authentication since, in an inversion of the norm, I&#8217;ve already logged onto my laptop before firing up the AD server so it can&#8217;t be the authenticating agent for my account.</p>
<p>I&#8217;ve got the top two layers working and I&#8217;m looking at tests &#8212; at the very least, exercise tests: ie those which simply call every function just to make sure it doesn&#8217;t completely fall over. Then I&#8217;ll probably release it as a work in progress while working on the more sophisticated extra layer which does some transparent transformations to and from Python types based on the schema definition of the AD object and which handles things like memberOf entries in a more Python way.</p>
<p>Watch this space&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/05/23/too-much-code-too-few-releases/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Projects I Wish I Had A Reason To Use</title>
		<link>http://ramblings.timgolden.me.uk/2011/05/20/projects-i-wish-i-had-a-reason-to-use/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/05/20/projects-i-wish-i-had-a-reason-to-use/#comments</comments>
		<pubDate>Fri, 20 May 2011 09:16:18 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/05/20/projects-i-wish-i-had-a-reason-to-use/</guid>
		<description><![CDATA[I keep half an eye on various of the channels through which new or updated Python projects are announced: planet.python.org, the PyPI feed, and c.l.py.announce. While I am occasionally irritated by the noise which PyPI produces (nested lists, anyone?) it&#8217;s helpful to see projects go past, just  to remind myself what&#8217;s out there.
One phenomenon [...]]]></description>
			<content:encoded><![CDATA[<p>I keep half an eye on various of the channels through which new or updated Python projects are announced: <a href="http://planet.python.org">planet.python.org</a>, the <a href="http://www.python.org/pypi?:action=rss">PyPI feed</a>, and <a href="http://mail.python.org/mailman/listinfo/python-announce-list">c.l.py.announce</a>. While I am occasionally irritated by the noise which PyPI produces (nested lists, anyone?) it&#8217;s helpful to see projects go past, just  to remind myself what&#8217;s out there.</p>
<p>One phenomenon I&#8217;ve experienced is that I&#8217;ll not even have *heard* of some underlying library or web service until someone writes a Python interface to it. Glancing randomly at the current PyPI front page, I see &#8220;Python yubico client&#8221; which refers to some kind of <a href="http://www.yubico.com/">one-key logon service</a> which I&#8217;d never heard of. Then there&#8217;s &#8220;sunburnt - a Python interface to <a href="http://lucene.apache.org/solr/">Solr</a>&#8221; which, it happens, I have heard of. And a project which refers to the &#8220;Comprehensive Knowledge Archive Network&#8221; which, even after I&#8217;ve visited <a href="http://ckan.org/">the website</a>, I&#8217;m still not very clear why I might want to use it. But I&#8217;m sure it&#8217;s really good for the people who do.</p>
<p>This is great news for two reasons at least: people are using Python for all sorts of things, and not just the big-named everyone-does-that stuff; and there&#8217;s an inadvertent advertising effect when they publish their work, which brings a possibly interesting project to the attention of a wider audience.</p>
<p>Which brings me to the main point of this post: from time to time I see a project go past which really grabs the programmer in me, and I just wish I had an excuse to use. Occasionally I actually get to fulfil this wish, but usually I just look wistfully on and check as each new update is released to see if there&#8217;s any way I can squeeze it into whatever I am paid to do (or have time to do otherwise).</p>
<ul>
<li><a href="http://www.kamaelia.org/Home.html">Kamaelia</a> - I&#8217;ve followed this one since its owner (Michael Sparks) presented it at a London Python meetup some years ago. I love the idea of simple objects and network pipelines between them. (Who wouldn&#8217;t?). I recall a thread a few years ago where Michael wondered why more people hadn&#8217;t taken it up (and why they&#8217;d gone for Twisted instead which seemed so much less intuitive).
<li><a href="http://celeryproject.org/">Celery</a> - obviously not unrelated to the previous entry. My interest in lightweight distributed message passing probably goes back to my days using <a href="http://en.wikipedia.org/wiki/Modula-2">Modula-2</a>, the language I used at <a href="http://www.umist.ac.uk/">University</a> and which led to my discovering Python. (Modula-2 has built-in support for coroutines).
<li><a href="http://pypi.python.org/pypi/requests">requests</a> - bit of a newcomer but it it exemplifies one of the things I admire most about Python code: it makes it really easy to do something which is conceptually simple. In this case, making HTTP requests. I think this is a key differentiator when comparing Python to other useful and successful languages: it just doesn&#8217;t take much code to get something done. It&#8217;s something I try for in my own libraries, and is, sadly, one of the reasons why the built-in logging module gets such a bad press. (In spite of its author&#8217;s ready willingness to answer questions, address issues, improve things, and update docs).
<li><a href="https://bitbucket.org/mchaput/whoosh/wiki/Home">Whoosh</a> - a pure Python search engine. For no very good reason, the idea of doing this in pure Python appeals to me. As it happens I&#8217;ve rolled my own search facilities for several small projects. (And who hasn&#8217;t?). Unfortunately, the cognitive overhead of replacing those by Whoosh is <em>just</em> too great at the moment to justify the small risk in changing. One day&#8230;
<li><a href="http://api.mongodb.org/python/current/">PyMongo</a> (or any other of the several interfaces to MongoDB). As a daytime database developer, I&#8217;m as intrigued as the next man by the various schemaless / distributed databases currently going under the &#8220;NoSQL&#8221; umbrella. I&#8217;ve played with CouchDB (very RESTful interface but map-reduce all the way down) and MongoDB (less pure but more practical) and I even toyed with re-implementing our Helpdesk system using one of them, but as ever the risks were too great and there&#8217;s no real benefit to the business. (Only to me :) ).
</ul>
<p>There are loads more; these are just some that occur to me. Others include the kind of popup notifiers inspired by <a href="http://www.growlforwindows.com/gfw/">Growl</a>, lkcl&#8217;s recently-discussed <a href="http://pyjs.org/">pyjamas</a> and even some Windows-specific functionality within the pywin32 modules.</p>
<p>If only time and opportunity allowed&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/05/20/projects-i-wish-i-had-a-reason-to-use/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Tears &#038; Laughter at the London Python Dojo</title>
		<link>http://ramblings.timgolden.me.uk/2011/04/08/tears-laughter-at-the-london-python-dojo/</link>
		<comments>http://ramblings.timgolden.me.uk/2011/04/08/tears-laughter-at-the-london-python-dojo/#comments</comments>
		<pubDate>Fri, 08 Apr 2011 07:52:46 +0000</pubDate>
		<dc:creator>tim</dc:creator>
		
		<category><![CDATA[Dojo]]></category>

		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://ramblings.timgolden.me.uk/2011/04/08/tears-laughter-at-the-london-python-dojo/</guid>
		<description><![CDATA[Yesterday&#8217;s Dojo was as entertaining as ever. It almost went wrong before it started, as Fry-IT &#8212; who continue to provide the venue and the food &#038; drink &#8212; had no working projector. Fortunately, my company were willing to lend one for the evening which got over that hurdle.
We started with a couple of lightning(ish) [...]]]></description>
			<content:encoded><![CDATA[<p>Yesterday&#8217;s Dojo was as entertaining as ever. It almost went wrong before it started, as <a href="http://fry-it.com/">Fry-IT</a> &#8212; who continue to provide the venue and the food &#038; drink &#8212; had no working projector. Fortunately, my company were willing to lend one for the evening which got over that hurdle.</p>
<p>We started with a couple of lightning(ish) talks. Ravi had been on the <a href="http://startupbus.com/teams">StartupBus</a> and he and the team had produced the final winner: <a href="http://startupbus.com/teams/47-tripmedi">TripMedi</a>. Ravi explained the way the thing works and various of the challenges involved. He also explained how <a href="http://ycombinator.com/">YCombinator</a> works &#8212; something I&#8217;d only been vaguely aware of. [On a personal note, I can&#8217;t even imagine the kind of person who&#8217;d actually want to make use of what TripMedi provides, but I suppose it takes all sorts&#8230;] <strong>UPDATE</strong>: Ravi has <a href="http://twitter.com/r4vi">just tweeted</a> that the team has made it through to the next stage of YCombinator. Congratulations!</p>
<p>I then gave a presentation on contributing to Python core development and how you could go about it. Thanks to the efforts of Jesse Noller, Doug Hellmann and others, there is now the <a href="http://blog.python.org/">Python Insider</a> blog, whose intention is to give greater visibility of some of the wider-reaching discussions taking place on python-dev. And the <a href="http://jessenoller.com/2011/04/05/python-core-mentorship-up-and-running/">new core-mentorship</a> <a href="http://mail.python.org/mailman/listinfo/core-mentorship">mailing list</a> is specifically intended to welcome would-be contributors who aren&#8217;t too sure how to go about things, or what the ground rules and policies are.</p>
<p>Once all the talking was done, the trouble started :) <a href="http://ntoll.org">Nicholas</a>, the indefatigable organiser of the London Python Code Dojo, has been quite keen on promoting <a href="http://xmpp.org/">XMPP</a> (aka Jabber) to implement some sort of network-ability for our nascent multi-Dojo game engine. For the previous Dojo, his team had produced a simple <a href="http://xmpp.org/extensions/xep-0114.html">XMPP Component</a> which implemented a to-do list: the challenge for that Dojo. This time, Nicholas was keen for everyone to have a go with the same thing. He&#8217;d put <a href="https://github.com/ntoll/xmppComponent">code on Github</a>, added a <a href="https://github.com/ntoll/xmppComponent/blob/master/README.rst">readme</a>, and recommended the <a href="http://www.lua.org/">lua</a>-based <a href="http://prosody.im/">Prosody</a> server and <a href="http://code.google.com/p/sleekxmpp/">SleekXMPP</a> for the Python end.</p>
<p>So we broke up into small groups (as they say), fired  up git, pip and whatever, and dove in with about 75 minutes to produce something. </p>
<p>About 45 minutes later, most of us were still diving in, trying to get Prosody to listen to anything and failing to get the component talking to Prosody.</p>
<p>At this point, Mr Tollervey very wisely decided that we should cut our losses. Fortunately, <a href="http://twitter.com/#!/john_chandler">John Chandler</a> was willing to go up front and ask for a code review of the code he had produced. Which turned out to consist of two lines, one of which was &#8220;import random&#8221;. Being social coders, we were more than willing to advise him on the many ways in which he could make this simple and correct code into an over-engineered mess of obfuscation.</p>
<p>Since we&#8217;re in the middle of <a href="http://www.pyweek.org/">PyWeek</a>, it seemed apt to have a demo from Daniel Pope of the game he&#8217;s developing on the theme of &#8220;Nine Times&#8221;. Impressive as always. (If you haven&#8217;t seen it, check out <a href="http://code.google.com/p/bamboo-warrior/">Bamboo Warrior</a>, one of his previous efforts).</p>
<p>As always, we ended with a raffle of name-stickers for an O&#8217;Reilly Book and &#8212; this time &#8212; an additional donation from Mr Tollervery himself. Ironically Jon &#8220;I don&#8217;t like XMPP&#8221; Ribbens got the <a href="http://oreilly.com/catalog/9780596521271">O&#8217;Reilly book on XMPP</a>.</p>
<p>Watch the <a href="http://mail.python.org/mailman/listinfo/python-uk">python-uk</a> mailing list or follow <a href="http://twitter.com/#!/ntoll">ntoll on Twitter</a> to know when tickets are available for the next Dojo (it usually takes place on the first Thursday of the month).</p>
]]></content:encoded>
			<wfw:commentRss>http://ramblings.timgolden.me.uk/2011/04/08/tears-laughter-at-the-london-python-dojo/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>

