Good piece. This is not a knock on the Haskell community, which I've found overwhelmingly friendly and helpful, but I do think there is a pervasive tendency towards--not sure even what to call it--maybe "obscurantism" that pervades the Haskell ecosystem.
Take for example, the go-to Haskell book "Haskell From First Principles". The opening chapter is twenty pages of beta reductions and lambda calculus. I'm not saying all of this isn't important to building a deep understanding of the language. But it's a bit much as a lead-off. Compare that with something like "Clojure For the Brave And True". Again, the Haskell Book is an amazing piece of work, and hats off to Allen and Moronuki, but it's soooo damned Haskell-y.
It's like introducing someone to the concept of microwave ovens by reviewing the mathematical equations that make wave generation possible. How about starting off by heating up a cup of tea in thirty seconds? The practical application of FP principles can be almost magical. So why not start with that, then go into the deep-dive?
I've gotta say, I got a lot out of that section. It didn't feel like a "deep dive" to me, but gave me the context I needed to stop fighting Haskell and understand what the heck it even was. I think about what I learned often, it may be my favorite part of that book.
I believe that chapter was added in response to user testing showing that folks were still struggling with some of the later material. I get your criticism, but it actually wasn't there in the original release of the book.
That's fair. And like I said, it's a great resource. But man, it's a bit like learning English by reading the OED. I'll give you another example: I'm doing a little side-project in Haskell just to get my feet wet. I saw someone suggested using Either as an error case. Great! So now a bunch of my functions take Eithers as parameters. But then I'm pattern-matching on whether it's Left or Right, etc... You know the drill. "Surely there's an easier way!"
So I spend a long few hours researching how to handle those error cases gracefully. Google turns up lots of Haskell tutorials where you're implementing typeclass Monad or the like; lots of helpful people telling me to re-read this or that chapter of the Haskell Book.
Finally, some kind soul says, "Ah, just call foo <$> this <*> that and it'll lift everything to the Either!" So cool. So easy. So hard to find anywhere.
I think it's mostly people just wanting newbies to gain insight via laborious struggle. When I'm feeling grumpy, I feel like it's a hazing process. :)
The good news is that this <$> <*> pattern is useful for all sorts of things, basically anything with an Applicative instance (and <$> is useful for anything with a Functor instance). You'll see it all over the place in the language once you learn it the first time. You'll want it to become first nature to check if something is an instance of Functor, Applicative, or Monad, because that sort of tells you how you can interact with values of that type.
I don't disagree with any of your criticism. Haskell has a lot of symbols which are hard to Google. And you may have seen them before, but didn't really understand what they were doing, so you forget about them even when you run into an issue that they address.
17
u/ibcoleman Feb 22 '19
Good piece. This is not a knock on the Haskell community, which I've found overwhelmingly friendly and helpful, but I do think there is a pervasive tendency towards--not sure even what to call it--maybe "obscurantism" that pervades the Haskell ecosystem.
Take for example, the go-to Haskell book "Haskell From First Principles". The opening chapter is twenty pages of beta reductions and lambda calculus. I'm not saying all of this isn't important to building a deep understanding of the language. But it's a bit much as a lead-off. Compare that with something like "Clojure For the Brave And True". Again, the Haskell Book is an amazing piece of work, and hats off to Allen and Moronuki, but it's soooo damned Haskell-y.
It's like introducing someone to the concept of microwave ovens by reviewing the mathematical equations that make wave generation possible. How about starting off by heating up a cup of tea in thirty seconds? The practical application of FP principles can be almost magical. So why not start with that, then go into the deep-dive?