feat(debug): call graph, state events, and breakpoint improvements#1319
Merged
cristipufu merged 1 commit intomainfrom Feb 15, 2026
Merged
feat(debug): call graph, state events, and breakpoint improvements#1319cristipufu merged 1 commit intomainfrom
cristipufu merged 1 commit intomainfrom
Conversation
- Add AST-based call graph builder (graph_builder.py) that parses user code and builds a UiPathRuntimeGraph with file:line node IDs - Include call graph in runtime schema returned by get_schema() - Emit UiPathRuntimeStateEvent for call-graph functions during execution, even without breakpoints, so the debug bridge can visualise flow - Propagate OTEL context to background trace thread via contextvars - Use first body line (skipping docstrings) for node IDs so breakpoints don't fire during module imports - Skip <module> frame line events to avoid breakpoints on def statements - Deduplicate breakpoint hits per frame to prevent multiline expressions from triggering the same breakpoint twice Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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
graph_builder.py): parses user code from an entrypoint function, builds aUiPathRuntimeGraphwithfile:linenode IDs that double as breakpoint locationsUiPathRuntimeStateEventfor every call-graph function entry (even without breakpoints), so the debug bridge can visualise execution flow through graph nodescontextvarsto the background trace thread so@traceddecorator spans are properly linked to the parent tracedefline, preventing false breakpoint hits during module imports<module>frame line events are skipped in the trace callbackreturn Foo(arg=bar(...))) from triggering the same breakpoint twice due to bytecode line bouncingTest plan
🤖 Generated with Claude Code