Darrell Norton's Blog [MVP]

Sponsors

The Lounge

News

  • Darrell Norton pic

    MVP logo

    View Darrell Norton's profile on LinkedIn

    Currently Reading:

    weewar.com

Advertisement

Images in this post missing? We recently lost them in a site migration. We're working to restore these as you read this. Should you need an image in an emergency, please contact us at imagehelp@codebetter.com
Something to code by

 "There are no exceptions to Postel's Law.  Anyone who tries to tell you differently is probably a client-side developer who wants the entire world to change so that their life might be 0.00001% easier.  The world doesn't work that way."  [via Dive Into Mark]

Postel's Law is originally stated in RFC 793 as "be conservative in what you do, be liberal in what you accept from others".


Posted 02-06-2004 1:19 PM by Darrell Norton

[Advertisement]

Comments

JosephCooney wrote re: Something to code by
on 02-08-2004 9:58 AM
Either there are no exceptions to Postel's Law...or Postel's Law is wrong.
Darrell wrote re: Something to code by
on 02-08-2004 3:27 PM
The author takes the position that there are no exceptions. Postel's law has held up for the past 22+ years (since 1981), so what is different about now?

However, apparently there are XML enthusiasts that don't think Postel's Law applies to XML. See the article for full details.
JosephCooney wrote re: Something to code by
on 02-08-2004 4:36 PM
I've kind of been following the "draconian" vs. "tolerant" debate which has been discussed
http://www.25hoursaday.com/weblog/PermaLink.aspx?guid=23d8b5ec-e0c8-4a61-b317-7bca1d8d74f3
I think I am a draconian.

Should my ASP.NET pages be liberal in what they accept from others? The thinking these days seems to be more "determine what valid input looks like and allow that, disallow everything else", which seems to fly in the face of Postel's Law.

Maybe Postel's Law isn't really a law at all, or maybe I just have the wrong end of the stick.
Darrell wrote re: Something to code by
on 02-09-2004 2:22 AM
I guess it depends on your audience. If your audience is other corporate developers for B2B web services, then draconian is probably a good idea. However, if your audience is normal people using a computer, they just want to read feeds. There is nothing mission critical about it, and you know that some feeds will not be strictly correct XML. At that time I would fall on the side of the tolerant.
JosephCooney wrote re: Something to code by
on 02-09-2004 11:10 AM
So there are exceptions to Postel's "Law"? How much of a "Law" is it then? OK - I'll stop being pedantic now.