Rustler compiling for every iteration

I have rust nifs that uses Solana library, it doesnt seem to load much things, the compilation time has been slow, not much problem about this, but eveytime I run my project, just a run, mix phxserver, or tests, even If I do not modify any rust, I’m compiling the rust everytime. How to present this?

cargo toml

[package]
name = "mifs"
version = "0.1.0"
authors = []
edition = "2021"

[lib]
name = "mifs"
path = "src/lib.rs"
crate-type = ["cdylib"]

[dependencies]
rustler = "0.34.0"
bip39 = ""
bs58 = ""
solana-sdk = ""
solana-client = ""
1 Like

Does not happen to me with Rustler 0.35, Elixir 1.18.1 (OTP 27) and Erlang 27.2. What are your versions?

NOTE: I am not overriding Rust edition though, and mine is at 2024 currently.

1 Like

I’m testing rn with this rustler version to see if it changes
Elixir 1.17.3 ERL/OTP 26

No Rustler version is visible, you only posted Elixir and Erlang versions.

was using Rustler 0.34 and sometimes I was having this very strange behavior where I didn’t change anything in my nifs but was forced to recompile, rustler 0.35 sor far is not given me this problem

Well then, then mark “Rustler 0.35 solves the problem” as the solution. :smiley:

1 Like