Closed Bug 1081767 Opened 11 years ago Closed 11 years ago

JavaScript error: chrome://messenger/content/nsContextMenu.js, line 693: TypeError: item is null

Categories

(Thunderbird :: Message Reader UI, defect)

x86_64
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: ishikawa, Unassigned)

References

Details

During |make mozmill| test of locally built DEBUG BUILD of C-C TB I see JavaScript error: chrome://messenger/content/nsContextMenu.js, line 693: TypeError: item is null ( I see a similar error once more in a different place of the log but it repors a different line #: 694 ??? off by one???) mailContextMenus.js is This one for TB: comm-central/mail/base/content/mailContextMenus.js : comm-central/suite/mailnews/mailContextMenus.js Funny, though, line 693 is at the end of the file (!) Actually, the file has only 619 lines.??? TIA
Sorry I was looking at a wrong file. nsContextMenus.js vs mailContextMenus.js: Correct file nsContextMenu.js: 684 /** 685 * Set a DOM node's hidden property by passing in the node's id or the 686 * element itself. 687 * @param aItemOrId 688 * a DOM node or the id of a DOM node 689 * @param aShow 690 * true to show, false to hide 691 */ 692 showItem : function CM_showItem(aItemOrId, aShow) { 693 var item = aItemOrId.constructor == String ? document.getElementById(aItemOrId) : aItemOrId; 694 item.hidden = !aShow; 695 }, So item becomes null on 693.
See Also: → 1081763
Which test causes this message? I think you could put a "debugger;" statement (https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/debugger) into the showItem function so see what is the caller of the function.
(In reply to :aceman from comment #2) > Which test causes this message? > I think you could put a "debugger;" statement > (https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/ > Statements/debugger) into the showItem function so see what is the caller of > the function. Thank you for the suggestion for "debugger;" statement. This is an important addition to my arsenal to fight the bugs :-) Anyway, for like a week or so after the refresh of the source tree, the bug has disappeared. When it appeared in the middle of October, [my log showed 13 October], it appeared in the following tests and I show lines immediately preceding and following the mentioned errors: TEST-START | /REF-COMM-CENTRAL/comm-central/mail/test/mozmill/message-header/test-message-header.js | test_msg_id_context_menu ... JavaScript strict warning: chrome://messenger/content/nsContextMenu.js, line 103: ReferenceError: reference to undefined property this.onEditableArea JavaScript error: chrome://messenger/content/nsContextMenu.js, line 693: TypeError: item is null JavaScript strict warning: resource://gre/modules/FormHistory.jsm, line 639: ReferenceError: reference to undefined property change.guid [7319] WARNING: 1 sort operation has occurred for the SQL statement '0x7f6fc4046c40'. See https://developer.mozilla.org/En/Storage/Warnings details.: file /REF-COMM-CENTRAL/comm-central/mozilla/storage/src/mozStoragePrivateHelpers.cpp, line 114 TEST-START | /REF-COMM-CENTRAL/comm-central/mail/test/mozmill/message-window/test-commands.js | test_copy_eml_message Step Pass: {"function": "Controller.keypress()"} ... JavaScript strict warning: chrome://messenger/content/nsContextMenu.js, line 103: ReferenceError: reference to undefined property this.onEditableArea JavaScript error: chrome://messenger/content/nsContextMenu.js, line 694: TypeError: item is null Step Pass: {"function": "controller.rightClick()"} Step Pass: {"function": "controller.click()"} Step Pass: {"function": "controller.click()"} GetDiskSpaceAvailable returned: 2476208128 bytes Step Pass: {"function": "controller.click()"} Step Pass: {"function": "Controller.keypress()"} Step Pass: {"function": "Controller.keypress()"} You see both of the errors are preceded by JavaScript's ReferenceError: reference to undefined property this.onEditableArea; If I am not mistaken this bug with onEditableArea has been fixed. I suspect that "item is null" was triggered by the error. Since I don't see it anymore in the tree for the last week or so, I am closing it. Thank you for your advice about "debug;" statement. I may want to use this for debugging the issue https://bugzilla.mozilla.org/show_bug.cgi?id=936007 JavaScript strict warning: chrome://global/content/bindings/tree.xml, line 50: reference to undefined property this.treeBoxObject.columns which got me stumped.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → WONTFIX
Resolution: WONTFIX → WORKSFORME
You need to log in before you can comment on or make changes to this bug.