This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 239058 - console log messages that use argument substitution do not return proper value in Output Browser log window
Summary: console log messages that use argument substitution do not return proper valu...
Status: NEW
Alias: None
Product: javascript
Classification: Unclassified
Component: Debugger (show other bugs)
Version: 7.4
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: Martin Entlicher
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-02 23:58 UTC by peppertech
Modified: 2015-07-01 12:47 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description peppertech 2013-12-02 23:58:13 UTC
Product Version = NetBeans IDE Dev (Build web-main-72-on-20131124)
Operating System = Windows 7 version 6.1 running on amd64
Java; VM; Vendor = 1.7.0_17
Runtime = Java HotSpot(TM) 64-Bit Server VM 23.7-b01


If I use a console.log() call that uses argument substitution, it will show up fine in all of the browser dev tools, including CDT, but it will not resolve properly in the Browser log output window.

Use the JET logger API (which just wraps console API) Code such as:
var yLog = oj.Logger;
myLog.error("My log level is %d and the string is %s", myLog.option("level"), 'Something interesting');

Returns this in the IDE log window.
My log level is %d and the string is %s (12:38:24:344 | error)

In Chrome CDT it returns
My log level is 4 and the string is Something interesting
Comment 1 Vladimir Riha 2013-12-03 08:55:02 UTC
Reproducible for both parameters and multiple strings:

window.console.log("Error: %s (%i)", "Server is  not responding",500);
window.console.log("A", "B");


Product Version: NetBeans IDE Dev (Build 201312030002)