mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-07-02 05:38:12 +00:00
Add text helper for flow CEL prompts (#6404)
CEL string concatenation currently fails when prompt builders read missing or null fields. This commit adds `text(root, "path", "default")` custom CEL helper so prompt text can safely read nested state/output values.
This commit is contained in:
@@ -29,6 +29,12 @@ def test_create_flow_declarative_project_can_run(
|
||||
agents_md = (project_root / "AGENTS.md").read_text(encoding="utf-8")
|
||||
assert "CrewAI Flow declaration" in agents_md
|
||||
assert "schema: crewai.flow/v1" in agents_md
|
||||
assert 'text(root, "path", "default")' in agents_md
|
||||
assert "call: expression" in agents_md
|
||||
assert "call: tool" not in agents_md
|
||||
assert "call: script" not in agents_md
|
||||
assert "call: each" not in agents_md
|
||||
assert "human_feedback" not in agents_md
|
||||
|
||||
monkeypatch.chdir(project_root)
|
||||
result = CliRunner().invoke(crewai, ["run"], env={"UV_RUN_RECURSION_DEPTH": "1"})
|
||||
|
||||
Reference in New Issue
Block a user