-
Wicked [stuff]. published on May 22, 2008
It’s been a while since I’ve posted regularly, and those of you who really keep your ear to the community already know why. Last week, news broke that I’m writing a book. I’ve actually been writing it for several months now, since before the sprint last December, toying with the idea of contacting a publisher. After getting positive feedback from several people at the sprint, I bit the bullet and contacted Apress in January, got a …
-
Google App Engine: First Thoughts published on Apr 8, 2008
Like much of the Web development world, I caught wind of Google’s new App Engine launch last night, during the NCAA championship game. I wasn’t following the Scobleizer video though, so I was relying on the TechCrunch article and people in #django and #django-dev to fill me in on what all the fuss was about.
Well, once I realized what was going on, my interest was piqued. I hadn’t delved into any of these new scalable systems …
-
Post-PyCon published on Mar 17, 2008
So, PyCon proper has come and gone, and today begins the sprint. I had a great time, got my talk on (I’ll try to fix the fonts, but it’s online, anyway), and learned some fascinating stuff.
This week, I’m working hard on my file storage patch, which I sincerely hope gets committed without too much trouble. I may be able to help Jacob work on rewriting the signal code as well, if I can fnd the time …
-
Review: The Definitive Guide to Django published on Jan 16, 2008
While I normally prefer to write about code, I’d like to take a few minutes and review the recently-published definitive guide on my favorite subject. That’s right, I’m talking about The Definitive Guide to Django: Web Development Done Right by Adrian Holovaty and Jacob Kaplan-Moss (and special quest author Simon Willison).
The process
I can’t really discuss this book without describing the process it went through before it was published. While Adrian and Jacob were writing …
-
A Simple Plugin Framework published on Jan 10, 2008
Since getting involved with Python, I’ve read a few discussions about Zope, and though I haven’t used it, I do enjoy reading articles about it, to see how other people approach common problems. In particular, a recent Satchmo discussion pointed me to an article about using Zope3 interfaces to essentially manage plugins. I knew Trac did this, as I had tried to write a Trac plugin a while back, but I hadn’t really seen a good description …
-
Google Chart API published on Dec 7, 2007
So, I was surprised to see my news this morning, when information aesthetics spread the news of the new Google Chart API. Looks like they’ve been reading my blog, and they decided to save me the trouble of installing matplotlib or anything.
It’s not interactive, which still makes Dojo charting a very useful alternative, but it’s good to have a quick, easy API for just embedded charts for simple data. As an example, here’s a chart …
-
Looking back at the sprint published on Dec 3, 2007
Sadly, the sprint is now over, but we got a lot done. I won’t go over the whole list, but I will regretfully admit that I didn’t get anything finished in time to get committed during the sprint.
I did get a ton of work done on the FileField refactor, and a new patch will be ready this week. I didn’t realize just how hacked that patch was, so I had to a lot of cleanup and …
-
Closing out November published on Nov 30, 2007
It’s been a long month. It’s been a very long month. I’ve had my ups and downs, but over all, it’s been a good time. I stuck it out to the end, and I’m proud of that.
With the sprint this weekend, I’ll probably be updating a few times with smaller posts, indicating the progress I’m making. But after that, I’ll be going back to fewer posts with higher quality. This has …
-
Django Projects published on Nov 29, 2007
A while back, Jacob posted a list of Django projects he found outstanding. I’ve now had some time to work with several projects myself, and I’d like to take the opportunity to recommend a few of them.
Coltrane
It might not look like much from the “Coming soon…” note on the front page, but Coltrane is a nicely-done blog app, containing the most necessary features. It’s not a full-on WordPress, but it really doesn’t need to …
-
Upcoming Sprint published on Nov 27, 2007
I’m finally able to make a sprint this time. I missed the last one (though I did have my own shortly beforehand), but I’m all set to make this one, live and in Lawrence. I’m incredibly excited to be meeting everybody in person, I expect it’ll be a great time. It’s especially great that I’m one of those weird people who love nothing more than coding in my spare time.
I’ve posted about …
-
Python Descriptors, Part 2 of 2 published on Nov 24, 2007
Yesterday, I gave a basic overview of descriptors and what they can do, including a simple example to demonstrate one in action. That’s all well and good, but today I’ll explain how this can be genuinely useful in your apps, particularly when used in models.
Storing data with a descriptor
Yesterday’s example generated a new value each time it was accessed, which is really only useful in a few situations. More often, you’ll need to still …
-
Python Descriptors, Part 1 of 2 published on Nov 23, 2007
I rather enjoyed writing about a relatively underused feature yesterday, so today is more of the same. Of course, continuing with a focus on Django, today’s Python feature is also commonly used throughout a number of Django’s internals: descriptors. Python’s documentation on descriptors is rather sparse, though there’s a great writeup on it already. I won’t try to reinvent the wheel in its entirety here, I’ll just write up some basic details and how …
-
Except the Unexpected published on Nov 21, 2007
No, that title isn’t a typo. Predictably, yesterday’s post drew out an opposing view, and I’m very glad for it. While I haven’t changed my mind on the subject, Cedric did raises some reasonable points that I neglected in my original post. Maybe it’s just that I’m growing tired of posting every day, but I didn’t adequately explain my views, and for that I apologize. Only for not explaining, though, not for the …
-
Returning None is Evil published on Nov 20, 2007
Yes, that headline was written for dramatic effect. No, I don’t think that
Noneitself is evil. Yes, I realize there are many cases whereNoneis an appropriate return value. No, this post isn’t about those cases.This is mostly a rant about Java, but the pitfall described below is definitely a potential problem in Python. I hope none of my fellow Djangonauts have fallen into this trap, but hopefully this post will help make sure it …
-
Working on Visual Design published on Nov 18, 2007
It’s no secret that I’ve been very involved with Django, which requires a lot of design with regard to programming, but it doesn’t really deal with the visual aspect. Instead, that’s (rightfully!) left to graphic designers. Unfortunately, this only works at its best when you have access to a designer. When building my own site, I’m constantly reminded that I don’t have design skills, nor can I hire a designer. In fact, that’s …
-
Fixing bugs or adding features? published on Nov 17, 2007
No, I’m not going to actually answer that question, as I expect it to be different for each person. This post is more about what I go through when trying to answer it for myself. With the upcoming sprint, it’s especially important to answer, at least it is for me.
I’ve generally been more concerned with adding new features, both for Django itself and for my own applications. It’s just something that I’ve always found …
-
Data Visualization in Django: A dream? published on Nov 16, 2007
Continiung a bit in the vein of yesterday’s post, one thing I go keep wishing I could do is easily generate graphs and charts of Django-managed data. I have so much other stuff going on that I can’t work on it now, but I’d love to do it sometime. I know things like matplotlib are already out there, and I’m not hoping to reinvent them.
Instead, I’d like to built a Django-friendly interface to them …
-
Blog stats published on Nov 15, 2007
I was looking at my Google Analytics data today, and I noticed a few surprising things.
First, my series on declarative syntax did well, but not remarkably so. Still, it seemed to maintain enough readers day after day, so I’ll definitely continue it at some point soon, and do more like it when I can.
I also apparently can manage to write longer posts if I want. The average time spent on the site for the month of October …
-
What I mean by “modular” published on Nov 13, 2007
I’m putting my series on hold for a little while, as there’s been some recent chatter about a project I’ve been working on, django-modular, and I thought I’d try to write it up properly for the first time.
It’s a very cool app, and I think it could do wonders for Django-powered sites of all shapes and sizes (as long as app developers get on-board), but it doesn’t do anybody any good if nobody …
-
Using Declarative Syntax, Part 3 published on Nov 12, 2007
Continuing where we left off yesterday, it’s time for some more sugary syntactic goodness.
We now have a
Widgetclass to work with, but the API specifies a number of preferences that widgets can utilize, as necessary. These are not only an important part of the widget’s design; they’re probably the most interesting (and most complicated) part of our framework’s declarative syntax. As such, this post will be dedicated entirely to getting them to work in … -
Using Declarative Syntax, Part 2 published on Nov 11, 2007
Today, continuing the series, get ready for some code. The first thing we’ll need to do is lay out some files to work with.
I previously described the syntax in three separate parts:
- A single module namespace to import
- A base class to specify in subclases
- A set of attribute classes to instantiate
Thankfully, those can map very nicely to three different files. These files will all be placed in a
widgetsdirectory somewhere on thePYTHONPATH, representing the … -
Using Declarative Syntax, Part 1 published on Nov 10, 2007
A while back, I wrote a bit about my work on django-modular, and one of the comments pointed me to the Netvibes UWA. While that wasn’t the point of django-modular, it still looked like it would be reasonably easy to support in a way that would integrate well with a Django app.
One of the defining characteristics of Django is its declarative syntax, and I knew I wanted to incorporate it into this as well. The API seemed well-suited …
-
A Django Analogy published on Nov 9, 2007
I was thinking recently about how I look at Django and my place in it, and I found a certain analogy to be very apt: it’s a lot like a kitchen. Bear with me here.
Most people don’t go to the kitchen just to stand there. They have a purpose: to make a meal. The kitchen doesn’t provide the meal, it just provides most of the things you need in order to make the meal. There’s …
-
Customizing filenames without patching Django published on Nov 7, 2007
Recently, I’ve noticed a good bit of chatter on the mailing lists about how to override the filename of an uploaded file before saving it. Django currently provides options for customizing the location based on upload time, but nothing else. Often, projects find the need to store attachments in directories according to details of the object or a related object. I’m doing a good bit of work on FileField at the moment, but that’s still a way …
-
Ohloh published on Nov 6, 2007
I discovered Ohloh a while back, and I must say that I find the idea very intriguing. The notion of tracking who uses a particular framework is fine and dandy, but it’s great to be able to track real statistics about code size over time, commits over time, even approximately how much it would cost to be developed commercially.
As time goes on, and more people and proejcts get added to their database, I think they’ll find they …
-
Local Branches published on Nov 5, 2007
Okay, I officially despise National Blog Posting Month. It’s neat to try to think about how to populate the blog every day, and I really appreciate all the extra thought it’s made me put into it. But I just don’t think I can reasonably manage to do it. Here it is, five days in, and I’ve already resorted to a minor status update just to get my post in for the day. Sorry folks, you’re …
-
Django in JavaScript published on Nov 4, 2007
Well, this post isn’t very substantial, because I don’t really have much code to back up my plans in this area, but it’s time for me to post again on what I’ve worked out for using Django with Google Gears. It’s turning out to be a bit trickier than I thought, bu I think it’s still something worth working toward.
A large part of Django will have to be rewritten in JavaScript, but I …
-
Storing passages of time published on Nov 3, 2007
One thing I need for VGMix is the ability to store the length of a song in a Django model. There are date and time features, but nothing for just a length of time, unrelated to any particular point in time. I did a bit of searching and found a ticket to add an IntervalField to Django, but no patches were provided.
So naturally, I decided to investigate and write a patch for it. The result is attached to that …
-
The future of dbsettings published on Nov 2, 2007
I took a look at Satchmo recently, and I noticed that its new configuration system (now in Satchmo 0.6) looked vaguely familiar. I had a brief conversation with Bruce about it, and it turns out he forked dbsettings! And I mean that in a good way.
As it turns out, they had issues with their previous configuration system (a mess of settings files, it looks like), and dbsettings looked similar to something they could use. Of course, they had …
-
Django Projects published on Nov 1, 2007
Thanks, James, for giving me a heads-up about National Blog Posting Month. It’s unfortunate that I heard about it with just one hour left on November 1, but I’ll give it a shot.
In the spirit of Malcolm’s TODO list (sorry, can’t find the link offhand), I thought I’d outline a few things I’m currently thinking about and/or working on for Django in the near future. This probably isn’t complete, but it …
-
My very own mini-sprint published on Sep 7, 2007
Perhaps in anticipation of next week’s sprint, or maybe due to just plain luck of the draw, I made major progress on three separate projects today. I feel tired, but exhilarated at the same time. If this is what a sprint feels like, I want to take part. Badly.
First, my dbsettings project just gained a comprehensive test suite, which means it’s finally in a complete condition. Unless somebody has major features or bugs, it’s done.
Second …
-
Django and the Linux Desktop published on Sep 5, 2007
Reading a recent discussion regarding Django’s ORM, I got to thinking about how I might respond if someone raise such an argument to me. After some reflection, I think my view on the matter comes down to something I’ve learned from being on the django-developers mailing list for the past several months.
Django is optimized for the common case.
I’ll be the first to acknowledge that Django isn’t perfect for everything, and the more complex a …
-
Dynamic models in the real world published on Aug 14, 2007
A while back, I wrote up an article on creating models dynamically at run-time, and Malcolm Tredinnick rightly noted that there are potential uses, but it’s high time I provide an actual example.
Malcolm had it right in his analysis, reading between the lines in my example code to realize that I do indeed have plans for web-based model design. On a more practicle (and already available) note, however, a recent discussion on django-developers allowed me a chance to …
-
Update on database-backed settings published on Jul 16, 2007
I’ve made a few updates recently to dbsettings, which finally brings the issue count to zero, and adds some new features worth discussing.
The biggest improvement is that it finally uses Django’s cache framework, so it’s able to work properly in multi-process setups. This was essential in order make the framework useful in production environments.
The one caveat is that two of Django’s cache backends aren’t suitable for this framework, and one of those two …
-
Signed Cookies published on Jun 16, 2007
Some time ago, I created a Signed Cookies middleware for Django, allowing views to transparently sign and validate cookies. With recent developments on django-developers, it was best to create a separate project for it, rather than maintain it as a ticket.
With that in mind, I created a Google Code project for this application. For those who haven’t been following its progress, I’ll list some of its features:
-
A middleware to do everything automatically
- Signs outgoing cookies
- Validates …
-
A middleware to do everything automatically
-
Offline Django? published on Jun 1, 2007
A few weeks back, I got bored for a bit and started trying to emulate Django’s declarative model syntax in JavaScript. This was a fairly useless exercise, but one that seemed entertaining at the time. However, now that I look into some of the information on how Google Gears helps makes web applications available offline, I wonder it might actually be worth the time to make it happen.
Essentially Google Gears uses a combination of a fake server to …
-
Choosing a name published on May 18, 2007
For those of you who have been following my progress lately on django-developers, that title probably makes some sense. For the rest of you, I’ll explain. I’ve been working on on a project for quite some time now, with the goal of eventually being accepted as a contrib app in the official distribution. Trouble is, nobody (myself included) likes the name as it stands: django-values.
Essentially, it’s an attempt to encourage separation between programmers and managers with …