Skip to content
This repository has been archived by the owner on Mar 31, 2024. It is now read-only.

Documentation needed #7

Open
bobd988 opened this issue Aug 20, 2023 · 1 comment
Open

Documentation needed #7

bobd988 opened this issue Aug 20, 2023 · 1 comment

Comments

@bobd988
Copy link

bobd988 commented Aug 20, 2023

I was trying the example ros2 bridge under examples/python-ros2- dataflow folder. As there is no instructions I assume the run.rs should do the work, so first I run rustc run.rs to compile it .
rustc is 1.71.1 and dora-cli 0.2.4

error[E0670]: async fn is not permitted in Rust 2015
--> run.rs:5:1
|
5 | async fn main() -> eyre::Result<()> {
| ^^^^^ to use async fn, switch to Rust 2018 or later
|
= help: pass --edition 2021 to rustc
= note: for more on editions, read https://doc.rust-lang.org/edition-guide

error: environment variable CARGO_MANIFEST_DIR not defined at compile time
--> run.rs:6:26
|
6 | let root = Path::new(env!("CARGO_MANIFEST_DIR"));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: Cargo sets build script variables at run time. Use std::env::var("CARGO_MANIFEST_DIR") instead
= note: this error originates in the macro env (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0432]: unresolved import eyre
--> run.rs:1:5
|
1 | use eyre::WrapErr;
| ^^^^ maybe a missing crate eyre?
|
= help: consider adding extern crate eyre to use the eyre crate

error[E0433]: failed to resolve: use of undeclared crate or module tokio
--> run.rs:4:3
|
4 | #[tokio::main]
| ^^^^^ use of undeclared crate or module tokio

error[E0433]: failed to resolve: use of undeclared crate or module dora_daemon
--> run.rs:11:5
|
11 | dora_daemon::Daemon::run_dataflow(dataflow).await?;
| ^^^^^^^^^^^ use of undeclared crate or module dora_daemon

error[E0599]: no method named wrap_err found for enum Result in the current scope
--> run.rs:8:10
|
7 | / std::env::set_current_dir(root.join(file!()).parent().unwrap())
8 | | .wrap_err("failed to set working dir")?;
| | -^^^^^^^^ help: there is a method with a similar name: unwrap_err
| |_________|
|

error[E0752]: main function is not allowed to be async
--> run.rs:5:1
|
5 | async fn main() -> eyre::Result<()> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ main function is not allowed to be async

error[E0433]: failed to resolve: use of undeclared crate or module eyre
--> run.rs:5:20
|
5 | async fn main() -> eyre::Result<()> {
| ^^^^ use of undeclared crate or module eyre

error: aborting due to 8 previous errors

Some errors have detailed explanations: E0432, E0433, E0599, E0670, E0752.
For more information about an error, try rustc --explain E0432.

@haixuanTao
Copy link
Contributor

Good point! I'll work on that!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants