Skip to content

Commit

Permalink
Merge #459: Pin dependencies when using MSRV
Browse files Browse the repository at this point in the history
c6d89cd Pin dependencies when using MSRV (Tobin C. Harding)
15b57cd Remove TOOLCHAIN (Tobin C. Harding)

Pull request description:

  A recent release of `form_urlencoded` breaks our test run when using 1.41.1 toolchain.

  Pin the `url` and `form_urlencoded` dependencies when on 1.41.1 toolchain. Add a section to the readme instructing devs how to pin relevant dependencies (only when running tests).

ACKs for top commit:
  apoelstra:
    ACK c6d89cd

Tree-SHA512: bff67d12b344c70f6f787e12b5640ea0bba6a8a460e6116f42c2049d7fc8e370157b37884ef0a9dc765e5cef852786cae50a53ef1785b6f45640d6a061d146ea
  • Loading branch information
apoelstra committed Sep 12, 2022
2 parents 75a3577 + c6d89cd commit 8fcbeb1
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 6 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,14 @@ or in [the `examples/` directory](https://github.com/apoelstra/rust-miniscript/t
This library should always compile with any combination of features (minus
`no-std`) on **Rust 1.41.1** or **Rust 1.47** with `no-std`.

Some dependencies do not play nicely with our MSRV, if you are running the tests
you may need to pin as follows:

```
cargo update --package url --precise 2.2.2
cargo update --package form_urlencoded --precise 1.0.1
```

## Contributing
Contributions are generally welcome. If you intend to make larger changes please
discuss them in an issue before PRing them to avoid duplicate work and
Expand Down
18 changes: 12 additions & 6 deletions contrib/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,24 @@ set -e

FEATURES="compiler serde rand"

# Use toolchain if explicitly specified
if [ -n "$TOOLCHAIN" ]
then
alias cargo="cargo +$TOOLCHAIN"
fi

cargo update -p serde --precise 1.0.142
cargo update -p serde_derive --precise 1.0.142

cargo --version
rustc --version

# Work out if we are using a nightly toolchain.
MSRV=false
if cargo --version | grep "1\.41\.0"; then
MSRV=true
fi

# form_urlencoded 1.1.0 breaks MSRV.
if [ "$MSRV" = true ]; then
cargo update -p url --precise 2.2.2
cargo update -p form_urlencoded --precise 1.0.1
fi

# Format if told to
if [ "$DO_FMT" = true ]
then
Expand Down

0 comments on commit 8fcbeb1

Please sign in to comment.