Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 358480 - Logging statements crash IE and Firefox
Summary: Logging statements crash IE and Firefox
Status: RESOLVED FIXED
Alias: None
Product: RAP
Classification: RT
Component: RWT (show other bugs)
Version: 1.5   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: 1.5 M2   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-21 15:26 EDT by Austin Riddle CLA
Modified: 2011-09-22 04:32 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Austin Riddle CLA 2011-09-21 15:26:25 EDT
While upgrading the JIT visualizations in the incubator, I discovered that they crash in IE and Firefox.
This is because of the this.info() calls made throughout the custom widget code. The browser complains of a bad reference to console.
The statements work in Chrome.

Tim, what are custom widgets supposed to do about logging now?
Comment 1 Ralf Sternberg CLA 2011-09-22 04:26:36 EDT
Fixed in Object.js#debug(). We mistakenly checked for a global variable with if( console ) instead of if( window.console ).
Changes are in HEAD.
Comment 2 Ralf Sternberg CLA 2011-09-22 04:32:12 EDT
(In reply to comment #0)
> Tim, what are custom widgets supposed to do about logging now?

We removed the client logging entirely and only left a very small implementation of the info(), warning(), etc. methods in place. The RAP client doesn't use any of them anymore. We consider logging on the client useless. For debugging purposes, you can use the console API, that is now supported by almost any browser's dev tools. For production, a widget should IMHO either work or fail fast.