jasongilman / proto-repl

A Clojure Development Environment package for the Atom editor
https://atom.io/packages/proto-repl
MIT License
563 stars 50 forks source link

Extended stack trace in REPL? #219

Closed shoxter closed 7 years ago

shoxter commented 7 years ago

For example -- I get an error like this:

MysqlDataTruncation Data truncation: Data too long for column 'X' at row 1  com.mysql.jdbc.MysqlIO.checkErrorPacket (MysqlIO.java:4206)

However, the normal stack trace and error message includes the table, etc.

How is this done with proto-repl?

carocad commented 7 years ago

@shoxter in general in Clojure you can always get the latest exception by calling *e , see https://clojuredocs.org/clojure.core/*e

In general people tend to use a stacktrace library like clojure.repl clojure.stacktrace, clj-stacktrace or aviso/pretty (off the top of my head). If you dont want to have to choose among all of those simply call (clojure.repl/pst) since you dont need any extra dependencies ;)

shoxter commented 7 years ago

Thank you very much. (println *e) solved my issue.

I appreciate your help friend.