Pryme8 Posted March 12, 2016 Share Posted March 12, 2016 I really like the idea of the playground, but the one problem that I am running into that is deterring me from continuing to use it, is that when you drop and error it does not tell you where... cant covert obj from null, cool where? expecting } after blah blah, cool where?!? I know this kinda sounds like im complaining but Im not. I was wondering what would be a way for me to figure out what line needs to be looked at when working in the playground because my console reports are all sorts of overloaded with other information coming from the playground and I cant seem to efficiently pick through simple errors. Dad72 1 Quote Link to comment Share on other sites More sharing options...
Dad72 Posted March 12, 2016 Share Posted March 12, 2016 It is true that this would good be the playground tell us the line of the error in the code. Quote Link to comment Share on other sites More sharing options...
Pryme8 Posted March 12, 2016 Author Share Posted March 12, 2016 var showError = function (errorMessage) { var errorContent = '<div class="alert alert-error"><button type="button" class="close" data-dismiss="alert">×</button><h4>Compilation error</h4>' + errorMessage + '</div>'; document.getElementById("errorZone").innerHTML = errorContent; } If I can get a console.log(errorMessage) I can take a look at that Object and see if that information is stored anywhere... looks like it might be a quick fix! **EDIT** Yup I reviewed the error process, and want to fix it... I made an intentional error called peculiarly enough "error" as an undefined variable in a try catch loop so I can confirm that the error object was in standard format... ReferenceError: error is not defined Stack trace: createScene@http://www.babylonjs-playground.com/index.js line 207 > eval:80:3 compileAndRun@http://www.babylonjs-playground.com/index.js:208:25 checkHash/xmlHttp.onreadystatechange@http://www.babylonjs-playground.com/index.js:511:33 EventHandlerNonNull*checkHash@http://www.babylonjs-playground.com/index.js:503:21 @http://www.babylonjs-playground.com/index.js:536:5 @http://www.babylonjs-playground.com/index.js:1:2 is the information that is passed to me and in the object it has the exact line of the error, if this happens not to be the one we want I will come up with a simple calculation to count the number of lines on the DOM on top of the line we want and offset it so the number in the playground line matchs the error. If you guys give me the information I need to edit the playground and then submit the changes I will have a much more robust error system done for us before I go to bed. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted March 13, 2016 Share Posted March 13, 2016 Hello Pryme8:) what are you looking for exactly? I cannot OSS playground code but I can definitely update it if you provide me the fixes you want to apply Quote Link to comment Share on other sites More sharing options...
Pryme8 Posted March 13, 2016 Author Share Posted March 13, 2016 I think you addressed this in the other thread, I believe this one can be closed. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.