It could be countless, and highly subjective reasons but I’ve thought about this a lot and have some ideas at least at the individual, more personal level.
- One of my friend’s choices for going with Python\Django: The automatic admin UI is a huge time-saver for getting a feature out that staff can work on. I don’t think there’s a Clojure adjacent as of now which includes a solid backend and frontend experience for scaffolding an app. For those unfamiliar: You define your model then Django can generate the admin form pages for it including form UI and validation and related backend CRUD.
- Learning Clojure does require you to change the way you approach problems. That’s hard to let go.
- Hosting for a Clojure app is not quite as cheap or as easy to setup as say PHP
- It’s not already on your system like Python is on OS X and some Linux distros
- It’s a little more complex to run than say JS, Ruby, Java, or Python given that it’s a hosted language. Though the Clj tool goes a long way towards fixing that.
- Clojure is not taught in most schools as far as I know, so in most cases it requires a choice on people’s part to spend the time to learn it.
- The simplicity Clojure brings is hard to communicate because when it’s done right it’s intentionally underwhelming [1]
- You don’t find as extensive docs for Clojure projects as you do a lot of major Python or Ruby libs. [2]
- I theorize people love finding quantifiable facts (# of bugs on avg, static types, startup time, hiring etc…) that they can use to justify their subjective choices. [3]
- I also theorize the more excited you are about something, the more resistant your peers are to trying it. Few want to believe peers know something they don’t or have an advantage over them [4]
- Because it’s not mainstream people want to assume it’s for a good reason, or may feel it’s too risky.
- Sunk cost fallacy (Java is what I already know so Java is what I should use)
[1] That sense of addictive accomplishment working on a complex problem isn’t as apparent in Clojure than when you finally wrap your head around a complex Gang-of-Four pattern, or finally learning how that mission-critical, under-documented system, built around a cutting-edge at-the-time Postgres plugin, that a co-worker just barely got done before leaving the company developed. Where as in Clojure often you feel like, “Meh. It’s a function that takes a hash-map and returns a seq of hash-maps. I never have to think or worry about this ever again.”
[2] Something that took getting used to when transitioning. From my Python, especially Django experience, you DREAD hitting the View Source link to the github repo. You know if you do, you’ll be chasing down so many arbitrary class definitions to find that one class that affects the behavior you wanted to learn more about.
In Clojure, viewing source can become your first reaction to learning functions. You realize you don’t need a book of docs for every project because most of your code is just transforming arguments and finally sending it somewhere with side-effects. Projects like Django and most Ruby projects I’ve explored really like to invent a lot of terminology between the code required to solve the problem and the domain problem you’re solving.
“No, you can’t just transform a hash-map of request data into a hash-map of response data. You need this specialized View class which receives an HttpRequest instance, and sub-classes the TemplateView class and uses these lifecycle methods to manipulate these specific attributes so you can return an HttpResponse instance. But don’t worry. We’ve generated docs for every class, subclass, method, and attribute.”
[3] In reality, I feel it’s a lot like choosing a color for a painting. It’s usually an informed choice, layered with expectations, but it usually comes down to mostly liking it.
[4] When I first met someone who used Clojure, I didn’t react with bewilderment and curiosity. I thought it looked weird and unreadable with all those parenthesis and believed at the time that a language like Python or Ruby with its cleaner syntax would make things more maintainable in the future. Oh what a fool I was!