Commit e899a92
authored
Tunnel debug port RPC errors to callers (#6507)
The debug port's getEntrypoint() and getActor() methods used plain
KJ_ASSERT_NONNULL for error cases (service not found, entrypoint not
found, DO class not found). KJ exceptions without a jsg. prefix get
sanitized by decodeTunneledException() into a generic
"internal error; reference = <id>" before reaching the caller.
Prefix these assertion messages with "jsg.Error:" so they tunnel
through capnp RPC and the caller receives the actual error description
(e.g. "Entrypoint not found: NonExistentEntrypoint").1 parent 271477b commit e899a92
2 files changed
Lines changed: 12 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5952 | 5952 | | |
5953 | 5953 | | |
5954 | 5954 | | |
5955 | | - | |
| 5955 | + | |
5956 | 5956 | | |
5957 | 5957 | | |
5958 | 5958 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5507 | 5507 | | |
5508 | 5508 | | |
5509 | 5509 | | |
5510 | | - | |
5511 | | - | |
5512 | | - | |
| 5510 | + | |
| 5511 | + | |
| 5512 | + | |
5513 | 5513 | | |
5514 | 5514 | | |
5515 | 5515 | | |
| |||
5531 | 5531 | | |
5532 | 5532 | | |
5533 | 5533 | | |
5534 | | - | |
| 5534 | + | |
| 5535 | + | |
5535 | 5536 | | |
5536 | 5537 | | |
5537 | | - | |
5538 | | - | |
| 5538 | + | |
5539 | 5539 | | |
5540 | 5540 | | |
5541 | 5541 | | |
| |||
5560 | 5560 | | |
5561 | 5561 | | |
5562 | 5562 | | |
5563 | | - | |
5564 | | - | |
| 5563 | + | |
| 5564 | + | |
5565 | 5565 | | |
5566 | 5566 | | |
5567 | 5567 | | |
5568 | 5568 | | |
5569 | | - | |
| 5569 | + | |
5570 | 5570 | | |
5571 | 5571 | | |
5572 | 5572 | | |
5573 | | - | |
| 5573 | + | |
| 5574 | + | |
5574 | 5575 | | |
5575 | 5576 | | |
5576 | 5577 | | |
| |||
0 commit comments