snarkOS: Compilation Failure in snarkOS-node-consensus v2.2.7 due to Deprecated Methods and Type Mismatch

πŸ› Bug Report


During the compilation of snarkOS-node-consensus v2.2.7, multiple warnings and an error were encountered related to deprecated methods and mismatched types.


The issue seems to block the compilation process, indicating a critical severity level as it halts further development or usage of the software until resolved.


This affects the snarkOS-node-consensus module, particularly the compilation process which is critical for development and deployment.

Steps to Reproduce

  1. Compile snarkOS-node-consensus v2.2.7 using Rust.
  2. Observe the warnings about deprecated indexmap::IndexMap::remove methods.
  3. Encounter the error E0308: mismatched types in node/rest/src/ at line 115:54.

Error Messages and Stack Traces

  • Warnings for deprecated indexmap::IndexMap::remove method suggest using swap_remove for explicit behavior.
  • Compilation error E0308 in node/rest/src/ indicates an expected Body type but found a String type instead.

Expected Behavior

The compilation process should complete without errors or warnings, allowing the software to build successfully.

Your Environment

  • snarkOS Version: v2.2.7
  • Rust Version: rustc 1.69.0 (84c898d65 2023-04-16)
  • Computer OS: Windows 10 Version 22H2 (OS Build 10945.3930)

About this issue

  • Original URL
  • State: closed
  • Created 5 months ago
  • Comments: 15

Most upvoted comments

Not yet, but it’s quite simple to apply it locally (either use cargo install with --locked or build manually via cargo build --release) if you’d like to use it already.

i still got above issue when running, first cargo install works fine