Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgraded dependencies #202

Merged
merged 10 commits into from
Aug 6, 2024
Merged

Upgraded dependencies #202

merged 10 commits into from
Aug 6, 2024

Conversation

DariuszDepta
Copy link
Member

@DariuszDepta DariuszDepta commented Aug 6, 2024

Upgraded cosmasm-std to version 2.1.1
After this upgrade, building MultiTest with minimal versions of dependencies failed on CI.
The same effect can be reproduced locally, by doing this:

cargo clean
rm -rf Cargo.lock
cargo +nightly build -Zminimal-versions --all-features

Running cargo tree just after above commands shows awkward dependencies:

│   ├── cosmwasm-crypto v2.1.1
│   │   ├── ark-bls12-381 v0.4.0
│   │   │   ├── ark-ec v0.4.2
│   │   │   │   ├── ark-ff v0.4.2
│   │   │   │   │   ├── ark-ff-asm v0.4.2-alpha.1 (proc-macro)
│   │   │   │   │   │   ├── quote v1.0.35
│   │   │   │   │   │   │   └── proc-macro2 v1.0.79
│   │   │   │   │   │   │       └── unicode-ident v1.0.0
│   │   │   │   │   │   └── syn v1.0.3
│   │   │   │   │   │       ├── proc-macro2 v1.0.79 (*)
│   │   │   │   │   │       ├── quote v1.0.35 (*)
│   │   │   │   │   │       └── unicode-xid v0.2.2
│   │   │   │   │   ├── ark-ff-macros v0.4.2-alpha.1 (proc-macro)
│   │   │   │   │   │   ├── num-bigint v0.4.0
│   │   │   │   │   │   │   ├── num-integer v0.1.42
│   │   │   │   │   │   │   │   └── num-traits v0.2.18
│   │   │   │   │   │   │   │       [build-dependencies]
│   │   │   │   │   │   │   │       └── autocfg v1.0.0
│   │   │   │   │   │   │   │   [build-dependencies]
│   │   │   │   │   │   │   │   └── autocfg v1.0.0
│   │   │   │   │   │   │   └── num-traits v0.2.18 (*)
│   │   │   │   │   │   │   [build-dependencies]
│   │   │   │   │   │   │   └── autocfg v1.0.0
│   │   │   │   │   │   ├── num-traits v0.2.18 (*)
│   │   │   │   │   │   ├── proc-macro2 v1.0.79 (*)
│   │   │   │   │   │   ├── quote v1.0.35 (*)
│   │   │   │   │   │   └── syn v1.0.3 (*)
│   │   │   │   │   ├── ark-serialize v0.4.2
│   │   │   │   │   │   ├── ark-serialize-derive v0.4.2-alpha.1 (proc-macro)
│   │   │   │   │   │   │   ├── proc-macro2 v1.0.79 (*)
│   │   │   │   │   │   │   ├── quote v1.0.35 (*)
│   │   │   │   │   │   │   └── syn v1.0.3 (*)
│   │   │   │   │   │   ├── ark-std v0.4.0
│   │   │   │   │   │   │   ├── num-traits v0.2.18
│   │   │   │   │   │   │   │   [build-dependencies]
│   │   │   │   │   │   │   │   └── autocfg v1.0.0
│   │   │   │   │   │   │   ├── rand v0.8.0
│   │   │   │   │   │   │   │   ├── rand_chacha v0.3.0
│   │   │   │   │   │   │   │   │   ├── ppv-lite86 v0.2.8
│   │   │   │   │   │   │   │   │   └── rand_core v0.6.4
│   │   │   │   │   │   │   │   │       └── getrandom v0.2.0
│   │   │   │   │   │   │   │   │           ├── cfg-if v0.1.2
│   │   │   │   │   │   │   │   │           └── libc v0.2.95
│   │   │   │   │   │   │   │   └── rand_core v0.6.4 (*)
│   │   │   │   │   │   │   └── rayon v1.9.0
│   │   │   │   │   │   │       ├── either v1.0.0
│   │   │   │   │   │   │       └── rayon-core v1.12.1
│   │   │   │   │   │   │           ├── crossbeam-deque v0.8.1
│   │   │   │   │   │   │           │   ├── cfg-if v1.0.0
│   │   │   │   │   │   │           │   ├── crossbeam-epoch v0.9.5
│   │   │   │   │   │   │           │   │   ├── cfg-if v1.0.0
│   │   │   │   │   │   │           │   │   ├── crossbeam-utils v0.8.7
│   │   │   │   │   │   │           │   │   │   ├── cfg-if v1.0.0
│   │   │   │   │   │   │           │   │   │   └── lazy_static v1.4.0
│   │   │   │   │   │   │           │   │   ├── lazy_static v1.4.0
│   │   │   │   │   │   │           │   │   ├── memoffset v0.6.1
│   │   │   │   │   │   │           │   │   │   [build-dependencies]
│   │   │   │   │   │   │           │   │   │   └── autocfg v1.0.0
│   │   │   │   │   │   │           │   │   └── scopeguard v1.1.0
│   │   │   │   │   │   │           │   └── crossbeam-utils v0.8.7 (*)
│   │   │   │   │   │   │           └── crossbeam-utils v0.8.7 (*)
│   │   │   │   │   │   ├── digest v0.10.7
│   │   │   │   │   │   │   ├── block-buffer v0.10.1
│   │   │   │   │   │   │   │   └── generic-array v0.14.6
│   │   │   │   │   │   │   │       ├── typenum v1.14.0
│   │   │   │   │   │   │   │       └── zeroize v1.7.0
│   │   │   │   │   │   │   │           └── zeroize_derive v1.3.2 (proc-macro)
│   │   │   │   │   │   │   │               ├── proc-macro2 v1.0.79 (*)
│   │   │   │   │   │   │   │               ├── quote v1.0.35 (*)
│   │   │   │   │   │   │   │               ├── syn v1.0.3 (*)
│   │   │   │   │   │   │   │               └── synstructure v0.12.2
│   │   │   │   │   │   │   │                   ├── proc-macro2 v1.0.79 (*)
│   │   │   │   │   │   │   │                   ├── quote v1.0.35 (*)
│   │   │   │   │   │   │   │                   ├── syn v1.0.3 (*)
│   │   │   │   │   │   │   │                   └── unicode-xid v0.2.2
│   │   │   │   │   │   │   │       [build-dependencies]
│   │   │   │   │   │   │   │       └── version_check v0.9.4
│   │   │   │   │   │   │   ├── const-oid v0.9.2
│   │   │   │   │   │   │   ├── crypto-common v0.1.3
│   │   │   │   │   │   │   │   ├── generic-array v0.14.6 (*)
│   │   │   │   │   │   │   │   └── typenum v1.14.0
│   │   │   │   │   │   │   └── subtle v2.4.0
│   │   │   │   │   │   └── num-bigint v0.4.0 (*)
│   │   │   │   │   ├── ark-std v0.4.0 (*)
│   │   │   │   │   ├── derivative v2.2.0 (proc-macro)
│   │   │   │   │   │   ├── proc-macro2 v1.0.79 (*)
│   │   │   │   │   │   ├── quote v1.0.35 (*)
│   │   │   │   │   │   └── syn v1.0.3 (*)
│   │   │   │   │   ├── digest v0.10.7 (*)
│   │   │   │   │   ├── itertools v0.10.0
│   │   │   │   │   │   └── either v1.0.0
│   │   │   │   │   ├── num-bigint v0.4.0 (*)
│   │   │   │   │   ├── num-traits v0.2.18 (*)
│   │   │   │   │   ├── paste v1.0.0 (proc-macro)
│   │   │   │   │   ├── rayon v1.9.0 (*)
│   │   │   │   │   └── zeroize v1.7.0 (*)
│   │   │   │   │   [build-dependencies]
│   │   │   │   │   └── rustc_version v0.4.0
│   │   │   │   │       └── semver v1.0.0
│   │   │   │   ├── ark-poly v0.4.2-alpha.1
│   │   │   │   │   ├── ark-ff v0.4.2 (*)
│   │   │   │   │   ├── ark-serialize v0.4.2 (*)
│   │   │   │   │   ├── ark-std v0.4.0 (*)
│   │   │   │   │   ├── derivative v2.2.0 (proc-macro) (*)
│   │   │   │   │   └── hashbrown v0.13.1
│   │   │   │   │       └── ahash v0.8.4 <---------- HERE !!!

Result:

   Compiling cpufeatures v0.2.6
error[E0635]: unknown feature `stdsimd`
  --> /home/confio/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ahash-0.8.4/src/lib.rs:99:42
   |
99 | #![cfg_attr(feature = "stdsimd", feature(stdsimd))]
   |                                          ^^^^^^^

   Compiling quote v1.0.35
For more information about this error, try `rustc --explain E0635`.
error: could not compile `ahash` (lib) due to 1 previous error

The above problem was solved in version 0.8.7 of ahash, but pinning its version in Cargo.toml in MultiTest raises even more problems:

error[E0308]: mismatched types
    --> /home/confio/.cargo/registry/src/index.crates.io-6f17d22bba15001f/num-bigint-0.4.0/src/biguint/convert.rs:70:19
     |
70   |         .div_ceil(&big_digit::BITS.into())
     |          -------- ^^^^^^^^^^^^^^^^^^^^^^^ expected `u64`, found `&_`
     |          |
     |          arguments to this method are incorrect
     |
     = note:   expected type `u64`
             found reference `&_`
note: method defined here
    --> /home/confio/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/num/mod.rs:1159:5
     |
1159 | /     uint_impl! {
1160 | |         Self = u64,
1161 | |         ActualT = u64,
1162 | |         SignedT = i64,
...    |
1176 | |         bound_condition = "",
1177 | |     }
     | |_____^
     = note: this error originates in the macro `uint_impl` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider removing the borrow
     |
70   -         .div_ceil(&big_digit::BITS.into())
70   +         .div_ceil(big_digit::BITS.into())
     |

error[E0308]: mismatched types
    --> /home/confio/.cargo/registry/src/index.crates.io-6f17d22bba15001f/num-bigint-0.4.0/src/biguint/convert.rs:585:19
     |
585  |         .div_ceil(&u64::from(bits))
     |          -------- ^^^^^^^^^^^^^^^^ expected `u64`, found `&u64`
     |          |
     |          arguments to this method are incorrect
     |
note: method defined here
    --> /home/confio/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/num/mod.rs:1159:5
     |
1159 | /     uint_impl! {
1160 | |         Self = u64,
1161 | |         ActualT = u64,
1162 | |         SignedT = i64,
...    |
1176 | |         bound_condition = "",
1177 | |     }
     | |_____^
     = note: this error originates in the macro `uint_impl` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider removing the borrow
     |
585  -         .div_ceil(&u64::from(bits))
585  +         .div_ceil(u64::from(bits))
     |

error[E0308]: mismatched types
    --> /home/confio/.cargo/registry/src/index.crates.io-6f17d22bba15001f/num-bigint-0.4.0/src/biguint/convert.rs:613:19
     |
613  |         .div_ceil(&u64::from(bits))
     |          -------- ^^^^^^^^^^^^^^^^ expected `u64`, found `&u64`
     |          |
     |          arguments to this method are incorrect
     |
note: method defined here
    --> /home/confio/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/num/mod.rs:1159:5
     |
1159 | /     uint_impl! {
1160 | |         Self = u64,
1161 | |         ActualT = u64,
1162 | |         SignedT = i64,
...    |
1176 | |         bound_condition = "",
1177 | |     }
     | |_____^
     = note: this error originates in the macro `uint_impl` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider removing the borrow
     |
613  -         .div_ceil(&u64::from(bits))
613  +         .div_ceil(u64::from(bits))
     |

@DariuszDepta
Copy link
Member Author

DariuszDepta commented Aug 6, 2024

Temporarily commented out the removal of Cargo.lock in CI.

@DariuszDepta DariuszDepta self-assigned this Aug 6, 2024
@DariuszDepta DariuszDepta added this to the 2.1.1 milestone Aug 6, 2024
@DariuszDepta DariuszDepta merged commit 25bc03b into main Aug 6, 2024
6 of 7 checks passed
@DariuszDepta DariuszDepta deleted the upgrading-dependencies branch August 6, 2024 13:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants