[INFO] cloning repository https://github.com/hxse/pyo3-quant [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/hxse/pyo3-quant" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhxse%2Fpyo3-quant", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhxse%2Fpyo3-quant'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] df6bcb681923c06e0171c46856054f161d3c5455 [INFO] checking hxse/pyo3-quant against master#2c0f4860cc86e2354a55ea04e738848168435c90 for pr-149145 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhxse%2Fpyo3-quant" "/workspace/builds/worker-0-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-0-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/hxse/pyo3-quant [INFO] finished tweaking git repo https://github.com/hxse/pyo3-quant [INFO] tweaked toml for git repo https://github.com/hxse/pyo3-quant written to /workspace/builds/worker-0-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/hxse/pyo3-quant on toolchain 2c0f4860cc86e2354a55ea04e738848168435c90 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+2c0f4860cc86e2354a55ea04e738848168435c90" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/hxse/pyo3-quant already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+2c0f4860cc86e2354a55ea04e738848168435c90" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Updating crates.io index [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded pyo3-polars v0.25.0 [INFO] [stderr] Downloaded recursive v0.1.1 [INFO] [stderr] Downloaded recursive-proc-macro-impl v0.1.1 [INFO] [stderr] Downloaded now v0.1.3 [INFO] [stderr] Downloaded array-init-cursor v0.2.1 [INFO] [stderr] Downloaded debug_unsafe v0.1.3 [INFO] [stderr] Downloaded phf_shared v0.12.1 [INFO] [stderr] Downloaded pyo3-macros v0.26.0 [INFO] [stderr] Downloaded atoi_simd v0.16.1 [INFO] [stderr] Downloaded polars-schema v0.52.0 [INFO] [stderr] Downloaded phf v0.12.1 [INFO] [stderr] Downloaded polars-dtype v0.52.0 [INFO] [stderr] Downloaded polars-error v0.52.0 [INFO] [stderr] Downloaded serde_stacker v0.1.14 [INFO] [stderr] Downloaded streaming-decompression v0.1.2 [INFO] [stderr] Downloaded target-lexicon v0.13.3 [INFO] [stderr] Downloaded pyo3-build-config v0.26.0 [INFO] [stderr] Downloaded planus v1.1.1 [INFO] [stderr] Downloaded polars-row v0.52.0 [INFO] [stderr] Downloaded boxcar v0.2.14 [INFO] [stderr] Downloaded fs4 v0.13.1 [INFO] [stderr] Downloaded fast-float2 v0.2.3 [INFO] [stderr] Downloaded polars-mem-engine v0.52.0 [INFO] [stderr] Downloaded polars-parquet-format v0.1.0 [INFO] [stderr] Downloaded polars-arrow-format v0.2.1 [INFO] [stderr] Downloaded argminmax v0.6.3 [INFO] [stderr] Downloaded compact_str v0.9.0 [INFO] [stderr] Downloaded polars-time v0.52.0 [INFO] [stderr] Downloaded polars-lazy v0.52.0 [INFO] [stderr] Downloaded polars-utils v0.52.0 [INFO] [stderr] Downloaded pyo3-macros-backend v0.26.0 [INFO] [stderr] Downloaded pyo3-ffi v0.26.0 [INFO] [stderr] Downloaded polars-expr v0.52.0 [INFO] [stderr] Downloaded polars-compute v0.52.0 [INFO] [stderr] Downloaded polars v0.52.0 [INFO] [stderr] Downloaded polars-io v0.52.0 [INFO] [stderr] Downloaded polars-ops v0.52.0 [INFO] [stderr] Downloaded polars-parquet v0.52.0 [INFO] [stderr] Downloaded quick-xml v0.38.3 [INFO] [stderr] Downloaded polars-stream v0.52.0 [INFO] [stderr] Downloaded polars-arrow v0.52.0 [INFO] [stderr] Downloaded polars-core v0.52.0 [INFO] [stderr] Downloaded polars-plan v0.52.0 [INFO] [stderr] Downloaded chrono-tz v0.10.4 [INFO] [stderr] Downloaded pyo3 v0.26.0 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:94a0c148923f5b2b52a63ef0eeb1882ad339ab61bce784c8077cbe41c61feb6c" "/opt/rustwide/cargo-home/bin/cargo" "+2c0f4860cc86e2354a55ea04e738848168435c90" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] f2349af43f29f1f83959d949005a49ebfec932e152720549d7573176df07b9a8 [INFO] running `Command { std: "docker" "start" "-a" "f2349af43f29f1f83959d949005a49ebfec932e152720549d7573176df07b9a8", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "f2349af43f29f1f83959d949005a49ebfec932e152720549d7573176df07b9a8", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "f2349af43f29f1f83959d949005a49ebfec932e152720549d7573176df07b9a8", kill_on_drop: false }` [INFO] [stdout] f2349af43f29f1f83959d949005a49ebfec932e152720549d7573176df07b9a8 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:94a0c148923f5b2b52a63ef0eeb1882ad339ab61bce784c8077cbe41c61feb6c" "/opt/rustwide/cargo-home/bin/cargo" "+2c0f4860cc86e2354a55ea04e738848168435c90" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] cc6e4fc15c4e339ae539d34cba44f7b3b94d830069e981b4d72f2695515a0ef3 [INFO] running `Command { std: "docker" "start" "-a" "cc6e4fc15c4e339ae539d34cba44f7b3b94d830069e981b4d72f2695515a0ef3", kill_on_drop: false }` [INFO] [stderr] Compiling target-lexicon v0.13.3 [INFO] [stderr] Compiling find-msvc-tools v0.1.4 [INFO] [stderr] Compiling serde_core v1.0.228 [INFO] [stderr] Compiling serde v1.0.228 [INFO] [stderr] Compiling num-traits v0.2.19 [INFO] [stderr] Compiling object v0.32.2 [INFO] [stderr] Checking either v1.15.0 [INFO] [stderr] Compiling syn v2.0.109 [INFO] [stderr] Compiling signal-hook v0.3.18 [INFO] [stderr] Checking regex-automata v0.4.13 [INFO] [stderr] Checking parking_lot_core v0.9.12 [INFO] [stderr] Checking rayon-core v1.13.0 [INFO] [stderr] Compiling slotmap v1.0.7 [INFO] [stderr] Checking unindent v0.2.4 [INFO] [stderr] Checking foldhash v0.2.0 [INFO] [stderr] Checking castaway v0.2.4 [INFO] [stderr] Compiling polars-utils v0.52.0 [INFO] [stderr] Compiling cc v1.2.45 [INFO] [stderr] Checking simdutf8 v0.1.5 [INFO] [stderr] Checking raw-cpuid v11.6.0 [INFO] [stderr] Checking phf_shared v0.12.1 [INFO] [stderr] Checking rayon v1.11.0 [INFO] [stderr] Compiling polars-schema v0.52.0 [INFO] [stderr] Compiling chrono-tz v0.10.4 [INFO] [stderr] Checking phf v0.12.1 [INFO] [stderr] Compiling polars-arrow v0.52.0 [INFO] [stderr] Checking parking_lot v0.12.5 [INFO] [stderr] Compiling typenum v1.19.0 [INFO] [stderr] Checking streaming-iterator v0.1.9 [INFO] [stderr] Checking ethnum v1.5.2 [INFO] [stderr] Compiling generic-array v0.14.9 [INFO] [stderr] Compiling polars-compute v0.52.0 [INFO] [stderr] Checking debug_unsafe v0.1.3 [INFO] [stderr] Checking fast-float2 v0.2.3 [INFO] [stderr] Checking atoi_simd v0.16.1 [INFO] [stderr] Checking boxcar v0.2.14 [INFO] [stderr] Checking strength_reduce v0.2.4 [INFO] [stderr] Compiling pyo3-build-config v0.26.0 [INFO] [stderr] Compiling polars-core v0.52.0 [INFO] [stderr] Checking xxhash-rust v0.8.15 [INFO] [stderr] Compiling polars-ops v0.52.0 [INFO] [stderr] Checking glob v0.3.3 [INFO] [stderr] Compiling polars-expr v0.52.0 [INFO] [stderr] Compiling polars-lazy v0.52.0 [INFO] [stderr] Compiling polars v0.52.0 [INFO] [stderr] Compiling stacker v0.1.22 [INFO] [stderr] Checking chrono v0.4.42 [INFO] [stderr] Checking rand_distr v0.5.1 [INFO] [stderr] Checking argminmax v0.6.3 [INFO] [stderr] Compiling crypto-common v0.1.6 [INFO] [stderr] Compiling block-buffer v0.10.4 [INFO] [stderr] Compiling digest v0.10.7 [INFO] [stderr] Compiling sha2 v0.10.9 [INFO] [stderr] Checking regex v1.12.2 [INFO] [stderr] Compiling polars-plan v0.52.0 [INFO] [stderr] Compiling pyo3-ffi v0.26.0 [INFO] [stderr] Compiling pyo3-macros-backend v0.26.0 [INFO] [stderr] Compiling pyo3 v0.26.0 [INFO] [stderr] Checking now v0.1.3 [INFO] [stderr] Compiling ar_archive_writer v0.2.0 [INFO] [stderr] Compiling psm v0.1.28 [INFO] [stderr] Compiling serde_derive v1.0.228 [INFO] [stderr] Compiling bytemuck_derive v1.10.2 [INFO] [stderr] Compiling strum_macros v0.27.2 [INFO] [stderr] Compiling recursive-proc-macro-impl v0.1.1 [INFO] [stderr] Compiling thiserror-impl v1.0.69 [INFO] [stderr] Compiling thiserror-impl v2.0.17 [INFO] [stderr] Checking recursive v0.1.1 [INFO] [stderr] Checking thiserror v1.0.69 [INFO] [stderr] Checking thiserror v2.0.17 [INFO] [stderr] Checking bytemuck v1.24.0 [INFO] [stderr] Checking hashbrown v0.16.0 [INFO] [stderr] Checking compact_str v0.9.0 [INFO] [stderr] Checking bytes v1.10.1 [INFO] [stderr] Compiling pyo3-macros v0.26.0 [INFO] [stderr] Checking indexmap v2.12.0 [INFO] [stderr] Checking polars-error v0.52.0 [INFO] [stderr] Checking polars-dtype v0.52.0 [INFO] [stderr] Checking polars-row v0.52.0 [INFO] [stderr] Checking polars-io v0.52.0 [INFO] [stderr] Checking polars-time v0.52.0 [INFO] [stderr] Checking polars-mem-engine v0.52.0 [INFO] [stderr] Checking pyo3-polars v0.25.0 [INFO] [stderr] Checking pyo3-quant v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused import: `backtest_error::BacktestError` [INFO] [stdout] --> src/backtest_engine/backtester/mod.rs:2:20 [INFO] [stdout] | [INFO] [stdout] 2 | use crate::error::{backtest_error::BacktestError, QuantError}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `backtest_error::BacktestError` [INFO] [stdout] --> src/backtest_engine/backtester/atr_calculator.rs:3:20 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::error::{backtest_error::BacktestError, QuantError}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `ATRConfig` and `atr_eager` [INFO] [stdout] --> src/backtest_engine/backtester/data_preparer.rs:2:23 [INFO] [stdout] | [INFO] [stdout] 2 | indicators::atr::{atr_eager, ATRConfig}, [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `types::param_set::BacktestParams` [INFO] [stdout] --> src/backtest_engine/backtester/data_preparer.rs:5:30 [INFO] [stdout] | [INFO] [stdout] 5 | use crate::data_conversion::{types::param_set::BacktestParams, DataContainer}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `backtest_error::BacktestError` [INFO] [stdout] --> src/backtest_engine/backtester/data_preparer.rs:6:20 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::error::{backtest_error::BacktestError, QuantError}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::backtest_engine::utils::print_position_debug` [INFO] [stdout] --> src/backtest_engine/backtester/main_loop.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::backtest_engine::utils::print_position_debug; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `data_conversion::BacktestParams` [INFO] [stdout] --> src/backtest_engine/backtester/pause_control/utils.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | data_conversion::BacktestParams, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `current_bar_data::CurrentBarData` [INFO] [stdout] --> src/backtest_engine/backtester/state/risk_trigger/long_exit.rs:2:36 [INFO] [stdout] | [INFO] [stdout] 2 | backtest_state::BacktestState, current_bar_data::CurrentBarData, position_state::Position, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `action::Action`, `capital_state::CapitalState`, `current_bar_data::CurrentBarData`, `position_state::Position`, and `risk_trigger::risk_state::RiskState` [INFO] [stdout] --> src/backtest_engine/backtester/state/mod.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 13 | action::Action, backtest_state::BacktestState, capital_state::CapitalState, [INFO] [stdout] | ^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 14 | current_bar_data::CurrentBarData, position_state::Position, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 15 | risk_trigger::risk_state::RiskState, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `null_when_expr` [INFO] [stdout] --> src/backtest_engine/indicators/adx.rs:7:31 [INFO] [stdout] | [INFO] [stdout] 7 | utils::{null_to_nan_expr, null_when_expr}, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `null_when_expr` [INFO] [stdout] --> src/backtest_engine/indicators/ema.rs:6:31 [INFO] [stdout] | [INFO] [stdout] 6 | utils::{null_to_nan_expr, null_when_expr}, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around assigned value [INFO] [stdout] --> src/backtest_engine/indicators/macd.rs:241:9 [INFO] [stdout] | [INFO] [stdout] 241 | (std::cmp::max(config.fast_period, config.slow_period) + config.signal_period - 2); [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 241 - (std::cmp::max(config.fast_period, config.slow_period) + config.signal_period - 2); [INFO] [stdout] 241 + std::cmp::max(config.fast_period, config.slow_period) + config.signal_period - 2 ; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `null_when_expr` [INFO] [stdout] --> src/backtest_engine/indicators/psar/mod.rs:3:31 [INFO] [stdout] | [INFO] [stdout] 3 | utils::{null_to_nan_expr, null_when_expr}, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `pyo3::prelude::*` [INFO] [stdout] --> src/data_conversion/types/mod.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | use pyo3::prelude::*; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `PyList` [INFO] [stdout] --> src/data_conversion/types/backtest_summary.rs:4:21 [INFO] [stdout] | [INFO] [stdout] 4 | types::{PyDict, PyList}, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `BacktestSummary`, `IndicatorResults`, and `PerformanceMetrics` [INFO] [stdout] --> src/data_conversion/types/mod.rs:14:28 [INFO] [stdout] | [INFO] [stdout] 14 | pub use backtest_summary::{BacktestSummary, IndicatorResults, PerformanceMetrics}; [INFO] [stdout] | ^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `backtest_error::BacktestError` [INFO] [stdout] --> src/backtest_engine/backtester/mod.rs:2:20 [INFO] [stdout] | [INFO] [stdout] 2 | use crate::error::{backtest_error::BacktestError, QuantError}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `backtest_error::BacktestError` [INFO] [stdout] --> src/backtest_engine/backtester/atr_calculator.rs:3:20 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::error::{backtest_error::BacktestError, QuantError}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of deprecated type alias `pyo3::PyObject`: use `Py` instead [INFO] [stdout] --> src/minimal_working_example/calculate_metrics.rs:13:15 [INFO] [stdout] | [INFO] [stdout] 13 | ) -> PyResult { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(deprecated)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `ATRConfig` and `atr_eager` [INFO] [stdout] --> src/backtest_engine/backtester/data_preparer.rs:2:23 [INFO] [stdout] | [INFO] [stdout] 2 | indicators::atr::{atr_eager, ATRConfig}, [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `types::param_set::BacktestParams` [INFO] [stdout] --> src/backtest_engine/backtester/data_preparer.rs:5:30 [INFO] [stdout] | [INFO] [stdout] 5 | use crate::data_conversion::{types::param_set::BacktestParams, DataContainer}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `backtest_error::BacktestError` [INFO] [stdout] --> src/backtest_engine/backtester/data_preparer.rs:6:20 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::error::{backtest_error::BacktestError, QuantError}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::backtest_engine::utils::print_position_debug` [INFO] [stdout] --> src/backtest_engine/backtester/main_loop.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::backtest_engine::utils::print_position_debug; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `data_conversion::BacktestParams` [INFO] [stdout] --> src/backtest_engine/backtester/pause_control/utils.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | data_conversion::BacktestParams, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `current_bar_data::CurrentBarData` [INFO] [stdout] --> src/backtest_engine/backtester/state/risk_trigger/long_exit.rs:2:36 [INFO] [stdout] | [INFO] [stdout] 2 | backtest_state::BacktestState, current_bar_data::CurrentBarData, position_state::Position, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `action::Action`, `capital_state::CapitalState`, `current_bar_data::CurrentBarData`, `position_state::Position`, and `risk_trigger::risk_state::RiskState` [INFO] [stdout] --> src/backtest_engine/backtester/state/mod.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 13 | action::Action, backtest_state::BacktestState, capital_state::CapitalState, [INFO] [stdout] | ^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 14 | current_bar_data::CurrentBarData, position_state::Position, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 15 | risk_trigger::risk_state::RiskState, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `null_when_expr` [INFO] [stdout] --> src/backtest_engine/indicators/adx.rs:7:31 [INFO] [stdout] | [INFO] [stdout] 7 | utils::{null_to_nan_expr, null_when_expr}, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `null_when_expr` [INFO] [stdout] --> src/backtest_engine/indicators/ema.rs:6:31 [INFO] [stdout] | [INFO] [stdout] 6 | utils::{null_to_nan_expr, null_when_expr}, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around assigned value [INFO] [stdout] --> src/backtest_engine/indicators/macd.rs:241:9 [INFO] [stdout] | [INFO] [stdout] 241 | (std::cmp::max(config.fast_period, config.slow_period) + config.signal_period - 2); [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 241 - (std::cmp::max(config.fast_period, config.slow_period) + config.signal_period - 2); [INFO] [stdout] 241 + std::cmp::max(config.fast_period, config.slow_period) + config.signal_period - 2 ; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `null_when_expr` [INFO] [stdout] --> src/backtest_engine/indicators/psar/mod.rs:3:31 [INFO] [stdout] | [INFO] [stdout] 3 | utils::{null_to_nan_expr, null_when_expr}, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `pyo3::prelude::*` [INFO] [stdout] --> src/data_conversion/types/mod.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | use pyo3::prelude::*; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `PyList` [INFO] [stdout] --> src/data_conversion/types/backtest_summary.rs:4:21 [INFO] [stdout] | [INFO] [stdout] 4 | types::{PyDict, PyList}, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `BacktestSummary`, `IndicatorResults`, and `PerformanceMetrics` [INFO] [stdout] --> src/data_conversion/types/mod.rs:14:28 [INFO] [stdout] | [INFO] [stdout] 14 | pub use backtest_summary::{BacktestSummary, IndicatorResults, PerformanceMetrics}; [INFO] [stdout] | ^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of deprecated type alias `pyo3::PyObject`: use `Py` instead [INFO] [stdout] --> src/minimal_working_example/calculate_metrics.rs:13:15 [INFO] [stdout] | [INFO] [stdout] 13 | ) -> PyResult { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(deprecated)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `backtest_df` [INFO] [stdout] --> src/backtest_engine/performance_analyzer/mod.rs:12:5 [INFO] [stdout] | [INFO] [stdout] 12 | backtest_df: &DataFrame, [INFO] [stdout] | ^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_backtest_df` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `backtest_df` [INFO] [stdout] --> src/backtest_engine/performance_analyzer/mod.rs:12:5 [INFO] [stdout] | [INFO] [stdout] 12 | backtest_df: &DataFrame, [INFO] [stdout] | ^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_backtest_df` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `time` and `volume` are never read [INFO] [stdout] --> src/backtest_engine/backtester/state/current_bar_data.rs:8:9 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct CurrentBarData { [INFO] [stdout] | -------------- fields in this struct [INFO] [stdout] 7 | /// 时间戳 [INFO] [stdout] 8 | pub time: i64, [INFO] [stdout] | ^^^^ [INFO] [stdout] ... [INFO] [stdout] 18 | pub volume: f64, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: methods `is_reversal` and `is_hold` are never used [INFO] [stdout] --> src/backtest_engine/backtester/state/position_state.rs:62:12 [INFO] [stdout] | [INFO] [stdout] 25 | impl Position { [INFO] [stdout] | ------------- methods in this implementation [INFO] [stdout] ... [INFO] [stdout] 62 | pub fn is_reversal(&self) -> bool { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 70 | pub fn is_hold(&self) -> bool { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `calc_psar_core` is never used [INFO] [stdout] --> src/backtest_engine/indicators/psar/psar_core.rs:193:15 [INFO] [stdout] | [INFO] [stdout] 193 | pub(crate) fn calc_psar_core( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `print_position_debug` is never used [INFO] [stdout] --> src/backtest_engine/utils/position_debug.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn print_position_debug(state: &BacktestState, index: usize) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `skip_mask` is never read [INFO] [stdout] --> src/data_conversion/types/data_dict.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 9 | pub struct DataContainer { [INFO] [stdout] | ------------- field in this struct [INFO] [stdout] 10 | pub mapping: DataFrame, [INFO] [stdout] 11 | pub skip_mask: Option, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `DataContainer` has a derived impl for the trait `Clone`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: multiple fields are never read [INFO] [stdout] --> src/data_conversion/types/param.rs:8:9 [INFO] [stdout] | [INFO] [stdout] 4 | pub struct Param { [INFO] [stdout] | ----- fields in this struct [INFO] [stdout] ... [INFO] [stdout] 8 | pub initial_value: f64, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 9 | /// 参数最小值限制 [INFO] [stdout] 10 | pub min: f64, [INFO] [stdout] | ^^^ [INFO] [stdout] 11 | /// 参数初始最小值,用于重置或恢复默认配置 [INFO] [stdout] 12 | pub initial_min: f64, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 13 | /// 参数最大值限制 [INFO] [stdout] 14 | pub max: f64, [INFO] [stdout] | ^^^ [INFO] [stdout] 15 | /// 参数初始最大值,用于重置或恢复默认配置 [INFO] [stdout] 16 | pub initial_max: f64, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 17 | /// 参数步长,用于优化时的增量调整 [INFO] [stdout] 18 | pub step: f64, [INFO] [stdout] | ^^^^ [INFO] [stdout] 19 | /// 参数初始步长,用于重置或恢复默认配置 [INFO] [stdout] 20 | pub initial_step: f64, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] 21 | /// 是否开启参数优化,在参数优化过程中使用 [INFO] [stdout] 22 | pub optimize: bool, [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] 23 | /// 是否开启对数分布,用于参数优化时的采样策略 [INFO] [stdout] 24 | pub log_scale: bool, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Param` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `tsl_per_bar_update` is never read [INFO] [stdout] --> src/data_conversion/types/param_set.rs:78:9 [INFO] [stdout] | [INFO] [stdout] 45 | pub struct BacktestParams { [INFO] [stdout] | -------------- field in this struct [INFO] [stdout] ... [INFO] [stdout] 78 | pub tsl_per_bar_update: bool, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `BacktestParams` has derived impls for the traits `Debug` and `Clone`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `has_any_pct_param` is never used [INFO] [stdout] --> src/data_conversion/types/param_set.rs:135:12 [INFO] [stdout] | [INFO] [stdout] 109 | impl BacktestParams { [INFO] [stdout] | ------------------- method in this implementation [INFO] [stdout] ... [INFO] [stdout] 135 | pub fn has_any_pct_param(&self) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `name` is never read [INFO] [stdout] --> src/data_conversion/types/templates.rs:111:9 [INFO] [stdout] | [INFO] [stdout] 110 | pub struct SignalTemplate { [INFO] [stdout] | -------------- field in this struct [INFO] [stdout] 111 | pub name: String, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `SignalTemplate` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `time` and `volume` are never read [INFO] [stdout] --> src/backtest_engine/backtester/state/current_bar_data.rs:8:9 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct CurrentBarData { [INFO] [stdout] | -------------- fields in this struct [INFO] [stdout] 7 | /// 时间戳 [INFO] [stdout] 8 | pub time: i64, [INFO] [stdout] | ^^^^ [INFO] [stdout] ... [INFO] [stdout] 18 | pub volume: f64, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: methods `is_reversal` and `is_hold` are never used [INFO] [stdout] --> src/backtest_engine/backtester/state/position_state.rs:62:12 [INFO] [stdout] | [INFO] [stdout] 25 | impl Position { [INFO] [stdout] | ------------- methods in this implementation [INFO] [stdout] ... [INFO] [stdout] 62 | pub fn is_reversal(&self) -> bool { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 70 | pub fn is_hold(&self) -> bool { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `calc_psar_core` is never used [INFO] [stdout] --> src/backtest_engine/indicators/psar/psar_core.rs:193:15 [INFO] [stdout] | [INFO] [stdout] 193 | pub(crate) fn calc_psar_core( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `print_position_debug` is never used [INFO] [stdout] --> src/backtest_engine/utils/position_debug.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn print_position_debug(state: &BacktestState, index: usize) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `skip_mask` is never read [INFO] [stdout] --> src/data_conversion/types/data_dict.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 9 | pub struct DataContainer { [INFO] [stdout] | ------------- field in this struct [INFO] [stdout] 10 | pub mapping: DataFrame, [INFO] [stdout] 11 | pub skip_mask: Option, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `DataContainer` has a derived impl for the trait `Clone`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: multiple fields are never read [INFO] [stdout] --> src/data_conversion/types/param.rs:8:9 [INFO] [stdout] | [INFO] [stdout] 4 | pub struct Param { [INFO] [stdout] | ----- fields in this struct [INFO] [stdout] ... [INFO] [stdout] 8 | pub initial_value: f64, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 9 | /// 参数最小值限制 [INFO] [stdout] 10 | pub min: f64, [INFO] [stdout] | ^^^ [INFO] [stdout] 11 | /// 参数初始最小值,用于重置或恢复默认配置 [INFO] [stdout] 12 | pub initial_min: f64, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 13 | /// 参数最大值限制 [INFO] [stdout] 14 | pub max: f64, [INFO] [stdout] | ^^^ [INFO] [stdout] 15 | /// 参数初始最大值,用于重置或恢复默认配置 [INFO] [stdout] 16 | pub initial_max: f64, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 17 | /// 参数步长,用于优化时的增量调整 [INFO] [stdout] 18 | pub step: f64, [INFO] [stdout] | ^^^^ [INFO] [stdout] 19 | /// 参数初始步长,用于重置或恢复默认配置 [INFO] [stdout] 20 | pub initial_step: f64, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] 21 | /// 是否开启参数优化,在参数优化过程中使用 [INFO] [stdout] 22 | pub optimize: bool, [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] 23 | /// 是否开启对数分布,用于参数优化时的采样策略 [INFO] [stdout] 24 | pub log_scale: bool, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Param` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `tsl_per_bar_update` is never read [INFO] [stdout] --> src/data_conversion/types/param_set.rs:78:9 [INFO] [stdout] | [INFO] [stdout] 45 | pub struct BacktestParams { [INFO] [stdout] | -------------- field in this struct [INFO] [stdout] ... [INFO] [stdout] 78 | pub tsl_per_bar_update: bool, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `BacktestParams` has derived impls for the traits `Debug` and `Clone`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `has_any_pct_param` is never used [INFO] [stdout] --> src/data_conversion/types/param_set.rs:135:12 [INFO] [stdout] | [INFO] [stdout] 109 | impl BacktestParams { [INFO] [stdout] | ------------------- method in this implementation [INFO] [stdout] ... [INFO] [stdout] 135 | pub fn has_any_pct_param(&self) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `name` is never read [INFO] [stdout] --> src/data_conversion/types/templates.rs:111:9 [INFO] [stdout] | [INFO] [stdout] 110 | pub struct SignalTemplate { [INFO] [stdout] | -------------- field in this struct [INFO] [stdout] 111 | pub name: String, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `SignalTemplate` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 1m 11s [INFO] running `Command { std: "docker" "inspect" "cc6e4fc15c4e339ae539d34cba44f7b3b94d830069e981b4d72f2695515a0ef3", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "cc6e4fc15c4e339ae539d34cba44f7b3b94d830069e981b4d72f2695515a0ef3", kill_on_drop: false }` [INFO] [stdout] cc6e4fc15c4e339ae539d34cba44f7b3b94d830069e981b4d72f2695515a0ef3