Debugger Values in iOS?

Hey all,

How does one debug stuff in iOS? How can you look up properties of controls, etc? There seems to be no way to do this.

Pause the debugger, then you don’t see the variables?
Perhaps you have the wrong thread selected?

Nope. I see nothing. And there’s only the main thread. This is a simple test app.

In what context is it? Is it paused or is it paused-on-breakpoint?

Either. It doesn’t matter.

If I put a break point in a custom control prior to everything launching, I can see the items inside that control fine. But even then I can only see just that item. Yes, the view object is always available, but clicking on that shows nothing other than stats about that. No controls, etc. There’s nothing in the Application or Runtime objects other than the View which again has nothing useful in it.

That’s something i havn’t seen before. You compile 64-bit ? maybe clearing the cache helps (i’m just one that haven’t seen this before). i can’t think of anything else that may have something to do with the debugger being odd.

Which version of Xcode do you use? And which macOS version do you use?

[quote=474282:@Derk Jochems]That’s something i havn’t seen before. You compile 64-bit ? maybe clearing the cache helps (i’m just one that haven’t seen this before). i can’t think of anything else that may have something to do with the debugger being odd.

Which version of Xcode do you use? And which macOS version do you use?[/quote]

You can’t compile in anything but 64 bit for iOS
OS 10.13.4
Xcode 9.4.1

Yes there’s limited variables shown in the debugger for iOS projects. I find myself writing a lot more System.Debuglog entries for iOS than desktop.

It’s not “limited.” It’s nothing.

Oh OK. I see local variables, just no control properties.

Right. How the heck do you debug then? Is anyone really seriously using Xojo to create iOS apps?

Jeremy most definitely is
He has some 650K users afaict
https://blog.xojo.com/2019/11/08/migrating-a-huge-mysql-database-with-minimal-downtime/

Then he must be one awesome programmer. Because if there’s no way to debug and go looking at the values of different objects, etc. It’s next to impossible to see what’s going on.

I manage to cope, as I said by using System.Debuglog sometimes. But I mostly need to see local variables, which the debugger shows me. My app is B2B so not as popular as Jérémie’s :slight_smile: but it still gets more than 35,000 sessions per week. Definitely a serious app.

The easiest way to debug on iOS is to place a breakpoint close to the object / control you want to debug.
You can also use system.debuglog as Jason suggested.

Pausing the debugger out of nowhere usually doesn’t display a thing in the debugger.