Chesterton’s Fence (2020)
fs.blog
fs.blog
Caveat is that if you reach a local maxima a more drastic change may be required, but the journey to the local maxima has probably taught you enough about the system that you can safely make the bigger jump.
In any sufficiently complex system this is probably true. Often there's a reason for some thing being there, and that reason is often enough a workaround for an issue in an external library. Then the library gets updated, but the workaround remains.
I've observed this often enough. I try to add a comment whenever I do this linking to the issue on the external repo if possible, so that later on you can check if it's still needed.
But this is not fool proof and not everyone will leave breadcrumbs. The breadcrumbs might also be eaten in the meantime by some merges and refactorings.
In the end you're often left with a useless workaround, the person that made it is not in the company anymore, and there's nothing to observe for why it's necessary.
If you don't want your system to eventually collapse under its own weight, sometimes you have to go for a risky refactoring. Doing it incrementally mitigates the risk.
To follow the metaphor, maybe the reason the fence is there is because the county water supply is behind the fence and they put it there to stop cows and livestock from fouling the water.
That's why every time somebody argues against it. It's because at some point you have to abandon that rule, and all the interesting discussion is about when to abandon it, not on how to follow it.
This is another thing the Fence metaphor helps us understand when we think about it a little bit more.
Related to Chesterton's fence is Levi's Onion:
https://www.joeydevilla.com/2001/12/03/4419/
Which is sort of a Chesterton's fence situation where someone took those required steps.
Being aware of this, it is easy to assume that, no matter how many reasons you can think of as to why something was done, there might very well be other reasons you don't know, at that point, it seems to me, the options are either accepting the risk or never changing anything.
The article makes the point that people do not build fences for no reason. It costs time, effort and resources, not to mention it's a lot of work and people are lazy. There's always a reason for the fence.
>or the reason is completely lost.
This may be true. A fence in the middle of a wood may have been put there 90 years ago because of old property demarcations, or an effort to keep the dread bearded grindlesnatch from attacking the village. The property is now owned by one person, and climate change killed the bearded grindlesnatch, so the fence isn't needed anymore. But the point is to find out why it was there before you tear it down, and if you can't find the reason, you should be extra careful about yanking it down. Perhaps now the fence harbors a mini ecosystem of berry bushes that has increased the potential environment for wild game.
Progressives tend to be very dismissive of the Chesterton's Fence analogy, because they think change is an unalloyed good. There are a lot of social mores or codes that seem unnecessary, outdated or even bad, but they don't want to look at the reasoning behind them. Second order effects are easy to dismiss as speculation, so they usually are dismissed; but any change, radical or otherwise, will have second order effects, so careful thought must go into them.
A fine example of how the warning of Chesterton's Fence is ignored by inferring the worst possible motive without evidence or reason, and using that unsupported aspersion as a reason to rip something up.
> "The whole modern world has divided itself into Conservatives and Progressives. The business of Progressives is to go on making mistakes. The business of the Conservatives is to prevent the mistakes from being corrected."
Having read some of his Christian apologetic essays, I suspected the fence argument was fundamentally motivated by religion, and again from the wiki page, it originated in from his book "The Thing: Why I Am a Catholic".
EDIT: GP said "Progressives tend to be very dismissive of the Chesterton's Fence analogy, because they think change is an unalloyed good." to which parent complained "Why did you need to make this political?". I found Chesterton's own words both relevant and sufficient warrant to broaden the discussion along the lines of the GP.
Chesterton's fence is a rational argument in favor of being conservative.
A "conservative" from Chesterton's time doesn't necessarily map cleanly onto the modern notion of the same name... Supposing the allegorical "fence" to be something like clean air or water regulation, one could argue that it's modern "conservatives" more often than not arguing to disturb things without considering second-order effects.
I really don't like referring to Republican's as conservative or Democrats as liberal precisely because neither party really sticks to those concepts. "Conservatives" as a political unit are not conservative and "Liberals" aren't liberal.
The world is a dumb place.
And I always felt Chesterton's fence to be advice to be deliberate in your actions. Spending the time and effort to find out why the fence exists, doesn't mean it won't get torn down. It just means that we won't be taking it down spontaneously.
Since this is HN, I think a lot of us have experience with software. If you do, then I find it incredible that you have never discovered some complicated code that serves no real purpose, or at least no good one, and was presumably written to amuse the author more than anything else.
Hell, I've written some of that. Very complicated, usually awful code, but it did at one point have a purpose.
If somebody wrote something complicated, just for amusement, then that is its purpose. That's a fence that can be rebuilt or thrown away, but you'd better be sure that nothing else references it or otherwise depends on it doing its quirky baroque thing.
Edit to add: thinking about it, I don't think I've ever found code in a legacy codebase that had literally no purpose. The closest might be code that was once used but now isn't referenced anywhere.
Understanding whether the purpose was good implies understanding the purpose. Even with very bad code you can at least see what the author was going for. Most code I've seen and felt was bad could be described as "Author needed to do X but wasn't aware of Y." I can't remember a time where I had to deal with code where I couldn't figure out what X was.
What I’ll say to you now is that if you are actually looking for the reasons, and all you can find are people making your life hard for the glorification of their ego, you have a much bigger problem than whether it’s worth presuming that there is no reason for code you want to remove:
You are located in a local pessimum. Consider working on a different code base. Ask yourself what is going on that you keep running into all this code written by people you disrespect so much.
Back to that two page function. Yes, I know, it’s just a simple function to display a window, but it has grown little hairs and stuff on it and nobody knows why. Well, I’ll tell you why: those are bug fixes. One of them fixes that bug that Nancy had when she tried to install the thing on a computer that didn’t have Internet Explorer. Another one fixes that bug that occurs in low memory conditions. Another one fixes that bug that occurred when the file is on a floppy disk and the user yanks out the disk in the middle. That LoadLibrary call is ugly but it makes the code work on old versions of Windows 95.
Each of these bugs took weeks of real-world usage before they were found. The programmer might have spent a couple of days reproducing the bug in the lab and fixing it. If it’s like a lot of bugs, the fix might be one line of code, or it might even be a couple of characters, but a lot of work and time went into those two characters.
When you throw away code and start from scratch, you are throwing away all that knowledge. All those collected bug fixes. Years of programming work.
https://www.joelonsoftware.com/2000/04/06/things-you-should-...
Yes, it may be the case that we no longer support Internet Explorer, and none of our customers even know that Windows 95 ever existed, much less run it. And our users look at a floopy disk and exclaim "Cool, a 3D-printed save icon!"
So yes, lots of code serves "no good purpose" today, even if it was a good purpose when it was written. HARD AGREE.
Presumably written to amuse the author? Hard disagree from my n=1 experience, even if that experience with commercial software development dates back to the early 1980s. I think those cases are outliers that exist, but shouldn't drive our decision-making. The key word is "presumably." Presuming that code we find doesn't seem to serve a purpose was written for the self-gratification of the author is, in my experience, a very bad way to manage risk.
I'm prepared to assume that code which doesn't seem to serve a purpose may no longer serve a purpose, but while it may never have served a purpose, I'll try my best to find out what that purpose was before throwing it away.
Going back to the metaphor, if the fence you want to pull down is only a couple of months old, the knowledge of why it was put up in the first place is readily available. Just ask around.
https://www.joelonsoftware.com/2000/04/06/things-you-should-...
I think it’s more than sometimes reasons go away and sometimes people do unreasonable things. I don’t think anyone thinks that people literally build fences completely randomly.
> The article makes the point that people do not build fences for no reason
Sure. That doesn’t mean that the reasons are good or accessible to you to make that decision. Now when the reason is obviously apparent and widely known, that’s a totally different thing with the caveat being that conditions change and you may not have realized that in a complex system.
It's a neat analogy but it has limited utility as a general rule for either side.
Yes: To get the rocks out of the dirt so we can farm there.
https://www.loe.org/shows/segments.html?programID=18-P13-000...
https://www.atlasobscura.com/articles/new-england-stone-wall...
Now, of course, New England with its rocky soil is no longer an agricultural powerhouse, so maintaining a stone wall in the middle of re-forested land is rather pointless from the perspective of anything other than an antiquarian interest. The whole world has changed and the walls weren't primarily intended as boundaries anyway.
Naturally everything that ends up happening has a cause and happens for _some_ reason; that's nearly a tautology. But I think the is that there are many things that don't happen for any _good_ reason, many often for bad reasons. And it's also common to find that the reasons for these things aren't discernible. Someone made a mistake decades ago, and now no one wants to correct it because there must have been a reason for it, but we can't figure out what it was.
Years ago I was the member of a local governing board, and there were many people there who thought that because we were part of a bureaucracy, we should act more bureaucratic. The more work we did, the more we required of other people, the longer the meetings, the more trainings for systems we'd never use, the better.
I remember one particular situation where another agency was asking our input about an application in our jurisdiction, and the chair told me to tell the applicant about all the extra paperwork they would need to file with our board. I contacted the agency the application was actually filed with, and they told me they already handled that, and they were only notifying us in the off-chance there were any special considerations in our district the agency needed to be notified of. As far as I could tell, the dozens of boards who oversaw other jurisdictions didn't have our additional requirement either. When I told our chair that the agency wasn't asking us for the additional paperwork, he replied "but that's how we've always handled this." At some point years before somebody on the board wanted to add additional paperwork (and it's questionable whether they actually had the authority to do this), and the rest of the board just mindlessly followed along for years.
That's a bit of a strawman. One could just as easily argue that reactionaries in the USA don't want to admit why many fences were built.
Is this true? Who is leading the charge to distrust longstanding institutions such as universities… or the CDC? Who is trying to hold nature in balance? Even the right to terminate a pregnancy can be seen as a Chesterson’s fence that is looking to be torn down.
The former leader of the “conservative” party was infamous for steamrolling norms.
I’m not a progressive personally, but I think this is an unfair description of them. Too broad a brush.
The condition is to make an effort, not to necessarily succeed. If you try and can't make sense of it, you have the green light to proceed with caution.
Then we would still notice the difference between two kinds of reformer: those who don't know (and don't care) why an institution is the way it is and those who are reasonably curious about what the institution was for, how it worked, and so on, even as they recognize a need for reform.
A lot of engineers would write something like "this fence is made of silver oak planks cut to a length of 3 feet and fastened together aluminum wire" and while that may be useful if you have to fix the fence, for the people in the allegory it would be much more helpful to have a sign that says "this fence is here to keep cows from fouling the water in the lake behind it because 5 houses nearby use it for drinking water". If either the 5 houses or the cows are no longer there, it makes the whole system much less resistant to change.
Japanese seaside communities frequently have markers showing the height or inland range of previous tsunamis. Proscriptions against specific materials, sites, foods, or practices may be based on previous lessons for which available archival mechanisms were insufficient to detail though lore and monuments might serve as warning.
Jared Diamond observes that in New Guinea, natives refuse to sleep beneath certain types of tree, despite what seems a small risk of limb-fall. The occasional recreational camper might get away with spending a few nights out of a lifetime under such a tree or camping on low ground. Small risks repeated sufficiently many times become large, and those living such a lifestyle take precautions.
Similarly: many safety regulations, standards, and precautions are written in blood. Oderised gas is the scented memorial to the 300 souls of the New London School.
Long-term, latent, non-manifest risks are a chief form of technical debt.
Obviously paralysis is a different matter - but taking time and consideration to get to the appropriate decision actually is highly productive in the long run - though if you are an executive it might not signal that you are going to be around for a long time due to organization thinking you aren't up to task.
N.B - taking the time to access a decision is always a trade-off.
For example, I think open borders might be good for the world (maybe outside of pandemics, say), with less than 100% confidence. However, debating completely open borders is sort of pointless. The actual lever we have is how much legal immigration we allow (and possibly how much enforcement we do against illegal immigration). So in practice, the road to open borders would be steady increases in the number of visas we grant (unless things start to go badly), not just tearing down the "fence" all at once.
Even with 100% knowledge¹ that Open Borders is the right policy, implementing it overnight can be a disaster, since institutions, culture, public opinion etc need time to adjust to the new reality.
¹ For the sake of argument. Let's not debate immigration policy.
These include pilot projects, modelling, stratified or distributed deployments (different regulations in different districts, rolling out changes to subsets of a userbase, etc.).
There are times when an entire system needs to be modified as a whole. Those are not all instances however.
I wonder whether if that observation is transferable so that the second-order thinking need not be original if there exists a directory of common decisions & outcomes?
I've been trying to validate[1] whether if we could create a standardization for common decisions and outcomes; Then people could share their recipes of decisions & outcomes to a central directory which can be used to make Second-Order decisions without actually having to make one our self.
[1] https://needgap.com/problems/263-plan-second-order-third-ord...
Why do engineers hate to work with other people's code? Let me try to make an analogy.
You are hired to finish building a scientific lab on a distant island. When you arrive, you see half-finished building, a giant (same size than the building) fan and a hot air balloon. In the basement you found a room full of floor mops - about a thousand of these.
You clean up the mess, finish all the work, the lab starts it's first experiment and then suddenly after only five minutes scientists are starting running around screaming about toxic gas leak. You call your predecessor.
- Buddy, what's up, there's a toxic gas leak, how's that possible?
- I don't know, everything should just work, did you change anything?
- Yes, I put all those floor mops away.
- Why did you do that?! It was meant to support the floor above, where the toxic gas reservoir is! It was too heavy, thus the mops!
- Are you crazy to support the toxic gas reservoir with mops? Why didn't you at least put a sign on the door? What do I do now?
- Turn on the fan, it will blow the gas away.
- Dude, I disassembled the fan first thing, why didn't you put a box of gas masks instead?
- Where do I find gas masks? And the fan was a spare from the other project!
- This is terrible! We all gonna die here!
- Why are you still there? Jump to the balloon and fuck off the damn island!
Under those circumstances, it is best to figure out options in front of us, make a decision and move forward. Doing nothing is also an option, but one cannot be stuck in endless analysis-paralysis and fail to decide.
When this occurs, they dig in firmly in their positions and either argue for keeping the fence as-is (maintain status quo) or taking it down (action bias).
Bureaucrats famously build things just to associate themselves with "getting things done".
This is the stuff technical debt is made of.
Sometimes it's the right decision to risk second-order regressions in order to make forward progress. This of course depends on the circumstances and the costs of regressions.
True, but also ignoring Chesterton's Fence is what catastrophic rewrites are made of.
If you know why the fence is there and have confidence the reasons no longer apply, you can be bold. If you're not sure because the archeology is expensive, you should take baby steps if possible. (Which I think you get at with the cost of regressions.)
For my team, that's often flipping a feature flag where we don't expect any difference, and watching the output for a while to verify. First sign of surprise, we can quickly flip back. We get surprised more than we would like.
Just as a general rule in conversation, invoking so-and-so's law or this fence isn't a productive tactic. Instead, ask the question that wisdom suggests you ask, and for this bothersome fence in particular, keep in mind that you are weighing an unidentified consequence against a proposed benefit, and at least endeavor to expend some of your own effort on suggesting what the value of the fence might be or how one might go about finding it. You may find some of that effort has been undertaken and that failure has not been shared.
Not true. If we both are familiar with the concept, saying "Consider Chesterson's fence" conveys a lot of information. If we aren't, chasing down the reference will almost always result in a much more articulate version of the concept than whatever you or I would come up with on the fly.
Like so many logical constructs, it really just seems to exist so we can apply it when we are frustrated, not in our day to day decision making.
Chesterton’s Fence: A Lesson in Second Order Thinking - https://news.ycombinator.com/item?id=22533484 - March 2020 (85 comments)
The Fallacy of Chesterton’s Fence (2014) - https://news.ycombinator.com/item?id=13063246 - Nov 2016 (26 comments)
The Fallacy of Chesterton’s Fence (2014) - https://news.ycombinator.com/item?id=11743965 - May 2016 (2 comments)
There was also https://news.ycombinator.com/item?id=23196731, which was on the front page for 5 minutes before we buried it.
It's true that it's an internet cliché though—so much so that Chesterton seems in danger of turning into his fence.
Before destroying/removing/deleting something, make sure you spend sufficient time to understand why it was created in the first place and if you can't, then leave it intact.
No need to spread 1 piece of butter on a whole bakery worth of bread
The first interpretation is generally more defensible, but still not an absolute. There may be circumstances in which time does not exist and other exigencies prevail. As an example, if you come across a fence in the course of, say, responding to / evacuating from a natural disaster, you might consider briefly if there's some specific danger that the fence guards against (say, a cliff or other hazard), but determine that the greater benefit is in removal for the purpose of effecting rescue or escape.
First-responders don't agonise over why car doors were created when deploying Jaws of Life, earthquake responders don't survey plans of buildings to determine why walls exist before demolishing or removing them to access victims.
In less pressing circumstances, such as making incremental updates or changes to some system, performing some inquiry into purpose, intent, or function is strongly advisable, and Chesterton's Law is a check against naive and uninformed alteration without such considerations.
It's really important to challenge these things, but they're tricky specifically because no one owns the decision (the person who chose left, or forgot, or who knows) so a naïve application of "don't change what you can't figure out the reason for" fails when there may be no clearly documented reason, beyond a shared hunch that it mattered at some point.
Sure you should still investigate, but if after a decent investigation you can't figure out why, yes, change the thing. Sometimes you'll be wrong, but this is what we have error budgets for.
Where the change is needed and previous rationale can't be determined, if possible:
- Note that you've made the change.
- That the previous rationale wasn't clear.
- If possible, provide for backing out the change if it proves ill-advised.
Often an initial approach can be to disable or bypass a specific mechanism. E.g., put a gate in a fence, a bridge over a gap, disable a feature, etc. Watch to see what does or doesn't fail.
In software, specific time-triggered events may exercise infrequently-traversed paths --- end of week, month, year, etc. Naturally, these are hard to detect in advance. More convoluted are conditions triggered rarely (lunar cycle ~= 19 years, leap years, Unix epoch overflows, etc.).
This is where documentation and QA engineering will save butts.
Its juxtaposition with Chesterton's essay is kind of weird, because Frost doesn't even know what the wall is for, and apparently neither does the neighbor.
Maybe not so much the HN crowd...but then again maybe especially them
Chesterton's Fence is a good principle; so is "Go and See" - https://en.wikipedia.org/wiki/Genchi_Genbutsu
Wisdom is deciding how much of each to do.
Yes, maybe the fence is there for a good reason, in which case the people that installed it made a poor documentation job. So who know what else they poorly implemented?
People are trying to interpret the analogy outside of the theological context in which Chesterton wrote, and therefore either reduce it to the kind of relativistic conservatism that GP rightly decries, or else deny what Chesterton actually wrote.
Chesterton’s point is that change can be good or destructive. Since evil is not a positively existing thing, but merely a lack of goodness, a lower goodness mistaken for a higher goodness, or vice versa, if I am to act upon something in order to bring it to its full goodness, I have to understand the goodness already in it, otherwise I act in a way that is destructive. In short, I can only be trusted to change a thing if I am able to love it.
CERN is an instrument to help us learn more about physics. Bringing it down would not help us make any change, and it would only hinder us from learning more about the truth of nature. You need a better example than that.
What if a high energy particle collision causes a miniature blackhole that destroys all life on earth? What if sailing across the uncharted sea makes God angry? What if knocking down the walls of my cage lets the monsters in? What if the act of investigating the fence destroys the fence?
This is reductio ad absurdium. There is a whole lot of contexts and dimensions where the concept of Chesterton's Fence can be applied before trying to dismiss it.
If you want a better example, you could ask "why so many religions teach to not eat pork?"[0]. Then we could look at historical contexts (i.e, understanding why it was put up in the first place), realize that most of those don't really apply to the modern world and "tear it down" if you want to enjoy delicious pulled pork sandwich.
> What if sailing across the uncharted sea makes God angry?
That is not a satisfactory answer to "why can't we explore the seas?", and any rational person would/should continue to investigate.
---
Using the "sail the uncharted sea makes god angry" example.
Maybe that particular parts of the ocean has sea monsters (dangerous animals), and lots of whirlpools, and lots of poisonous fish that kill you if you eat them, and pirates.
People short hand that to "going there makes God angry" because they know people don't come back and when they do come back its in worse condition. But its never quite the same root cause. (hence why they blame god, and not the pirates for example) So there is no easy one answer unless theres concrete efforts to add together the stories of the guy who got attacked by pirates, the guy who had a run in with a giant squid, the guy who got poisoned, and the guy who almost drowned in a whirlpool.
You'd be pretty foolish to ignore the "god will get angry" warning, if you go there. You might have heard one or even two of the dangers, but not all of them that push the risk profile so high. Thats where Chestertons fence becomes useful and says you should be the person that gets all the stories together and realizes the real dangers and not dismiss the "god will get angry" warning off hand.
"Make god angry" is parsed as "because these people had a religious belief i believe is false", and they assume they understand the Fence in question and mow it down.
It's easier to dismiss 20 different people saying the exact same, meaningless "God will be angry" answer than to dismiss 20 different tales of "someone two/three/six generations ago got attacked/drowned/never was seen again after going to the ocean".
Chesterton's Fence is a criticism of reformers, revolutionaries, and burn-it-all-down types who want to make changes without making an effort to understand why the thing they want to tear down is there in the first place, what purpose it is serving, and the consequences of doing so.
Responsible jurisprudence does this all the time. When judges are presented with a case that puts a law into question, they look at the origins of the law and make an effort to determine the costs of eliminating that law because the good of a lot of people may rely on that law being in place. This doesn't mean they don't change the law if some people would suffer as a result. It just means they are aware of why the law exists and what purpose it serves as well as the relative costs and benefits of doing so (principle of double effect). Naturally, as you have said, we do not have perfect knowledge, so obviously we can merely do the best we can. A person is not obligated to do the impossible.
most of these examples are not structured as a Chesterton's fence type problem.
If there is a prohibition against sailing across the seas in the town's bylaws and you do not know why it is there, then you would have Chesterton's fence. You would then do investigation until you found an old letter from the mayor about his indigestion and a bad dream that told him that sailing across the seas made God angry.
Then as making God angry is understood as not a reasonable prohibition and the mayor's indigestion not sufficient cause for anything (especially as that mayor died years ago) it would be concluded that you could then sail.
The next day God will of course smite you and everyone in the town, but thems the breaks.
on edit: fix typo, fix grammar
The kind of situations where it could be applied is when an individual wants to change a system, i.e., when an developer wants to rewrite a codebase that "is way too complex for what it is", when a employee see a process that doesn't seem to make any sense, when a reformist wants to change the rules of society, ...
It's basically an invitation to consider why the system was put this way, before envisioning how to change it. Instead of designing a new system based on the flaws of the current system, find out why it was designed this way, so you can design a system that solves both the flaws of the current system, and the flaws of the previous system, for which the current system was put in place.
You’re applying Chestertons fence backwards. Instead, it would inform you to _not_ shutdown CERN until you tried to understand its purpose.
I have yet to see a detailed balance sheet on that choice (which includes externalities) from the 'someone who made that decision'. No doubt 'profits' are up, depending on who defines 'profit', and who it advantaged. Sometimes things start out seeming like a great idea (universal automobile ownership). Sometimes haste (like universal nuclear energy, all political motivations aside) makes waste.
Often, new leaders replace old frustrations, and concluding that the previous regime had some wisdom of its own is received like a lead balloon.
Chesterton was right, but probably did not consider corporate politics :-)
But that doesn't mean we should always establish why the fence is there. Sometimes, the opportunity cost of working out the reason outweighs additional certainty. I guess good leadership is repeatedly making the right call over when to do one or the other, and putting in place appropriate mitigations in case you're wrong.
I think succeeding in this part already requires quite a bit of the understanding that Chesterton's Fence is actually calling for.
If you're (in good faith) able to make an informed opinion between choosing taking the risk and gathering yet more additional information, you're already in a much stronger position than what's usually considered as the failure mode of not taking the Fence into account at all.
Chesterton’s Fence: A Lesson in Second Order Thinking - https://news.ycombinator.com/item?id=22533484 - March 2020 (85 comments)
The Fallacy of Chesterton’s Fence (2014) - https://news.ycombinator.com/item?id=13063246 - Nov 2016 (26 comments)
All I take this nice parable to mean is that maybe you make your second, less instinctive thought be "why is that here?". That's it. Consider it then carry on. No law mandating a thorough investigation. No restriction on change without complete understanding. No need for deterministic certainty. Just a simple consideration that you should entertain. Or perhaps more accurately, a consideration you shouldn't disregard.
Recognising the possiblity of misrepresentation is yet another higher-order level of awareness.
Here’s a better approach:
- admit that deprecation work is hard. Damn hard.
- but know that is important. Damn important.
- read the chapter on deprecation (15) in the book Software Engineering at Google [1]
- come to appreciate that if deprecation is a hard problem for Google, then it is hard for you
- sit down, take a breath, make a plan, then roll up your sleeves and do it. Smash that fence.
- if needed, watch Shia LeBoeuf’s motivational on youtube
- just do it