How to debug Rust code with Flutter? #213
Replies: 3 comments
-
Hi @ivan-sirosh , that's an interesting viewpoint for debugging that I didn't think about before. I don't think using Rust breakpoints in a Flutter app is possible. Instead, using If you have some new ideas or opinions, please let me know! |
Beta Was this translation helpful? Give feedback.
-
The idea behind to allow to run rust code independently. The protobuf communicates by gRPC (socket port is opened) or by HTTP, what does not matter in that case. I would like to have some debug parameter to connect to remote protobuf host instead of default which is spawn by It will allows me to develop backend with real frontend in use. Something line like run Rust code with brake points in the IDE and meanwhile run flutter app to execute real call to gRPC bridge. |
Beta Was this translation helpful? Give feedback.
-
I see, but I do see one caveat. It's that Rust tasks are exeucted in parallel concurrency system(async). If you have 16 cores on your PC, Rust tasks will be executed in 16 threads when using Rinf(by If you want to check debug parameters, is the Or, would sending custom development signals to Rust be helpful(via keyboard events, etc)? P.S. In Rinf, protobuf is used only for serial/deserialization. Sending data between Dart and Rust is done by native ABI. |
Beta Was this translation helpful? Give feedback.
-
Since Rust code is compiled and run by Flutter, it is not possible to put any brakepoint in the Rust code.
Is there any way to run Rust part of program independent of Flutter part and still communicate between them?
Beta Was this translation helpful? Give feedback.
All reactions