[Seaside] How can I debug ajax errors?
Johan Brichau
johan at inceptive.be
Sat Feb 11 08:18:15 UTC 2017
Hey Mariano,
There’s a syntax error somewhere.
Ok… that’s a lousy response, I know :)
Can you fetch the generated JS from the url and send that in a text file?
Just to be sure: is this happening with the result of a jQuery script callback?
It would be good to know what Seaside-JS code that is executing to generate the script you are sending.
Johan
>
> I am now printint to console the requestResponse that was in this ajax error handler, and this is what I get:
>
> Object
> data
> :
> undefined
> error
> :
> SyntaxError: Unexpected token , at eval (<anonymous>) at https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616> at Function.globalEval (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627>) at n.fn.init.domManip (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:22515 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:22515>) at n.fn.init.replaceWith (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:21650 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:21650>) at eval (eval at <anonymous> (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616>), <anonymous>:1:13) at eval (<anonymous>) at https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616> at Function.globalEval (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627>) at text script (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:4:26788 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:4:26788>)
> message
> :
> "Unexpected token ,"
> stack
> :
> "SyntaxError: Unexpected token ,↵ at eval (<anonymous>)↵ at https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616>↵ at Function.globalEval (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627)↵ <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627)%E2%86%B5> at n.fn.init.domManip (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:22515)↵ <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:22515)%E2%86%B5> at n.fn.init.replaceWith (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:21650)↵ <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:21650)%E2%86%B5> at eval (eval at <anonymous> (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616>), <anonymous>:1:13)↵ at eval (<anonymous>)↵ at https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616>↵ at Function.globalEval (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627)↵ <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627)%E2%86%B5> at text script (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:4:26788 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:4:26788>)"
> __proto__
> :
> Error
> httpStatus
> :
> 200
> method
> :
> "GET"
> url
> :
> "/reps?_s=YZ0L_G1AYPiERSfd&_k=-szkZv0x3mvWhG7t&193&203=VALE&206=1&207=&216=&221=&_=1486757530835"
> __proto__
> :
> Object
>
>
>
> SyntaxError: Unexpected token ,
> at eval (<anonymous>)
> at https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616>
> at Function.globalEval (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627>)
> at n.fn.init.domManip (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:22515 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:22515>)
> at n.fn.init.replaceWith (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:21650 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:3:21650>)
> at eval (eval at <anonymous> (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616>), <anonymous>:1:13)
> at eval (<anonymous>)
> at https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2616>
> at Function.globalEval (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:2:2627>)
> at text script (https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:4:26788 <https://debrisdemo.quuve.com/JQDeploymentLibrary/jQuery.js:4:26788>)
>
>
> I don't understand what is going on. Any ideas?
>
> Thanks in advance
>
>
> Chrome shows me that with a red underline like if that would have an error, but such JS is correct.
>
> Any idea how can I know what is going on?
>
>
> --
> Mariano
> http://marianopeck.wordpress.com <http://marianopeck.wordpress.com/>
>
>
>
> --
> Mariano
> http://marianopeck.wordpress.com <http://marianopeck.wordpress.com/>
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org <mailto:seaside at lists.squeakfoundation.org>
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside <http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/seaside/attachments/20170211/c7cab51f/attachment-0001.html>
More information about the seaside
mailing list