atom feed1 message in com.googlegroups.prototype-coreRe: [Prototype-core] Javascript error...
FromSent OnAttachments
Samuel LebeauAug 25, 2009 8:49 pm 
Subject:Re: [Prototype-core] Javascript errors in Ajax callbacks are not being reported to console.
From:Samuel Lebeau ("
Date:Aug 25, 2009 8:49:47 pm

Hi Luisgo,

From what I remember you're absolutely right and this could be quite annoying when debugging an application. Ajax API provides a `onException` callback/responder but exception is silently ignored when none is provided. [1]

I guess a less-surprising behavior would be to re-throw exception in that case, but unfortunately current `Ajax.Responders` implementation doesn't allow to know if there is such a registered responder. Furthermore, testing this behavior will only be possible on platforms that allow catching exceptions globally (`window.onerror`...).

Sounds like it definitely needs discussion...

BTW, It looks like, due to this try/catch statement, exception thrown within an `onException` callback will be silently ignored too... [2] Can someone confirm this?

[1] [2]

Best, Samuel.

On 18 juin 09, at 23:48, Luisgo wrote:

I realize this may not be a prototype-specific problem but I only use prototype and have not seen this anywhere else.

Whenever something breaks inside an ajax callback, errors die silently without reporting at all. I thought the problem could be in firebug but errors are not being reported to the firefox error console either.

Is this something in prototype or am I completely off?

Sorry if this is not the appropriate place to ask.