Debug script

You can use all debug stuff that a debugger should provide, for instance, we can use breakpoints. You can configure debugger via Script Exec.

Debug console

Iedis 2 launches a debug console during a debug session, you can execute Redis commands via debug console:

debug console2

Auto completion

Iedis 2 provide command auto-completion in debug console which is the same as Command Exec:

auto completion2


Iedis 2 provide command documentation in debug console which is the same as Command Exec:


Command execution

Iedis 2 will print the detail of command interaction in the debugger if you choose Print Redis call detail when stepping over in Script Exec. This is pretty useful to determine that how your script affects the data set:

command execution detail2

You can use redis.debug() to print debug message to serve as logger.debug() for debugging purpose:

debug message2

Note: This is available when you use breakpoints.

Code evaluation

You can run other Lua script while you're debugging an existing script. You can evaluate code by right-click on Lua editor → select Evaluate Expression:

evaluate expression2

You can execute script via evaluate expression dialog:

evaluate expression dialog2

If your script is long you can switch to evaluate code fragment mode:

evaluate code fragment2

A string with a single world will be determined as a variable, and Iedis 2 will use PRINT command to display it's current value in current debug session. Otherwise, Lua script will be evaluated using EVAL command.

Note: The EVAL command is executed in a different call frame.


You can use watcher to monitor things to help you debugging easier:


Codes Magic © 2013-2019 · Terms