Building codes are about standardizing things so builder and inspectors barely have to communicate - at a glance they can see they followed x, y, z.
But the law should have a place for homeowners who do things safely, just not exactly how a builder would do it. That's why many places require permits for various work (for example electrical work) - unless you do it yourself, in which case you are exempt. And that's the right way to do things.
Just like you don't need the health department in your kitchen, but you do in a restaurant.
The same goes for your house. After all, you simply won't life there forever: Either you'll sell the house or die eventually. Anything you do to that house that doesn't meet codes can seriously affect the folks that live there after you.
This is why the codes are important.
Because, based on the article, it sounds like absolutely no common sense is used for exceptions.
But some of those codes one doesn't have to pay attention to as much: Requiring grounded plugs with minimal construction standards. If you just buy your stuff, you won't have to worry about the construction standards of your outlet unit, merely that you buy the grounded sort.
"Absolutely no common sense is used for exceptions"
To me, this looked more like ignorance on both sides. If the inspector has no real training in construction, all he really has is the code - the stickers for the wood (for example). And the man building should have checked codes upfront to see what he needed to do to work around it.
Significant portions of England were built well before modern codes. Why can those be legal residences and something built in the same style and method be illegal?
Edit: So if you can downvote you've been here long enough to know you should tell me why. Shame.
Sometimes you catch something, and sometimes you don't, and sometimes the previous owner masks normal markers of problems. Most the ones I've seen check for major problems in places you can see them. Codes don't make it so you don't have the responsibility: They, in theory, make sure your electrical system is as safe as possible when you are building and other such things. The inspections help to identify known problems, especially important to older houses built to different standards.
Which is why buying a pre-existing house is slightly more risky than a new house. My parents had to treat a basement boiler for asbestos: One house the owners covered up signs of the roof leaking and the electrical was obviously not professional, even for the time of the upgrade. This house was inspected pre-purchase.
Most codes grandfather in old codes, but if you upgrade the system, you need to meet the new code for safety reasons.
I often think you should be able to rebuild in the same general visual style and size. But method? Lets face it, some of the old places were the cookie-cutter houses of the time - it isn't like every old building is of high quality. They used lead paint and asbestos, for example! But so long as the old methods meet current codes (some of which, like the number of nails, was meant to deter shoddy construction) I don't see where most folks get into trouble.
Part of your statement, the bit about style, gets to be a mix of aesthetic zoning laws and safety, the first I generally disagree with and the second usually helps folks when there is fire.
It's not uncommon to spend a few hundred dollars during a remodel for load calcs. I.e. it's probably not a huge extra expense for a major project.
While building standards exist to ensure a base minimum of safety and quality, that's it---it's a base and there's no real reason to exceed it (it just adds expense). The older homes were built more conservatively (the Brooklyn Bridge is something like six times the strength it needs; compare to the Tacoma Narrows Bridge (https://en.wikipedia.org/wiki/Tacoma_Narrows_Bridge_(1940)) built "just to spec").
I reject the thesis that removing building codes would RAISE the quality of buildings. I'm sure builders would love to dial down the material used a couple more steps so that it stand up just long enough for the big bad wolf to come along.