Skip to content

[ENGCE-57552] test(uipath-maestro-flow): array filter mandatory-source smoke#590

Open
baishalighosh wants to merge 1 commit intomainfrom
engce-57552-skill-tests
Open

[ENGCE-57552] test(uipath-maestro-flow): array filter mandatory-source smoke#590
baishalighosh wants to merge 1 commit intomainfrom
engce-57552-skill-tests

Conversation

@baishalighosh
Copy link
Copy Markdown
Contributor

@baishalighosh baishalighosh commented May 5, 2026

Jira: ENGCE-57552[Skills][CLI] Add support for array filter in trigger
RCA: ENGCE-57498 — Gmail Email Received trigger returns 400 on Debug (Confluence)
Companion PR: skills #589 — docs (impl.md + triggers.md updates that explain the shape this test exercises).
Replaces: skills #587 (please close — content split into the docs PR + this PR).

Summary

Adds the skill-flow-trigger-with-array-filter smoke eval — Gmail "Email Received" trigger on INBOX with a freeform subject contains "invoice" leaf. Regression guard for ENGCE-57498: the original 400 happened because agents (and the CLI) were authoring the mandatory folder clause as a freeform filter leaf with the wrong JMES shape.

The eval asserts the SW-mirrored contract that the companion docs PR and the CLI fix jointly establish:

  • eventParameters.folder === "INBOX" — mandatory source lives on eventParameters, not in filter.
  • filter tree exists for the user's subject leaf; no top-level filterExpression at the detail root.
  • Freeform tree leaves do not reference folder / ParentFolders ids — duplicating the auto-emitted mandatory clause would double-apply the constraint at runtime.

Also flattens the connector_trigger eval suite from tests/tasks/uipath-maestro-flow/nodes/connector_trigger/ to tests/tasks/uipath-maestro-flow/connector_trigger/ so both filter tests live alongside each other.

Files

  • tests/tasks/uipath-maestro-flow/connector_trigger/trigger_with_array_filter.yaml — new
  • tests/tasks/uipath-maestro-flow/connector_trigger/check_trigger_filter.py — moved from nodes/connector_trigger/
  • tests/tasks/uipath-maestro-flow/connector_trigger/trigger_with_filter.yaml — moved from nodes/connector_trigger/

Depends on

  • skills #589 — companion docs (the eval prompt expects agents to follow the new mandatory-filter guidance).
  • uipcli #1823 — CLI fix that gives the new guidance teeth at runtime.

Land in the order: uipcli #1823 → skills #589 → this PR.

Test plan

  • tests/tasks/uipath-maestro-flow/connector_trigger/trigger_with_filter.yaml — existing Outlook subject+from filter eval still passes against the renamed path
  • tests/tasks/uipath-maestro-flow/connector_trigger/trigger_with_array_filter.yaml — new Gmail INBOX + subject filter eval passes locally with the updated skill prompt

References

  • StudioWeb PR #18007 — array projection (defect 1)
  • StudioWeb PR #18040 — scalar quoting + sanitized-id lookup + translator wiring
  • PO.Frontend PR #5206 — Maestro side of defect 4

…ENGCE-57552]

Adds skill-flow-trigger-with-array-filter — Gmail "Email Received" trigger
on INBOX with a freeform "subject contains invoice" leaf. Asserts:

- eventParameters.folder === "INBOX" (mandatory source lives there, not
  in the freeform tree).
- filter tree exists for the user's subject leaf, no top-level
  filterExpression at the detail root.
- freeform tree leaves do NOT reference folder / ParentFolders (would
  duplicate the auto-emitted mandatory clause and double-apply the
  constraint at runtime). Regression guard for the original 400 in
  ENGCE-57498.

Also flattens the connector_trigger eval suite from
tests/tasks/uipath-maestro-flow/nodes/connector_trigger/ to
tests/tasks/uipath-maestro-flow/connector_trigger/ so both filter tests
live alongside each other.

Doc updates that explain the shape these tests exercise (impl.md +
triggers.md) ship in the companion PR engce-57552-skill-docs.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 5, 2026

Claude finished @baishalighosh's task in 2m 10s —— View job


Summary

Adds the skill-flow-trigger-with-array-filter smoke eval — a regression guard for ENGCE-57498 ensuring Gmail's mandatory folder parameter lives on eventParameters (not duplicated in the freeform filter tree). Also flattens the connector_trigger test suite from nodes/connector_trigger/ to connector_trigger/ at the skill-test root.

Change-by-Change Review

1. tests/tasks/uipath-maestro-flow/connector_trigger/check_trigger_filter.py (RENAMED)

Severity: OK

Pure rename from nodes/connector_trigger/connector_trigger/. No content changes. The old nodes/ directory is fully removed. The shared Python checker validates subject + PascalCase Contains — works correctly for both the existing Outlook test and the new Gmail test.

2. tests/tasks/uipath-maestro-flow/connector_trigger/trigger_with_filter.yaml (RENAMED)

Severity: OK

Same pure rename. Content unchanged. Tags and task_id remain valid. The $TASK_DIR/check_trigger_filter.py reference resolves correctly at the new path since $TASK_DIR is relative to the task file.

3. tests/tasks/uipath-maestro-flow/connector_trigger/trigger_with_array_filter.yaml (ADDED)

Severity: Low (one nit)

Well-structured smoke test. Observations:

  • Tags (line 6): [uipath-maestro-flow, smoke, connector-trigger, filter, mandatory-filter] — skill name is first tag, smoke is a valid test type. Good.

  • task_id (line 1): skill-flow-trigger-with-array-filter — follows the skill-<domain>-<capability> pattern. Good.

  • initial_prompt (lines 12-35): Describes the goal clearly without prescribing implementation steps. Correctly instructs the agent to avoid live CLI calls (sandbox has no tenant). Good.

  • success_criteria (lines 37-117): Five checks with appropriate weights:

    1. file_exists — basic guard (weight 1.0)
    2. run_command — JSON validity (weight 1.0)
    3. json_check — core structural assertions: eventParameters.folder === "INBOX", filter tree present, no top-level filterExpression (weight 3.0)
    4. run_command via check_trigger_filter.py — validates subject field + PascalCase operator (weight 2.0)
    5. run_command inline Python — verifies freeform tree excludes folder/ParentFolders leaves (weight 2.0)

    The assertion weighting appropriately emphasizes the structural contract (3.0) and the regression-specific checks (2.0 each) over basic existence checks (1.0).

  • Nit (line 69, json_check): filter.groupOperator is checked with operator: type / expected: "number" — same pattern as the sibling test. This validates the type but not the value. Both 0 (And) and 1 (Or) pass. For this scenario (single subject leaf), 0 (And) is the only logical choice, but the test doesn't enforce it. This is fine for a smoke test — just noting it.

  • Inline Python (lines 94-113): The leaves() generator correctly walks nested dicts/lists looking for nodes with a string operator field. The id field check for folder/parentfolders substrings is a reasonable heuristic. One edge case: if an agent uses a completely different key name (not id) for the field identifier, the check would vacuously pass. However, check_trigger_filter.py (criterion 4) already validates the field naming via id/fieldName/field/name, so the two checks complement each other well.

What's Missing

  • CODEOWNERS for test path: No /tests/tasks/uipath-maestro-flow/ entry in CODEOWNERS. However, only 5 of many skill test directories have CODEOWNERS entries, so this is a pre-existing gap, not introduced by this PR. Low — not blocking.
  • No e2e-tagged task in connector_trigger/: Both tasks here are tagged smoke. Per code_review.md, the suite should have at least one smoke and one e2e. That said, the e2e/ directory already has devcon_expense_approval.yaml covering end-to-end, so the skill overall has both coverage types. The connector_trigger subdirectory is smoke-only by design. Low — not blocking.

Area Ratings

Area Status Notes
Frontmatter N/A No skill SKILL.md changed — test-only PR
E2E Tests OK New smoke task is well-structured; skill has e2e coverage elsewhere
Skill Body N/A No skill docs changed
References & Assets N/A No references changed
Repo Hygiene OK No secrets, no cross-skill refs, old nodes/ dir cleanly removed

Issues for Manual Review

Conclusion

Clean, well-scoped test PR. The new eval directly guards the ENGCE-57498 regression with appropriate structural assertions. The directory flattening is clean (old nodes/ fully removed). No blocking issues found — approve.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant