feat: add wait_for_triggers option to poll instead of suspend#74
Closed
feat: add wait_for_triggers option to poll instead of suspend#74
Conversation
cristipufu
requested changes
Jan 28, 2026
Member
cristipufu
left a comment
There was a problem hiding this comment.
Nope. Please explain what you re trying to achieve
Member
|
If you want polling, just wrap the runtime with a Debug Runtime instantiated with a polling interval gt 0 |
6bdc01f to
70476f8
Compare
Author
What I am trying to achieve here is experiment the option of running the |
70476f8 to
dcc49ef
Compare
Add a new execution option `wait_for_triggers` that allows the runtime to poll triggers until completion instead of suspending and returning. This keeps the process running and automatically resumes execution when triggers complete. Key behavior: When wait_for_triggers=True, triggers are created (to start the work like invoking processes, creating tasks) but NOT persisted to storage. The runtime polls inline and resumes without involving the persistence layer. Changes: - Add `wait_for_triggers` and `trigger_poll_interval` options to UiPathExecuteOptions - Create shared TriggerPoller utility for reusable polling logic - Update UiPathResumableRuntime to loop and poll when wait_for_triggers=True - Add skip_storage parameter to _handle_suspension() to avoid persistence - Refactor UiPathDebugRuntime to use the shared TriggerPoller Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
dcc49ef to
b25b6f3
Compare
mjnovice
added a commit
to UiPath/uipath-python
that referenced
this pull request
Jan 28, 2026
…rchestrator
Add CLI flags to enable polling mode for triggers instead of suspending:
- `--wait-for-triggers`: Poll triggers until completion instead of suspending
- `--trigger-poll-interval`: Configurable poll interval (default: 5.0s)
This enables running agents locally with tool calls (InvokeProcess, CreateTask, etc.)
without requiring serverless/orchestrator infrastructure.
Usage:
uipath run my_agent.main '{"query": "hello"}' --wait-for-triggers
uipath run my_agent.main '{"query": "hello"}' --wait-for-triggers --trigger-poll-interval 10.0
Depends on: UiPath/uipath-runtime-python#74
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
3 tasks
Member
|
The whole point of triggers is persistance. If you don't persist the triggers, you don't need suspend/resume semantics. Just poll for results in the tool itself |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
wait_for_triggersandtrigger_poll_intervaloptions toUiPathExecuteOptionswait_for_triggers=True, the runtime polls triggers until completion instead of suspendingTriggerPollerutility for reusable polling logicUiPathDebugRuntimeto use the sharedTriggerPollerUsage
Test plan
🤖 Generated with Claude Code
Development Package