Skip to content

feat: support multiple resume triggers per interrupt#138

Open
radu-mocanu wants to merge 1 commit into
mainfrom
feat/runtime-create-triggers-protocol
Open

feat: support multiple resume triggers per interrupt#138
radu-mocanu wants to merge 1 commit into
mainfrom
feat/runtime-create-triggers-protocol

Conversation

@radu-mocanu

@radu-mocanu radu-mocanu commented Jun 27, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • add create_triggers to the resumable trigger creator protocol
  • persist all triggers returned for one interrupt so multiple resume conditions can race
  • add __uipath trigger metadata to composite interrupt resume values so callers can identify which sibling fired
  • keep sibling triggers scoped by interrupt id so when one fires the remaining siblings do not leak into later suspensions
  • Force cross-repo uv resolves to use the runtime wheel under test. (similar to ci: force local wheels via uv override in cross-tests uipath-python#1723)

Depends on: UiPath/uipath-python#1768 and UiPath/uipath-python#1773

Development Package

  • Add this package as a dependency in your pyproject.toml:
[project]
dependencies = [
  # Exact version:
  "uipath-runtime==0.12.0.dev1001380581",

  # Any version from PR
  "uipath-runtime>=0.12.0.dev1001380000,<0.12.0.dev1001390000"
]

[[tool.uv.index]]
name = "testpypi"
url = "https://test.pypi.org/simple/"
publish-url = "https://test.pypi.org/legacy/"
explicit = true

[tool.uv.sources]
uipath-runtime = { index = "testpypi" }

@radu-mocanu radu-mocanu requested a review from a team as a code owner June 27, 2026 21:38
@radu-mocanu radu-mocanu force-pushed the feat/runtime-skip-timer-triggers branch from 2e5abd3 to 76ea3f8 Compare June 27, 2026 22:25
@radu-mocanu radu-mocanu force-pushed the feat/runtime-create-triggers-protocol branch 2 times, most recently from e7d2707 to df65b23 Compare June 27, 2026 22:43
@radu-mocanu radu-mocanu force-pushed the feat/runtime-skip-timer-triggers branch 2 times, most recently from 0296604 to d68d3cc Compare June 29, 2026 16:02
@radu-mocanu radu-mocanu force-pushed the feat/runtime-create-triggers-protocol branch from df65b23 to 37acdd4 Compare June 30, 2026 08:51
@radu-mocanu radu-mocanu changed the base branch from feat/runtime-skip-timer-triggers to main June 30, 2026 09:41
@radu-mocanu radu-mocanu force-pushed the feat/runtime-create-triggers-protocol branch 2 times, most recently from fd7b080 to 300a6b9 Compare June 30, 2026 10:10
Copilot AI review requested due to automatic review settings June 30, 2026 10:10

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR extends the resumable runtime to support multiple resume triggers per interrupt, enabling multiple resume conditions to race while preserving enough metadata for callers to identify which sibling trigger fired.

Changes:

  • Add create_triggers(...) -> list[UiPathResumeTrigger] to the trigger-creator protocol and update the resumable runtime to persist all triggers per interrupt.
  • Annotate resume values with __uipath trigger metadata when an interrupt has multiple sibling triggers.
  • Update tests and CI workflows (via a new helper script) to validate/consume the new behavior and ensure cross-repo tests use the wheel under test.

Reviewed changes

Copilot reviewed 7 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/uipath/runtime/resumable/runtime.py Calls create_triggers, builds resume input with sibling-trigger metadata, and persists multiple triggers per interrupt.
src/uipath/runtime/resumable/protocols.py Extends the trigger creator protocol with create_triggers.
tests/test_resumable.py Adds coverage for sibling-trigger behavior and updates mocks to support create_triggers.
.github/scripts/force-runtime-override.py New helper to force uv resolves to use the runtime wheel under test in cross-repo workflows.
.github/workflows/test-uipath.yml Uses the override helper script when installing the runtime wheel for uipath-python tests/typecheck.
.github/workflows/test-uipath-langchain.yml Uses the override helper script when installing the runtime wheel for uipath-langchain tests/typecheck.
pyproject.toml Bumps package version to 0.12.0.
uv.lock Updates locked version to 0.12.0.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/uipath/runtime/resumable/runtime.py
Comment thread src/uipath/runtime/resumable/runtime.py
Comment thread .github/scripts/force-runtime-override.py
@radu-mocanu radu-mocanu force-pushed the feat/runtime-create-triggers-protocol branch from 300a6b9 to d5e123f Compare June 30, 2026 13:22
@radu-mocanu radu-mocanu force-pushed the feat/runtime-create-triggers-protocol branch from d5e123f to a0eb8ad Compare June 30, 2026 14:09
@sonarqubecloud

Copy link
Copy Markdown

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants