Use crate.io/typos to repalce CodeSpell for CI typo check
bodhi-crypo opened this issue · 0 comments
bodhi-crypo commented
🧐 Motivation
currently openzeppelin-contracts
already integrate codespell
typo checker,But https://github.com/crate-ci/typos works better
below is crate-ci/typos
result:
error: `Transfered` should be `Transferred`
--> ./certora/specs/ERC20FlashMint.spec:21:62
|
21 | ghost mapping(address => mapping(address => mathint)) trackedTransferedAmount;
| ^^^^^^^^^^
|
error: `Transfered` should be `Transferred`
--> ./certora/specs/ERC20FlashMint.spec:31:16
|
31 | trackedTransferedAmount[from][to] = amount;
| ^^^^^^^^^^
|
error: `Transfered` should be `Transferred`
--> ./certora/specs/ERC20FlashMint.spec:54:51
|
54 | assert (fees > 0 && recipient != 0) => trackedTransferedAmount[receiver][recipient] == to_mathint(fees);
| ^^^^^^^^^^
|
error: `leafs` should be `leaves`
--> ./contracts/utils/cryptography/MerkleProof.sol:49:11
|
49 | * of leafs & pre-images are assumed to be sorted.
| ^^^^^
|
error: `recomment` should be `recommend`
--> ./audits/2017-03.md:162:160
|
162 | I have a general concern about the difference between `owners`, `_owners`, and `owner` in `Ownable.sol`. I recommend "Owners" be renamed. In general we do not recomment single character differences in variable names, although a preceding underscore is not uncommon in Solidity code.
| ^^^^^^^^^
|
error: `quroum` should be `quorum`
--> ./test/governance/extensions/GovernorVotesQuorumFraction.test.js:77:11
|
77 | it('quroum reached', async function () {
| ^^^^^^
|
error: `quroum` should be `quorum`
--> ./test/governance/extensions/GovernorVotesQuorumFraction.test.js:85:11
|
85 | it('quroum not reached', async function () {
| ^^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:9:19
|
9 | const makeTree = (leafs = [ethers.ZeroHash]) =>
| ^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:11:5
|
11 | leafs.map(leaf => [leaf]),
| ^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:42:13
|
42 | const leafs = Array.from({ length: 2 ** Number(DEPTH) }, () => ethers.ZeroHash);
| ^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:45:23
|
45 | for (const i in leafs) {
| ^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:47:38
|
47 | const hashedLeaf = hashLeaf((leafs[i] = generators.bytes32()));
| ^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:50:31
|
50 | const tree = makeTree(leafs);
| ^^^^^
|
error: `Leafs` should be `Leaves`
--> ./test/utils/structs/MerkleTree.test.js:70:15
|
70 | const zeroLeafs = Array.from({ length: 2 ** Number(DEPTH) }, () => ethers.ZeroHash);
| ^^^^^
|
error: `Leafs` should be `Leaves`
--> ./test/utils/structs/MerkleTree.test.js:71:35
|
71 | const zeroTree = makeTree(zeroLeafs);
| ^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:74:11
|
74 | const leafs = Array.from({ length: 2 ** Number(DEPTH) }, () => ethers.ZeroHash);
| ^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:75:34
|
75 | const hashedLeaf = hashLeaf((leafs[0] = generators.bytes32())); // fill first leaf and hash it
| ^^^^^
|
error: `leafs` should be `leaves`
--> ./test/utils/structs/MerkleTree.test.js:76:27
|
76 | const tree = makeTree(leafs);
| ^^^^^
|
📝 Details
suggestion: Use crate.io/typos to repalce CodeSpell for CI typo check