This feature was removed in Pricefx Studio 8.1.


How it Works

Formula elements are executed by a simplified formula engine in Pricefx Studio, similarly to the one running on the Pricefx backend server. The local calculation engine mimics the server one and it executes the elements sequentially as ordinary Groovy scripts and the idea is that each of the Pricefx Groovy API is implemented as a separate stateless call of the backend server.

  • This functionality is only experimental. It supports only a very limited scope of API and since it cannot cover 100% cases, the development has been put on hold and is not supported.
  • Due to the implementation, not all of the API functions are supported and it is not guaranteed that the results will be the identical to the standard formula test feature.
  • Only logics with all elements of the Groovy type are supported.

Prerequisites

For the project in IDEA you need to:

Debug Logic

  1. Select parameters for the debug run as described here. You need to save the parameters into a file, since the filename will be passed to the launched debugger process as a parameter.
  2. Put the breakpoint at the last line of the src/debug.groovy script. This script file will be created automatically when you run the debugging for the first time.
  3. Open the desired element file(s) and add breakpoint(s) on the lines where you want to stop the formula execution.
  4. Click the 'Debug' button in the Logic editor. This starts the standard IDEA debugging of the debug.groovy script which will be automatically created in the src/ folder.
  5. When the debugger stops here, add the desired variables into Watches.

Hints for Variable Watches

Here are some tips for useful watches available from the element Groovy script:

Analogically, some of the watches are available in debug.groovy as:

Debugger results

Evaluate Expressions on the Fly

You can also evaluate some API methods online e.g. vLookup() or api.find():

  1. Right click anywhere in the source code text of some element script and choose "Evaluate expression" (Alt+F8).
  2. Enter some expression there and press Enter.

Supported APIs

Supported APIs with No Effect in Debug Mode

What Will Not Be Supported

Best Practices for Logic Development with Debug Support