Code Editor
The Code Editor is where developers write UDFs using standard Python libraries and installed dependencies. The Editor tab contain functionality to organize code, create HTTPS endpoints, and configure the UDF.

Editor
The editor contains the UDF's function declaration. Whenever code is updated, Fused automatically runs the function named udf that is decorated with @fused.udf and returns the output. Other UDFs declared in the editor are ignored unless referenced by the main udf function.
Debug
The code editor highlights errors in the code and shows error logs to help debug.
UDF Execution in Canvas
UDFs in Canvas are automatically executed to ensure that the displayed results are always up to date.
UDFs are executed when:
- First loading a canvas (page refresh, loading new canvas, opening shared canvas)
- user Clicks the “Run button”
- user hits
Shift + Enter - user Clicks somewhere else in Canvas → This will also rerun the UDF so Canvas always displays the latest version of a UDF
- Is triggered by an upstream connected UDF
A UDF execution can be paused by clicking the Hide icon. When hidden, the UDF will not run automatically and will only execute when explicitly triggered by the user:
- Clicking “Run”
- Doing Shift + Enter
- HTTPS call (calling the UDF through shared token)
- UDF is called in another UDF. For example if
udf_1is hidden it will still be executed ifudf_2calls it:
# inside udf_2
upstream_udf = fused.load("udf_1")
result = upstream_udf()
Hiding a UDF in Workbench only prevents it from being executed in Workbench directly.
UDFs that execute large or parallel workloads require confirmation before running.
This includes:
@fused.udf(engine="small")
Because these operations may start multiple parallel executions or dedicated jobs, Canvas displays a confirmation popup to prevent accidental execution.
Profiler
UDF Builder comes with a built-in profiler that can be used to analyze the performance of a UDF.
This gives you the line-by-line execution time in the UDF.
Note:
- Values are only available for the current run of the UDF.
- Running the same UDF twice might lead to different runtimes especially if you call cached functions or cached UDFs.
- When a line is called multiple times the profiler shows the sum time of all calls & number of hits:

UDFs are automatically saved after any change on the canvas. There is no need to manually save your work.
Utils Module [Legacy]
It is only available as a legacy feature (available to turn on in the Workbench Preferences).
A Fused UDF can import Python objects from its accompanying utils Module, defined in the Utils Tab's code editor. You can import functions from it in your UDF with from utils import my_function.
Here is an example in an old version ofthe Public Overture_Maps_example UDF:
# This is an old version of the code for demonstration purposes
@fused.udf
def udf(
bounds: fused.types.Bounds,
release: str = "2025-01-22-0",
):
from utils import get_overture
gdf = get_overture(
bounds=bounds,
release=release,
)
return gdf
