I initially was using PublishInfoMessage to create popup messages. For a while, that seemed reliable. (I used debug flags that I set at the beginning of the function so I could easily turn them on and off without having to comment/uncomment them.)
This seemed to be a reasonable approach, but then sometimes, in some environments, the messages just don’t show.
I have asked Perplexity AI, and it seems to say that PublishInfoMessage won’t always show.
When I asked for best practices, it seemed to say that temporarily throwing an exception is the recommended way (not my idea of a good plan).
Further suggestions were to create a UD log table in the database and insert records into that.
So, what do YOU use to debug App Studio processes/functions/etc.?
You could write all of your debugging info to an output parameter and then use the Function Executioner that Jose made to manually run your function and view all of the outputs. I’ve found it incredibly useful when working on new functions.
That function executioner sounds really nice. Sadly, we are on Kinetic version 2023.2, but we’ll be up to 2025.x next year (if we get approval, etc.).
Looking forward to trying the Function executioner. I grumble every time I have to click Demote from Production, Design, Source, edit one line of code, then Save, Save, Promote to Production.