
The Caves of Clojure - joeyespo
http://stevelosh.com/blog/2012/07/caves-of-clojure-01/
======
espeed
_Despite its Rubyesque culture of brokenness, rampant lack of documentation,
and warty JVM interop..._

This has not been my impression.

~~~
mattdeboard
Ha, this is funny. I came here to say that this has been exactly my impression
(sans Java interop warts since I haven't done much there).

There is a lot of missing documentation -- and by that I mean high-quality,
contextual, human-readable, practical documentation -- though the community
has been working to remedy that.

There is a particular definition of "culture of brokenness" that I'd agree
with but there are a lot more that I wouldn't. I'd have to hear the author's
definition of what he means by that before I agree.

That being said Clojure is downright _beautiful_. I wish I had opportunity to
work with it more.

~~~
bengl3rt
To me the most frustrating thing about programming in Clojure (not that I'm
generally frustrated by doing it, in fact I love it) are the totally
cryptic/useless error messages, especially syntax errors that don't contain a
line number (or they do but it's invariably 0).

Thank goodness for syntax-coloring editors or it would take me hours to track
some of these things down.

~~~
masklinn
> the totally cryptic/useless error messages

I can but agree with this, Clojure rivals template-heavy C++ in GCC for the
uselessness and pointlessness of the humongous heaps of cryptic error messages
it produces.

~~~
lukev
Not that this is an excuse, but once you know a bit more about how Clojure and
the JVM work, stack traces become a lot easier to interpret. Most of the time,
there's at least one line in the stack barf that tells me exactly where to
look to find the problem.

This may actually be a _bad_ thing, because it disincentivizes those who have
the ability to fix things to be more newbie-friendly.

~~~
astine
I've been wondering if the fix would be as simple as filtering stack trace
entries generated by higher lower level code (ie, from Clojure itself rather
than the application code.) It seems like such a simple fix that I wonder why
it hasn't been done.

~~~
lukev
It has, several times (the clojure.stacktrace lib, also
<https://github.com/mmcgrana/clj-stacktrace>).

The problem is that these require a running, working system to format and
print the stacktrace (as well as inspecting the state of the Clojure runtime).
Unfortunately, uncaught exceptions will also quite often FUBAR the REPL, if
not the entire JVM, meaning that improved stacktrace tools can only work some
of the time, and will sometimes even make things much worse (if the JVM throws
an exception from within the stacktrace formatter itself.)

------
BadassFractal
Keep us posted, Steve. As someone learning Clojure, I enjoy every bit of its
code out there that shows me how things could be done idiomatically.

