workbenchdev / workbenchdev/Workbench
Cannot inspect Rust panics
Open
Nobody has claimed this yet.
rust
- Dominant language
- JavaScript
- Stars
- 844
- Forks
- 91
- Avg merge
- 7h 12m
- Merged PRs (30d)
- 1
Description
If Rust fails to compile, the error message is nicely visible in the console.
However, if Rust panics at runtime, all you get is:
(re.sonny.Workbench.Devel:4): Gjs-WARNING **: 20:30:17.056: Unhandled promise rejection. To suppress this warning, add an error handler to your promise chain with .catch() or a try-catch block around your await expression. Stack trace of the failed promise:
save@resource:///re/sonny/Workbench/Document.js:18:8
Document/start/handler_id<@resource:///re/sonny/Workbench/Document.js:27:7
_init/GLib.MainLoop.prototype.runAsync/</<@resource:///org/gnome/gjs/modules/core/overrides/GLib.js:266:34
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the save and Document/start/handler_id paths shown in resource:///re/sonny/Workbench/Document.js, especially lines 18 and 27, and reproduce a Rust runtime panic. Compare this behavior with the visible compile-error path; done means the panic details are inspectable in the console instead of only producing the shown unhandled-promise warning.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, rust
- Domain
- desktop, devtools
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100