開発で there is no reactor running, must be called from the context of a Tokio 1.x runtimeが出て困った話

DocBrowser進捗その02

tauriで開発しているプロジェクトに、rspcというtrpcのライブラリを追加して動作させようとしたところ、ランタイムエラーが発生した。

there is no reactor running, must be called from the context of a Tokio 1.x runtime

crateの依存関係によるtokioのバージョン差異を疑ったりしたが、結局tokio公式ドキュメントのサンプルコードを真似して、main関数にマクロ?を追加したところ解決できた。

+ #[tokio::main]
+ async fn main() {
- fn main() {