rust-lang / rustup

The Rust toolchain installer
https://rust-lang.github.io/rustup/
Apache License 2.0
6.19k stars 893 forks source link

Rust not working with docker files #2102

Closed MarinaGamal closed 5 years ago

MarinaGamal commented 5 years ago

I am trying to run the hyperledger indy demo but when trying to build, an error rises in the docker file where rust is downloaded

rror[E0119]: conflicting implementations of traitstd::convert::From<&>for typetypes::to_sql::ToSqlOutput<'>`: --> /home/indy/.cargo/registry/src/github.com-1ecc6299db9ec823/rusqlcipher-0.14.6/src/types/to_sql.rs:26:1 18 / impl<'a, T: ?Sized> From<&'a T> for ToSqlOutput<'a> 19 where &'a T: Into<ValueRef<'a>> 20 { 21 fn from(t: &'a T) -> Self { 22 ToSqlOutput::Borrowed(t.into()) 23 } 24 } _- first implementation here 25 26 impl<'a, T: Into> From for ToSqlOutput<'a> { ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for types::to_sql::ToSqlOutput<'_>

= note: downstream crates may implement trait std::convert::From<&_> for type types::value::Value

error: aborting due to previous error

For more information about this error, try rustc --explain E0119. error: Could not compile rusqlcipher. warning: build failed, waiting for other jobs to finish... error: build failed ERROR: Service 'client' failed to build: The command '/bin/sh -c /home/indy/.cargo/bin/cargo build' returned a non-zero code: 101`

I searched and someone said that he solved the issue by downgrading the rust version but I have been trying to do so but I can't Any help on how to solve this or how to downgrade the rust version using a dockerfile?

kinnison commented 5 years ago

Hi Marina,

I'm not sure that I can help you with the SQL content itself, but if you're trying to affect the version of Rust in your docker container, I'll need to know how the docker file is constructed in order to help you. Could you attach the dockerfile itself, or point me to a repo where it's constructed?