Stephen Newey


Developer shock at the utility of JSON Schema

22 February 2015

As a developer who’s spent years working with popular “scripting languages” I’ve developed a certain dislike of XML. Especially it’s formality. It’s all great when you’re an “enterprise” developer using “enterprise” tools to build “enterprise” solutions.

I’m lead to believe Java and .NET take away all the complexity of turning things like SOAP into something useful. Not so in the worlds of PHP, Python, Javascript et al. I await a barage of links to libraries I’m not aware of that do just that.

And then JSON came along. Oh my god. This is just so easy. It reads like Python. My browser can understand it with a single command.

And then some people came along and decided that JSON things need schemas. And I was all like… “urgh! get your dirty XML covered fingers off my JSON!”

Would Like To Build: Kotaka the Deployer

16 February 2015

Following up on Django app deployer I want to get down some of my ideas for the deployment tool I’d like to build.

It’s provisionally named Kotaka after a Japanese torpedo boat from the late 19th century, considered to be a forerunner to Destroyers according to Wikipedia. It turned out I wasn’t the first person to think of the pun “X the Destroyer” / “X the Deployer” and so all the comic book examples I found were already taken.

Don’t worry, I’ll still be here after you’ve exited the wikiloop I just sent you on.

Django app deployer

16 February 2015

Continuing on the theme of my previous posts, I’d like to give an overview of the automation processes I’ve built to deploy Django sites.

Hosting decisions

15 February 2015

In my previous post I discussed how I setup a simple failover system between VPSes with Linode and DigitalOcean. Now I’d like to take a step back and explain how I chose those providers.

Cheap, resilient hosting

10 February 2015

One of my clients is a digital agency, producing Django CMS powered websites for a range of clients, many in the legal industry. These clients care about the uptime of their sites but don’t have big budgets.

My client wants to offer redundancy both in physical location and in service provider. They’re especially keen that hardware failure doesn’t result in all their sites going down at the same time.

The budget available doesn’t extend to the costs involved in purchasing duplicate sets of hardware, hosting it at two locations and provisioning BGP routable IP addresses to allow automatic failover.

Back, with Python

01 February 2015

It’s that time again. My biennial recollection that I have a web site and that I’ve been meaning to write something on it for the past two years.

As always, the first task is not to write anything, but instead to distract myself by poking around with the technology. And I’ve made three big changes this time around.

Realtime websites with Flask, Gevent and Server-Sent Events

16 October 2012

Also: PyConUK

A couple of week ago I attended my first PyConUK conference. It was a really interesting and useful event that left me enthused to do more with Python and get involved with the fantastic community around it.

I enjoyed Saturday’s lightning talks so much that it inspired me to try and give one for myself on Sunday. I stayed up until 3am working on the slides and then spent most of Sunday feeling apprehensive, especially given the quality of the other talks. When the time came I rushed through my topic fuelled only by nervous energy.

The video of the Sunday afternoon has now been posted here. My talk is around 1hr45m in. I’d swear I was talking faster than that.

The topic of my talk was the topic of this post. Hopefully I can capture it in a little more detail here.

Keep Compiling CoffeeScript in OS X

07 April 2012

Lately I’ve been producing a lot of code in JavaScript. I use the word produce, because I’ve actually been writing the code in CoffeeScript. It better suites my Python sensibilities and is usually half the size of the resultant JavaScript.

The CoffeeScript compiler has a handy feature where it can watch a directory for you and any new or modified files are instantly compiled into JavaScript. By default these land next to their CoffeeScript originals, or optionally in a separate location.

CoffeeScript is brilliant, but using it has also resulted in wasted time trying to debug new code. I wondered why it didn’t seem to be doing anything only to realise I hadn’t started the compiler this session. None of my lovely new code was making it to the browser.


22 March 2012

Hi. I’m Stephen, and this is my blog. I’ve lost count which iteration of it this must be. My enthusiasm for keeping such things up to date seems to wane pretty quickly. I’m hoping this time might be different.

Recently I’ve been learning and using some …

Postfix for Development and Staging Servers

21 March 2012

Sometimes we’ll have a client who sends tens of thousands of emails a day from their production systems. And that client insists on copying over their production database to their development server, unmodified each night.

They probably won’t want to send test emails to their real customers, and they’ll probably blame us if this happens. So, what can we do?

Postfix gives us a couple of ways for limiting the destinations it’ll allow emails to be sent to. I like to implement both, just to be sure.

Page 1 / 1