36

improved debugging

I'd like to see improved debugging options.  Like many people, I use Flash actions to check on progress of a complex task.  But those extra Flash actions have to be manually turned off or deleted or they clutter up the screen when the task is actually running.  And then they have to be recreated or turned back on when I need to tweak or troubleshoot the task. 

I'd love to see another Alert type (or an option on the Flash action) that displays only in debug mode, and then an option at the task/profile level to turn debugging mode on/off for that task/profile.

Ideally, I'd like this debug Flash to include helpful information automatically, such as the task name, action number, caller, %err %errmsg if set, etc.  But probably everyone would want different things included, so that might get unwieldy.

3 replies

A suggestion would be to create your own %Debug variable. It could have various values to debug a specific task or a specific group of tasks. The Flash action has a built-in IF statement.

For example, IF %Debug ~ (matches) Driving, could be used for Flash actions that are part of your driving related tasks.

P

Tasker is largely similar to desktop RPA software such as UiPath and being UiPath developer I really miss being able to debug complex tasks with breakpoints and going step by step while being able to see variable values etc. Doing that on a phone would likely be very limited, but perhaps there is a remote chance of doing that on another screen? Via Join or something. So for instance on a PC you could see something similar to current task view in Tasker when it's run, with green and red dots but in addition to that you would be able to do things mentioned earlier. Even rudimentary version of that I'm sure would be a lot of help.

Since I relied on this post, my debugging has evolved. Using FLASH is very cumbersome.

For quite a while I have used the Set Tasker Pref command to turn system logging on and off in the task.

I use the IF in the command to check a global variable to see if debugging is on. If you are set up to debug several tasks, you can set %Debug each type with a / separator, like Driving/Walking and test for the appropriate value in the command.

This is not as great as a real debug tool. But it is way better than FLASH, since you don't have to watch the screen.

<first action or just before the section to be debugged>
A1: Set Tasker Pref [
Set: Run Log
Value: On
Continue Task After Error:On ]
If [ %Debug ~ type ]

<<<all of the actions to be debugged>>>

<last action or just after the section to be debugged>
A2: Set Tasker Pref [
Set: Run Log
Continue Task After Error:On ]