0

My Cordova app has been output console.log just fine in Console of Xcode. Then suddenly one day (not sure what happened), it just shows blank. I followed the instructions here but nothing works Xcode 4 - Debug Area no longer shows my console output (NSLog)

Here are what I have:

enter image description here

This always shows but BLANK:

enter image description here

enter image description here

enter image description here

UPDATE 1

I tried an old codebase and no console log either. So this looks like Xcode configuration specific. Something messed up randomly and automatically.

Community
  • 1
  • 1
HP.
  • 19,226
  • 53
  • 154
  • 253
  • I recently read that it is possible to use Safari's devtools to connect to/debug a remote device based on its webview over usb as well (much the same as you can with chrome/android) - I don't mention it as a possible solution so much as a possible additional diagnostic. – barry-johnson Mar 21 '15 at 04:22
  • I am using Cordova plugin so I am not sure if Safari can output that especially it must have access the device feature as an app (not a website) – HP. Mar 21 '15 at 04:29
  • Would seem reasonable re: the plugin output. I just looked again. It is in the early access version of [this book](http://www.manning.com/camden/) , which I would encourage you to consider buying. But it says that if you enable web inspector in Settings>Safari>Advanced, even hybrid app webviers will show up in your connected safari devtools. I have not tested it, so I cannot confirm, but the author is no hack. – barry-johnson Mar 21 '15 at 05:12
  • I just tested it and it works. But my intention is to look in Xcode console (just for the convenience). I would not prefer to open Safari and go thru the menu. – HP. Mar 22 '15 at 08:08

1 Answers1

0

I found out the deployment to device AND start may take up to a minute. If you open the app manually right after it deployed, it is a different instance and no debug available in Xcode. You have to wait for Xcode to run the app itself to show console info.

HP.
  • 19,226
  • 53
  • 154
  • 253