diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 3f51bde0..af3071df 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -55,3 +55,8 @@ jobs: with: command: doc args: --workspace --all-features + typos: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: crate-ci/typos@master diff --git a/CHANGELOG.md b/CHANGELOG.md index aa8754d4..472f6e90 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -87,7 +87,7 @@ v0.2.0-beta.3 - Multiple BIP-32 improvements on top of rust-bitcoin functionality - Better CI - Android/iOS/Windows/MacOs build fixes -- AchorId strict encoding +- AnchorId strict encoding - Fixed issue with broken `serde_with` macro (pinned older version in Cargo.toml) - More collection types supporting `AutoConceal` diff --git a/Cargo.toml b/Cargo.toml index 1606fbed..e2116a13 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -29,7 +29,7 @@ aluvm = { version = "~0.11.0-beta.2", features = ["std"] } commit_verify = { version = "~0.11.0-beta.2", features = ["rand", "derive"] } single_use_seals = "~0.11.0-beta.2" bp-core = { version = "~0.11.0-beta.2" } -secp256k1-zkp = { version = "0.9.2", features = ["rand", "rand-std", "global-context"] } # TODO: Update version before the relese +secp256k1-zkp = { version = "0.9.2", features = ["rand", "rand-std", "global-context"] } # TODO: Update version before the release baid58 = "~0.4.4" mime = "~0.3.17" serde_crate = { package = "serde", version = "1", features = ["derive"], optional = true } diff --git a/README.md b/README.md index c8743501..00757e63 100644 --- a/README.md +++ b/README.md @@ -54,7 +54,7 @@ The current list of the projects based on the library include: Minimum supported rust compiler version (MSRV): 1.66, rust 2021 edition. The library can be integrated into other rust projects via `Cargo.toml` -`[dependecies]` section: +`[dependencies]` section: ```toml [dependencies] diff --git a/SECURITY.md b/SECURITY.md index 22101c1e..b84a0706 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -15,7 +15,7 @@ Instead, please report them to the repository maintainers by sending a **GPG encrypted e-mail** to _all maintainers of a specific repo_ using their GPG keys. A list of repository maintainers and their keys and e-mail addresses are -provided inside MAINTANERS.md file and MANIFEST.yml, with the latter also +provided inside MAINTAINERS.md file and MANIFEST.yml, with the latter also included in the README.md as a manifest block, which looks in the following way: ```yaml diff --git a/_typos.toml b/_typos.toml new file mode 100644 index 00000000..0aece21d --- /dev/null +++ b/_typos.toml @@ -0,0 +1,9 @@ +[files] +# exclude the directory "stl/" +extend-exclude = ["stl/"] + +[default.extend-words] +# Don't correct the name "Jon Atack". +Atack = "Atack" +# Don't correct the Seh in "pkXwpsb-aemTWhtSg-VDGF25hEi-jtTAnPjzh-B63ZwSehE-WvfhF9". +Seh = "Seh" diff --git a/src/schema/occurrences.rs b/src/schema/occurrences.rs index 4f7a2a0a..fe72278d 100644 --- a/src/schema/occurrences.rs +++ b/src/schema/occurrences.rs @@ -167,97 +167,97 @@ mod test { #[test] fn test_once_check_count() { - let occurence: Occurrences = Occurrences::Once; - occurence.check(1).unwrap(); + let occurrence: Occurrences = Occurrences::Once; + occurrence.check(1).unwrap(); } #[test] #[should_panic(expected = "OccurrencesMismatch { min: 1, max: 1, found: 0 }")] fn test_once_check_count_fail_zero() { - let occurence: Occurrences = Occurrences::Once; - occurence.check(0).unwrap(); + let occurrence: Occurrences = Occurrences::Once; + occurrence.check(0).unwrap(); } #[test] #[should_panic(expected = "OccurrencesMismatch { min: 1, max: 1, found: 2 }")] fn test_once_check_count_fail_two() { - let occurence: Occurrences = Occurrences::Once; - occurence.check(2).unwrap(); + let occurrence: Occurrences = Occurrences::Once; + occurrence.check(2).unwrap(); } #[test] fn test_none_or_once_check_count() { - let occurence: Occurrences = Occurrences::NoneOrOnce; - occurence.check(1).unwrap(); + let occurrence: Occurrences = Occurrences::NoneOrOnce; + occurrence.check(1).unwrap(); } #[test] fn test_none_or_once_check_count_zero() { - let occurence: Occurrences = Occurrences::NoneOrOnce; - occurence.check(0).unwrap(); + let occurrence: Occurrences = Occurrences::NoneOrOnce; + occurrence.check(0).unwrap(); } #[test] #[should_panic(expected = "OccurrencesMismatch { min: 0, max: 1, found: 2 }")] fn test_none_or_once_check_count_fail_two() { - let occurence: Occurrences = Occurrences::NoneOrOnce; - occurence.check(2).unwrap(); + let occurrence: Occurrences = Occurrences::NoneOrOnce; + occurrence.check(2).unwrap(); } #[test] fn test_once_or_up_to_none() { - let occurence: Occurrences = Occurrences::OnceOrMore; - occurence.check(1).unwrap(); + let occurrence: Occurrences = Occurrences::OnceOrMore; + occurrence.check(1).unwrap(); } #[test] fn test_once_or_up_to_none_large() { - let occurence: Occurrences = Occurrences::OnceOrMore; - occurence.check(core::u16::MAX).unwrap(); + let occurrence: Occurrences = Occurrences::OnceOrMore; + occurrence.check(core::u16::MAX).unwrap(); } #[test] #[should_panic(expected = "OccurrencesMismatch { min: 1, max: 65535, found: 0 }")] fn test_once_or_up_to_none_fail_zero() { - let occurence: Occurrences = Occurrences::OnceOrMore; - occurence.check(0).unwrap(); + let occurrence: Occurrences = Occurrences::OnceOrMore; + occurrence.check(0).unwrap(); } #[test] fn test_once_or_up_to_42() { - let occurence: Occurrences = Occurrences::OnceOrUpTo(42); - occurence.check(42).unwrap(); + let occurrence: Occurrences = Occurrences::OnceOrUpTo(42); + occurrence.check(42).unwrap(); } #[test] #[should_panic(expected = "OccurrencesMismatch { min: 1, max: 42, found: 43 }")] fn test_once_or_up_to_42_large() { - let occurence: Occurrences = Occurrences::OnceOrUpTo(42); - occurence.check(43).unwrap(); + let occurrence: Occurrences = Occurrences::OnceOrUpTo(42); + occurrence.check(43).unwrap(); } #[test] #[should_panic(expected = "OccurrencesMismatch { min: 1, max: 42, found: 0 }")] fn test_once_or_up_to_42_fail_zero() { - let occurence: Occurrences = Occurrences::OnceOrUpTo(42); - occurence.check(0).unwrap(); + let occurrence: Occurrences = Occurrences::OnceOrUpTo(42); + occurrence.check(0).unwrap(); } #[test] fn test_none_or_up_to_none_zero() { - let occurence: Occurrences = Occurrences::NoneOrMore; - occurence.check(0).unwrap(); + let occurrence: Occurrences = Occurrences::NoneOrMore; + occurrence.check(0).unwrap(); } #[test] fn test_none_or_up_to_none_large() { - let occurence: Occurrences = Occurrences::NoneOrMore; - occurence.check(core::u16::MAX).unwrap(); + let occurrence: Occurrences = Occurrences::NoneOrMore; + occurrence.check(core::u16::MAX).unwrap(); } #[test] fn test_none_or_up_to_42_zero() { - let occurence: Occurrences = Occurrences::NoneOrMore; - occurence.check(0).unwrap(); + let occurrence: Occurrences = Occurrences::NoneOrMore; + occurrence.check(0).unwrap(); } #[test] fn test_none_or_up_to_42() { - let occurence: Occurrences = Occurrences::NoneOrMore; - occurence.check(42).unwrap(); + let occurrence: Occurrences = Occurrences::NoneOrMore; + occurrence.check(42).unwrap(); } #[test] #[should_panic(expected = "OccurrencesMismatch { min: 0, max: 42, found: 43 }")] fn test_none_or_up_to_42_large() { - let occurence: Occurrences = Occurrences::NoneOrUpTo(42); - occurence.check(43).unwrap(); + let occurrence: Occurrences = Occurrences::NoneOrUpTo(42); + occurrence.check(43).unwrap(); } } diff --git a/src/validation/validator.rs b/src/validation/validator.rs index a228352e..7539b808 100644 --- a/src/validation/validator.rs +++ b/src/validation/validator.rs @@ -42,7 +42,7 @@ use crate::{ pub enum TxResolverError { /// transaction {0} is not mined Unknown(Txid), - /// unable to retriev transaction {0}, {1} + /// unable to retrieve transaction {0}, {1} Other(Txid, String), }