|
View:
New views
8 Messages
—
Rating Filter:
Alert me
|
|
|
Post build runtime errorAll, I pretty much have my custom build working. I have inlined templates within my widgets and in CSS style sheets as well. I can also see that there are no 404 errors when loading my page. That part is awesome! There is an issue at runtime I get in a couple of my pages, and it seems to be happening when I pass my mouse over the tabs in tab panels, or in the accordion pane tabs as well. The runtime error reads something like: A runtime error has occured... Line <a really big number> ... Error: 'undefined' is null or not an object. The location if I choose to debug is from an anonymous source so I can't see much in the debugger, but this is a notification
from the DOM which I take to be a mouseover event. I have to be missing something from my build, but there is nothing requested from the server that is not found, and no complaints in the firebug console. My custom layer contains some dijits and dojo code. I include right now the built dojo.js.uncompressed.js and my custom.js.uncompressed.js, in that order, in my page. Maybe I put this together wrong. I've seen a few examples where dijit.css is ignored in the cssImport, and other examples where one layer in the profile is told to depend on another layer. I can add more information, but does anyone have an idea of how to tackle this? Thanks, Scott
_______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest |
|
|
Re: Post build runtime errorOn Thu, Nov 5, 2009 at 4:56 AM, Scott <jackett_dad@...> wrote:
> There is an issue at runtime I get in a couple of my pages, and it seems to > be happening when I pass my mouse over the tabs in tab panels, or in > the accordion pane tabs as well. The runtime error reads something like: A > runtime error has occured... Line <a really big number> ... Error: > 'undefined' is null or not an object. > The location if I choose to debug is from an anonymous source so I can't see > much in the debugger, but this is a notification from the DOM which I take > to be a mouseover event. Are you using Firebug with "break on all errors" turned on? I notice that sometimes firebug will stop on errors that are in a try/catch block, but they are in the try/catch for a reason in that they could be expected to fail. I have noticed this in particular with one of the mouse event things. James _______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest |
|
|
Re: Post build runtime errorJames, It turns out that my issue was not build related, although I've yet to see if the build is completely working yet. How do you turn that option on in Firebug? I don't have options available to me. But, I think Firebug may have given me an important clue to the issue that is haunting me (today). The error reads: [Exception... "'Error: already called!' when calling method: [nsIDOMEventListener::handleEvent]" nsresult: "0x8057001c (NS_ERROR_XPC_JS_THREW_JS_OBJECT)" location: "<unknown>" data: no] Line 3459 Normally I am running this app in IE, so I switched to Firefox and Firebug to see what it would tell me. This information is a wee bit more helpful. If I click through to that line in dojo.js.uncompressed.js, I see this block of code: if(!dojo.isIE && (name == "mouseenter" || name == "mouseleave")){ 3451 var ofp = fp; 3452 //oname = name; 3453
name = (name == "mouseenter") ? "mouseover" : "mouseout"; 3454 fp = function(e){ 3455 // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV of INPUT) 3456 // which causes isDecendant to return false which causes 3457 // spurious, and more importantly, incorrect mouse events to fire. 3458 // TODO: remove tagName check when Firefox 2 is no longer supported 3459 try{ e.relatedTarget.tagName; } catch(e2){ return; } 3460 if(!dojo.isDescendant(e.relatedTarget, node)){ 3461 // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally immutable. 3462 return ofp.call(this, e); 3463 } 3464 } 3465 } In bold is the line number referred to. As I had mentioned, this error occurs during a mouse event, and this seems to have trapped it because of using Firefox. I'm don't understand what is being said in the comments, but it appears that I'm getting mouse events I shouldn't be getting. Does anyone have some insight into this? Thanks, Scott From: James Burke <jburke@...> To: dojo-interest@... Sent: Thu, November 5, 2009 1:19:59 PM Subject: Re: [Dojo-interest] Post build runtime error On Thu, Nov 5, 2009 at 4:56 AM, Scott <jackett_dad@...> wrote: > There is an issue at runtime I get in a couple of my pages, and it seems to > be happening when I pass my mouse over the tabs in tab panels, or in > the accordion pane tabs as well. The runtime error reads something like: A > runtime error has occured... Line <a really big number> ... Error: > 'undefined' is null or not an object. > The location if I choose to debug is from an anonymous source so I can't see > much in the debugger, but this is a notification from the DOM which I take > to be a mouseover event. Are you using Firebug with "break on all errors" turned on? I notice that sometimes firebug will stop on errors that are in a try/catch block, but they are in the try/catch for a reason in that they could be expected to fail. I have noticed this in particular with one of the mouse event things. James _______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest _______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest |
|
|
Re: Post build runtime errorOn Fri, Nov 6, 2009 at 8:24 AM, Scott <jackett_dad@...> wrote:
> James, > It turns out that my issue was not build related, although I've yet to see > if the build is completely working yet. > How do you turn that option on in Firebug? I don't have options available > to me. But, I think Firebug may have given me an important clue to the I am using Firebug 1.4.5. In the Script tab, there is a little down-facing arrow in the tab title, next to "Script". Be sure that only Enabled is checked. > issue that is haunting me (today). The error reads: > [Exception... "'Error: already called!' when calling method: > [nsIDOMEventListener::handleEvent]" nsresult: "0x8057001c > (NS_ERROR_XPC_JS_THREW_JS_OBJECT)" location: "<unknown>" data: no] > http://localhost:8080/MyServer/dojo/dojo/dojo.js.uncompressed.js > Line 3459 This message is about someone trying to call a dojo.Deferred's callback() or errback() after one of those methods have already been called. If you are using dojo.Deferreds in your own code and manually call .callback() or errback() then you probably want to put breakpoints at those code lines to see the cause. If you are not using dojo.Deferreds directly, dojo uses them in a few modules, so it is hard to diagnose without a test case. > Normally I am running this app in IE, so I switched to Firefox and Firebug > to see what it would tell me. This information is a wee bit more helpful. > If I click through to that line in dojo.js.uncompressed.js, I see this > block of code: > if(!dojo.isIE && (name == "mouseenter" || name == "mouseleave")){ > 3451 var ofp = fp; > 3452 //oname = name; > 3453 name = (name == "mouseenter") ? "mouseover" : "mouseout"; > 3454 fp = function(e){ > 3455 // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV > of INPUT) > 3456 // which causes isDecendant to return false which causes > 3457 // spurious, and more importantly, incorrect mouse events to fire. > 3458 // TODO: remove tagName check when Firefox 2 is no longer supported > 3459 try{ e.relatedTarget.tagName; } catch(e2){ return; } > 3460 if(!dojo.isDescendant(e.relatedTarget, node)){ > 3461 // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally > immutable. > 3462 return ofp.call(this, e); > 3463 } > 3464 } > 3465 } > In bold is the line number referred to. As I had mentioned, this error > occurs during a mouse event, and this seems to have trapped it because of > using Firefox. I'm don't understand what is being said in the comments, but > it appears that I'm getting mouse events I shouldn't be getting. > Does anyone have some insight into this? Are yo using Firefox 2? I believe if you set the Firebug script panel settings to as I described above, you will not see this error any more. James _______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest |
|
|
Re: Post build runtime errorJames, First, thanks for all your help so far. I fixed some of the errors I was encountering in my app and retried my build, but I am getting problems as before, so I'm not as far forward as I thought. I upgraded to the latest Firefox and Firebug and am getting a clue as to what is going on. I am not calling deferreds directly. This has to do with ContentPanes loading from a URL. At my company it's a famous issue, and one that has eluded me since we upgraded to 1.2.2. Most likely the issue centers around the fact that we have entire sets of tab panels that are conditionally visible as we navigate a tree to the left. There
is an accordian pane as well that can alter the state of the main portion of the page. Sometimes these deferreds get called and attempt to access an invisible or no longer existent widget and the error occurs. I need to get to the bottom of this. But in this instance, I think the deferred is getting called after a parsing error occurs. Here it is: Error parsing in _ContentSetter#Setter_DIV_1 TypeError: parent is undefined message=parent is undefined How can I find out what it is exactly that is
undefined? And keep in mind, this only happens in my build version. Other parts of the application work, but this for some reason fails. I just need to find a way to track it down. Scott From: James Burke <jburke@...> To: dojo-interest@... Sent: Fri, November 6, 2009 1:34:44 PM Subject: Re: [Dojo-interest] Post build runtime error On Fri, Nov 6, 2009 at 8:24 AM, Scott <jackett_dad@...> wrote: > James, > It turns out that my issue was not build related, although I've yet to see > if the build is completely working yet. > How do you turn that option on in Firebug? I don't have options available > to me. But, I think Firebug may have given me an important clue to the I am using Firebug 1.4.5. In the Script tab, there is a little down-facing arrow in the tab title, next to "Script". Be sure that only Enabled is checked. > issue that is haunting me (today). The error reads: > [Exception... "'Error: already called!' when calling method: > [nsIDOMEventListener::handleEvent]" nsresult: "0x8057001c > (NS_ERROR_XPC_JS_THREW_JS_OBJECT)" location: "<unknown>" data: no] > http://localhost:8080/MyServer/dojo/dojo/dojo.js.uncompressed.js > Line 3459 This message is about someone trying to call a dojo.Deferred's callback() or errback() after one of those methods have already been called. If you are using dojo.Deferreds in your own code and manually call .callback() or errback() then you probably want to put breakpoints at those code lines to see the cause. If you are not using dojo.Deferreds directly, dojo uses them in a few modules, so it is hard to diagnose without a test case. > Normally I am running this app in IE, so I switched to Firefox and Firebug > to see what it would tell me. This information is a wee bit more helpful. > If I click through to that line in dojo.js.uncompressed.js, I see this > block of code: > if(!dojo.isIE && (name == "mouseenter" || name == "mouseleave")){ > 3451 var ofp = fp; > 3452 //oname = name; > 3453 name = (name == "mouseenter") ? "mouseover" : "mouseout"; > 3454 fp = function(e){ > 3455 // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV > of INPUT) > 3456 // which causes isDecendant to return false which causes > 3457 // spurious, and more importantly, incorrect mouse events to fire. > 3458 // TODO: remove tagName check when Firefox 2 is no longer supported > 3459 try{ e.relatedTarget.tagName; } catch(e2){ return; } > 3460 if(!dojo.isDescendant(e.relatedTarget, node)){ > 3461 // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally > immutable. > 3462 return ofp.call(this, e); > 3463 } > 3464 } > 3465 } > In bold is the line number referred to. As I had mentioned, this error > occurs during a mouse event, and this seems to have trapped it because of > using Firefox. I'm don't understand what is being said in the comments, but > it appears that I'm getting mouse events I shouldn't be getting. > Does anyone have some insight into this? Are yo using Firefox 2? I believe if you set the Firebug script panel settings to as I described above, you will not see this error any more. James _______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest _______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest |
|
|
Re: Post build runtime errorI am not a heavy user of ContentPane, someone more familiar with it
might be able to give some better information. I would probably just try using the debugger in IE8 (if an IE error) or Firebug to try to put breakpoints around the error area and trace back from there. Sorry I don't have anything else more helpful to offer. James On Fri, Nov 6, 2009 at 3:06 PM, Scott <jackett_dad@...> wrote: > I am not calling deferreds directly. This has to do with ContentPanes > loading from a URL. At my company it's a famous issue, and one that has > eluded me since we upgraded to 1.2.2. > Most likely the issue centers around the fact that we have entire sets of > tab panels that are conditionally visible as we navigate a tree to the left. > There is an accordian pane as well that can alter the state of the main > portion of the page. Sometimes these deferreds get called and attempt to > access an invisible or no longer existent widget and the error occurs. > I need to get to the bottom of this. > But in this instance, I think the deferred is getting called after a parsing > error occurs. > Here it is: > Error parsing in _ContentSetter#Setter_DIV_1 TypeError: parent is undefined > message=parent is undefined > How can I find out what it is exactly that is undefined? > And keep in mind, this only happens in my build version. Other parts of the > application work, but this for some reason fails. I just need to find a way > to track it down. > Scott FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest |
|
|
Re: Post build runtime errorJames, I discovered the source of all my errors. Once I've got my build completely worked out I am going to post my ant script that does the work for me, and what I've done within my JSP pages to interact with the build in dev and release modes. The biggest issue that was causing me trouble was in my JSP pages that were being loaded as pages in a TabContainer or a Dialog (both using the dojox ContentPane with an href attribute to load). Within the ContentPane code it says in the comments that you should not do dojo.requires in the page, that some widgets need to be imported already to function correctly in the page load. Well... I was doing just that, and I created a test case to
prove that was the case. Since the page was a separate entity, I thought it needed to fully initialize dojo. Turns out that wasn't the case. Dojo was resident and ready to use without all that, and I didn't need to do anything as long as the appropriate dojo.requires were called beforehand--and I wasn't reloading dojo.js. Big discovery, huge blunder on my part for the longest time. The build is looking good, but my pages are currently missing some styles. I think I can deal with that one. I'll post later since my build process is comprehensive in pruning what I don't need. Thanks for all the replies. Scott From: James Burke <jburke@...> To: dojo-interest@... Sent: Sat, November 7, 2009 7:02:03 PM Subject: Re: [Dojo-interest] Post build runtime error I am not a heavy user of ContentPane, someone more familiar with it might be able to give some better information. I would probably just try using the debugger in IE8 (if an IE error) or Firebug to try to put breakpoints around the error area and trace back from there. Sorry I don't have anything else more helpful to offer. James On Fri, Nov 6, 2009 at 3:06 PM, Scott <jackett_dad@...> wrote: > I am not calling deferreds directly. This has to do with ContentPanes > loading from a URL. At my company it's a famous issue, and one that has > eluded me since we upgraded to 1.2.2. > Most likely the issue centers around the fact that we have entire sets of > tab panels that are conditionally visible as we navigate a tree to the left. > There is an accordian pane as well that can alter the state of the main > portion of the page. Sometimes these deferreds get called and attempt to > access an invisible or no longer existent widget and the error occurs. > I need to get to the bottom of this. > But in this instance, I think the deferred is getting called after a parsing > error occurs. > Here it is: > Error parsing in _ContentSetter#Setter_DIV_1 TypeError: parent is undefined > message=parent is undefined > How can I find out what it is exactly that is undefined? > And keep in mind, this only happens in my build version. Other parts of the > application work, but this for some reason fails. I just need to find a way > to track it down. > Scott FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest _______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest |
|
|
Re: Post build runtime errorthe dojox.layout.ContentPane can also handle scripts (including dojo.requires) and css links/styles I believe. Dustin Machi
_______________________________________________ FAQ: http://dojotoolkit.org/support/faq Book: http://docs.dojocampus.org Dojo-interest@... http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest |
| Free embeddable forum powered by Nabble | Forum Help |