[INFO] cloning repository https://github.com/amplidex-labs/amplidex-protocol [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/amplidex-labs/amplidex-protocol" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Famplidex-labs%2Famplidex-protocol", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Famplidex-labs%2Famplidex-protocol'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 1a425ed87c5284ae766aa57cb2e59c3e962cc3ce [INFO] checking amplidex-labs/amplidex-protocol against ba28ff76f353a722f31c4f3dd2ac4e437d36411b for pr-160780 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Famplidex-labs%2Famplidex-protocol" "/workspace/builds/worker-4-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/amplidex-labs/amplidex-protocol [INFO] finished tweaking git repo https://github.com/amplidex-labs/amplidex-protocol [INFO] tweaked toml for git repo https://github.com/amplidex-labs/amplidex-protocol written to /workspace/builds/worker-4-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/amplidex-labs/amplidex-protocol on toolchain ba28ff76f353a722f31c4f3dd2ac4e437d36411b [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ba28ff76f353a722f31c4f3dd2ac4e437d36411b" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/amplidex-labs/amplidex-protocol 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" "+ba28ff76f353a722f31c4f3dd2ac4e437d36411b" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded visibility v0.1.1 [INFO] [stderr] Downloaded crate-git-revision v0.0.6 [INFO] [stderr] Downloaded time-core v0.1.9 [INFO] [stderr] Downloaded ref-cast v1.0.27 [INFO] [stderr] Downloaded escape-bytes v0.1.1 [INFO] [stderr] Downloaded keccak v0.1.6 [INFO] [stderr] Downloaded defmt-parser v1.0.0 [INFO] [stderr] Downloaded darling_macro v0.23.0 [INFO] [stderr] Downloaded soroban-builtin-sdk-macros v25.0.1 [INFO] [stderr] Downloaded jiff-static v0.2.35 [INFO] [stderr] Downloaded num-conv v0.2.2 [INFO] [stderr] Downloaded hex-literal v0.4.1 [INFO] [stderr] Downloaded ref-cast-impl v1.0.27 [INFO] [stderr] Downloaded darling_macro v0.20.11 [INFO] [stderr] Downloaded macro-string v0.1.4 [INFO] [stderr] Downloaded wasmi_arena v0.4.1 [INFO] [stderr] Downloaded soroban-spec v25.3.2 [INFO] [stderr] Downloaded zeroize_derive v1.5.0 [INFO] [stderr] Downloaded indexmap-nostd v0.4.0 [INFO] [stderr] Downloaded soroban-env-guest v25.0.1 [INFO] [stderr] Downloaded bytes-lit v0.0.5 [INFO] [stderr] Downloaded wasmi_core v0.13.0 [INFO] [stderr] Downloaded stellar-strkey v0.0.13 [INFO] [stderr] Downloaded defmt-macros v1.1.1 [INFO] [stderr] Downloaded serde_with_macros v3.22.0 [INFO] [stderr] Downloaded primeorder v0.13.6 [INFO] [stderr] Downloaded stellar-strkey v0.0.16 [INFO] [stderr] Downloaded time-macros v0.2.32 [INFO] [stderr] Downloaded soroban-sdk-macros v25.3.1 [INFO] [stderr] Downloaded darling v0.23.0 [INFO] [stderr] Downloaded defmt v1.1.1 [INFO] [stderr] Downloaded soroban-env-macros v25.0.1 [INFO] [stderr] Downloaded darling v0.20.11 [INFO] [stderr] Downloaded soroban-sdk v25.3.1 [INFO] [stderr] Downloaded soroban-spec-rust v25.3.2 [INFO] [stderr] Downloaded jiff-tzdb v0.1.8 [INFO] [stderr] Downloaded find-msvc-tools v0.1.11 [INFO] [stderr] Downloaded ethnum v1.5.3 [INFO] [stderr] Downloaded soroban-env-common v25.0.1 [INFO] [stderr] Downloaded darling_core v0.20.11 [INFO] [stderr] Downloaded p256 v0.13.2 [INFO] [stderr] Downloaded base64ct v1.8.3 [INFO] [stderr] Downloaded darling_core v0.23.0 [INFO] [stderr] Downloaded schemars v1.2.2 [INFO] [stderr] Downloaded schemars v0.9.0 [INFO] [stderr] Downloaded portable-atomic-util v0.2.7 [INFO] [stderr] Downloaded indexmap v1.9.3 [INFO] [stderr] Downloaded indexmap v2.14.1 [INFO] [stderr] Downloaded cc v1.4.4 [INFO] [stderr] Downloaded soroban-wasmi v0.31.1-soroban.20.0.1 [INFO] [stderr] Downloaded jiff-core v0.1.0 [INFO] [stderr] Downloaded wasmparser-nostd v0.100.2 [INFO] [stderr] Downloaded libm v0.2.16 [INFO] [stderr] Downloaded wasmparser v0.116.1 [INFO] [stderr] Downloaded serde_with v3.22.0 [INFO] [stderr] Downloaded time v0.3.55 [INFO] [stderr] Downloaded syn v3.0.4 [INFO] [stderr] Downloaded curve25519-dalek v5.0.0 [INFO] [stderr] Downloaded ark-bls12-381 v0.4.0 [INFO] [stderr] Downloaded fiat-crypto v0.3.0 [INFO] [stderr] Downloaded soroban-env-host v25.0.1 [INFO] [stderr] Downloaded jiff v0.2.35 [INFO] [stderr] Downloaded sha3 v0.10.9 [INFO] [stderr] Downloaded stellar-xdr v25.0.0 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,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" "-m" "1610612736" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:8683fc1fc2eb5c9ac98e0d076ab094b2ffac7f99da555d2b6a2e27f346de2ec7" "sleep" "infinity", kill_on_drop: false }` [INFO] [stdout] 989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd [INFO] running `Command { std: "docker" "start" "989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd", kill_on_drop: false }` [INFO] running `Command { std: "docker" "exec" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-w" "/opt/rustwide/workdir" "--user" "0:0" "989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd" "/opt/rustwide/cargo-home/bin/cargo" "+ba28ff76f353a722f31c4f3dd2ac4e437d36411b" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd", kill_on_drop: false }` [INFO] running `Command { std: "docker" "exec" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-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" "-w" "/opt/rustwide/workdir" "--user" "0:0" "989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd" "/opt/rustwide/cargo-home/bin/cargo" "+ba28ff76f353a722f31c4f3dd2ac4e437d36411b" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stderr] Compiling proc-macro2 v1.0.107 [INFO] [stderr] Compiling quote v1.0.47 [INFO] [stderr] Compiling unicode-ident v1.0.24 [INFO] [stderr] Compiling serde_core v1.0.229 [INFO] [stderr] Compiling zmij v1.0.23 [INFO] [stderr] Compiling serde v1.0.229 [INFO] [stderr] Checking typenum v1.20.1 [INFO] [stderr] Compiling serde_json v1.0.151 [INFO] [stderr] Compiling memchr v2.8.3 [INFO] [stderr] Compiling itoa v1.0.18 [INFO] [stderr] Checking subtle v2.6.1 [INFO] [stderr] Compiling autocfg v1.5.1 [INFO] [stderr] Compiling libc v0.2.189 [INFO] [stderr] Compiling zerocopy v0.8.56 [INFO] [stderr] Compiling semver v1.0.28 [INFO] [stderr] Compiling generic-array v0.14.9 [INFO] [stderr] Compiling paste v1.0.15 [INFO] [stderr] Compiling schemars v0.8.22 [INFO] [stderr] Compiling dyn-clone v1.0.20 [INFO] [stderr] Compiling rustc_version v0.4.1 [INFO] [stderr] Compiling data-encoding v2.11.1 [INFO] [stderr] Compiling ahash v0.8.12 [INFO] [stderr] Compiling escape-bytes v0.1.1 [INFO] [stderr] Compiling ethnum v1.5.3 [INFO] [stderr] Checking once_cell v1.21.4 [INFO] [stderr] Checking base16ct v0.2.0 [INFO] [stderr] Checking either v1.18.0 [INFO] [stderr] Compiling libm v0.2.16 [INFO] [stderr] Compiling num-traits v0.2.19 [INFO] [stderr] Checking itertools v0.10.5 [INFO] [stderr] Compiling hashbrown v0.17.1 [INFO] [stderr] Compiling syn v2.0.119 [INFO] [stderr] Compiling syn v3.0.4 [INFO] [stderr] Compiling syn v1.0.109 [INFO] [stderr] Compiling thiserror v1.0.69 [INFO] [stderr] Compiling curve25519-dalek v4.1.3 [INFO] [stderr] Checking hybrid-array v0.4.14 [INFO] [stderr] Compiling indexmap v2.14.1 [INFO] [stderr] Compiling prettyplease v0.2.37 [INFO] [stderr] Checking indexmap-nostd v0.4.0 [INFO] [stderr] Checking downcast-rs v1.2.1 [INFO] [stderr] Compiling curve25519-dalek v5.0.0 [INFO] [stderr] Compiling num-integer v0.1.47 [INFO] [stderr] Checking wasmparser-nostd v0.100.2 [INFO] [stderr] Compiling num-bigint v0.4.8 [INFO] [stderr] Checking smallvec v1.16.0 [INFO] [stderr] Compiling crypto-common v0.1.6 [INFO] [stderr] Checking getrandom v0.2.17 [INFO] [stderr] Compiling block-buffer v0.10.4 [INFO] [stderr] Checking byteorder v1.5.0 [INFO] [stderr] Compiling digest v0.10.7 [INFO] [stderr] Compiling sha2 v0.10.9 [INFO] [stderr] Checking wasmi_core v0.13.0 [INFO] [stderr] Checking rand_core v0.6.4 [INFO] [stderr] Compiling wasmparser v0.116.1 [INFO] [stderr] Checking ff v0.13.1 [INFO] [stderr] Checking block-buffer v0.12.1 [INFO] [stderr] Checking crypto-common v0.2.2 [INFO] [stderr] Checking group v0.13.0 [INFO] [stderr] Checking wasmi_arena v0.4.1 [INFO] [stderr] Checking spin v0.9.9 [INFO] [stderr] Compiling heapless v0.8.0 [INFO] [stderr] Compiling base64 v0.22.1 [INFO] [stderr] Checking hash32 v0.3.1 [INFO] [stderr] Checking cpufeatures v0.3.1 [INFO] [stderr] Checking stable_deref_trait v1.2.1 [INFO] [stderr] Checking keccak v0.1.6 [INFO] [stderr] Compiling soroban-env-host v25.0.1 [INFO] [stderr] Checking hex-literal v0.4.1 [INFO] [stderr] Checking digest v0.11.3 [INFO] [stderr] Compiling serde_derive v1.0.229 [INFO] [stderr] Checking soroban-wasmi v0.31.1-soroban.20.0.1 [INFO] [stderr] Checking ppv-lite86 v0.2.21 [INFO] [stderr] Checking hashbrown v0.13.2 [INFO] [stderr] Checking rand_chacha v0.3.1 [INFO] [stderr] Checking rand v0.8.8 [INFO] [stderr] Compiling darling_core v0.23.0 [INFO] [stderr] Compiling darling_core v0.20.11 [INFO] [stderr] Compiling macro-string v0.1.4 [INFO] [stderr] Checking ark-std v0.4.0 [INFO] [stderr] Compiling ark-serialize-derive v0.4.2 [INFO] [stderr] Compiling ark-ff-asm v0.4.2 [INFO] [stderr] Compiling derivative v2.2.0 [INFO] [stderr] Compiling ark-ff-macros v0.4.2 [INFO] [stderr] Compiling zeroize_derive v1.5.0 [INFO] [stderr] Compiling cfg_eval v0.1.2 [INFO] [stderr] Compiling num-derive v0.4.2 [INFO] [stderr] Compiling thiserror-impl v1.0.69 [INFO] [stderr] Compiling curve25519-dalek-derive v0.1.1 [INFO] [stderr] Compiling soroban-builtin-sdk-macros v25.0.1 [INFO] [stderr] Checking zeroize v1.9.0 [INFO] [stderr] Compiling bytes-lit v0.0.5 [INFO] [stderr] Checking der v0.7.10 [INFO] [stderr] Compiling visibility v0.1.1 [INFO] [stderr] Checking crypto-bigint v0.5.5 [INFO] [stderr] Checking sec1 v0.7.3 [INFO] [stderr] Checking signature v2.2.0 [INFO] [stderr] Checking ark-serialize v0.4.2 [INFO] [stderr] Checking hmac v0.12.1 [INFO] [stderr] Checking sha3 v0.10.9 [INFO] [stderr] Checking ed25519 v2.2.3 [INFO] [stderr] Checking ark-ff v0.4.2 [INFO] [stderr] Checking rfc6979 v0.4.0 [INFO] [stderr] Compiling darling_macro v0.20.11 [INFO] [stderr] Compiling crate-git-revision v0.0.6 [INFO] [stderr] Compiling hex v0.4.3 [INFO] [stderr] Compiling stellar-strkey v0.0.13 [INFO] [stderr] Compiling stellar-xdr v25.0.0 [INFO] [stderr] Compiling soroban-env-common v25.0.1 [INFO] [stderr] Compiling stellar-strkey v0.0.16 [INFO] [stderr] Compiling soroban-sdk v25.3.1 [INFO] [stderr] Compiling darling v0.20.11 [INFO] [stderr] Checking ed25519-dalek v2.2.0 [INFO] [stderr] Compiling darling_macro v0.23.0 [INFO] [stderr] Checking elliptic-curve v0.13.8 [INFO] [stderr] Compiling darling v0.23.0 [INFO] [stderr] Compiling serde_with_macros v3.22.0 [INFO] [stderr] Checking ecdsa v0.16.9 [INFO] [stderr] Checking primeorder v0.13.6 [INFO] [stderr] Checking k256 v0.13.4 [INFO] [stderr] Checking p256 v0.13.2 [INFO] [stderr] Compiling serde_with v3.22.0 [INFO] [stderr] Checking ark-poly v0.4.2 [INFO] [stderr] Checking ark-ec v0.4.2 [INFO] [stderr] Checking ark-bn254 v0.4.0 [INFO] [stderr] Checking ark-bls12-381 v0.4.0 [INFO] [stderr] Compiling soroban-spec v25.3.2 [INFO] [stderr] Compiling soroban-spec-rust v25.3.2 [INFO] [stderr] Compiling soroban-env-macros v25.0.1 [INFO] [stderr] Compiling soroban-sdk-macros v25.3.1 [INFO] [stderr] Checking amplifi-protocol v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: function `estimate_exact_in` is never used [INFO] [stdout] --> src/aquarius.rs:39:8 [INFO] [stdout] | [INFO] [stdout] 39 | pub fn estimate_exact_in( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `estimate_exact_out` is never used [INFO] [stdout] --> src/aquarius.rs:56:8 [INFO] [stdout] | [INFO] [stdout] 56 | pub fn estimate_exact_out( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `authorize_pool_swap_exact_in` is never used [INFO] [stdout] --> src/aquarius.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | pub fn authorize_pool_swap_exact_in( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `authorize_pool_swap_exact_out` is never used [INFO] [stdout] --> src/aquarius.rs:118:8 [INFO] [stdout] | [INFO] [stdout] 118 | pub fn authorize_pool_swap_exact_out( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `swap_exact_in` is never used [INFO] [stdout] --> src/aquarius.rs:163:8 [INFO] [stdout] | [INFO] [stdout] 163 | pub fn swap_exact_in( [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `swap_exact_out` is never used [INFO] [stdout] --> src/aquarius.rs:208:8 [INFO] [stdout] | [INFO] [stdout] 208 | pub fn swap_exact_out( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `ensure_pool_operational` is never used [INFO] [stdout] --> src/aquarius.rs:259:8 [INFO] [stdout] | [INFO] [stdout] 259 | pub fn ensure_pool_operational(env: &Env, market: &MarketConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `BPS` is never used [INFO] [stdout] --> src/constants.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | pub const BPS: i128 = 10_000; [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `YEAR_SECS` is never used [INFO] [stdout] --> src/constants.rs:2:11 [INFO] [stdout] | [INFO] [stdout] 2 | pub const YEAR_SECS: i128 = 31_536_000; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `HOURS_PER_YEAR` is never used [INFO] [stdout] --> src/constants.rs:3:11 [INFO] [stdout] | [INFO] [stdout] 3 | pub const HOURS_PER_YEAR: i128 = 8_760; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `DAYS_PER_YEAR` is never used [INFO] [stdout] --> src/constants.rs:4:11 [INFO] [stdout] | [INFO] [stdout] 4 | pub const DAYS_PER_YEAR: i128 = 365; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `RATE_SCALE` is never used [INFO] [stdout] --> src/constants.rs:5:11 [INFO] [stdout] | [INFO] [stdout] 5 | pub const RATE_SCALE: i128 = 1_000_000_000_000; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `INDEX_SCALE` is never used [INFO] [stdout] --> src/constants.rs:6:11 [INFO] [stdout] | [INFO] [stdout] 6 | pub const INDEX_SCALE: i128 = 1_000_000_000_000; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `MAX_KEEPER_INSPECTIONS` is never used [INFO] [stdout] --> src/constants.rs:7:11 [INFO] [stdout] | [INFO] [stdout] 7 | pub const MAX_KEEPER_INSPECTIONS: u32 = 50; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `TTL_RENEW_THRESHOLD` is never used [INFO] [stdout] --> src/constants.rs:12:11 [INFO] [stdout] | [INFO] [stdout] 12 | pub const TTL_RENEW_THRESHOLD: u32 = 120_960; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `TTL_EXTEND_TO` is never used [INFO] [stdout] --> src/constants.rs:13:11 [INFO] [stdout] | [INFO] [stdout] 13 | pub const TTL_EXTEND_TO: u32 = 518_400; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `AmpliFiProtocol` is never constructed [INFO] [stdout] --> src/contract.rs:41:12 [INFO] [stdout] | [INFO] [stdout] 41 | pub struct AmpliFiProtocol; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: multiple associated functions are never used [INFO] [stdout] --> src/contract.rs:78:12 [INFO] [stdout] | [INFO] [stdout] 44 | impl AmpliFiProtocol { [INFO] [stdout] | -------------------- associated functions in this implementation [INFO] [stdout] ... [INFO] [stdout] 78 | pub fn set_paused(env: Env, paused: bool) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 87 | pub fn set_market(env: Env, market: MarketConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 135 | pub fn set_market_enabled(env: Env, asset: Address, enabled: bool) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 147 | pub fn set_interest_rate_config( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 165 | pub fn upgrade(env: Env, wasm_hash: BytesN<32>) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 172 | pub fn deposit_liquidity( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 216 | pub fn withdraw_liquidity( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 256 | pub fn open_long( [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 442 | pub fn open_short( [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 624 | pub fn add_margin( [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 698 | pub fn close_position( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 723 | pub fn execute_liquidation(env: Env, keeper: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 808 | pub fn get_position_states(env: Env) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 871 | pub fn get_global_config(env: Env) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 875 | pub fn get_market(env: Env, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 879 | pub fn get_open_position( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 888 | pub fn get_position(env: Env, id: u64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 892 | pub fn get_risk(env: Env, id: u64) -> Result { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 897 | pub fn get_interest_rate_config(env: Env, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 903 | pub fn get_borrow_rate(env: Env, asset: Address, side: Side) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 928 | pub fn get_lp_shares(env: Env, lp: Address, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 938 | pub fn get_lp_position(env: Env, lp: Address, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 974 | pub fn preview_position(env: Env, id: u64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 979 | pub fn preview_add_margin( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 1014 | pub fn get_pool(env: Env, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `settle_liquidation` is never used [INFO] [stdout] --> src/contract.rs:1021:4 [INFO] [stdout] | [INFO] [stdout] 1021 | fn settle_liquidation(env: &Env, mut p: Position, keeper: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `settle_user_close` is never used [INFO] [stdout] --> src/contract.rs:1215:4 [INFO] [stdout] | [INFO] [stdout] 1215 | fn settle_user_close( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `risk_at` is never used [INFO] [stdout] --> src/contract.rs:1431:4 [INFO] [stdout] | [INFO] [stdout] 1431 | fn risk_at(env: &Env, p: &Position) -> Result { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `preview_position_at` is never used [INFO] [stdout] --> src/contract.rs:1534:4 [INFO] [stdout] | [INFO] [stdout] 1534 | fn preview_position_at(env: &Env, p: &Position) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_market` is never used [INFO] [stdout] --> src/contract.rs:1631:4 [INFO] [stdout] | [INFO] [stdout] 1631 | fn validate_market(env: &Env, cfg: &GlobalConfig, market: &MarketConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_global_config` is never used [INFO] [stdout] --> src/contract.rs:1659:4 [INFO] [stdout] | [INFO] [stdout] 1659 | fn validate_global_config(c: &GlobalConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_open` is never used [INFO] [stdout] --> src/contract.rs:1666:4 [INFO] [stdout] | [INFO] [stdout] 1666 | fn validate_open(market: &MarketConfig, collateral: i128, leverage_bps: u32) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `OpenPositionEvent` is never constructed [INFO] [stdout] --> src/events.rs:6:12 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct OpenPositionEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `ClosePositionEvent` is never constructed [INFO] [stdout] --> src/events.rs:15:12 [INFO] [stdout] | [INFO] [stdout] 15 | pub struct ClosePositionEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `AddMarginEvent` is never constructed [INFO] [stdout] --> src/events.rs:26:12 [INFO] [stdout] | [INFO] [stdout] 26 | pub struct AddMarginEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `PositionLiquidationEvent` is never constructed [INFO] [stdout] --> src/events.rs:33:12 [INFO] [stdout] | [INFO] [stdout] 33 | pub struct PositionLiquidationEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `LiquidityDepositEvent` is never constructed [INFO] [stdout] --> src/events.rs:38:12 [INFO] [stdout] | [INFO] [stdout] 38 | pub struct LiquidityDepositEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `LiquidityWithdrawalEvent` is never constructed [INFO] [stdout] --> src/events.rs:46:12 [INFO] [stdout] | [INFO] [stdout] 46 | pub struct LiquidityWithdrawalEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `borrowed_asset_for_side` is never used [INFO] [stdout] --> src/interest.rs:11:8 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn borrowed_asset_for_side(cfg: &GlobalConfig, p: &Position) -> Address { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `scaled_borrow_amount` is never used [INFO] [stdout] --> src/interest.rs:18:8 [INFO] [stdout] | [INFO] [stdout] 18 | pub fn scaled_borrow_amount(amount: i128, borrow_index: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `position_debt` is never used [INFO] [stdout] --> src/interest.rs:24:8 [INFO] [stdout] | [INFO] [stdout] 24 | pub fn position_debt(pool: &PoolState, borrow_scaled: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `default_interest_rate_config` is never used [INFO] [stdout] --> src/interest.rs:31:8 [INFO] [stdout] | [INFO] [stdout] 31 | pub fn default_interest_rate_config() -> InterestRateConfig { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_interest_rate_config` is never used [INFO] [stdout] --> src/interest.rs:42:8 [INFO] [stdout] | [INFO] [stdout] 42 | pub fn validate_interest_rate_config(rate: &InterestRateConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `utilization_bps` is never used [INFO] [stdout] --> src/interest.rs:57:8 [INFO] [stdout] | [INFO] [stdout] 57 | pub fn utilization_bps(pool: &PoolState) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `borrow_apr_bps_for_utilization` is never used [INFO] [stdout] --> src/interest.rs:64:8 [INFO] [stdout] | [INFO] [stdout] 64 | pub fn borrow_apr_bps_for_utilization( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `project_pool_to_timestamp` is never used [INFO] [stdout] --> src/interest.rs:93:8 [INFO] [stdout] | [INFO] [stdout] 93 | pub fn project_pool_to_timestamp( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `projected_pool` is never used [INFO] [stdout] --> src/interest.rs:130:8 [INFO] [stdout] | [INFO] [stdout] 130 | pub fn projected_pool(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `accrue_pool` is never used [INFO] [stdout] --> src/interest.rs:136:8 [INFO] [stdout] | [INFO] [stdout] 136 | pub fn accrue_pool(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `available_liquidity` is never used [INFO] [stdout] --> src/interest.rs:142:8 [INFO] [stdout] | [INFO] [stdout] 142 | pub fn available_liquidity(pool: &PoolState) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `ensure_borrow_capacity` is never used [INFO] [stdout] --> src/interest.rs:146:8 [INFO] [stdout] | [INFO] [stdout] 146 | pub fn ensure_borrow_capacity( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `require_positive` is never used [INFO] [stdout] --> src/math.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn require_positive(value: i128) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `checked_add` is never used [INFO] [stdout] --> src/math.rs:11:8 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn checked_add(a: i128, b: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `checked_sub` is never used [INFO] [stdout] --> src/math.rs:15:8 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn checked_sub(a: i128, b: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `mul_div` is never used [INFO] [stdout] --> src/math.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn mul_div(a: i128, b: i128, denominator: i128) -> Result { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `mul_div_round_up` is never used [INFO] [stdout] --> src/math.rs:29:8 [INFO] [stdout] | [INFO] [stdout] 29 | pub fn mul_div_round_up(a: i128, b: i128, denominator: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bps` is never used [INFO] [stdout] --> src/math.rs:46:8 [INFO] [stdout] | [INFO] [stdout] 46 | pub fn bps(value: i128, bps_value: u32) -> Result { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `apply_negative_bps` is never used [INFO] [stdout] --> src/math.rs:50:8 [INFO] [stdout] | [INFO] [stdout] 50 | pub fn apply_negative_bps(value: i128, bps_value: u32) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `apply_positive_bps` is never used [INFO] [stdout] --> src/math.rs:54:8 [INFO] [stdout] | [INFO] [stdout] 54 | pub fn apply_positive_bps(value: i128, bps_value: u32) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `min_i128` is never used [INFO] [stdout] --> src/math.rs:58:8 [INFO] [stdout] | [INFO] [stdout] 58 | pub fn min_i128(a: i128, b: i128) -> i128 { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `non_negative` is never used [INFO] [stdout] --> src/math.rs:66:8 [INFO] [stdout] | [INFO] [stdout] 66 | pub fn non_negative(value: i128) -> i128 { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `signed_equity` is never used [INFO] [stdout] --> src/math.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | pub fn signed_equity(assets: i128, obligations: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `i128_to_u32` is never used [INFO] [stdout] --> src/math.rs:78:8 [INFO] [stdout] | [INFO] [stdout] 78 | pub fn i128_to_u32(value: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `value_asset_usdc` is never used [INFO] [stdout] --> src/position.rs:8:8 [INFO] [stdout] | [INFO] [stdout] 8 | pub fn value_asset_usdc(amount: i128, price: i128, market: &MarketConfig) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_close_bps` is never used [INFO] [stdout] --> src/position.rs:15:8 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn validate_close_bps(close_bps: u32) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `proportional_close_amount` is never used [INFO] [stdout] --> src/position.rs:22:8 [INFO] [stdout] | [INFO] [stdout] 22 | pub fn proportional_close_amount(amount: i128, close_bps: u32) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `proportional_amount_allow_zero` is never used [INFO] [stdout] --> src/position.rs:35:8 [INFO] [stdout] | [INFO] [stdout] 35 | pub fn proportional_amount_allow_zero(amount: i128, close_bps: u32) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `effective_price_from_exact_in` is never used [INFO] [stdout] --> src/position.rs:53:8 [INFO] [stdout] | [INFO] [stdout] 53 | pub fn effective_price_from_exact_in( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `long_effective_leverage_bps` is never used [INFO] [stdout] --> src/position.rs:64:8 [INFO] [stdout] | [INFO] [stdout] 64 | pub fn long_effective_leverage_bps( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `short_entry_notional_usdc` is never used [INFO] [stdout] --> src/position.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | pub fn short_entry_notional_usdc( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `short_effective_leverage_bps` is never used [INFO] [stdout] --> src/position.rs:85:8 [INFO] [stdout] | [INFO] [stdout] 85 | pub fn short_effective_leverage_bps( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bump_instance_ttl` is never used [INFO] [stdout] --> src/storage.rs:11:8 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn bump_instance_ttl(env: &Env) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bump_persistent_ttl` is never used [INFO] [stdout] --> src/storage.rs:17:8 [INFO] [stdout] | [INFO] [stdout] 17 | pub fn bump_persistent_ttl(env: &Env, key: &DataKey) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `open_position_key` is never used [INFO] [stdout] --> src/storage.rs:42:8 [INFO] [stdout] | [INFO] [stdout] 42 | pub fn open_position_key(owner: &Address, asset: &Address, side: Side) -> DataKey { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `get_indexed_open_position` is never used [INFO] [stdout] --> src/storage.rs:46:8 [INFO] [stdout] | [INFO] [stdout] 46 | pub fn get_indexed_open_position( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `set_open_position_index` is never used [INFO] [stdout] --> src/storage.rs:94:8 [INFO] [stdout] | [INFO] [stdout] 94 | pub fn set_open_position_index(env: &Env, position: &Position) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `clear_open_position_index` is never used [INFO] [stdout] --> src/storage.rs:101:8 [INFO] [stdout] | [INFO] [stdout] 101 | pub fn clear_open_position_index(env: &Env, position: &Position) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `rate_config` is never used [INFO] [stdout] --> src/storage.rs:117:8 [INFO] [stdout] | [INFO] [stdout] 117 | pub fn rate_config(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `global_config` is never used [INFO] [stdout] --> src/storage.rs:128:8 [INFO] [stdout] | [INFO] [stdout] 128 | pub fn global_config(env: &Env) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `active_global_config` is never used [INFO] [stdout] --> src/storage.rs:138:8 [INFO] [stdout] | [INFO] [stdout] 138 | pub fn active_global_config(env: &Env) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `market_config` is never used [INFO] [stdout] --> src/storage.rs:147:8 [INFO] [stdout] | [INFO] [stdout] 147 | pub fn market_config(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `active_market` is never used [INFO] [stdout] --> src/storage.rs:158:8 [INFO] [stdout] | [INFO] [stdout] 158 | pub fn active_market(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `ensure_supported_pool_asset` is never used [INFO] [stdout] --> src/storage.rs:167:8 [INFO] [stdout] | [INFO] [stdout] 167 | pub fn ensure_supported_pool_asset( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pool_for` is never used [INFO] [stdout] --> src/storage.rs:179:8 [INFO] [stdout] | [INFO] [stdout] 179 | pub fn pool_for(env: &Env, asset: &Address) -> PoolState { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `set_pool` is never used [INFO] [stdout] --> src/storage.rs:186:8 [INFO] [stdout] | [INFO] [stdout] 186 | pub fn set_pool(env: &Env, asset: &Address, pool: &PoolState) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `empty_pool` is never used [INFO] [stdout] --> src/storage.rs:192:8 [INFO] [stdout] | [INFO] [stdout] 192 | pub fn empty_pool(timestamp: u64) -> PoolState { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `save_position` is never used [INFO] [stdout] --> src/storage.rs:204:8 [INFO] [stdout] | [INFO] [stdout] 204 | pub fn save_position(env: &Env, p: &Position) { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `load_position` is never used [INFO] [stdout] --> src/storage.rs:210:8 [INFO] [stdout] | [INFO] [stdout] 210 | pub fn load_position(env: &Env, id: u64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `next_id` is never used [INFO] [stdout] --> src/storage.rs:221:8 [INFO] [stdout] | [INFO] [stdout] 221 | pub fn next_id(env: &Env) -> Result { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `has_open_positions_for_asset` is never used [INFO] [stdout] --> src/storage.rs:235:8 [INFO] [stdout] | [INFO] [stdout] 235 | pub fn has_open_positions_for_asset(env: &Env, asset: &Address) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `estimate_exact_in` is never used [INFO] [stdout] --> src/aquarius.rs:39:8 [INFO] [stdout] | [INFO] [stdout] 39 | pub fn estimate_exact_in( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `estimate_exact_out` is never used [INFO] [stdout] --> src/aquarius.rs:56:8 [INFO] [stdout] | [INFO] [stdout] 56 | pub fn estimate_exact_out( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `authorize_pool_swap_exact_in` is never used [INFO] [stdout] --> src/aquarius.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | pub fn authorize_pool_swap_exact_in( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `authorize_pool_swap_exact_out` is never used [INFO] [stdout] --> src/aquarius.rs:118:8 [INFO] [stdout] | [INFO] [stdout] 118 | pub fn authorize_pool_swap_exact_out( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `swap_exact_in` is never used [INFO] [stdout] --> src/aquarius.rs:163:8 [INFO] [stdout] | [INFO] [stdout] 163 | pub fn swap_exact_in( [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `swap_exact_out` is never used [INFO] [stdout] --> src/aquarius.rs:208:8 [INFO] [stdout] | [INFO] [stdout] 208 | pub fn swap_exact_out( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `ensure_pool_operational` is never used [INFO] [stdout] --> src/aquarius.rs:259:8 [INFO] [stdout] | [INFO] [stdout] 259 | pub fn ensure_pool_operational(env: &Env, market: &MarketConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `BPS` is never used [INFO] [stdout] --> src/constants.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | pub const BPS: i128 = 10_000; [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `YEAR_SECS` is never used [INFO] [stdout] --> src/constants.rs:2:11 [INFO] [stdout] | [INFO] [stdout] 2 | pub const YEAR_SECS: i128 = 31_536_000; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `HOURS_PER_YEAR` is never used [INFO] [stdout] --> src/constants.rs:3:11 [INFO] [stdout] | [INFO] [stdout] 3 | pub const HOURS_PER_YEAR: i128 = 8_760; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `DAYS_PER_YEAR` is never used [INFO] [stdout] --> src/constants.rs:4:11 [INFO] [stdout] | [INFO] [stdout] 4 | pub const DAYS_PER_YEAR: i128 = 365; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `RATE_SCALE` is never used [INFO] [stdout] --> src/constants.rs:5:11 [INFO] [stdout] | [INFO] [stdout] 5 | pub const RATE_SCALE: i128 = 1_000_000_000_000; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `INDEX_SCALE` is never used [INFO] [stdout] --> src/constants.rs:6:11 [INFO] [stdout] | [INFO] [stdout] 6 | pub const INDEX_SCALE: i128 = 1_000_000_000_000; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `MAX_KEEPER_INSPECTIONS` is never used [INFO] [stdout] --> src/constants.rs:7:11 [INFO] [stdout] | [INFO] [stdout] 7 | pub const MAX_KEEPER_INSPECTIONS: u32 = 50; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `TTL_RENEW_THRESHOLD` is never used [INFO] [stdout] --> src/constants.rs:12:11 [INFO] [stdout] | [INFO] [stdout] 12 | pub const TTL_RENEW_THRESHOLD: u32 = 120_960; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `TTL_EXTEND_TO` is never used [INFO] [stdout] --> src/constants.rs:13:11 [INFO] [stdout] | [INFO] [stdout] 13 | pub const TTL_EXTEND_TO: u32 = 518_400; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `AmpliFiProtocol` is never constructed [INFO] [stdout] --> src/contract.rs:41:12 [INFO] [stdout] | [INFO] [stdout] 41 | pub struct AmpliFiProtocol; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: multiple associated functions are never used [INFO] [stdout] --> src/contract.rs:78:12 [INFO] [stdout] | [INFO] [stdout] 44 | impl AmpliFiProtocol { [INFO] [stdout] | -------------------- associated functions in this implementation [INFO] [stdout] ... [INFO] [stdout] 78 | pub fn set_paused(env: Env, paused: bool) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 87 | pub fn set_market(env: Env, market: MarketConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 135 | pub fn set_market_enabled(env: Env, asset: Address, enabled: bool) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 147 | pub fn set_interest_rate_config( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 165 | pub fn upgrade(env: Env, wasm_hash: BytesN<32>) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 172 | pub fn deposit_liquidity( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 216 | pub fn withdraw_liquidity( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 256 | pub fn open_long( [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 442 | pub fn open_short( [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 624 | pub fn add_margin( [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 698 | pub fn close_position( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 723 | pub fn execute_liquidation(env: Env, keeper: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 808 | pub fn get_position_states(env: Env) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 871 | pub fn get_global_config(env: Env) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 875 | pub fn get_market(env: Env, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 879 | pub fn get_open_position( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 888 | pub fn get_position(env: Env, id: u64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 892 | pub fn get_risk(env: Env, id: u64) -> Result { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 897 | pub fn get_interest_rate_config(env: Env, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 903 | pub fn get_borrow_rate(env: Env, asset: Address, side: Side) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 928 | pub fn get_lp_shares(env: Env, lp: Address, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 938 | pub fn get_lp_position(env: Env, lp: Address, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 974 | pub fn preview_position(env: Env, id: u64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 979 | pub fn preview_add_margin( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 1014 | pub fn get_pool(env: Env, asset: Address) -> Result { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `settle_liquidation` is never used [INFO] [stdout] --> src/contract.rs:1021:4 [INFO] [stdout] | [INFO] [stdout] 1021 | fn settle_liquidation(env: &Env, mut p: Position, keeper: Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `settle_user_close` is never used [INFO] [stdout] --> src/contract.rs:1215:4 [INFO] [stdout] | [INFO] [stdout] 1215 | fn settle_user_close( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `risk_at` is never used [INFO] [stdout] --> src/contract.rs:1431:4 [INFO] [stdout] | [INFO] [stdout] 1431 | fn risk_at(env: &Env, p: &Position) -> Result { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `preview_position_at` is never used [INFO] [stdout] --> src/contract.rs:1534:4 [INFO] [stdout] | [INFO] [stdout] 1534 | fn preview_position_at(env: &Env, p: &Position) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_market` is never used [INFO] [stdout] --> src/contract.rs:1631:4 [INFO] [stdout] | [INFO] [stdout] 1631 | fn validate_market(env: &Env, cfg: &GlobalConfig, market: &MarketConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_global_config` is never used [INFO] [stdout] --> src/contract.rs:1659:4 [INFO] [stdout] | [INFO] [stdout] 1659 | fn validate_global_config(c: &GlobalConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_open` is never used [INFO] [stdout] --> src/contract.rs:1666:4 [INFO] [stdout] | [INFO] [stdout] 1666 | fn validate_open(market: &MarketConfig, collateral: i128, leverage_bps: u32) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `advance_scan_cursor` is never used [INFO] [stdout] --> src/contract.rs:1674:4 [INFO] [stdout] | [INFO] [stdout] 1674 | fn advance_scan_cursor(current: u64, position_count: u64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `OpenPositionEvent` is never constructed [INFO] [stdout] --> src/events.rs:6:12 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct OpenPositionEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `ClosePositionEvent` is never constructed [INFO] [stdout] --> src/events.rs:15:12 [INFO] [stdout] | [INFO] [stdout] 15 | pub struct ClosePositionEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `AddMarginEvent` is never constructed [INFO] [stdout] --> src/events.rs:26:12 [INFO] [stdout] | [INFO] [stdout] 26 | pub struct AddMarginEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `PositionLiquidationEvent` is never constructed [INFO] [stdout] --> src/events.rs:33:12 [INFO] [stdout] | [INFO] [stdout] 33 | pub struct PositionLiquidationEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `LiquidityDepositEvent` is never constructed [INFO] [stdout] --> src/events.rs:38:12 [INFO] [stdout] | [INFO] [stdout] 38 | pub struct LiquidityDepositEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `LiquidityWithdrawalEvent` is never constructed [INFO] [stdout] --> src/events.rs:46:12 [INFO] [stdout] | [INFO] [stdout] 46 | pub struct LiquidityWithdrawalEvent { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `borrowed_asset_for_side` is never used [INFO] [stdout] --> src/interest.rs:11:8 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn borrowed_asset_for_side(cfg: &GlobalConfig, p: &Position) -> Address { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `scaled_borrow_amount` is never used [INFO] [stdout] --> src/interest.rs:18:8 [INFO] [stdout] | [INFO] [stdout] 18 | pub fn scaled_borrow_amount(amount: i128, borrow_index: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `position_debt` is never used [INFO] [stdout] --> src/interest.rs:24:8 [INFO] [stdout] | [INFO] [stdout] 24 | pub fn position_debt(pool: &PoolState, borrow_scaled: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `default_interest_rate_config` is never used [INFO] [stdout] --> src/interest.rs:31:8 [INFO] [stdout] | [INFO] [stdout] 31 | pub fn default_interest_rate_config() -> InterestRateConfig { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_interest_rate_config` is never used [INFO] [stdout] --> src/interest.rs:42:8 [INFO] [stdout] | [INFO] [stdout] 42 | pub fn validate_interest_rate_config(rate: &InterestRateConfig) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `utilization_bps` is never used [INFO] [stdout] --> src/interest.rs:57:8 [INFO] [stdout] | [INFO] [stdout] 57 | pub fn utilization_bps(pool: &PoolState) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `borrow_apr_bps_for_utilization` is never used [INFO] [stdout] --> src/interest.rs:64:8 [INFO] [stdout] | [INFO] [stdout] 64 | pub fn borrow_apr_bps_for_utilization( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `project_pool_to_timestamp` is never used [INFO] [stdout] --> src/interest.rs:93:8 [INFO] [stdout] | [INFO] [stdout] 93 | pub fn project_pool_to_timestamp( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `projected_pool` is never used [INFO] [stdout] --> src/interest.rs:130:8 [INFO] [stdout] | [INFO] [stdout] 130 | pub fn projected_pool(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `accrue_pool` is never used [INFO] [stdout] --> src/interest.rs:136:8 [INFO] [stdout] | [INFO] [stdout] 136 | pub fn accrue_pool(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `available_liquidity` is never used [INFO] [stdout] --> src/interest.rs:142:8 [INFO] [stdout] | [INFO] [stdout] 142 | pub fn available_liquidity(pool: &PoolState) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `ensure_borrow_capacity` is never used [INFO] [stdout] --> src/interest.rs:146:8 [INFO] [stdout] | [INFO] [stdout] 146 | pub fn ensure_borrow_capacity( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `require_positive` is never used [INFO] [stdout] --> src/math.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn require_positive(value: i128) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `checked_add` is never used [INFO] [stdout] --> src/math.rs:11:8 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn checked_add(a: i128, b: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `checked_sub` is never used [INFO] [stdout] --> src/math.rs:15:8 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn checked_sub(a: i128, b: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `mul_div` is never used [INFO] [stdout] --> src/math.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn mul_div(a: i128, b: i128, denominator: i128) -> Result { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `mul_div_round_up` is never used [INFO] [stdout] --> src/math.rs:29:8 [INFO] [stdout] | [INFO] [stdout] 29 | pub fn mul_div_round_up(a: i128, b: i128, denominator: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bps` is never used [INFO] [stdout] --> src/math.rs:46:8 [INFO] [stdout] | [INFO] [stdout] 46 | pub fn bps(value: i128, bps_value: u32) -> Result { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `apply_negative_bps` is never used [INFO] [stdout] --> src/math.rs:50:8 [INFO] [stdout] | [INFO] [stdout] 50 | pub fn apply_negative_bps(value: i128, bps_value: u32) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `apply_positive_bps` is never used [INFO] [stdout] --> src/math.rs:54:8 [INFO] [stdout] | [INFO] [stdout] 54 | pub fn apply_positive_bps(value: i128, bps_value: u32) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `min_i128` is never used [INFO] [stdout] --> src/math.rs:58:8 [INFO] [stdout] | [INFO] [stdout] 58 | pub fn min_i128(a: i128, b: i128) -> i128 { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `non_negative` is never used [INFO] [stdout] --> src/math.rs:66:8 [INFO] [stdout] | [INFO] [stdout] 66 | pub fn non_negative(value: i128) -> i128 { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `signed_equity` is never used [INFO] [stdout] --> src/math.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | pub fn signed_equity(assets: i128, obligations: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `i128_to_u32` is never used [INFO] [stdout] --> src/math.rs:78:8 [INFO] [stdout] | [INFO] [stdout] 78 | pub fn i128_to_u32(value: i128) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `value_asset_usdc` is never used [INFO] [stdout] --> src/position.rs:8:8 [INFO] [stdout] | [INFO] [stdout] 8 | pub fn value_asset_usdc(amount: i128, price: i128, market: &MarketConfig) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `validate_close_bps` is never used [INFO] [stdout] --> src/position.rs:15:8 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn validate_close_bps(close_bps: u32) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `proportional_close_amount` is never used [INFO] [stdout] --> src/position.rs:22:8 [INFO] [stdout] | [INFO] [stdout] 22 | pub fn proportional_close_amount(amount: i128, close_bps: u32) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `proportional_amount_allow_zero` is never used [INFO] [stdout] --> src/position.rs:35:8 [INFO] [stdout] | [INFO] [stdout] 35 | pub fn proportional_amount_allow_zero(amount: i128, close_bps: u32) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `effective_price_from_exact_in` is never used [INFO] [stdout] --> src/position.rs:53:8 [INFO] [stdout] | [INFO] [stdout] 53 | pub fn effective_price_from_exact_in( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `long_effective_leverage_bps` is never used [INFO] [stdout] --> src/position.rs:64:8 [INFO] [stdout] | [INFO] [stdout] 64 | pub fn long_effective_leverage_bps( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `short_entry_notional_usdc` is never used [INFO] [stdout] --> src/position.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | pub fn short_entry_notional_usdc( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `short_effective_leverage_bps` is never used [INFO] [stdout] --> src/position.rs:85:8 [INFO] [stdout] | [INFO] [stdout] 85 | pub fn short_effective_leverage_bps( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bump_instance_ttl` is never used [INFO] [stdout] --> src/storage.rs:11:8 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn bump_instance_ttl(env: &Env) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bump_persistent_ttl` is never used [INFO] [stdout] --> src/storage.rs:17:8 [INFO] [stdout] | [INFO] [stdout] 17 | pub fn bump_persistent_ttl(env: &Env, key: &DataKey) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `open_position_key` is never used [INFO] [stdout] --> src/storage.rs:42:8 [INFO] [stdout] | [INFO] [stdout] 42 | pub fn open_position_key(owner: &Address, asset: &Address, side: Side) -> DataKey { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `get_indexed_open_position` is never used [INFO] [stdout] --> src/storage.rs:46:8 [INFO] [stdout] | [INFO] [stdout] 46 | pub fn get_indexed_open_position( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `set_open_position_index` is never used [INFO] [stdout] --> src/storage.rs:94:8 [INFO] [stdout] | [INFO] [stdout] 94 | pub fn set_open_position_index(env: &Env, position: &Position) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `clear_open_position_index` is never used [INFO] [stdout] --> src/storage.rs:101:8 [INFO] [stdout] | [INFO] [stdout] 101 | pub fn clear_open_position_index(env: &Env, position: &Position) -> Result<(), Error> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `rate_config` is never used [INFO] [stdout] --> src/storage.rs:117:8 [INFO] [stdout] | [INFO] [stdout] 117 | pub fn rate_config(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `global_config` is never used [INFO] [stdout] --> src/storage.rs:128:8 [INFO] [stdout] | [INFO] [stdout] 128 | pub fn global_config(env: &Env) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `active_global_config` is never used [INFO] [stdout] --> src/storage.rs:138:8 [INFO] [stdout] | [INFO] [stdout] 138 | pub fn active_global_config(env: &Env) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `market_config` is never used [INFO] [stdout] --> src/storage.rs:147:8 [INFO] [stdout] | [INFO] [stdout] 147 | pub fn market_config(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `active_market` is never used [INFO] [stdout] --> src/storage.rs:158:8 [INFO] [stdout] | [INFO] [stdout] 158 | pub fn active_market(env: &Env, asset: &Address) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `ensure_supported_pool_asset` is never used [INFO] [stdout] --> src/storage.rs:167:8 [INFO] [stdout] | [INFO] [stdout] 167 | pub fn ensure_supported_pool_asset( [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pool_for` is never used [INFO] [stdout] --> src/storage.rs:179:8 [INFO] [stdout] | [INFO] [stdout] 179 | pub fn pool_for(env: &Env, asset: &Address) -> PoolState { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `set_pool` is never used [INFO] [stdout] --> src/storage.rs:186:8 [INFO] [stdout] | [INFO] [stdout] 186 | pub fn set_pool(env: &Env, asset: &Address, pool: &PoolState) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `empty_pool` is never used [INFO] [stdout] --> src/storage.rs:192:8 [INFO] [stdout] | [INFO] [stdout] 192 | pub fn empty_pool(timestamp: u64) -> PoolState { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `save_position` is never used [INFO] [stdout] --> src/storage.rs:204:8 [INFO] [stdout] | [INFO] [stdout] 204 | pub fn save_position(env: &Env, p: &Position) { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `load_position` is never used [INFO] [stdout] --> src/storage.rs:210:8 [INFO] [stdout] | [INFO] [stdout] 210 | pub fn load_position(env: &Env, id: u64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `next_id` is never used [INFO] [stdout] --> src/storage.rs:221:8 [INFO] [stdout] | [INFO] [stdout] 221 | pub fn next_id(env: &Env) -> Result { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `has_open_positions_for_asset` is never used [INFO] [stdout] --> src/storage.rs:235:8 [INFO] [stdout] | [INFO] [stdout] 235 | pub fn has_open_positions_for_asset(env: &Env, asset: &Address) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 1m 46s [INFO] running `Command { std: "docker" "inspect" "989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd", kill_on_drop: false }` [INFO] [stdout] 989428c3f97b49248746d716e6c904d259bda526f29f85bd2b681d3def361bcd