In python, when you install stuff with pip, it is recommended to use a venv, to avoid breaking dependencies for a program when uninstalling another one, or when two programs need two different versions of the same dependence.
I was wondering if with Rust is the same, or if Cargo manages it all on its own (kind of like apt does), and I shouldn’t care about it.
Also since I know Linux kernel is using some Rust, isn’t there a risk of breaking my system if I uninstall a program that need some deps that the system itsel needs?
Go and try out cargo. It always uses separate environments for installing dependencies.
It’s worth nothing that Rust doesn’t have system dependencies like Python or C, as all depdencies are statically linked with the binary. There’s no .so files like C (usually), and there’s no pip store like Python for Rust programs to read from.
I think virtual environments are more of a interpreted language thing, as I only know of them existing for Python and PHP. (NPM also uses separated environments by default)