Commit 27a8882
fix: preserve checkpoint on breakpoint resume to prevent duplicate events
When a breakpoint fired before any new checkpoint was created during a
workflow.run() call, the stale checkpoint detection (baseline == latest)
saved checkpoint_id=None. The next resume then replayed from
original_input, re-executing already-completed executors like triage,
which re-emitted handoff_to_billing_agent events (4x duplicates).
Fix: fall back to self._resumed_from_checkpoint_id instead of None when
no new checkpoint was created. This preserves the checkpoint we resumed
from (still valid) instead of losing it. For fresh turns,
_resumed_from_checkpoint_id is None, so the multi-turn stale checkpoint
fix from 5c6dc25 is preserved.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 5c6dc25 commit 27a8882
4 files changed
Lines changed: 249 additions & 46 deletions
File tree
- packages/uipath-agent-framework
- src/uipath_agent_framework/runtime
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
Lines changed: 14 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
443 | 443 | | |
444 | 444 | | |
445 | 445 | | |
446 | | - | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
447 | 451 | | |
448 | 452 | | |
449 | 453 | | |
450 | | - | |
| 454 | + | |
451 | 455 | | |
452 | 456 | | |
453 | 457 | | |
| |||
655 | 659 | | |
656 | 660 | | |
657 | 661 | | |
658 | | - | |
659 | | - | |
660 | | - | |
661 | | - | |
662 | | - | |
663 | | - | |
664 | | - | |
| 662 | + | |
| 663 | + | |
665 | 664 | | |
666 | 665 | | |
667 | 666 | | |
| |||
683 | 682 | | |
684 | 683 | | |
685 | 684 | | |
686 | | - | |
687 | | - | |
688 | | - | |
| 685 | + | |
| 686 | + | |
| 687 | + | |
689 | 688 | | |
690 | 689 | | |
691 | 690 | | |
| |||
738 | 737 | | |
739 | 738 | | |
740 | 739 | | |
| 740 | + | |
| 741 | + | |
741 | 742 | | |
742 | 743 | | |
743 | 744 | | |
744 | | - | |
| 745 | + | |
745 | 746 | | |
746 | 747 | | |
747 | 748 | | |
| |||
0 commit comments