Skip to content

Commit

Permalink
fix some issues with deps
Browse files Browse the repository at this point in the history
  • Loading branch information
besok committed Jun 24, 2024
1 parent c63d8f9 commit 8b59d5c
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 136 deletions.
128 changes: 6 additions & 122 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ env_logger = "0.11.3"
serde = { version = "1.0.166", features = ["derive"] }
serde_json = { version = "1.0.99" }
serde_yaml = "0.9.22"
reqwest = { version = "0.12.4", features = ["blocking", "json"] }
reqwest = { version = "0.11", features = ["blocking", "json"] }
tracing = "0.1"
axum = "0.6.16"
tokio = { version = "1.37.0", features = ["full"] }
Expand Down
6 changes: 3 additions & 3 deletions src/converter/to_nav.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,18 +30,18 @@ impl<'a> Converter for ToRosNavConverter<'a> {
while let Some((id, st)) = stack.pop() {
let node = self.tree.node(&id)?;
if node.is_action() {
&self.write_terminal(&mut writer, id, node)?;
let _ = &self.write_terminal(&mut writer, id, node)?;
} else {
match st {
State::Ready => {
&self.write_interior_start(&mut writer, id, node)?;
let _ = &self.write_interior_start(&mut writer, id, node)?;
stack.push((id, State::Started));
for child in node.children().iter().rev() {
stack.push((*child, State::Ready));
}
}
State::Started => {
&self.write_interior_end(&mut writer, id, node)?;
let _ = &self.write_interior_end(&mut writer, id, node)?;
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions src/runtime/action/builtin/remote.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::runtime::action::{Impl, ImplRemote, Tick};
use crate::runtime::action::{ ImplRemote, Tick};
use crate::runtime::args::{RtArgs, RtArgument};
use crate::runtime::context::{TreeRemoteContextRef};
use crate::runtime::{to_fail, TickResult};
Expand Down Expand Up @@ -62,7 +62,7 @@ impl ImplRemote for RemoteHttpAction {
let resp = env.runtime.block_on(async {
let client: Client<HttpConnector, Body> =
hyper::Client::builder().build(HttpConnector::new());
/// todo with vec is slow. Bytes?
// todo with vec is slow. Bytes?
let body_js = serde_json::to_vec(&request).unwrap();

let request = Request::builder()
Expand Down
2 changes: 1 addition & 1 deletion src/runtime/env.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use tokio::runtime::{Builder, Runtime};
use tokio::task::JoinError;
use tokio::task::JoinHandle;
use tokio_util::sync::CancellationToken;
use crate::runtime::env::daemon::{DaemonFn, DaemonName, Daemon};
use crate::runtime::env::daemon::{ DaemonName, Daemon};
use crate::runtime::env::daemon::context::DaemonContext;
use crate::runtime::env::daemon::task::{DaemonStopSignal, DaemonTask};

Expand Down
2 changes: 1 addition & 1 deletion src/runtime/forester/decorator.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::runtime::args::{RtArgs, RtArgument, RtValue, RtValueNumber};
use crate::runtime::args::{RtArgs, RtValue, RtValueNumber};
use crate::runtime::context::{RNodeState, TreeContext};
use crate::runtime::forester::flow::{run_with, LEN, REASON};
use crate::runtime::rtree::rnode::DecoratorType;
Expand Down
4 changes: 2 additions & 2 deletions src/runtime/rtree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ pub mod transform;
use crate::runtime::action::ActionName;
use crate::runtime::args::transform::{to_dec_rt_args, to_rt_args};

use crate::runtime::rtree::rnode::{DecoratorType, FlowType, RNode, RNodeId};
use crate::runtime::rtree::rnode::{DecoratorType, RNode, RNodeId};
use crate::runtime::rtree::transform::{StackItem, Transformer};
use crate::runtime::{RtOk, RtResult, RuntimeError};
use crate::tree::parser::ast::call::Call;
Expand Down Expand Up @@ -137,7 +137,7 @@ impl RuntimeTree {
// - if it is lambda we already found it
Call::HoInvocation(key) => {
debug!(target:"tree[construct]", "found ho invocation with id {id} in parent {parent_id}");
let (p_id, parent_args, parent_params) =
let (p_id, _parent_args, _parent_params) =
builder.get_chain_skip_lambda(&parent_id)?.get_tree();
let call = builder.find_ho_call(&parent_id, &key)?;
if call.is_lambda() || call.is_decorator() {
Expand Down
2 changes: 1 addition & 1 deletion src/runtime/rtree/analyzer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ impl<'a> RtTreeAnalyzer<'a> {
{
self.tree
.iter()
.find(|(id, node)| filter(node))
.find(|(_id, node)| filter(node))
}
/// Returns the node by filter
pub fn find_map_by<F, T>(&self, filter_map: F) -> Option<(RNodeId, T)>
Expand Down
3 changes: 2 additions & 1 deletion src/simulator/builder.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

use crate::get_pb;
use crate::runtime::action::keeper::ActionImpl;
use crate::runtime::builder::ForesterBuilder;
Expand Down Expand Up @@ -97,7 +98,7 @@ impl SimulatorBuilder {
pub fn root(&mut self, root: PathBuf) {
self.root = Some(root);
}

#[allow(irrefutable_let_patterns)]
/// Build
pub fn build(&mut self) -> RtResult<Simulator> {
let mut fb = self.fb.take().ok_or(RuntimeError::uex(
Expand Down
2 changes: 1 addition & 1 deletion src/tree/parser/ast/arg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use crate::tree::parser::ast::Key;
use crate::tree::{cerr, TreeError};
use itertools::Itertools;
use serde::{Deserialize, Serialize};
use std::fmt::{Display, Formatter, Write};
use std::fmt::{Display, Formatter};

/// Just a pair of name and type
/// This is a representation of a tree parameter
Expand Down
2 changes: 1 addition & 1 deletion src/tree/parser/ast/call.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ impl Debug for Call {
let _ = write!(f, "{}({}) :", tpe, args);
let mut elems = f.debug_list();
elems.entry(call);
elems.finish();
let _ = elems.finish();
Ok(())
}
}
Expand Down

0 comments on commit 8b59d5c

Please sign in to comment.