Commit Graph

4505 Commits

Author SHA1 Message Date
Tobin C. Harding 0a45c68cf8
Introduce helper function name policy
As much as it hurts the C hacker inside me we have settled on using
`_internal` to mark private function names that clash with a public
function of the same name.

Introduce a policy section and rename one instance, I did not grep the
codebase looking for other violations.

This came up because I had to look at what `_inner` implied when reading
the function name somewhere else.
2024-08-06 04:17:28 +10:00
merge-script 8c0de95749
Merge rust-bitcoin/rust-bitcoin#3113: Push up the Default bound on HashEngine in order to better support keyed hash functions
2969b032f9 Push up the Default bound on HashEngine (Nick Johnson)

Pull request description:

  Backstory for this patch is in #3084, and this might be enough to close that issue, but I think some follow up work might be required.

  I took Kixunil's advice and pushed up the `Default` bound on `HashEngine` all the way to the default methods themselves on the `GeneralHash` trait. I initially placed the bound just on the assocated type `Engine` of `GeneralHash`, which is a tad cleaner and keeps the bound from "leaking" downstream into things like `Hmac` and `Hkdf` implementations. However, that restricts `GeneralHash` implementations to just unkeyed hash functions and I believe there will be value in having `Poly1305` and `SipHash24` still leverage the interface. I struggled a bit on the best spots to put these bounds (even found the syntax a little jarring at times, I found [RFC2289](https://rust-lang.github.io/rfcs/2289-associated-type-bounds.html) helpful if others do too).

  Refactored the existing keyed hash function, `SipHash24`, to no longer have `Default` functions with zero-value keys. I kept the test coverage though by just hardcoding the zero-value keys over in the tests.

  Refactoring the `hash_type` macro for keyed hashes was getting a little hairy, so backed off and just wrote the bare minimum for `SipHash24` inline. Once `Poly1305` lands there will be two keyed hash functions and I think it will make more sense to then generalize over them.

ACKs for top commit:
  Kixunil:
    ACK 2969b032f9
  apoelstra:
    ACK 2969b032f9

Tree-SHA512: 9ca8f8baa6d60c36627eb3564f5faafcddd0a69fed5e29965404e405d3d09cb08bec2e05f14e177b8bfa2a488efba9947c0e0c158db6b00b44c8c11869328f5a
2024-08-01 16:02:26 +00:00
Tobin C. Harding 877ed23e28
Merge rust-bitcoin/rust-bitcoin#3116: Automated daily update to rustc (to nightly-2024-07-31)
3bd59a5497 Automated update to Github CI to rustc nightly-2024-07-31 (Update Nightly Rustc Bot)

Pull request description:

  Automated update to Github CI workflow `rust.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  tcharding:
    ACK 3bd59a5497

Tree-SHA512: 713a576da3050759e186b275aa49f0106765161f4dc78283721af96dce5a6cfd5317b0493c994512ba8de0c3621687306cf31c4348b33b09848f4b27d45746d0
2024-08-01 07:38:48 -05:00
Update Nightly Rustc Bot 3bd59a5497 Automated update to Github CI to rustc nightly-2024-07-31 2024-08-01 01:41:09 +00:00
Nick Johnson 2969b032f9 Push up the Default bound on HashEngine
* The Default bound only makes sense for unkeyed hash functions which
can fire up a new engine without a key. Keyed hash functions, like
SipHash24 or Poly1305 require a secret key to be initialized and
should not implement a default engine generator.
* SipHash24 tests updated to the previous default key "0".
2024-07-31 13:13:51 -07:00
merge-script 80671bbea8
Merge rust-bitcoin/rust-bitcoin#3096: Add validation extension to script
298b96c579 Add an extension trait for script validation (Tobin C. Harding)
c1aa33ed89 Use impl syntax instead of generic (Tobin C. Harding)

Pull request description:

  Add an extension trait for the validation logic in preparation for moving the `Script` type to `primitives`.

ACKs for top commit:
  Kixunil:
    ACK 298b96c579
  apoelstra:
    ACK 298b96c579

Tree-SHA512: 6282bf7bd5657f0ec68e1369150969daf51f97dc6ff72a419fe823d60ab8a993f1e6d56b1cffa114580d388b36fe2bcbf7b9865776f98c46d68b7368168a07ee
2024-07-30 15:36:55 +00:00
Tobin C. Harding 298b96c579
Add an extension trait for script validation
Add an extension trait for the validation logic in preparation for
moving the `Script` type to `primitives`.
2024-07-29 07:48:07 -05:00
Tobin C. Harding c1aa33ed89
Use impl syntax instead of generic
A single trait bound can be expressed using the `impl` style. This is a
breaking change because callers can no longer use turbofish. In this
case that probably does not matter because users are likely just passing
an integer in and letting the compiler infer the type.

Done in preparation for moving logic into an extension trait so that the
functions can be parsed by the `define_extension_trait` macro.

ref: https://doc.rust-lang.org/reference/types/impl-trait.html
2024-07-29 07:43:50 -05:00
Tobin C. Harding 1fbc653822
Merge rust-bitcoin/rust-bitcoin#3111: Automated daily update to rustc (to nightly-2024-07-28)
842fc9b24d Automated update to Github CI to rustc nightly-2024-07-28 (Update Nightly Rustc Bot)

Pull request description:

  Automated update to Github CI workflow `rust.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  tcharding:
    ACK 842fc9b24d

Tree-SHA512: 3763f634bf6209207a45564ce1e7ac8ee042eb1fe7bfe32721daebcc191aaff0928dbb0a21827f83c4ac5b7a87f420b56524effd0829e9c7a678ce8fdc221167
2024-07-29 07:39:32 -05:00
Update Nightly Rustc Bot 842fc9b24d Automated update to Github CI to rustc nightly-2024-07-28 2024-07-29 01:36:26 +00:00
merge-script 15b87606bf
Merge rust-bitcoin/rust-bitcoin#3100: Bump MSRV to 1.63
c72069e921 Bump MSRV to 1.63 (Martin Habovstiak)

Pull request description:

  The version 1.63 satisfies our requirements for MSRV and provides significant benefits so this commit bumps it. This commit also starts using some advantages of the new MSRV, namely namespaced features, weak dependencies and the ability to use trait bounds in `const` context.

  This however does not yet migrade the `rand-std` feature because that requires a release of `secp256k1` with the same kind of change - bumping MSRV to 1.63 and removing `rand-std` in favor of weak dependency. (Accompanying PR to secp256k1: https://github.com/rust-bitcoin/rust-secp256k1/pull/709 )

  Suggested plan:

  * merge both PRs
  * at some point release `hashes` and `secp256k`
  * remove `rand-std` from `bitcoin`
  * release the rest of the crates

ACKs for top commit:
  apoelstra:
    ACK c72069e921
  tcharding:
    ACK c72069e921

Tree-SHA512: 0b301ef8145f01967318d3ed1c738d33e6cf9e44f835f3762122b460a536f926916dbd6ea39d6f80b4f95402cd845e924401e75427dbb0731ca5b12b4fa6915e
2024-07-28 21:11:28 +00:00
merge-script 0c5b1a6804
Merge rust-bitcoin/rust-bitcoin#3003: ci: semver-checks for non-additive cargo features
f76f68217b ci: pin cargo-semver-checks version and cron job (Jose Storopoli)
8a91015769 ci: harden zip command with -n (Jose Storopoli)
4edd504cb6 ci: pin stable in semver-checks and updates weekly (Jose Storopoli)
1948995443 ci: semver-check for non-additive cargo features (Jose Storopoli)
b5180732e6 io: add not_unwind_safe as PhantomData (Jose Storopoli)

Pull request description:

  Closes #3001.
  Closes #3023.

  ## Summary

  Adds new CI Job that checks for semver breaks in `no-default-features` against `all-features`.
  A fail would represent that we are inserting non-additive cargo features.

  Credits to @Kixunil for the amazing idea.

  This PR does:

  1. fix a non-additive feature in `bitcoin-io`;
  1. move the current `semver-checks` to `semver-checks-pr` since it checks if the PR is introducing classical semver-checks;
  1. adds a new `semver-checks-feature`;
  1. Add `-n` to `unzip` in `semver-checks`;
  1. pins `rustc` stable and updates in a cron job weekly on Fri; and
  1. pins `cargo-semver-checks` to `0.33.0` and updates in a cron job weekly on Sat.

  ## Implementation notes

  We don't need nightly (and somehow it fails) but if we incorporate the ENV [`RUSTC_BOOTSTRAP=1` as hardcoded in the cargo-semver-checks codebase](50b93599df/src/rustdoc_cmd.rs (L110C17-L110C39)) and run `cargo` with the stable toolchain it works.

  To get the `cargo-semver-checks` version we use the [`crates.io` API](https://crates.io/api/v1/crates/cargo-semver-checks) along with some quite intelligible `jg` magic (NOTE: `jq` is available in GH's `ubuntu-latest` image).

ACKs for top commit:
  Kixunil:
    ACK f76f68217b
  apoelstra:
    ACK f76f68217b At some point we should pull the stable-version to the root with the nightly-version and use it everywhere; but can be in a separate PR

Tree-SHA512: 9949350fb7d14853ed9b24c43c1b8c28d1178cc623fd4bb1a71b40f0e32a56052596f40ab55b1c26d17f4f4538a7a321b34cae2a65c110ed1939cc5cf0fc55ce
2024-07-28 17:46:39 +00:00
merge-script 9868d9aaec
Merge rust-bitcoin/rust-bitcoin#3108: Fix typo in primitives Cargo.toml
14fdffeb5a Fix typo in primitives Cargo.toml (Shing Him Ng)

Pull request description:

  Closes #3090

ACKs for top commit:
  apoelstra:
    ACK 14fdffeb5a
  tcharding:
    ACK 14fdffeb5a
  Kixunil:
    ACK 14fdffeb5a

Tree-SHA512: 368095b956bbd11ef1c3610914f1950256b56479295f5abab9993ed96de580f0de122bbbe3a6b5cf995259bd931ce5d97599d1ac2684533bf104414bd8aa3386
2024-07-28 16:56:15 +00:00
merge-script cf026cf677
Merge rust-bitcoin/rust-bitcoin#3109: Automated nightly rustfmt (2024-07-28)
08fc780033 2024-07-28 automated rustfmt nightly (Fmt Bot)

Pull request description:

  Automated nightly `rustfmt` changes by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  apoelstra:
    ACK 08fc780033

Tree-SHA512: c8b7900e41d5c1e672b262c048a6f83a45faaca1d1e8d625fa5ce983bff2e75feb792f24a9695ae0a67eaff79d105ac0c2744141e4f6298babc848935f944aa1
2024-07-28 16:10:42 +00:00
merge-script be4a3954d2
Merge rust-bitcoin/rust-bitcoin#3105: Set `diff=rust` for `*.rs` in `.gitattributes`
353af24ffe Set `diff=rust` for `*.rs` in `.gitattributes` (Martin Habovstiak)

Pull request description:

  This slightly improves the diffs shown by git commands.

ACKs for top commit:
  tcharding:
    utACK 353af24ffe
  apoelstra:
    ACK 353af24ffe

Tree-SHA512: 2b74efa362943e91823e0ad03efaa92f577ab73aabb0e0eecc28cbe1841d2e4a3ce14e94d2a6664e472f7bc5a2d6174f848ee2bd2dbb54a1b992b7874254c51d
2024-07-28 11:30:24 +00:00
Fmt Bot 08fc780033 2024-07-28 automated rustfmt nightly 2024-07-28 01:12:04 +00:00
Shing Him Ng 14fdffeb5a Fix typo in primitives Cargo.toml 2024-07-27 16:29:09 -05:00
merge-script 5f79ff0966
Merge rust-bitcoin/rust-bitcoin#3098: Make `ScriptBuf::p2wpkh_script_code` stand alone
feef34fdea Make ScriptBuf::p2wpkh_script_code stand alone (Tobin C. Harding)

Pull request description:

  We would like to move the `Script` type to `primitives` without moving any key stuff, including pubkey hashes. We may later, before releasing `primitives`, move the `WPubkeyHash` at which time this patch can be reverted or re-implemented on `ScriptBuf`.

  The `ScriptBuf::p2wpkh_script_code` function does not take `self` as a parameter but it does return `Self` - this can trivially be made into a standalone function.

  Make `ScriptBuf::p2wpkh_script_code` a standalone function.

ACKs for top commit:
  Kixunil:
    ACK feef34fdea
  apoelstra:
    ACK feef34fdea

Tree-SHA512: 9de43bb274480b85d328ddd4cb6d79b501a525837307ca399dea1c3d39e9a7c0d8719dbb0e5d852629351d2b1fe09ce0244df82c53ff9ef2342be85a71887329
2024-07-27 21:08:34 +00:00
merge-script d9981b3ac0
Merge rust-bitcoin/rust-bitcoin#3010: Add `length` field to `sha256::Midstate`
98fe6179db Use "unfinalized" in header of Midstate (Tobin C. Harding)
86de586898 Use const to construct Midstate (Tobin C. Harding)
dcb18bfa7a Add length to sha256::Midstate (Tobin C. Harding)
db0502d3cd Use third person in rustdoc (Tobin C. Harding)
34dd95f909 Debug Midstate forwards (Tobin C. Harding)
1d0e70b1da Add regression test for Midstate debug output (Tobin C. Harding)
ca823945fc Manually implement AsRef (remove Borrow) (Tobin C. Harding)
7dc68b62e9 Remove serde from sha256::Midstate (Tobin C. Harding)
07e8e5d3a6 Stop using macro for Midstate (Tobin C. Harding)
37b54dd54c Move from_midstate function (Tobin C. Harding)
9efe4cea9d Move impl block under struct (Tobin C. Harding)
5941008733 Import sha256t in docs builds (Tobin C. Harding)

Pull request description:

  "overhaul the midstate API" might be a better description. PR is broken up into many patches to the extreme to make sure all API the changes are easily noticed.

  Resolve: #2918

ACKs for top commit:
  Kixunil:
    ACK 98fe6179db
  apoelstra:
    ACK 98fe6179db

Tree-SHA512: 1384cdeea52f6a0d5b41bcfdc9127f9b983f57bb4b15c7749af2a4a40388598a9fe1ab07d0a6507ffd2f38983459f9dd400c5d3f927f6d37c1f9d80a5c7f9a6e
2024-07-27 17:11:53 +00:00
merge-script a4a84f4c1b
Merge rust-bitcoin/rust-bitcoin#3081: githooks: Added post-merge githook to check if hooks changed
a7fa237d32 githooks: Added post-merge githook to check if hooks changed (Ryan Breen)

Pull request description:

  Referring back to [this post](https://github.com/rust-bitcoin/rust-bitcoin/pull/2980#discussion_r1673140172) in #2980, there was discussion that a post-merge githook should be added to check if the user's copied githooks have changed.

  In order to distinguish between a githook that a user installed themselves and a rust-bitcoin githook, I chose to add a tag at the beginning of the project's hooks.

ACKs for top commit:
  Kixunil:
    ACK a7fa237d32
  apoelstra:
    ACK a7fa237d32 I have never used `git pull` but I also have not ever used githooks, so I guess this is good

Tree-SHA512: 90314fea81a93e5a2c698fad4837f7661dd90f9fb2ecd015cbe6472fbef8647e06a1595e2aab4f557a1cc770050b828d430eabda04500954c0e4c9995098237c
2024-07-27 16:23:47 +00:00
Martin Habovstiak 353af24ffe Set `diff=rust` for `*.rs` in `.gitattributes`
This slightly improves the diffs shown by git commands.
2024-07-27 08:53:19 +02:00
Martin Habovstiak c72069e921 Bump MSRV to 1.63
The version 1.63 satisfies our requirements for MSRV and provides
significant benefits so this commit bumps it. This commit also starts
using some advantages of the new MSRV, namely namespaced features, weak
dependencies and the ability to use trait bounds in `const` context.

This however does not yet migrade the `rand-std` feature because that
requires a release of `secp256k1` with the same kind of change - bumping
MSRV to 1.63 and removing `rand-std` in favor of weak dependency.
2024-07-27 07:24:32 +02:00
merge-script 1276a99061
Merge rust-bitcoin/rust-bitcoin#3092: Direct link to ./CONTRIBUTING.md
82a0656b57 Direct link to ./CONTRIBUTING.md (Joao Leal)

Pull request description:

  For convenience.

ACKs for top commit:
  tcharding:
    ACK 82a0656b57
  Kixunil:
    ACK 82a0656b57

Tree-SHA512: ef2e0941dfb5d9c341be2f8f80286e8d8d654728262a6324a8bfdef81cfa62cc1b3f864b8926d90205b9d1deac4a7805cf70fe4a9ebd68dc58200586cec8a204
2024-07-26 22:13:44 +00:00
Jose Storopoli f76f68217b
ci: pin cargo-semver-checks version and cron job 2024-07-26 09:06:45 -03:00
Jose Storopoli 8a91015769
ci: harden zip command with -n
from the man unzip:

 -n stands for never overwrite existing files.  If a file already exists,
 skip the extraction of that file without prompting.
2024-07-26 09:05:35 -03:00
Jose Storopoli 4edd504cb6
ci: pin stable in semver-checks and updates weekly 2024-07-26 09:05:30 -03:00
merge-script d5149c1f54
Merge rust-bitcoin/rust-bitcoin#3065: Move `validation` module to `consensus_validation`
29b213daca Move validation module to consensus_validation (Tobin C. Harding)

Pull request description:

  The `consensus` module is currently doing two things, validation and encoding. These two things are orthogonal.

  Move the `consensus::validation` module to `consensus_validation`. Remove the function re-exports from `consensus`.

  This was originally discussed here: https://github.com/rust-bitcoin/rust-bitcoin/issues/2779

ACKs for top commit:
  Kixunil:
    ACK 29b213daca
  apoelstra:
    ACK 29b213daca

Tree-SHA512: 3bd0e43c220b0d89a47e9df0e0c92b776ccc65f5f60d57f413db834acc8e86269379bc9fdd688f8c4f0138db22f8eb8983770afa2d7d53d51acf063f2302121c
2024-07-26 11:26:36 +00:00
Jose Storopoli 1948995443
ci: semver-check for non-additive cargo features
Co-authored-by: Predrag Gruevski <2348618+obi1kenobi@users.noreply.github.com>
2024-07-25 12:19:54 -03:00
Jose Storopoli b5180732e6
io: add not_unwind_safe as PhantomData 2024-07-25 12:19:48 -03:00
merge-script d218848b36
Merge rust-bitcoin/rust-bitcoin#3037: `primitives`: Re-export `units` types
991c73cdf9 primitives: Re-export everything from units (Tobin C. Harding)
7a44908aee primitives: Use wildard re-export in locktimes (Tobin C. Harding)
d1c876eda5 Remove rustfmt attribute (Tobin C. Harding)
e3d9376a9b units: Remove serde re-export (Tobin C. Harding)

Pull request description:

  Re-export `units` types by doing:

  - Patch 1: Remove the public re-export of `serde` so that it does not shadow the private one in `primitives`
  - Patch2: Fix formatting (remove attribute and format)
  - Patch 3 and 4: Use wildcard re-exports

ACKs for top commit:
  Kixunil:
    ACK 991c73cdf9
  apoelstra:
    ACK 991c73cdf9

Tree-SHA512: dd71aa97fe5718a1229bfe26b776a72ebdd745a15a0e8ce8dae421c3a4c49f0f1e27d676056b24c35318cc3643a2ce712b4a69cc09f42b7c43259680bea931f3
2024-07-25 14:16:54 +00:00
Tobin C. Harding 6e6a0578de
Merge rust-bitcoin/rust-bitcoin#3101: Automated daily update to rustc (to nightly-2024-07-24)
33d0a95b8c Automated update to Github CI to rustc nightly-2024-07-24 (Update Nightly Rustc Bot)

Pull request description:

  Automated update to Github CI workflow `rust.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  tcharding:
    ACK 33d0a95b8c

Tree-SHA512: a33ed623396222f73f145187297a7f6f44532790328d4d6d6821067e6d5fa3a21d7d285e420aec5101af9e5b54c778f12812cfff418bc1526d63000f007e3c26
2024-07-24 22:39:31 -05:00
Update Nightly Rustc Bot 33d0a95b8c Automated update to Github CI to rustc nightly-2024-07-24 2024-07-25 01:33:20 +00:00
Ryan Breen a7fa237d32 githooks: Added post-merge githook to check if hooks changed 2024-07-24 19:59:39 -04:00
Tobin C. Harding feef34fdea
Make ScriptBuf::p2wpkh_script_code stand alone
We would like to move the `Script` type to `primitives` without moving
any key stuff, including pubkey hashes. We may later, before releasing
`primitives`, move the `WPubkeyHash` at which time this patch can be
reverted or re-implemented on `ScriptBuf`.

The `ScriptBuf::p2wpkh_script_code` function does not take `self` as a
parameter but it does return `Self` - this can trivially be made into a
standalone function.

Make `ScriptBuf::p2wpkh_script_code` a standalone function.
2024-07-23 11:24:31 -05:00
merge-script 1b83763cdc
Merge rust-bitcoin/rust-bitcoin#3083: Fix rustdocs in `blockdata`
3b15ef6d27 Fix rustdocs in `blockdata` (Jamil Lambert, PhD)

Pull request description:

  Following up on the [comment](https://github.com/rust-bitcoin/rust-bitcoin/pull/2646#discussion_r1548848611) in #2646 the rustdocs formatting was fixed in `blockdata`.

ACKs for top commit:
  Kixunil:
    ACK 3b15ef6d27
  tcharding:
    ACK 3b15ef6d27

Tree-SHA512: 509aa2b8ae559f5a7f8230c016c0866f468cc147773238e226b9a975784d7a424c41a5d966ddcf9b3f8f8d4fe197a4f272b5777c61f3cc53051803abb520b95e
2024-07-23 13:29:27 +00:00
Tobin C. Harding 991c73cdf9
primitives: Re-export everything from units
We recently decided to make everything in `units` available at the same
path as in `primitives` and not re-export the actual `units` crate.

Re-export everything from the `units` crate root at the `primitives`
crate root using a wildcard.
2024-07-23 02:04:11 -05:00
Tobin C. Harding 7a44908aee
primitives: Use wildard re-export in locktimes
We recently decided to use wildcard re-exports when re-exporting things
from an identically named module in a sub crate, ie. to mirror the
directory structure structure ala core/std.

In the `primitives::locktime` modules re-export everything from the
`units::locktime` modules using a wildcard.
2024-07-23 01:50:44 -05:00
Tobin C. Harding d1c876eda5
Remove rustfmt attribute
There are no other use statements so we do not need to keep the public
ones separate with a `rustfmt` attribute.

Remove the attribute and run the formatter.
2024-07-23 01:48:20 -05:00
Tobin C. Harding e3d9376a9b
units: Remove serde re-export
We re-export to help users keep their dependencies in sync but `serde`
is at `v1.0` so this is not really a problem.

Remove the public re-export of `serde` (and with current MSRV we don't
need the `extern crate` at all).
2024-07-23 01:41:41 -05:00
merge-script e7af76f1cd
Merge rust-bitcoin/rust-bitcoin#2936: Bump honggfuzz version
43360bdd74 Bump honggfuzz version (yancy)

Pull request description:

  Bump hongfuzz version

ACKs for top commit:
  apoelstra:
    ACK 43360bdd74
  tcharding:
    ACK 43360bdd74

Tree-SHA512: fe0e9e5a54fa2d4205a3d9974c19b86e57bfd5e525cd7f379c3c1b7ed15d37b03e6808a7cbf5c15b35bf69df820bd302fb81b5a8525fd3a09102aef13f3abf0d
2024-07-22 21:57:14 +00:00
Joao Leal 82a0656b57
Direct link to ./CONTRIBUTING.md 2024-07-22 18:16:25 -03:00
Tobin C. Harding c82c052407
Merge rust-bitcoin/rust-bitcoin#3089: Automated daily update to rustc (to nightly-2024-07-21)
dbb5917128 Automated update to Github CI to rustc nightly-2024-07-21 (Update Nightly Rustc Bot)

Pull request description:

  Automated update to Github CI workflow `rust.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  tcharding:
    ACK dbb5917128

Tree-SHA512: 6f9a7939ff2eea6d07338cb75e393e319b2d38009dbad35e408bd23534e6240ef8c95a268b2316f7b81045eba7031e4269918a3841fe3353da966605ea752407
2024-07-22 14:26:55 -05:00
merge-script 5d20f2ec4c
Merge rust-bitcoin/rust-bitcoin#3085: Automated nightly rustfmt (2024-07-21)
61d46fffa8 2024-07-21 automated rustfmt nightly (Fmt Bot)

Pull request description:

  Automated nightly `rustfmt` changes by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  tcharding:
    ACK 61d46fffa8
  apoelstra:
    ACK 61d46fffa8

Tree-SHA512: 405120e45a94687504796c0cfcfa613eb4b29037a5a10d263dccc22f501a6e8f91ddb832964fc8eac804c3007b73bddbbd41c14356647d14c15a81b5da0c0829
2024-07-22 19:20:03 +00:00
Update Nightly Rustc Bot dbb5917128 Automated update to Github CI to rustc nightly-2024-07-21 2024-07-22 01:36:12 +00:00
Fmt Bot 61d46fffa8 2024-07-21 automated rustfmt nightly 2024-07-21 01:11:38 +00:00
merge-script 84ed27b194
Merge rust-bitcoin/rust-bitcoin#3056: CONTRIBUTING: error/expect messages
0beefda7ea CONTRIBUTING: error/expect messages (Jose Storopoli)

Pull request description:

  - adds an item that all error messages
    should be lower case, except for proper nouns and variable names.
  - adds a section on expect messages,
    following discussion in #3019 and #3053.

  Closes #3053.

ACKs for top commit:
  tcharding:
    ACK 0beefda7ea
  Kixunil:
    ACK 0beefda7ea
  apoelstra:
    ACK 0beefda7ea

Tree-SHA512: b924245e5d18d4f627d4998073422003def789c87502bca121d5db443f5bbe387bfe951664458c9495a6ea0995b6ccf6e28d1784e19dfb876d7eddf3c6209727
2024-07-19 17:07:01 +00:00
merge-script e1478b1802
Merge rust-bitcoin/rust-bitcoin#3069: Remove re-export of `ParseIntError`
ab581a90f8 Remove re-export of ParseIntError (Tobin C. Harding)

Pull request description:

  In d242125 I claimed that `ParseIntError` was somehow special, I no longer thing this is the case. As we pin down the re-export policy (for errors and other types) it is hard if we have one non-typical re-export.

  We have https://github.com/rust-bitcoin/rust-bitcoin/issues/3068 to discuss the policy, for now just remove the unusual re-export.

ACKs for top commit:
  Kixunil:
    ACK ab581a90f8
  shinghim:
    ACK ab581a90f8
  apoelstra:
    ACK ab581a90f8

Tree-SHA512: 5ac4123aeb27c8cee78e5760f21e70be8035d526ba7e14e72759cba27f98b51cc2cba9b2bf0eeb99e0f6b7210ec4a750986bb6c5dc0725ed892730fdec8a7e06
2024-07-19 15:36:21 +00:00
merge-script ff5d437d42
Merge rust-bitcoin/rust-bitcoin#3067: Move `params` to the `network` module
54c30556a2 Move params to network module (Tobin C. Harding)
045a661ebe Create network directory (Tobin C. Harding)

Pull request description:

  Discussed in #2779. Patch one moves `network.rs` to `network/mod.rs`, and patch 2 moves the `params` module over there.

ACKs for top commit:
  apoelstra:
    ACK 54c30556a2 Yeah, this seems like a good place for it
  Kixunil:
    ACK 54c30556a2

Tree-SHA512: 134813419db21323d303d465b12fcbf37fd61dc1baf3305e156d324eafd822379e63dede02877ee99dce41540193a29e6e13acd13f9121f3e2fe11096524aa5e
2024-07-19 14:10:26 +00:00
Tobin C. Harding 29b213daca
Move validation module to consensus_validation
The `consensus` module is currently doing two things, validation and
encoding. These two things are orthogonal.

Move the `consensus::validation` module to `consensus_validation`.

Remove the function re-exports from `consensus`.
2024-07-19 14:28:31 +10:00
Tobin C. Harding 1c3f39e99e
Merge rust-bitcoin/rust-bitcoin#3080: Automated daily update to rustc (to nightly-2024-07-17)
04bcb7950d Automated update to Github CI to rustc nightly-2024-07-17 (Update Nightly Rustc Bot)

Pull request description:

  Automated update to Github CI workflow `rust.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  tcharding:
    ACK 04bcb7950d

Tree-SHA512: 2b2a02fd5eb5dfcc1e8b1551ef66180d76019655262a5eebeb6e849885db5e37c495cd9d1108ce550b9401c446a5abf2ca30508eb3d1139a807188b668d232ef
2024-07-19 08:06:42 +10:00