What problem does it solve?
This skill helps engineers understand the Rust async/await execution model and diagnose runtime issues such as stuck or slow tasks, waker leaks, incorrect Pin/Unpin usage, and accidental blocking in asynchronous contexts.
Core Features & Use Cases
- Explains the Future trait and poll loop, how .await drives polling, and what Ready vs Pending means for task scheduling.
- Clarifies Pin and Unpin semantics for self-referential state machines and shows safe patterns for pinning on heap or stack.
- Guides tokio task usage including spawn, spawn_blocking, LocalSet, and cooperative yielding; explains common blocking pitfalls.
- Shows how to use tokio-console to inspect async tasks, interpret poll times and wake counts, and locate blocking or long-running tasks.
- Diagnoses select! and join! concurrency semantics and typical surprises like dropped futures, biased select behavior, and when to fuse futures.
- Use cases: debugging a task that never completes, fixing waker leaks, migrating blocking code to spawn_blocking or async equivalents, and improving latency in a tokio-based service.
Quick Start
Ask the skill to analyze why a specific async function blocks or wakes excessively and provide code-level fixes plus steps to inspect the behavior with tokio-console.