apa512 / clj-rethinkdb

Eclipse Public License 1.0
204 stars 42 forks source link

NullPointerException when upgrading to 2.3.3? #167

Closed arichiardi closed 8 years ago

arichiardi commented 8 years ago

Hello rethinkdb team, I have recently tried to switch from 2.3.2 to 2.3.3, but I receive a big bang as follows:

21:07:33.302 [async-dispatch-20] ERROR acu.system - Uncaught exception on async-dispatch-20
java.lang.NullPointerException
    at clojure.core$name.invokeStatic(core.clj:1546) ~[clojure-1.8.0.jar:?]
    at clojure.core$name.invoke(core.clj:1540) ~[clojure-1.8.0.jar:?]
    at rethinkdb.types$tt__GT_int.invokeStatic(types.cljc:236) ~[?:?]
    at rethinkdb.types$tt__GT_int.invoke(types.cljc:233) ~[?:?]
    at rethinkdb.query_builder$parse_term.invokeStatic(query_builder.cljc:62) ~[?:?]
    at rethinkdb.query_builder$parse_term.invoke(query_builder.cljc:59) ~[?:?]
    at rethinkdb.query_builder$parse_query.invokeStatic(query_builder.cljc:75) ~[?:?]
    at rethinkdb.query_builder$parse_query.invoke(query_builder.cljc:71) ~[?:?]
    at rethinkdb.net$setup_producer$fn__41638$state_machine__34555__auto____41639$fn__41641.invoke(net.clj:157) ~[?:?]
    at rethinkdb.net$setup_producer$fn__41638$state_machine__34555__auto____41639.invoke(net.clj:157) ~[?:?]
    at clojure.core.async.impl.ioc_macros$run_state_machine.invokeStatic(ioc_macros.clj:1011) ~[?:?]
    at clojure.core.async.impl.ioc_macros$run_state_machine.invoke(ioc_macros.clj:1010) ~[?:?]
    at clojure.core.async.impl.ioc_macros$run_state_machine_wrapped.invokeStatic(ioc_macros.clj:1015) ~[?:?]
    at clojure.core.async.impl.ioc_macros$run_state_machine_wrapped.invoke(ioc_macros.clj:1013) ~[?:?]
    at clojure.core.async.impl.ioc_macros$take_BANG_$fn__34571.invoke(ioc_macros.clj:1024) ~[?:?]
    at clojure.core.async.impl.channels.ManyToManyChannel$fn__30145.invoke(channels.clj:135) ~[?:?]
    at clojure.lang.AFn.run(AFn.java:22) ~[clojure-1.8.0.jar:?]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) ~[?:1.8.0_91]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) ~[?:1.8.0_91]
    at java.lang.Thread.run(Thread.java:745) [?:1.8.0_91]

I will try to have a look but it is weird that it does not even show which query is failing...

arichiardi commented 8 years ago

False alarm, the bug was in my code but not seeing the source of it (aaaaah good old Clojure error messages) I thought it came from the library. Sorry for the noise!

danielcompton commented 8 years ago

What was the cause of the error? We might be able to do some better error checking closer to the call site, rather than it blowing up in the internals.

lenaschoenburg commented 8 years ago

Better stacktraces would be very useful. With the current stack traces it's absolutely impossible to track down which query failed without resorting to println debugging.

arichiardi commented 8 years ago

I agree! the error was in a run body.. If run is a macro then yes there is enough info to display..