Titanium JIRA Archive
Appcelerator Community (AC)

[AC-2017] Multiline Ti.API.info() call logs first line with INFO and subsequent with DEBUG

GitHub Issuen/a
TypeBug
Priorityn/a
StatusClosed
ResolutionCannot Reproduce
Resolution Date2013-04-08T18:27:19.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
Labelsn/a
ReporterThierry Godfroid
AssigneeMauro Parra-Miranda
Created2013-01-02T10:01:08.000+0000
Updated2016-03-08T07:40:58.000+0000

Description

This code:
var win = Ti.UI.createWindow({
	backgroundColor : "#FFF"
});

var obj = {
	a : 1,
	b : 2
};
Ti.API.info("Got:", obj);

win.open();
when run with titanium build --platform=ios -T simulator -Y iphone results in
 
[INFO] Got: {
whereas run with titanium build --platform=ios -T simulator -Y iphone --log-level=debug it returns
[INFO] Got: {
[DEBUG]     a = 1;
[DEBUG]     b = 2;
[DEBUG] } 
It looks wrong to me: all lines should be in log level INFO The same holds true in TiStudio. This makes logging object painful (and I don't want to run everything in debug mode).

Comments

  1. Nikhil Sharma 2013-01-29

    What version of Titanium Studio are you using?
  2. Thierry Godfroid 2013-01-29

    As I said in the entry this shows with the CLI (see version above). That being said, it also show in Studio and version was 3.0.1. But I am mainly using CLI and it's bothersome. Thanks.
  3. Daniel Sefton 2013-04-08

    Cannot reproduce with: - Ti Studio 3.0.2.201302191606 - Ti SDK 3.1 CI - CLI 3.0.24 *titanium build --platform=ios -T simulator -Y iphone*
       [INFO]  Got: {
       [INFO]      a = 1;
       [INFO]      b = 2;
       [INFO]  }
       
    *titanium build --platform=ios -T simulator -Y iphone --log-level=debug*
       [INFO]  Got: {
       [INFO]      a = 1;
       [INFO]      b = 2;
       [INFO]  }
       
  4. Thierry Godfroid 2013-04-08

    Confirmed. I didn't upgrade to 3.0.2 because not really needed but I just did and it does solve the issue. Only tested in CLI. Thanks
  5. Mauro Parra-Miranda 2013-11-25

    Closed because of Thierry's last comment :D

JSON Source