Move adding try/catch blocks in evaluation from SDK to dwds
- Dominant language
- Dart
- Stars
- 224
- Forks
- 94
- Avg merge
- 7h 14m
- Merged PRs (30d)
- 2
Description
Currently, expression compiler wraps the compiled JS expression in a try/catch block, which does not work well with VMService.evaluate() calls using scope - dwds needs to strip the try/catch to be able to call the function that is the JS expression inside the block.
Suggestion: either remove the wrapper or make dwds decide when it is needed.
Note: we should make sure errors are reported cleanly.
Contributor guide
Research direction
Start by tracing the expression compiler's try/catch wrapper and DWDS handling of VMService.evaluate() calls using scope. Compare where the wrapper is added and where DWDS needs to remove it, then verify that evaluation errors are reported cleanly and that scoped calls can invoke the JavaScript expression function.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- dart
- Domain
- tooling
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100