That's probably a unique case because in the beginning the documentation was so bad, but especially in new and esoteric programming languages/methods $50 is no big deal, and there are lots of willing buyers. I'd bet the HaskellBook authors pulled in 100k+ too.
https://s3.amazonaws.com/gumroad/blog/DiscoverMeteorCaseStud...
It's true that market opportunities are hard to find, but you'll never find one if all you see is the "yes, buts". You miss 100% of the shots you don't take.
Search for the things that no one else sees or has the vision or boldness to turn into an outlandish success.
Take a chance. Live a little. Dig deep down for your inner crazy.
I know a half dozen other authors of technical/programming books who have probably made between $50k to $100k over the life of their books.
So there's a lot more money potential for the average programming book than there is for the average novel. (Bestselling novels make much more, but only a few books get that status)
If you give me a system that will help me become a full-time programmer in 12 months, making $75/hour, then I'll gladly give you hundreds of dollars for the book.
Out of 100, at least 3 people will see that value. If you charge $50/month for the book/course, and have a list of 3,000 people, you are effectively looking at a full-time income