-
Notifications
You must be signed in to change notification settings - Fork 75
Split into esplora-types and esplora-client crates
#229
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
Open
EliteCoder18
wants to merge
3
commits into
bitcoindevkit:master
Choose a base branch
from
EliteCoder18:feat/esplora-types-workspace
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
ed11218
chore: convert repo to a workspace, relocate esplora-client to top level
EliteCoder18 66362ab
feat: extract esplora-types crate, wire esplora-client to depend on it
EliteCoder18 03dd1c8
doc: add simple per-crate READMEs and update the workspace README to …
EliteCoder18 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,94 +1,7 @@ | ||
| [package] | ||
| name = "esplora-client" | ||
| version = "0.13.0" | ||
| edition = "2021" | ||
| authors = [ | ||
| "Alekos Filini <alekos.filini@gmail.com>", | ||
| "Bitcoin Dev Kit Developers" | ||
| ] | ||
| license = "MIT OR Apache-2.0" | ||
| homepage = "https://github.com/bitcoindevkit/rust-esplora-client" | ||
| repository = "https://github.com/bitcoindevkit/rust-esplora-client" | ||
| documentation = "https://docs.rs/esplora-client/" | ||
| description = "Asynchronous and blocking clients and types for interacting with Esplora servers over HTTP" | ||
| keywords = ["bitcoin", "esplora"] | ||
| readme = "README.md" | ||
| rust-version = "1.75.0" # MSRV | ||
| [workspace] | ||
| members = ["esplora-client", "esplora-types"] | ||
| resolver = "2" | ||
|
|
||
| [lib] | ||
| name = "esplora_client" | ||
| path = "src/lib.rs" | ||
|
|
||
| [dependencies] | ||
| serde = { version = "1.0.194", features = ["derive"] } | ||
| serde_json = { version = "1.0.117", features = ["std"], default-features = false } | ||
| bitcoin = { version = "0.32", features = ["serde", "std"], default-features = false } | ||
| hex = { version = "0.2.2", package = "hex-conservative" } | ||
| bitreq = { version = "0.3.7", optional = true } | ||
| # Default runtime when running async tests | ||
| tokio = { version = "1", features = ["time"], optional = true } | ||
|
|
||
| [dev-dependencies] | ||
| tokio = { version = "1", features = ["full"] } | ||
| electrsd = { version = "0.40.0", default-features = false, features = ["legacy", "esplora_a33e97e1", "bitcoind_download", "bitcoind_29_0"] } | ||
| # These pins are needed for `Cargo-minimal.lock`: | ||
| tar = { version = "0.4.45" } # blame: electrsd v0.38.0 -> bitcoind -> tar | ||
| log = { version = "0.4.29" } # blame: electrsd v0.38.0 -> bitcoind -> corepc_client | ||
| openssl-sys = { version = "0.9.114" } # blame: bitreq v0.3.5 -> native-tls -> openssl | ||
| openssl = { version = "0.10.78" } # blame: match `openssl-sys` | ||
| native-tls = { version = "0.2.11" } # blame: bitreq v0.3.5 -> native-tls | ||
| tempfile = { version = "=3.15.0" } # blame: tempfile >=v3.16 requires getrandom >=v0.3 | ||
| security-framework = { version = "=2.11.1" } # blame: rustls-native-certs 0.8.3 → security-framework 3.x (edition2024) | ||
|
|
||
| [features] | ||
| default = ["blocking", "blocking-https", "async", "async-https", "tokio"] | ||
|
|
||
| tokio = ["dep:tokio"] | ||
| async = ["bitreq/async", "bitreq/proxy", "bitreq/json-using-serde", "tokio?/time"] | ||
| async-https = ["async", "bitreq/async-https"] | ||
| async-https-native = ["async", "bitreq/async-https-native-tls"] | ||
| async-https-rustls = ["async", "bitreq/async-https-rustls"] | ||
| async-https-rustls-probe = ["async", "bitreq/async-https-rustls-probe"] | ||
|
|
||
| blocking = ["bitreq/proxy", "bitreq/json-using-serde"] | ||
| blocking-https = ["blocking", "bitreq/https"] | ||
| blocking-https-native = ["blocking", "bitreq/https-native-tls"] | ||
| blocking-https-rustls = ["blocking", "bitreq/https-rustls"] | ||
| blocking-https-rustls-probe = ["blocking", "bitreq/https-rustls-probe"] | ||
|
|
||
| [package.metadata.rbmt.toolchains] | ||
| [workspace.metadata.rbmt.toolchains] | ||
| stable = "1.96.1" | ||
| nightly = "nightly-2026-07-03" | ||
|
|
||
| [package.metadata.docs.rs] | ||
| all-features = true | ||
| rustdoc-args = ["--cfg", "docsrs"] | ||
|
|
||
| [package.metadata.rbmt.lint] | ||
| allowed_duplicates = [ | ||
| "getrandom", | ||
| "windows-sys", | ||
| "wit-bindgen", | ||
| ] | ||
|
|
||
| [package.metadata.rbmt.test] | ||
| # Don't test these features in isolation | ||
| exclude_features = [ | ||
| "tokio", | ||
| "async-https", | ||
| "async-https-native", | ||
| "async-https-rustls", | ||
| "async-https-rustls-probe", | ||
| "blocking-https", | ||
| "blocking-https-native", | ||
| "blocking-https-rustls", | ||
| "blocking-https-rustls-probe", | ||
| ] | ||
| # Run tests using these exact feature sets | ||
| exact_features = [ | ||
| ["async", "blocking"], | ||
| ["async-https", "blocking-https", "tokio"], | ||
| ["async-https-native", "blocking-https-native", "tokio"], | ||
| ["async-https-rustls", "blocking-https-rustls", "tokio"], | ||
| ["async-https-rustls-probe", "blocking-https-rustls-probe", "tokio"], | ||
| ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,91 @@ | ||
| [package] | ||
| name = "esplora-client" | ||
| version = "0.13.0" | ||
| edition = "2021" | ||
| authors = [ | ||
| "Alekos Filini <alekos.filini@gmail.com>", | ||
| "Bitcoin Dev Kit Developers" | ||
| ] | ||
| license = "MIT OR Apache-2.0" | ||
| homepage = "https://github.com/bitcoindevkit/rust-esplora-client" | ||
| repository = "https://github.com/bitcoindevkit/rust-esplora-client" | ||
| documentation = "https://docs.rs/esplora-client/" | ||
| description = "Asynchronous and blocking clients and types for interacting with Esplora servers over HTTP" | ||
| keywords = ["bitcoin", "esplora"] | ||
| readme = "README.md" | ||
| rust-version = "1.75.0" # MSRV | ||
|
|
||
| [lib] | ||
| name = "esplora_client" | ||
| path = "src/lib.rs" | ||
|
|
||
| [dependencies] | ||
| esplora-types = { path = "../esplora-types", version = "0.1.0" } | ||
| serde = { version = "1.0.194", features = ["derive"] } | ||
| serde_json = { version = "1.0.117", features = ["std"], default-features = false } | ||
| bitcoin = { version = "0.32", features = ["serde", "std"], default-features = false } | ||
| hex = { version = "0.2.2", package = "hex-conservative" } | ||
| bitreq = { version = "0.3.7", optional = true } | ||
| # Default runtime when running async tests | ||
| tokio = { version = "1", features = ["time"], optional = true } | ||
|
|
||
| [dev-dependencies] | ||
| tokio = { version = "1", features = ["full"] } | ||
| electrsd = { version = "0.40.0", default-features = false, features = ["legacy", "esplora_a33e97e1", "bitcoind_download", "bitcoind_29_0"] } | ||
| # These pins are needed for `Cargo-minimal.lock`: | ||
| tar = { version = "0.4.45" } # blame: electrsd v0.38.0 -> bitcoind -> tar | ||
| log = { version = "0.4.29" } # blame: electrsd v0.38.0 -> bitcoind -> corepc_client | ||
| openssl-sys = { version = "0.9.114" } # blame: bitreq v0.3.5 -> native-tls -> openssl | ||
| openssl = { version = "0.10.78" } # blame: match `openssl-sys` | ||
| native-tls = { version = "0.2.11" } # blame: bitreq v0.3.5 -> native-tls | ||
| tempfile = { version = "=3.15.0" } # blame: tempfile >=v3.16 requires getrandom >=v0.3 | ||
| security-framework = { version = "=2.11.1" } # blame: rustls-native-certs 0.8.3 → security-framework 3.x (edition2024) | ||
|
|
||
| [features] | ||
| default = ["blocking", "blocking-https", "async", "async-https", "tokio"] | ||
|
|
||
| tokio = ["dep:tokio"] | ||
| async = ["bitreq/async", "bitreq/proxy", "bitreq/json-using-serde", "tokio?/time"] | ||
| async-https = ["async", "bitreq/async-https"] | ||
| async-https-native = ["async", "bitreq/async-https-native-tls"] | ||
| async-https-rustls = ["async", "bitreq/async-https-rustls"] | ||
| async-https-rustls-probe = ["async", "bitreq/async-https-rustls-probe"] | ||
|
|
||
| blocking = ["bitreq/proxy", "bitreq/json-using-serde"] | ||
| blocking-https = ["blocking", "bitreq/https"] | ||
| blocking-https-native = ["blocking", "bitreq/https-native-tls"] | ||
| blocking-https-rustls = ["blocking", "bitreq/https-rustls"] | ||
| blocking-https-rustls-probe = ["blocking", "bitreq/https-rustls-probe"] | ||
|
|
||
| [package.metadata.docs.rs] | ||
| all-features = true | ||
| rustdoc-args = ["--cfg", "docsrs"] | ||
|
|
||
| [package.metadata.rbmt.lint] | ||
| allowed_duplicates = [ | ||
| "getrandom", | ||
| "windows-sys", | ||
| "wit-bindgen", | ||
| ] | ||
|
|
||
| [package.metadata.rbmt.test] | ||
| # Don't test these features in isolation | ||
| exclude_features = [ | ||
| "tokio", | ||
| "async-https", | ||
| "async-https-native", | ||
| "async-https-rustls", | ||
| "async-https-rustls-probe", | ||
| "blocking-https", | ||
| "blocking-https-native", | ||
| "blocking-https-rustls", | ||
| "blocking-https-rustls-probe", | ||
| ] | ||
| # Run tests using these exact feature sets | ||
| exact_features = [ | ||
| ["async", "blocking"], | ||
| ["async-https", "blocking-https", "tokio"], | ||
| ["async-https-native", "blocking-https-native", "tokio"], | ||
| ["async-https-rustls", "blocking-https-rustls", "tokio"], | ||
| ["async-https-rustls-probe", "blocking-https-rustls-probe", "tokio"], | ||
| ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| # Esplora Client | ||
|
|
||
| Asynchronous and blocking clients for interacting with Esplora servers over HTTP. | ||
|
|
||
| See [`esplora-types`](../esplora-types) if you only need the request/response types, with no HTTP client dependency. |
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| [package] | ||
| name = "esplora-types" | ||
| version = "0.1.0" | ||
| edition = "2021" | ||
| authors = [ | ||
| "Alekos Filini <alekos.filini@gmail.com>", | ||
| "Bitcoin Dev Kit Developers" | ||
| ] | ||
| license = "MIT OR Apache-2.0" | ||
| homepage = "https://github.com/bitcoindevkit/rust-esplora-client" | ||
| repository = "https://github.com/bitcoindevkit/rust-esplora-client" | ||
| documentation = "https://docs.rs/esplora-types/" | ||
| description = "Shared types for interacting with Esplora-compliant servers" | ||
| keywords = ["bitcoin", "esplora"] | ||
| readme = "README.md" | ||
| rust-version = "1.75.0" # MSRV | ||
|
|
||
| [lib] | ||
| name = "esplora_types" | ||
|
|
||
| [dependencies] | ||
| serde = { version = "1.0.194", features = ["derive"] } | ||
| bitcoin = { version = "0.32", features = ["serde"], default-features = false } | ||
|
|
||
| [package.metadata.docs.rs] | ||
| all-features = true | ||
| rustdoc-args = ["--cfg", "docsrs"] | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| # Esplora Types | ||
|
|
||
| Shared, transport-agnostic types and deserializers for the | ||
| [Esplora API](https://github.com/Blockstream/esplora/blob/master/API.md). | ||
|
|
||
| This crate has no HTTP client dependency. See | ||
| [`esplora-client`](../esplora-client) for a blocking and async HTTP client | ||
| built on these types. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the testenv specific to the esplora clients? If it isn't or doesn't have to be can it be shared somehow between the esplora-client and future mempoolspace-client tests? Don't need to change anything right now but something to think about for a future PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed testenv isn't Esplora-specific, and it'd make sense to share it once mempool-client gets its own tests. I'll factor that in when I open that PR.