Skip to content

Preserve Java command caller frames - #377

Merged
vincebln2 merged 3 commits into
VibiumDev:mainfrom
vincebln2:fix/java-exception-caller-frames-337
Aug 19, 2026
Merged

Preserve Java command caller frames#377
vincebln2 merged 3 commits into
VibiumDev:mainfrom
vincebln2:fix/java-exception-caller-frames-337

Conversation

@vincebln2

Copy link
Copy Markdown
Collaborator

Fixes #337.

Captures the Java caller stack when a protocol command is dispatched and attaches it to protocol-created exceptions before they return to the waiting caller.

The transport's own send frames are trimmed, so failures point at the Page or Element operation and the user's calling method instead of mapError and the BiDi receive thread. Exception types and messages are unchanged.

Tests cover retaining the user call site, removing transport frames, and preserving the original error message.

Validation: ./gradlew validateCapabilityMarkers test --tests com.vibium.internal.BiDiClientTest

@vincebln2
vincebln2 merged commit ce1daca into VibiumDev:main Aug 19, 2026
3 checks passed
@vincebln2
vincebln2 deleted the fix/java-exception-caller-frames-337 branch August 21, 2026 18:40
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.

Java client exceptions carry no caller frames — a failing call cannot be attributed to the code that made it

1 participant