Evaluate expressions without the need of pipelines.
fabrix is a Python toolkit to evaluate, validate, and debug Microsoft Fabric / Azure Data Factory pipeline expressions. It helps you test expressions locally, manage variables & parameters, and visualize execution with rich tracing.
⚠️ This project is still in progress. Expect changes and new features soon.
Documentation: https://github.com/luanee/fabrix/wiki Source Code: https://github.com/luanee/fabrix
- Parse & evaluate Fabric/ADF expressions locally
- Manage variables, pipeline parameters, and scope values
- Validate syntax: unmatched brackets, wrong quotes, unknown functions
- Debug with beautiful Rich tree traces
- Extend with your own custom functions via a registry
pip install fabrixfrom fabrix import Context, Expression, evaluate, run
# Create a context with parameters & variables
ctx = Context(
pipeline_parameters={
"myNumber": 42,
},
variables={
"greeting": "hello",
"row_index": 1,
},
)
# Simple expression
result = evaluate("@concat('Answer is: ', string(pipeline().parameters.myNumber))", ctx)
print(result) # Answer is: 42
# With variable assignment
expr_1 = Expression(expression="@toUpper(variables('greeting'))", variable="shout")
expr_2 = Expression(expression="@add(variables('row_index'),mul(4,5),add(variables('row_index'),max(4.5,3.9,578.4)))")
run(expr_1, expr_2, context=ctx, show_output=True) # see output below
print(ctx.variables["shout"]) # HELLO- Add more Fabric/ADF built-in functions
- Improve error messages with fuzzy suggestions
- Advanced type checking for function arguments
- VS Code extension with syntax highlighting & validation
- Better documentation and tutorials
- Publish first stable release on PyPI

