Thanks anyway for your help! I'll still give it a try. This happens because a function (like `block_on`) attempted to block the current thread while the thread is being used to drive 'Cannot start a runtime from within a runtime. This is the complete error message and it gives me the impression that Actix-rt and postgres crates won't just work together. Example usage: > cargo run -p rrgeo-cmd -release 40 -73 71 ms to load cities.csv 3 ms to build the KdTree (40.72788, -73. unwrap() Īre there ways around this without changing the codes too much? I spent the whole Sunday trying to fix this but to no avail.Īsync fn get_person(info: web::Path) -> impl Responder ::poll),actix_web::handler::Handler) -> std::future::GenFuture, (actix_web::types::path::Path), std::future::GenFuture, acti This crate is implemented as a library, an Actix REST API, a Warp REST API, and as a command-line utility, thanks to Cargo workspaces. Let mut client = Client::connect(pg_connection_string, NoTls). To Actix-Web 2.0 and Postgres 0.17.2 but I get the error 'Cannot start a runtime from within a runtime.' when this line runs: I am trying to port codes from these posts We'll do our best to keep these links up to date, but if we fall behind please don't hesitate to shoot us a modmail. This is not an official Rust forum, and cannot fulfill feature requests. Err on the side of giving others the benefit of the doubt.Īvoid re-treading topics that have been long-settled or utterly exhausted. This is a problem because the fork() call (used internaly by daemon()) only replicates the thread that called fork(). Please create a read-only mirror and link that instead.Ī programming language is rarely worth getting worked up over.īe charitable in intent. The issue with your application is that the actix-web runtime (i.e.
If criticizing a project on GitHub, you may not link directly to the project's issue tracker. Post titles should include useful context.įor Rust questions, use the stickied Q&A thread.Īrts-and-crafts posts are permitted on weekends.Ĭriticism is encouraged, though it must be constructive, useful and actionable. For content that does not, use a text post to explain its relevance. Posts must reference Rust or relate to things using Rust.
We observe the Rust Project Code of Conduct. The global standard for drive test survey analysis Actix enables mobile operators to optimize customer experience in the RAN and maximise the value of their network.
Strive to treat others with respect, patience, kindness, and empathy. Please read The Rust Community Code of Conduct The Rust Programming LanguageĪ place for all things related to the Rust programming language-an open-source systems language that emphasizes performance, reliability, and productivity.