Re: [ClojureScript] Cannot call method 'call' of undefined

2014-11-10 Thread Daniel Kersten
You could probably find or write a script or leiningen plugin to send errors to growl or other notification system. On Mon, 10 Nov 2014 00:20 Glen Mailer wrote: > Cheers for the advice everyone. > > For some reason I had assumed warnings would appear in the js console, but > of course warnings a

Re: [ClojureScript] Cannot call method 'call' of undefined

2014-11-09 Thread Glen Mailer
Cheers for the advice everyone. For some reason I had assumed warnings would appear in the js console, but of course warnings are emitted by the cljsbuild compiler! I've been using figwheel, so hadn't really paid much attention to the watch/compile terminal after starting it. I'll have to try

Re: [ClojureScript] Cannot call method 'call' of undefined

2014-11-09 Thread David Nolen
These are excellent tips. On Sun, Nov 9, 2014 at 4:46 PM, Asim Jalis wrote: > Hi Glenn, > > I ran into that problem several times. Initially I just gave up. In a second > iteration I tried to debug the problem by reducing program to get a minimal > repro of the issue. This proved to be a great le

Re: [ClojureScript] Cannot call method 'call' of undefined

2014-11-09 Thread Asim Jalis
Hi Glenn, I ran into that problem several times. Initially I just gave up. In a second iteration I tried to debug the problem by reducing program to get a minimal repro of the issue. This proved to be a great learning experience. Here are the issues I discovered: 1. A big source of problems was t

Re: [ClojureScript] Cannot call method 'call' of undefined

2014-11-09 Thread Daniel Kersten
This is true - with source maps most occurrences are easy to track down. On Sun, 9 Nov 2014 19:27 David Nolen wrote: > The compiler accurately warns in the case of non-higher order usage. > For the other cases - the JS debugger is your friend. With source maps > enabled and triggering JS debugge

Re: [ClojureScript] Cannot call method 'call' of undefined

2014-11-09 Thread David Nolen
The compiler accurately warns in the case of non-higher order usage. For the other cases - the JS debugger is your friend. With source maps enabled and triggering JS debugger break points on uncaught exceptions, finding out the source of a bad function invocation shouldn't take you more than a few

Re: [ClojureScript] Cannot call method 'call' of undefined

2014-11-09 Thread Daniel Kersten
I've found this troublesome too when starting out. The compiler does catch the obvious cases but there's still many that slip through. I found that I'm more careful now and overall don't find it too troublesome anymore. I guess you just get used to it. It would be nice if the compiler could warn yo

[ClojureScript] Cannot call method 'call' of undefined

2014-11-09 Thread Glen Mailer
Hi Everyone, I'm new to ClojureScript, but I've been doing Clojure for a while, and this was something that's been catching me out a lot. In Clojure, attempts to use an undefined var result in a compiler error, whereas in CLJS they are left to fail at runtime. Presumably this is to play nicely