Python Module

Python Module

With the Python Module configurations, you can write shared Python code that can be imported by multiple Python agents. This allows you to organize your Python code into different modules that can be reused.

Python module editor.png

To access the Python Module, click the New Configuration button and then select Python Module from the menu. The entire Python Module configuration is a code area where you can write code that you want Python agents to be able to import. See the code section for the relevant agent for further information.

The imported modules are referenced by the workflows, but as each agent has its own memory space, global variables will not be shared between agents or workflows.

Config Diff

If you want to compare the current version of a Python module configuration that you are displaying with a previous version of the same configuration, you can use Configuration Diff to compare the two versions side by side.

To view the Configuration Diff pop-up, click the Configuration Diff menu button of the Python module.

You can navigate through the differences by scrolling both panes in parallel using the scroll bar to the right of either pane. If you want to scroll through each pane separately, hover over the pane that you want to scroll through, and use the scroll wheel on your mouse.

If you want to skip through each difference in the panes, you can use the navigation buttons: Previous, Next and Refresh, which are described below.

Setting/Button

Description

Setting/Button

Description

History

To select a different version of the same configuration, use the drop-down box to select the version you want to display.

History.png

You can also display and view encrypted configurations. If you select an encrypted configuration, you are prompted to enter the relevant password to decrypt the configuration.

Previous

Click this button to skip to the previous difference in the configurations. The previous difference is highlighted in green.

Next

Click this button to skip to the next difference in the configurations. The next difference is highlighted in green.

Refresh

Click this button to display the updated version of the configuration. Configurations are not locked when you display them in Configuration Diff. If another user has modified and saved a configuration that you are viewing in this tool, you can click this button to view the latest updated version.

Python Code Editor Assistance

To provide assistance when you are writing code in the Python code area, there are several features in place:

  • Syntax Highlighting - Different parts of the code are color-coded according to type

  • Right-click Menu - A menu that provides editor options.

  • Code Completion - Helps you to write Python code in the Python Code Editor by providing context-sensitive proposals.

  • For further information on these features, see Python Code Editor Assistance.