diff --git a/rust/fastsim-core/fastsim-proc-macros/src/add_pyo3_api/pyo3_api_utils.rs b/rust/fastsim-core/fastsim-proc-macros/src/add_pyo3_api/pyo3_api_utils.rs index 219770bc..88af5f8e 100644 --- a/rust/fastsim-core/fastsim-proc-macros/src/add_pyo3_api/pyo3_api_utils.rs +++ b/rust/fastsim-core/fastsim-proc-macros/src/add_pyo3_api/pyo3_api_utils.rs @@ -146,13 +146,3 @@ macro_rules! impl_set_body { } }; } - -#[derive(Debug, Default, Clone)] -pub struct FieldOptions { - /// if true, getters are not generated for a field - pub skip_get: bool, - /// if true, setters are not generated for a field - pub skip_set: bool, - /// if true, current field is itself a struct with `orphaned` field - pub field_has_orphaned: bool, -} diff --git a/rust/fastsim-core/src/traits.rs b/rust/fastsim-core/src/traits.rs index 63d1a3e8..8c93c963 100644 --- a/rust/fastsim-core/src/traits.rs +++ b/rust/fastsim-core/src/traits.rs @@ -240,6 +240,7 @@ pub trait SerdeAPI: Serialize + for<'a> Deserialize<'a> { /// Instantiates an object from a url. Accepts yaml and json file types /// # Arguments /// - url: URL (either as a string or url type) to object + /// /// Note: The URL needs to be a URL pointing directly to a file, for example /// a raw github URL. fn from_url>(url: S, skip_init: bool) -> anyhow::Result { diff --git a/rust/fastsim-core/src/vehicle_utils.rs b/rust/fastsim-core/src/vehicle_utils.rs index 6f2c6a2f..8647525d 100644 --- a/rust/fastsim-core/src/vehicle_utils.rs +++ b/rust/fastsim-core/src/vehicle_utils.rs @@ -91,8 +91,7 @@ pub fn abc_to_drag_coeffs( vehicle: veh, dyno_func_lb: &dyno_func_lb, }; - let solver = - NelderMead::new(vec![array![0.0, 0.0], array![0.5, 0.0], array![0.5, 0.1]]); + let solver = NelderMead::new(vec![array![0.0, 0.0], array![0.5, 0.0], array![0.5, 0.1]]); let res = Executor::new(cost, solver) .configure(|state| state.max_iters(100)) .run() @@ -239,8 +238,8 @@ pub struct GitObjectInfo { pub links: Option, } -const VEHICLE_REPO_LIST_URL: &'static str = - &"https://api.github.com/repos/NREL/fastsim-vehicles/contents/public"; +const VEHICLE_REPO_LIST_URL: &str = + "https://api.github.com/repos/NREL/fastsim-vehicles/contents/public"; /// Function that takes a url and calls the url. If a 503 or 429 error is /// thrown, it tries again after a pause, up to four times. It returns either a