Re: ANN: Prone - better exception reporting middleware for Ring

2014-12-08 Thread Baishampayan Ghose
This is brilliant! Thanks Magnar :-) ~BG On Mon, Dec 8, 2014 at 1:15 PM, Magnar Sveen wrote: > Better exception reporting middleware for Ring. Heavily inspired by > better_errors > for Rails <https://github.com/charliesome/better_errors>. > > See it to believe it: a quic

ANN: Prone - better exception reporting middleware for Ring

2014-12-07 Thread Magnar Sveen
Better exception reporting middleware for Ring. Heavily inspired by better_errors for Rails <https://github.com/charliesome/better_errors>. See it to believe it: a quick video demoing Prone <https://dl.dropboxusercontent.com/u/3378230/prone-demo.mp4>. Prone presents your stack

Re: Exception reporting

2008-11-27 Thread Timothy Pratley
Hi > -                       throw new CompilerException((String) SOURCE.get > (), (Integer) LINE.get(), e); > +                       throw new CompilerException((String) SOURCE.get > (), (Integer) LINE_AFTER.get(), e); Having dug through the code a bit more, I don't my patch suggestion is quit

Re: Exception reporting

2008-11-26 Thread Timothy Pratley
I did some more testing on this and discovered some interesting things... Executive Summary: I propose the following patch Index: src/jvm/clojure/lang/Compiler.java === --- src/jvm/clojure/lang/Compiler.java (revision 1123) +++ src

Re: Exception reporting

2008-11-25 Thread Michael Wood
Hi On Wed, Nov 26, 2008 at 6:27 AM, Chris Turner <[EMAIL PROTECTED]> wrote: > > On Nov 24, 7:38 am, "Michael Wood" <[EMAIL PROTECTED]> wrote: >> On Mon, Nov 24, 2008 at 4:45 PM, Stuart Sierra >> >> <[EMAIL PROTECTED]> wrote: >> >> > If you're running this at the REPL, in recent versions only the

Re: Exception reporting

2008-11-25 Thread Chris Turner
On Nov 24, 7:38 am, "Michael Wood" <[EMAIL PROTECTED]> wrote: > On Mon, Nov 24, 2008 at 4:45 PM, Stuart Sierra > > <[EMAIL PROTECTED]> wrote: > > > If you're running this at the REPL, in recent versions only the name > > of the exception is printed.  If you want the full backtrace, do: > > (.print

Re: Exception reporting

2008-11-24 Thread Michael Wood
On Mon, Nov 24, 2008 at 4:45 PM, Stuart Sierra <[EMAIL PROTECTED]> wrote: > > If you're running this at the REPL, in recent versions only the name > of the exception is printed. If you want the full backtrace, do: > (.printStackTrace *e) That doesn't explain why the line number is listed as 0.

Re: Exception reporting

2008-11-24 Thread Stuart Sierra
If you're running this at the REPL, in recent versions only the name of the exception is printed. If you want the full backtrace, do: (.printStackTrace *e) -Stuart Sierra On Nov 24, 2:39 am, Timothy Pratley <[EMAIL PROTECTED]> wrote: > If you put the following into a file and run it: > > (defn

Exception reporting

2008-11-23 Thread Timothy Pratley
If you put the following into a file and run it: (defn new-listener [port] (try (java.net.ServerSocket. port) (println "Listening on " port) (catch Exception e (println "Failed to listen on port " port ": " (.getMessage e) (println "Server started") (let [listen

Re: Improved exception reporting

2008-11-16 Thread Howard Lewis Ship
Another idea I had was this (and I haven't had a chance to check the source code to see if any of this is already implemented): When Clojure creates a new Java class for a function, it should find a way to hang the meta-data for the function as a static field on the function. Alternately, there

Re: Improved exception reporting

2008-11-16 Thread Stuart Sierra
On Nov 16, 8:33 am, Rich Hickey <[EMAIL PROTECTED]> wrote: > I'm certainly interested in improving the error reporting, but in this > partiicular case: > >  java.lang.ClassCastException: clojure.lang.LazyCons > > is my all-time pet-peeve exception message, and it comes from the JVM. > Why on earth

Re: Improved exception reporting

2008-11-16 Thread Rich Hickey
On Nov 14, 3:50 pm, "Stephen C. Gilardi" <[EMAIL PROTECTED]> wrote: > On Nov 14, 2008, at 3:11 PM, Howard Lewis Ship wrote: > > > The point is, an exception that said something like: > > > "Expected java.lang.Comparable but received :king" would have helped > > me unravel this much, much easier!

Re: [DISCUSS] Improved exception reporting

2008-11-14 Thread Stephen C. Gilardi
On Nov 14, 2008, at 3:11 PM, Howard Lewis Ship wrote: > The point is, an exception that said something like: > > "Expected java.lang.Comparable but received :king" would have helped > me unravel this much, much easier! I agree. Clojure should give all the information it can about the object(s)

[DISCUSS] Improved exception reporting

2008-11-14 Thread Howard Lewis Ship
cases a comparison error. The point is, an exception that said something like: "Expected java.lang.Comparable but received :king" would have helped me unravel this much, much easier! I have a lot of experience, inside Tapestry, on these kinds of issues: useful exception reporting. A sign