Entries in category “Frameworks”

On “conceptual integrity”

Published February 11, 2008

Mark Ramm has a nice post this morning talking about Adam Gomaa’s discussion of “conceptual integrity” in Python web frameworks; I think it’s worth a read.

The key point Mark touches on is good documentation: ensuring that people see and understand the overarching structure of the framework is, ultimately, the key to helping people understand how it can help them get their work done. In the case of Django there is an official ...

Read full entry and comments

Shared hosting is not a ghetto

Published January 13, 2008

In the wake of the Dreamhost blog’s post on Rails and shared hosting, there’s been a bit of a meme going around with respect to deploying frameworks like Rails (or Django, or TurboGears…), and which more or less consists of people asking why, if you’re using one of these frameworks, you’re not just ponying up for a VPS or dedicated server. After all, it’s not like the offerings these days ...

Read full entry and comments

Web frameworks and web hosts

Published January 10, 2008

Today John Gruber linked to a post on the official Dreamhost blog lamenting the state of web-framework deployment on consumer-level shared hosting; while the post itself is largely concerned with Ruby on Rails, the current state of deploying popular (non-PHP-based) web frameworks on hosts like Dreamhost is, well, abysmal. A search for “dreamhost” in the archives of the django-users mailing list turns up nearly five hundred results, many of them people struggling to ...

Read full entry and comments

The why and wherefore

Published December 31, 2007

So, let me straighten a few things out.

First off, this is my personal blog. What you see here is me speaking my own personal mind, and I neither represent nor want to represent anything larger: not Django, not Python web development, not my employer, not anything except me and whatever I feel like writing about. This is an important point to keep in mind, because I don’t have any claim to represent anything ...

Read full entry and comments

With apologies to John Gruber

Published December 31, 2007

For a little while now I’ve been trying to stay out of Python framework debates, partly because I just haven’t had the time and partly because things seem to be taking a turn for the nasty again. But recently it’s been harder and harder to keep away, especially with the hard work of a new entrant into the arena: Noah Gift, whose blog posts at O’Reilly have, in the last month ...

Read full entry and comments

Let’s talk about frameworks (again)

Published November 19, 2007

Over the past year or so I’ve written several articles on frameworks, mostly talking about the pros and cons of using them and specific design decisions pertaining to specific frameworks. For the most part this has been in the context of programming — specifically Python and JavaScript programming — because, well, I’m a programmer; this is what I do for a living. But every so often the general topic of frameworks for the Web, recently ...

Read full entry and comments

ORM Wars

Published September 4, 2007

Last week while I was still on blog hiatus, Adam Gomaa wrote up a pretty constructive summary of why he prefers SQLAlchemy over the default Django ORM, and documented how he made SQLAlchemy a little less painful to use by writing a set of helper functions before moving on to announcing that he’s writing his own declarative layer — borrowing somewhat from Django’s model syntax — on top of SQLAlchemy.

I went back and read ...

Read full entry and comments

Hypothetical framework choices

Published June 2, 2007

I subscribe to feeds of items tagged with “django” on a couple of sites, and tonight I noticed a link which posed a hypothetical situation of wanting to port a large J2EE application to either Rails or Django, and asking about making the choice between them.

I wrote up a reply, but attempts to post it there netted me “The page you were looking for was not found. Moron.” So here it is in all ...

Read full entry and comments

PyCon 2007: Web frameworks panel

Published February 23, 2007

(this was liveblogged during the panel, and the only later edits were to correct a couple of typos and add this notice — the content has not been changed)

Titus, the moderator, has welcomed everyone. No blood shed so far. Probably not taking audience questions.

Introduction of the panelists:

  • Spyce: Jonathan Ellis
  • CherryPy: Robert Brewer
  • TurboGears: Kevin Dangoor
  • twisted/Nevow: Duncan McGreggor
  • Zope: Jim Fulton
  • Django: Adrian Holovaty

Titus pauses: “The most interesting thing about Django ...

Read full entry and comments

Python framework design

Published February 19, 2007

Lately I’ve found myself being baited into the same old debate over and over and over again, and I’m getting tired of making the same arguments each time. Usually it begins with someone lamenting how Django is anti-community or too inflexible or generally suffering from a raging case of NIH. From there it progresses into people proclaiming how TurboGears or (more often) Pylons is objectively “better” because of how they’re designed, and ...

Read full entry and comments

Choosing a JavaScript library

Published January 22, 2007

Previously we looked at some objections to JavaScript libraries and some possible responses. Now it’s time to ask a bigger question: do you need a JavaScript library, and if so how should you go about choosing one? I’m not going to recommend any particular library, because I don’t think there’s such a thing as one-size-fits-all in web development, but I can list a few things which are useful to keep in ...

Read full entry and comments

Django and NIH

Published October 21, 2006

Just so you know, Django is a smug, arrogant framework that doesn’t play nice with others. The developers are smug, arrogant assholes who don’t care what anyone else does or what other tools are available, and who always insist on doing things their way. Django absolutely refuses to support cool “standard” Python tools and libraries unless they were implemented first for Django. Just stay the hell away from it, and teach those goddamned ...

Read full entry and comments

How I got here

Published October 16, 2006

I’m not a formally-trained programmer. I wasn’t a computer science major in college (my degree is in philosophy), and my first job after graduation didn’t involve programming (it was phone-based customer service at a health-insurance company). But here I am, developing software for a living.

I’ve never written a compiler. I’ve never hand-tuned something by dropping in bits of assembly, or even by writing C extensions for an interpreted language ...

Read full entry and comments

Friday fun

Published September 1, 2006

It’s the end of the week and, while I’ve got plenty of things I could write about, I’m sort of tired and burned out. So let’s just look at a couple things that went on this week.

Django performance with foreign keys

There’s been a bit of a to-do the last few days over a supposed performance problem in Django. I have a hard time classifying it as a “bug ...

Read full entry and comments

Let’s talk about frameworks, security edition

Published August 13, 2006

It’s been an exciting week, hasn’t it?

The Rails vulnerability touched off quite a firestorm of commentary on the security of web application frameworks (and, by extension, applications developed with them), so let’s bring back the frameworks series for one last hurrah and take a look at security.

What do we mean by “secure”?

This may sound like a strange question to ask, but it’s an important one. A common misconception ...

Read full entry and comments

Mandy, I’m dandy

Published July 28, 2006

I don’t honestly expect any of you to remember this, but some time ago, when I posted an entry talking about Python and Ruby (on which comments are closed because the post is over a month old — hopefully this weekend I’ll get around to turning on the auto-moderation stuff I wrote up), I received a comment from one “Mandy Owens”, who seemed to think that, for both technical and marketing reasons, Rails makes ...

Read full entry and comments

Helpers, scaffolding, tradeoffs and other stuff

Published July 17, 2006

In one of the very, very few coherent things I’ve seen him say in comments posted here and elsewhere, one Lucas Carlson brought up the other perceived advantage of JavaScript helpers: they save time:

Sure it is possible to add javascript helper functions to Django, and yes that would speed up initial development times and reduce bugs since Python is usually more terse than JS… even for expert JS programmers.

I’m going to ...

Read full entry and comments

JavaScript, ORM and “hiding SQL

Published July 4, 2006

So my little rant on AJAX support in Django apparently touched a nerve with a couple people; that means it’s time to write more about it.

One of the common points people have been raising, in comments and elsewhere, is that I shouldn’t rail against “hiding JavaScript from the developer” when Django’s ORM already hides SQL from the developer; from the perspective of a server-side developer, SQL is just as important, right ...

Read full entry and comments

How Django processes a request

Published June 13, 2006

In a comment he left yesterday, Jonathan Snook posed an excellent challenge: document the chain of how Django processes a request, from start to finish, with plenty of detail on the various things being called internally and links to the appropriate documentation.

Simon Willison once wrote such a document, but it was a fairly high-level view and a fair number of things have changed since then, so I’m going to take a stab at ...

Read full entry and comments

Let’s talk about frameworks: When frameworks aren’t right

Published June 10, 2006

I know, I know, I said I was done with the series. But there’s one more thing I’ve been feeling like I should have mentioned: when frameworks aren’t the right choice for a project.

The big belly, revisited

A simple line graph which steeply curves upward from bottom left, then levels out and is mostly flat through its middle, then steeply curves upward again toward the upper right

Remember that image? It shows the types of projects for which I think frameworks are a good choice, the 80% or so of web projects which can all be handled by a database-driven application ...

Read full entry and comments

Django tips: Write better template tags

Published June 7, 2006

Django‘s template tags are a great way to handle things that don’t always make sense being in a view. If you want to have, say, a list of recently-added content which appears in a sidebar or footer on every page of a site, it’d be crazy to manually change every view to fetch that content and add it to the template context; a template tag is definitely the way to go.

For ...

Read full entry and comments

Django tips: extending the User model

Published June 6, 2006

One of Django‘s great strengths is its built-in user and authentication system; the bundled application django.contrib.auth includes models for users, user groups and permissions and views for logging users in and out and changing and resetting their passwords. This is enough to cover the needs of a huge number of sites and, after the admin, the auth system is probably the most popular bundled application Django ships (or maybe the other way ...

Read full entry and comments

Templating languages redux

Published June 5, 2006

So, I thought I’d explained why templating languages are pretty useful things. Markup is, after all, just about the fastest and simplest way to, well, mark up content for presentation and, when coupled with a small amount of logic, is by far the best way to present the output of a dynamic database-driven web application. I kind of hoped that I wouldn’t have to write more on the topic, because there are so ...

Read full entry and comments

Let’s talk about frameworks, DBA edition

Published June 4, 2006

In the previous entry in this series I took a look at some common criticisms programmers level against the new generation of web-development frameworks. Today I’ll be following up in somewhat the same vein, by expounding on something that might lead your friendly local database administrator to look somewhat askance at how these frameworks do things.

And let me say right now, before I ruffle anyone’s feathers, that when I talk about applications ...

Read full entry and comments

Let’s talk about frameworks, programmer edition

Published June 3, 2006

In the previous entries in this series I’ve been talking mostly about the benefits of the new web frameworks that have been popping up over the last year or so. And from a programmer’s perspective, there are certainly a number of benefits:

  • Speed. Because a framework gives you a solid foundation of code for common functions, it also gives you a pretty big head start on a new project. Generic data modeling and ...

Read full entry and comments

Let’s talk about frameworks, designer edition

Published May 31, 2006

Yesterday we got a brief overview of the new generation of web development frameworks and a general idea of why people are so excited about them; today let’s dive in and see what frameworks can do for the designers in the audience.

You don’t have to do (much) programming

This is probably the biggest factor I’ve seen drawing design-oriented people to frameworks. There are plenty of people out there who’ve mastered ...

Read full entry and comments

Let’s talk about frameworks

Published May 30, 2006

So you’ve been hearing all this hype about “frameworks”. People from all over the world of web design and development are raving about the way their lives have been changed by things with mysterious names like “Rails” and “Django”, and you’re scratching your head, wondering what all the fuss is about — is this just a fad that’ll pass, or is this a geniunely important new development? Maybe you’re wondering just what ...

Read full entry and comments

Why templating languages aren’t a bad idea

Published May 24, 2006

Before I get into any meaty details, a quick question. You have a dynamic, database-driven web application and you’re ready to sit down and bang out its HTML output. One part of one page will be an ordered list containing comments left by visitors. You have the following choices for doing this:

Option A:

<ol class="comments">
{% get_comment_list %}
{% for comment in comment_list %}
<li>{{ comment }}</li>
{% endfor %}
</ol>

Option B:

item = page.new_content_element('ol')
item ...

Read full entry and comments

Django, gzip and WSGI

Published May 21, 2006

One of the many things I like about Django is the range of available middleware you can use to do all sorts of interesting stuff. But one in particular has got me a little bit stumped.

One of the available middleware components for Django allows content to be gzipped for output when the client specifies ‘gzip’ in its Accept-Encoding header; this is handy because it both conserves bandwidth and allows pages to be downloaded more ...

Read full entry and comments

The Google Web Toolkit

Published May 21, 2006

So Google went and released something that people are calling an “AJAX toolkit” and, as so often happens whenever Google does something, the Internets are buzzing. But, in the long run, I don’t think this is going to be a game-changing move, and I think that should be pretty obvious to anyone who sits down and thinks about it.

The first question to ask about Google Web Toolkit is simple: who is it useful ...

Read full entry and comments