Commit Graph

3679 Commits

Author SHA1 Message Date
Tobin C. Harding 2dfe455161
Remove mention of core2
We no longer depend on `core2`, remove stale code comment mention of the
crate.

Fix: #2034
2024-01-16 09:44:00 +11:00
Tobin C. Harding de9c2bc43d
p2p: Improve nonce documentation
Better describe what the nonce is used for.

Note this file has not had its docs manicured so the line length is 80
still, just use the same line length instead of the conventional 100.

Fix: #575
2024-01-16 09:17:55 +11:00
Tobin C. Harding 32d68fd1fa
io: Add BufRead trait
Add a `BufRead` trait for types that perform buffered reading.

Implement it for:
- `Take`
- `Cursor`
- `std::io::BufRead` readers
- (in no-std builds) for slice of u8s
2024-01-16 09:11:20 +11:00
Andrew Poelstra 8f1dabb4d7
Merge rust-bitcoin/rust-bitcoin#2252: io: Simplify crate docs and add README
d480adaf25 io: Simplify crate docs and add README (Tobin C. Harding)

Pull request description:

  Simplify the docs in `lib.rs` and copy them into a minimal README file.

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

Tree-SHA512: 17b6bed688854f9b0cafa0a0320683e75cf0d8f190a4f526d982292c0ae0e4834e4f239e451a1ded124d44d6f0c8f248893eeb27f0a7a5a0b97a757515f732ee
2024-01-15 18:33:14 +00:00
Andrew Poelstra 6c94546360
Merge rust-bitcoin/rust-bitcoin#2248: Implement ArbitaryOrd for absolute::LockTime
518f0970c9 Implement ArbitaryOrd for absolute::LockTime (Tobin C. Harding)

Pull request description:

  At times we would like to provide types that do not implement `PartialOrd` and `Ord` because it does not make sense. I.e we do not want users writing `a < b`. This could range from kind-of-iffy to down-right-buggy (like comparing absolute locktimes).

  However this decision effects downstream users who may not care about what the ordering means they just need to use it for some other reason e.g., to use as part of a key for a `BTreeMap` (as we do in `miniscript` requiring the `AbsLockTime` type).

  A solution to this problem is to provide a wrapper data type that adds `PartialOrd` and `Ord` implementations. I wrote the `ordered` crate is for this very purpose.

ACKs for top commit:
  apoelstra:
    ACK 518f0970c9
  Kixunil:
    ACK 518f0970c9

Tree-SHA512: 05c753e650b6e2f181caf7dc363c4f8ec89237b42883bd695a64da0661436c9a7e715347f8fcf4fb19ce069cbf75a93032052e946f05fd8029f61860cf9c6225
2024-01-15 16:03:10 +00:00
Andrew Poelstra 8ad2a6e735
Merge rust-bitcoin/rust-bitcoin#2338: Improve `Signature` field names
271b45299f Improve Signature field names (Tobin C. Harding)

Pull request description:

  Applies to both `ecdsa::Signature` and `taproot::Signature`.

  Re-name the `Signature` fields with more descriptive names. The names used were decided upon in the issue discussion.

  Impove rustdocs while we are at it.

  Note, the change to `sign-tx-segwit-v0` is refactor only, the diff does not show it but we have a local variable already called `sighash_type` that is equal to `EcdsaSighashType::All`.

  Fix: #2139

ACKs for top commit:
  Kixunil:
    ACK 271b45299f
  apoelstra:
    ACK 271b45299f

Tree-SHA512: b27221e922206b2510b073c0f38678f97f0c946707e3e679eee181faa170348101198706f9ca5803a55c799b0b330cc263cc103cd9beefff4e5c58d8fea77b8d
2024-01-15 15:56:31 +00:00
Andrew Poelstra 910d5a56bd
Merge rust-bitcoin/rust-bitcoin#2340: Bump model-checking/kani-github-action from 1.0 to 1.1
9cbe348c9a Bump model-checking/kani-github-action from 1.0 to 1.1 (dependabot[bot])

Pull request description:

  Bumps [model-checking/kani-github-action](https://github.com/model-checking/kani-github-action) from 1.0 to 1.1.
  <details>
  <summary>Release notes</summary>
  <p><em>Sourced from <a href="https://github.com/model-checking/kani-github-action/releases">model-checking/kani-github-action's releases</a>.</em></p>
  <blockquote>
  <h2>Kani Verifier CI Action 1.1</h2>
  <h2>What's Changed</h2>
  <ul>
  <li>Use stable version to install Kani by <a href="https://github.com/zhassan-aws"><code>@zhassan-aws</code></a> in <a href="https://redirect.github.com/model-checking/kani-github-action/pull/53">model-checking/kani-github-action#53</a></li>
  </ul>
  <p><strong>Full Changelog</strong>: <a href="https://github.com/model-checking/kani-github-action/compare/v1.0...v1.1">https://github.com/model-checking/kani-github-action/compare/v1.0...v1.1</a></p>
  </blockquote>
  </details>
  <details>
  <summary>Commits</summary>
  <ul>
  <li><a href="f838096619"><code>f838096</code></a> Update README to use v1 instead of v1.0 (<a href="https://redirect.github.com/model-checking/kani-github-action/issues/55">#55</a>)</li>
  <li><a href="3c6810af57"><code>3c6810a</code></a> Use stable version to install Kani (<a href="https://redirect.github.com/model-checking/kani-github-action/issues/53">#53</a>)</li>
  <li>See full diff in <a href="https://github.com/model-checking/kani-github-action/compare/v1.0...v1.1">compare view</a></li>
  </ul>
  </details>
  <br />

  [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=model-checking/kani-github-action&package-manager=github_actions&previous-version=1.0&new-version=1.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

  Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

  [//]: # (dependabot-automerge-start)
  [//]: # (dependabot-automerge-end)

  ---

  <details>
  <summary>Dependabot commands and options</summary>
  <br />

  You can trigger Dependabot actions by commenting on this PR:
  - `@dependabot rebase` will rebase this PR
  - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
  - `@dependabot merge` will merge this PR after your CI passes on it
  - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
  - `@dependabot cancel merge` will cancel a previously requested merge and block automerging
  - `@dependabot reopen` will reopen this PR if it is closed
  - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
  - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

  </details>

ACKs for top commit:
  Kixunil:
    ACK 9cbe348c9a

Tree-SHA512: dc636fb480254da2029b3ce35970bee6f2f6e95f3efcf7ef5dc75a261f25054c50c47c66e02a4a7964fe94effabb0623d84bc2591e23e3fe547c9fb47244a392
2024-01-15 15:17:29 +00:00
dependabot[bot] 9cbe348c9a
Bump model-checking/kani-github-action from 1.0 to 1.1
Bumps [model-checking/kani-github-action](https://github.com/model-checking/kani-github-action) from 1.0 to 1.1.
- [Release notes](https://github.com/model-checking/kani-github-action/releases)
- [Commits](https://github.com/model-checking/kani-github-action/compare/v1.0...v1.1)

---
updated-dependencies:
- dependency-name: model-checking/kani-github-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-15 10:43:18 +00:00
Tobin C. Harding 271b45299f
Improve Signature field names
Applies to both `ecdsa::Signature` and `taproot::Signature`.

Re-name the `Signature` fields with more descriptive names. The
names used were decided upon in the issue discussion.

Impove rustdocs while we are at it.

Note, the change to `sign-tx-segwit-v0` is refactor only, the diff does
not show it but we have a local variable already called `sighash_type`
that is equal to `EcdsaSighashType::All`.

Includes a function argument rename as well, just to be uniform.

Fix: #2139
2024-01-15 10:26:40 +11:00
Tobin C. Harding 1d536ac8b2
units: Enable parsing Amount from u64::MAX
Our `Amount` type uses an internal `u64` and we maintain no invariants
on the inner value. Therefore we should be able to parse `u64::MAX`.

Fix the parsing code by removing the explicit, incorrect check and fix
unit tests to mirror this behaviour.

Fix: #2297
2024-01-15 08:56:57 +11:00
Tobin C. Harding e185fe46df
just: Lint with nightly toolchain
Recently we switched to using the nightly toolchain to lint, update the
`justfile` appropriately.
2024-01-15 06:43:33 +11:00
Andrew Poelstra 52b239ef70
Merge rust-bitcoin/rust-bitcoin#2334: Automated nightly rustfmt (2024-01-14)
e768c92ce3 2024-01-14 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 e768c92ce3 will merge with one ACK

Tree-SHA512: 76ecb717c9dee8e765fc3f4c94a58284549dc59309e35b47a183d45c482dce9ac68f2c13f010189a39c8a768410d12b895caf714c7faf409619556b8d4cfa39e
2024-01-14 15:40:26 +00:00
Andrew Poelstra 743bf6c598
Merge rust-bitcoin/rust-bitcoin#2332: fix nightly clippy issues
e762c53725 fix nightly clippy issues (Andrew Poelstra)

Pull request description:

  I don't mind making these PRs, but I think we should start pinning our nightlies, and using a script to update the pin every week (or day, or whatever). When our CI breaks due to tooling changes, it means that our release branches will have permanently broken CI jobs, which I'd like to avoid in the future.

  If the automatic pin update failed, we'd close it and manually create one that fixed the nw issues.

ACKs for top commit:
  tcharding:
    ACK e762c53725

Tree-SHA512: c61af0d69746258268b28be2ef7bd703e121c02fcf48c0625019e51407275b2b501aa31b2e65a548f8aaa903c49eda2d426c53e9530ba79b9bf1d82a690f4372
2024-01-14 15:15:53 +00:00
Fmt Bot e768c92ce3 2024-01-14 automated rustfmt nightly 2024-01-14 01:00:10 +00:00
Andrew Poelstra e762c53725
fix nightly clippy issues 2024-01-13 15:20:53 +00:00
Andrew Poelstra 5e3d1295e0
Merge rust-bitcoin/rust-bitcoin#2325: Fix some typos
04f3e939a7 Fix typos in test function names (GoodDaisy)
ed47c35b4d Fix typos in rustdocs (GoodDaisy)

Pull request description:

  1. Fix typos in rustdocs:

      hexidecimal -> hexadecimal
      lenght -> length

  2. Fix typos in test function names:

      u256_wrapping_add_wraps_at_boundry -> u256_wrapping_add_wraps_at_boundary
      u256_wrapping_sub_wraps_at_boundry -> u256_wrapping_sub_wraps_at_boundary

ACKs for top commit:
  apoelstra:
    ACK 04f3e939a7
  tcharding:
    ACK 04f3e939a7

Tree-SHA512: 3b94db3c2af71ae2f941c2662b358ea6270b5ff5a784b0c57520cad3b03c6e14adba3ee86bee21b5ba5217e40b85eb006dba16293d3842d61646bacc52fac9fe
2024-01-13 00:24:47 +00:00
Andrew Poelstra 1ddd1b959f
Merge rust-bitcoin/rust-bitcoin#2330: docs: Remove pinning from hashes readme
3a562db39d docs: Remove pinning from hashes readme (Tobin C. Harding)

Pull request description:

  We do not need to pin with the current MSRV, remove the stale mention of it from the `hashes` readme file.

ACKs for top commit:
  apoelstra:
    ACK 3a562db39d will merge with one-ACK carveout

Tree-SHA512: a3f2017ab40e28d1e047ec5466e4b101dfc13280226c71ec5b36d46f54bed359eccbce16d811cee100fb134f3091f7c986c7b2afa3adaa15942bee9e08e730f1
2024-01-12 15:14:01 +00:00
GoodDaisy 04f3e939a7 Fix typos in test function names 2024-01-11 22:45:58 +08:00
GoodDaisy ed47c35b4d Fix typos in rustdocs 2024-01-11 22:45:45 +08:00
Tobin C. Harding 3a562db39d
docs: Remove pinning from hashes readme
We do not need to pin with the current MSRV, remove the stale mention of
it from the `hashes` readme file.
2024-01-11 15:08:44 +11:00
Andrew Poelstra 67793d04c3
Merge rust-bitcoin/rust-bitcoin#2320: Remove `AddressInner` from rustdocs
08d2b203a5 Remove rustdoc about attribute (Tobin C. Harding)
eea0b697bf Fix stale docs (Tobin C. Harding)

Pull request description:

  Do two miner docs fixes.

  - Patch 1: Fixes some stale docs I left in when refactoring the `AddressInner` type.
  - Patch 2: Uses code comments instead of rustdoc and fixes the issue linked below.

  Fix: #2315

ACKs for top commit:
  sanket1729:
    utACK 08d2b203a5

Tree-SHA512: e68276473b451c02e230364d386d5b4b610c8ec73ff30e97e111cd339cc2238b65e08c9a83aac5f9d5d6c2e1dd1ee10fec727dfec3bca3cd7317b7049d689f4a
2024-01-10 16:23:02 +00:00
Tobin C. Harding 08d2b203a5
Remove rustdoc about attribute
Attributes are a code level thing, they should not be documented using
rustdoc.

Use code comments and simplify the comment.
2024-01-10 10:29:37 +11:00
Tobin C. Harding eea0b697bf
Fix stale docs
Recently we modified the `AddressInner` type but the docs are
stale (FTR the type is private).

Remove the stale sentence.
2024-01-10 10:29:37 +11:00
Tobin C. Harding 518f0970c9
Implement ArbitaryOrd for absolute::LockTime
At times we would like to provide types that do not implement
`PartialOrd` and `Ord` because it does not make sense. I.e., we do not
want users writing `a < b`. This could range from kind-of-iffy to
down-right-buggy (like comparing absolute locktimes).

However this decision effects downstream users who may not care about
what the ordering means they just need to use it for some other reason
e.g., to use as part of a key for a `BTreeMap` (as we do in `miniscript`
requiring the `AbsLockTime` type).

A solution to this problem is to provide a wrapper data type that adds
`PartialOrd` and `Ord` implementations. I wrote the `ordered` crate is
for this very purpose.

Feature gate a new dependency on `ordered` and implement `ArbitraryOrd`
for `absolute::LockTime`.
2024-01-09 13:15:29 +11:00
Andrew Poelstra de9f20a620
Merge rust-bitcoin/rust-bitcoin#2321: Derive `Copy` for `WitnessProgram`
b02c7d1d33 Derive Copy for WitnessProgram (Tobin C. Harding)

Pull request description:

  Recently we started using our custom `ArrayVec` for the `program` field of `WitnessProgram`, this means we can now derive `Copy`.

  Fix: #2313

ACKs for top commit:
  apoelstra:
    ACK b02c7d1d33
  sanket1729:
    ACK b02c7d1d33

Tree-SHA512: 5741081d578f7b056c156d046dc3b0817b4b13cf69dcc1dfb8c7f4dbe8a4f9ed6c8802aaaf2b0084dbf3984d3fde807a02dbaa8c3bd29c220b3b32d3cb7c9f38
2024-01-08 20:44:06 +00:00
Andrew Poelstra 8aab550e97
Merge rust-bitcoin/rust-bitcoin#2322: Remove Push enum
a8d50a5541 Remove Push enum (Tobin C. Harding)

Pull request description:

  The `Push` enum is only ever used to get access to one of its variants. Since it is a private type we can remove it entirely and just return `PushBytes` from the `last_pushdata` function.

  Needs careful review but I believe the function name is still correctly descriptive.

  This was discovered by of a new nightly clippy warning.

ACKs for top commit:
  apoelstra:
    ACK a8d50a5541 Looks good to me. The latest compiler complains about the currently-unused variants.
  sanket1729:
    ACK a8d50a5541.

Tree-SHA512: 7f96057b0f6f5673252578253ad4f1789793dbf6e917d3974274dedf942da27e6247946262a0669eb500d47987788fcca0e020ed16c0d672188e95ee31163242
2024-01-08 20:29:02 +00:00
Andrew Poelstra 6aaaae6ffc
Merge rust-bitcoin/rust-bitcoin#2294: Deprecate `Script::is_provably_unspendable`
089ce8f0fb Deprecate `Script::is_provably_unspendable` (Martin Habovstiak)

Pull request description:

  This method is not really that useful because it checked an arbitrary condition. There already exists `OP_RETURN` semantics and the method didn't cover all possible ways the script may be invalid.

  This deprecates the method and documents why.

  Closes #2191

ACKs for top commit:
  apoelstra:
    ACK 089ce8f0fb
  tcharding:
    ACK 089ce8f0fb
  sanket1729:
    ACK 089ce8f0fb

Tree-SHA512: 044f1c06fb8cbea4f84817be41bf10315f690b2a42748a07c1dd1eb0ba10932456780956fc628fec4bf57fe0722129537874a77be482d6660f9e02de5fc5a8a0
2024-01-08 15:12:50 +00:00
Andrew Poelstra 17146b0884
Merge rust-bitcoin/rust-bitcoin#2317: Automated nightly rustfmt (2024-01-07)
774b405ba9 2024-01-07 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:
  Kixunil:
    ACK 774b405ba9
  sanket1729:
    ACK 774b405ba9. I was missing for 3 months and we have cool new stuff

Tree-SHA512: ff905c8971bc92c0716c969222d5425715773803ea05336e1bbae35c4e5cfb5cf975451452ebb769296fa84eabbbfa03672bbc0aa161f871edeefaaeb594c2ca
2024-01-08 15:06:03 +00:00
Tobin C. Harding a8d50a5541
Remove Push enum
The `Push` enum is only ever used to get access to one of its variants.
Since it is a private type we can remove it entirely and just return
`PushBytes` from the `last_pushdata` function.

Needs careful review but I believe the function name is still correctly
descriptive.
2024-01-08 14:04:55 +11:00
Tobin C. Harding b02c7d1d33
Derive Copy for WitnessProgram
Recently we started using our custom `ArrayVec` for the `program` field
of `WitnessProgram`, this means we can now derive `Copy`.

Fix: #2313
2024-01-08 13:51:12 +11:00
Fmt Bot 774b405ba9 2024-01-07 automated rustfmt nightly 2024-01-07 00:59:57 +00:00
Andrew Poelstra d5c7061ae4
Merge rust-bitcoin/rust-bitcoin#2316: Fix some typos
cc45cfe3fe Fix typos (shuoer86)
3568b9b546 Fix typos (shuoer86)

Pull request description:

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

Tree-SHA512: a4abe767f07ee4120a1c9024fb6e5aa355918be451b28ee7efcdae05ce44aa63e2aa49e631ef734ea9190d137474345b0620c497b37ef1e66f383270759fa04c
2024-01-06 16:58:16 +00:00
Tobin C. Harding d480adaf25
io: Simplify crate docs and add README
Simplify the docs in `lib.rs` and copy them into a minimal README file.
2024-01-06 08:22:36 +11:00
shuoer86 cc45cfe3fe
Fix typos 2024-01-05 23:10:52 +08:00
shuoer86 3568b9b546
Fix typos 2024-01-05 23:10:31 +08:00
Andrew Poelstra b63921d625
Merge rust-bitcoin/rust-bitcoin#2306: Improve address conversion docs
03bfe1d433 Impove rustdoc on assume_checked_ref (Tobin C. Harding)
769809f1f2 Improve the docs on as_unchecked function (Tobin C. Harding)

Pull request description:

  In #1765 we added a couple of new functions.

  - Patch 1: Fix mis-documented function.
  - Patch 2: Do trivial rustdocs fix.

ACKs for top commit:
  apoelstra:
    ACK 03bfe1d433
  Kixunil:
    ACK 03bfe1d433

Tree-SHA512: 5be6b2d288c1f4e9096014acd8618dc84a3ec6f45ae38b5d44ef7f95eccc268021bc8e8435152166606d893d4238b03e59e8f9d4fc67ba9a6c33194f3f54fc40
2024-01-04 15:59:33 +00:00
Andrew Poelstra 5108f6ecdd
Merge rust-bitcoin/rust-bitcoin#2310: use arrayvec to represent witness programs internally
01df1417c7 use arrayvec to represent witness programs (conduition)

Pull request description:

  Fixes https://github.com/rust-bitcoin/rust-bitcoin/issues/2261

  Introduces a new constructor, `WitnessProgram::from_bytes`, which creates a witness program by copying the program content from a byte slice.

ACKs for top commit:
  Kixunil:
    ACK 01df1417c7
  apoelstra:
    ACK 01df1417c7

Tree-SHA512: 73b8f2785674cd99c3f5dfe0e2180ed256942a0c29bcb1d357e0bd84fddee5e62f3f230c6cd55a37322bc3a6011467e9b7dcf24d903b20f35c095a1a1f9a29ce
2024-01-03 19:41:00 +00:00
conduition 01df1417c7
use arrayvec to represent witness programs 2024-01-03 17:10:57 +00:00
Andrew Poelstra 471da86e5a
Merge rust-bitcoin/rust-bitcoin#2309: Add the implementation of `Display` for `transaction::Version`
429a3ecec4 Add the implementation of `Display` for `transaction::Version` (harshit933)

Pull request description:

  Adds the implementation of `Display` trait for `transaction::Version`

  fixes #2308

  This is unrelated to the issue but can anyone suggest some good issues that needs to be fixed. I am also taking a look but I am confused as to which I would be able to solve. I am here to learn more.
  Thank you.

ACKs for top commit:
  apoelstra:
    ACK 429a3ecec4 Merry Christmas
  tcharding:
    ACK 429a3ecec4

Tree-SHA512: 9e59a8fe494b01caa8f211441744709f26df03891be171242bea4f7ccd7c3cc58b548cad241cab5270ad66fc9bb33ea7d6f98cc60d496c47647fb3396db9410f
2024-01-02 16:37:56 +00:00
Andrew Poelstra 26195570d9
Merge rust-bitcoin/rust-bitcoin#2312: Add allow for out of bounds indexing
278229def5 Add allow for out of bounds indexing (yancy)

Pull request description:

  Out of bounds indexing is a workaround for const panic until MSRV +1.57

ACKs for top commit:
  apoelstra:
    ACK 278229def5 Happy New Year! Will merge based on CI one-ack carveout.

Tree-SHA512: 5d525b682c28407e910ae45e8999fe6c95226d5079db917ccda296c68d4ed7a204c9ff1c5ea36d0ae647ee605780939028bf04a3948b1034c71e88cf6f03c782
2024-01-02 15:49:03 +00:00
yancy 278229def5 Add allow for out of bounds indexing
Out of bounds indexing is a workaround for const panic until MSRV +1.57
2024-01-01 10:35:52 +01:00
harshit933 429a3ecec4 Add the implementation of `Display` for `transaction::Version` 2023-12-22 21:08:26 +05:30
Andrew Poelstra 9ea3e29d61
Merge rust-bitcoin/rust-bitcoin#2304: Whitelist some recent clippy lints
504f77adca ci: revert #2301 "update download-artifact to v4" (Andrew Poelstra)
5fd731f095 Don't match on complex expression (Martin Habovstiak)
6cdbb04820 clippy: whitelist uninhabited_references lint (Andrew Poelstra)

Pull request description:

  Clippy has introduced a couple new lints that are causing our CI to fail. `allow` them.

ACKs for top commit:
  tcharding:
    ACK 504f77adca
  Kixunil:
    ACK 504f77adca

Tree-SHA512: 4b2312dcd1645792fa7c08ca02e8ec9f6a13fc5c275559e78293bb55be93997e21f952cf1ac66c1291c4699b6c2976289222201d7e9bbf68349030d83804f8f7
2023-12-20 20:40:01 +00:00
Tobin C. Harding 03bfe1d433
Impove rustdoc on assume_checked_ref
Add a newline to separate the body and heading of function rustdoc.
2023-12-20 09:34:53 +11:00
Tobin C. Harding 769809f1f2
Improve the docs on as_unchecked function
The `as_unchecked` method is never dangerous to call because an
`Address<UncheckedNetwork>` provides a subset of functionality that is
always ok to use. It is only dangerous to go the other way unchecked to
checked.
2023-12-20 09:34:24 +11:00
Andrew Poelstra 504f77adca
ci: revert #2301 "update download-artifact to v4" 2023-12-19 19:28:44 +00:00
Martin Habovstiak 5fd731f095
Don't match on complex expression
Passing a complex expression to `match` is hard to read. Assign it to a
variable first.
2023-12-19 19:28:44 +00:00
Andrew Poelstra 6cdbb04820
clippy: whitelist uninhabited_references lint
This lint triggers on `fn input_len(&self) -> usize { match *self {} }`
where Self is an infallible type, claiming that the dereference of self
is UB. Maybe it would be, if this were possible. But it's not, and this
is literally the only point of using infallible types, so this lint is
always wrong.

Enabled in rustc 1.76 as warn by default.
2023-12-19 16:38:56 +00:00
Andrew Poelstra 8315760403
Merge rust-bitcoin/rust-bitcoin#2301: Bump actions/download-artifact from 3 to 4
7e2321de75 Bump actions/download-artifact from 3 to 4 (dependabot[bot])

Pull request description:

  Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 3 to 4.
  <details>
  <summary>Release notes</summary>
  <p><em>Sourced from <a href="https://github.com/actions/download-artifact/releases">actions/download-artifact's releases</a>.</em></p>
  <blockquote>
  <h2>v4.0.0</h2>
  <h2>What's Changed</h2>
  <p>The release of upload-artifact@v4 and download-artifact@v4 are major changes to the backend architecture of Artifacts. They have numerous performance and behavioral improvements.</p>
  <p>For more information, see the <a href="https://github.com/actions/toolkit/tree/main/packages/artifact"><code>@actions/artifact</code></a> documentation.</p>
  <h2>New Contributors</h2>
  <ul>
  <li><a href="https://github.com/bflad"><code>@bflad</code></a> made their first contribution in <a href="https://redirect.github.com/actions/download-artifact/pull/194">actions/download-artifact#194</a></li>
  </ul>
  <p><strong>Full Changelog</strong>: <a href="https://github.com/actions/download-artifact/compare/v3...v4.0.0">https://github.com/actions/download-artifact/compare/v3...v4.0.0</a></p>
  <h2>v3.0.2</h2>
  <ul>
  <li>Bump <code>@actions/artifact</code> to v1.1.1 - <a href="https://redirect.github.com/actions/download-artifact/pull/195">actions/download-artifact#195</a></li>
  <li>Fixed a bug in Node16 where if an HTTP download finished too quickly (&lt;1ms, e.g. when it's mocked) we attempt to delete a temp file that has not been created yet <a href="hhttps://redirect.github.com/actions/toolkit/pull/1278">actions/toolkit#1278</a></li>
  </ul>
  <h2>v3.0.1</h2>
  <ul>
  <li><a href="https://redirect.github.com/actions/download-artifact/pull/178">Bump <code>@actions/core</code> to 1.10.0</a></li>
  </ul>
  </blockquote>
  </details>
  <details>
  <summary>Commits</summary>
  <ul>
  <li><a href="7a1cd3216c"><code>7a1cd32</code></a> Merge pull request <a href="https://redirect.github.com/actions/download-artifact/issues/246">#246</a> from actions/v4-beta</li>
  <li><a href="8f32874a49"><code>8f32874</code></a> licensed cache</li>
  <li><a href="b5ff8444b1"><code>b5ff844</code></a> Merge pull request <a href="https://redirect.github.com/actions/download-artifact/issues/245">#245</a> from actions/robherley/v4-documentation</li>
  <li><a href="f07a0f73f5"><code>f07a0f7</code></a> Update README.md</li>
  <li><a href="7226129829"><code>7226129</code></a> update test workflow to use different artifact names for matrix</li>
  <li><a href="ada9446619"><code>ada9446</code></a> update docs and bump <code>@actions/artifact</code></li>
  <li><a href="7eafc8b729"><code>7eafc8b</code></a> Merge pull request <a href="https://redirect.github.com/actions/download-artifact/issues/244">#244</a> from actions/robherley/bump-toolkit</li>
  <li><a href="3132d12662"><code>3132d12</code></a> consume latest toolkit</li>
  <li><a href="5be1d38671"><code>5be1d38</code></a> Merge pull request <a href="https://redirect.github.com/actions/download-artifact/issues/243">#243</a> from actions/robherley/v4-beta-updates</li>
  <li><a href="465b526e63"><code>465b526</code></a> consume latest <code>@actions/toolkit</code></li>
  <li>Additional commits viewable in <a href="https://github.com/actions/download-artifact/compare/v3...v4">compare view</a></li>
  </ul>
  </details>
  <br />

  [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/download-artifact&package-manager=github_actions&previous-version=3&new-version=4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

  Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

  [//]: # (dependabot-automerge-start)
  [//]: # (dependabot-automerge-end)

  ---

  <details>
  <summary>Dependabot commands and options</summary>
  <br />

  You can trigger Dependabot actions by commenting on this PR:
  - `@dependabot rebase` will rebase this PR
  - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
  - `@dependabot merge` will merge this PR after your CI passes on it
  - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
  - `@dependabot cancel merge` will cancel a previously requested merge and block automerging
  - `@dependabot reopen` will reopen this PR if it is closed
  - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
  - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

  </details>

ACKs for top commit:
  apoelstra:
    ACK 7e2321de75 and will use CI-only one-ack carveout

Tree-SHA512: 8eb6c18ce8c2b99721f134a26e7407c8ebc1d6af4999a013ed395b52795852ddee1c24b1f8aaf60487f13a0c1288d6b496c34d0dbfe20f806fd6fe5643e02250
2023-12-18 18:01:26 +00:00
dependabot[bot] 7e2321de75
Bump actions/download-artifact from 3 to 4
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 3 to 4.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-12-18 10:36:58 +00:00