LLFourn / bdk_core_staging

Staging area for bdk_core initial development
15 stars 12 forks source link

Decide on MSRV for bdk_chain #187

Open LLFourn opened 1 year ago

LLFourn commented 1 year ago

Options:

  1. 1.48 -- this is for debian stable
  2. 1.56 -- first release of 2021 eddition

I don't think there's anything we need from >1.56 but we should check. One difficulty we may have is with the bincode v2 dependency for the file_store if this does turn out to be an issue we should just spin it out into its own crate. This would make sense because it's kind of "experimental" anyway and we didn't end up implementing bincode traits on our structs anyway.

Output:

notmandatory commented 1 year ago

The plan for the rust-bitcoin projects is to set their MSRV at 1.48 to work with Debian stable. To support 1.48 for rust-esplora-client (and WASM) we should be able to use minireq if @tcharding's PR https://github.com/neonmoe/minreq/pull/90 is accepted, with the caveat no TLS. With rustls the MSRV would have to be 1.57.

The situation for rust-electrum-client is a little different, for Linux it depends on the libc crate which is still debating their MSRV policy (https://github.com/rust-lang/libs-team/issues/72) or win-api-rs which seems to have MSRV of 1.6. In either case TLS would still push MSRV to 1.57.

In the async case where we need tokio the 1.25 release has MSRV at 1.49, but if we can pin to the 1.16.1 version its MSRV is 1.46 (see https://github.com/tokio-rs/tokio/pull/4457). And users can also always use whatever newer version they want.

LLFourn commented 1 year ago

Useful info thanks. Note esplora electurm etc aren't dependenices on bdk_chain. I think bincode is the only issue but the file store can be spun off into its own crate so we can use a lower MSRV here. Whether that means you can actually use that MSRV in your project with all the other dependencies it's likely to have is another story but that is not our concern here :)

notmandatory commented 1 year ago

Yup makes sense bdk_chain doesn't depend on the blockchain client projects. But if we are making it's MSRV 1.48 I'm thinking about how we can get the blockchain client projects we maintain to the same MSRV.

notmandatory commented 1 year ago

I started a bdk_chain with 1.48.0 experiment and was able to get it to build, but with a questionable clone or two. Should I make a PR out of my branch to discuss the fixes and any better work-rounds? I also still need to check some broken tests.

https://github.com/notmandatory/bdk_core_staging/commits/test_msrv_148