Debugging Low-code
The Low Code Debugger is available in Profound.js version 6.0.0.
Overview
The Designer IDE contains a built-in interface for debugging server-side low-code steps in Profound API and Rich Display File applications.
This Low-code debugger is different from the built-in Node.js debugger. The Low-code debugger does not pause the server when breakpoints are reached. Only debugged applications in specific debugging sessions are affected.
Launching Debug Targets
When possible Designer will automatically determine how to launch a file opened for debugging. Debug a low-code application or Profound.js API file by opening it in Designer; click the Launch menu; click Debug Low-code:
The debugging panel will appear with low-code routines. Click a routine to see the low-code steps. Click a low-code step to set a breakpoint for it:
Click the green play icon to run the low-code app in debug mode. A Rich Display file will run in a new Designer tab:
Launching Profound API Routes in Debug
Open the API file in Designer. Click Debug Low-code in the Launch menu if you have not already. In the Debug panel click on the API Route you want to debug, and set the desired breakpoints. Click the green play icon, and the API Test panel – on the right-middle panel of the API Designer – should become active:
Scroll to the Execute button in the Test tab, and click it to run the route in debug mode.
Manually Running a Debug Target Using the Debug Session ID
When Designer cannot determine how to launch a target for debugging, a user can manually run the API route or code in a separate application, browser tab, or window; add the debug session ID as the value for the dbgid URL parameter; then, the server will know to link that running application with the IDE's debugging session.
For example, if the debug session ID is deee2370-d58b-40b7-beb3-1efefab2e100, and the method to run a route is an HTTP POST, then to start running the application in debug mode, some other tool (PostMan, etc.) would need to send POST data to the URL and include a parameter, dbgid=deee2370-d58b-40b7-beb3-1efefab2e100. For example:
https://example.com/run/yourWorkSpaceName/yourExpressRoute?dbgid=deee2370-d58b-40b7-beb3-1efefab2e100