substrate
substrate copied to clipboard
Version conflict on if-addrs-sys
There seems to be an issue with the if-addrs-sys package, i tried checking and building with cargo right out of the box and i am unable to. When i do run
cargo check
i get the following error:
Updating git repository
https://github.com/rs-ipfs/rust-ipfsUpdating crates.io index Updating git repository
https://github.com/NLnetLabs/domain.giterror: failed to select a version for
if-addrs-sys. ... required by package
if-addrs v0.6.4... which is depended on by
libp2p-tcp v0.27.0... which is depended on by
libp2p v0.34.0... which is depended on by
ipfs v0.2.1 (https://github.com/rs-ipfs/rust-ipfs#cf370325)... which is depended on by
node-cli v2.0.0 (/home/cbnits/Documents/ref/substrate/bin/node/cli)... which is depended on by
chain-spec-builder v2.0.0 (/home/cbnits/Documents/ref/substrate/bin/utils/chain-spec-builder)versions that meet the requirements
^0.3` are: 0.3.2, 0.3.1
the package if-addrs-sys
links to the native library ifaddrs
, but it conflicts with a previous package which links to ifaddrs
as well:
package get_if_addrs-sys v0.1.1
... which is depended on by get_if_addrs v0.5.3
... which is depended on by libp2p-tcp v0.22.0
... which is depended on by libp2p v0.28.1
... which is depended on by node-browser-testing v2.0.0 (/home/cbnits/Documents/ref/substrate/bin/node/browser-testing)
failed to select a version for if-addrs-sys
which could resolve this conflict
`
What do you think is the solution to this?
Reference Screenshot:
@dEvK4n3Ki were you able to solve the issue? I encountered the same thing. It looks like the latest version of rust-ipfs uses libp2p 0.34.0 but the older libs used in this repo use 0.28.1. One fix is to specify the tag = "[email protected]", which uses libp2p 0.28.1. I have a fork that does that: https://github.com/driemworks/substrate/tree/offchain_ipfs_wsl Another (not as easy but definitey better) option would be to rebase this repo with the parity/substrate master branch.
edit: should be [email protected], not 0.2.1.
@dEvK4n3Ki were you able to solve the issue? I encountered the same thing. It looks like the latest version of rust-ipfs uses libp2p 0.34.0 but the older libs used in this repo use 0.28.1. One fix is to specify the tag = "[email protected]", which uses libp2p 0.28.1. I have a fork that does that: https://github.com/driemworks/substrate/tree/offchain_ipfs_wsl Another (not as easy but definitey better) option would be to rebase this repo with the parity/substrate master branch.
Can you tell me where to add tag ="[email protected]". Should I add it in the docker version?
@dEvK4n3Ki were you able to solve the issue? I encountered the same thing. It looks like the latest version of rust-ipfs uses libp2p 0.34.0 but the older libs used in this repo use 0.28.1. One fix is to specify the tag = "[email protected]", which uses libp2p 0.28.1. I have a fork that does that: https://github.com/driemworks/substrate/tree/offchain_ipfs_wsl Another (not as easy but definitey better) option would be to rebase this repo with the parity/substrate master branch.
Can you tell me where to add tag ="[email protected]". Should I add it in the docker version?
There are three packages that depend on ipfs, so the tag needs to be specified in the Cargo.toml in each. Take a look at: https://github.com/driemworks/substrate/commit/2072db4c13e77d8eab6e7ee3a9e7a2a4ce3653c3
I'm using WSL so if your system is different this could differ. I'm only able to get the project to run using ngihtly-2020-08-23. That is, running cargo +nightly-2020-08-23 build --release
and then cargo +nightly-2020-08-23 run --release -- --dev --tmp
@driemworks Thanks for your reply.
I edited the tag in all the 3 files.
I got the following error.
Please let me know how to fix this.
The error says wasm32-unknown-unknown target may not be installed. Install it:
rustup target add wasm32-unknown-unknown