{"id":59532,"library":"tor-rtcompat","title":"Tor Rtcompat","description":"Compatibility layer for asynchronous runtimes, used by Tor.","status":"active","version":"0.40.0","language":"rust","source_language":null,"source_url":"https://gitlab.torproject.org/tpo/core/arti.git/","tags":["async","tor","runtime","compatibility"],"install":[{"cmd":"# Cargo.toml\n[dependencies]\ntor-rtcompat = \"0.40.0\"","lang":"toml","label":"Cargo.toml"},{"cmd":"cargo add tor-rtcompat","lang":"bash","label":"cargo add"}],"dependencies":[],"imports":[{"symbol":"PreferredRuntime","correct":"use tor_rtcompat::PreferredRuntime;"}],"quickstart":{"code":"use tor_rtcompat::PreferredRuntime;\n\nfn main() {\n    let runtime = PreferredRuntime::create().unwrap();\n    runtime.block_on(async {\n        println!(\"Running on Tor's async runtime\");\n    });\n}","lang":"rust","description":"Creates and uses the preferred async runtime for Tor applications."},"warnings":[{"fix":"Add `features = [\"tokio\"]` or `features = [\"async-std\"]` to your Cargo.toml dependency.","message":"Requires a Tokio or async-std runtime feature to be enabled.","severity":"gotcha","affected_versions":">=0.1.0"}],"env_vars":null,"search_vec":"'async':11 'asynchron':6 'compat':3,14 'layer':4 'rtcompat':2 'runtim':7,13 'tor':1,10,12 'use':8","created_at":"2026-06-16T17:07:34.157809+00:00","updated_at":"2026-06-16T17:07:34.157809+00:00","problems":[],"ecosystem":"crates","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://gitlab.torproject.org/tpo/core/arti/-/wikis/home","github":null,"docs":"https://docs.rs/tor-rtcompat/","changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["async","networking"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-16","next_check":"2026-12-13","install_tag":null}}