Skip to content
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

chore: fix all typos #20196

Merged
merged 2 commits into from
Apr 26, 2024
Merged

chore: fix all typos #20196

merged 2 commits into from
Apr 26, 2024

Conversation

hoangdv2429
Copy link
Contributor

@hoangdv2429 hoangdv2429 commented Apr 26, 2024

Description

This PR will fix all typos in current repo.


Author Checklist

All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.

I have...

  • included the correct type prefix in the PR title
  • confirmed ! in the type prefix if API or client breaking change
  • targeted the correct branch (see PR Targeting)
  • provided a link to the relevant issue or specification
  • reviewed "Files changed" and left comments if necessary
  • included the necessary unit and integration tests
  • added a changelog entry to CHANGELOG.md
  • updated the relevant documentation or specification, including comments for documenting Go code
  • confirmed all CI checks have passed

Reviewers Checklist

All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.

I have...

  • confirmed the correct type prefix in the PR title
  • confirmed all author checklist items have been addressed
  • reviewed state machine logic, API design and naming, documentation is accurate, tests and test coverage

Summary by CodeRabbit

  • New Features
    • Enhanced clarity in module interfaces within the cosmos-sdk, now directly implementing extension interfaces on AppModule.
  • Documentation
    • Numerous typo corrections in comments and documentation across various modules, improving clarity and readability.
    • Updated status descriptions and potential uses in architecture documents for clearer understanding of processes and module functionalities.
  • Bug Fixes
    • Fixed typographical errors in API descriptions and comments that clarify transaction fee requirements and other functionalities.
  • Refactor
    • Updated several internal comments to reflect accurate descriptions and future development notes regarding the gas fee framework.

Copy link
Contributor

coderabbitai bot commented Apr 26, 2024

Walkthrough

Walkthrough

The recent updates across the cosmos-sdk codebase primarily focus on refining interface implementations, correcting typographical errors in comments and documentation, and enhancing clarity in module functionalities. These changes span various files, including API docs, core modules, and test suites, contributing to improved code quality and documentation accuracy.

Changes

File(s) Summary
CHANGELOG.md, x/evidence/CHANGELOG.md Updated module interfaces and documented API breaking changes.
api/cosmos/tx/v1beta1/tx.pulsar.go, client/docs/swagger-ui/swagger.yaml, proto/cosmos/tx/v1beta1/tx.proto, x/auth/migrations/legacytx/stdtx.go Corrected typos in comments regarding minimum gas price requirements for mempool acceptance.
core/appmodule/v2/module.go, tests/integration/staking/keeper/validator_test.go Corrected typos in comments about validator power and testing validators.
crypto/keys/secp256k1/.../libsecp256k1/include/secp256k1.h, crypto/keys/secp256k1/.../libsecp256k1/src/ecmult_impl.h Typo corrections in cryptographic function descriptions and comments.
docs/architecture/... (Multiple files) Various documentation corrections, including typos in ADRs and architecture guides.
tests/e2e/distribution/... (Multiple files) Typo corrections in comments within test suite teardown functions.
testutil/sims/simulation_helpers.go, x/authz/keeper/keeper.go, x/staking/types/authz.go Comment corrections and typo fixes related to gas fee frameworks and simulation setups.
x/auth/vesting/README.md, x/params/README.md Typo corrections in README files for clarity and accuracy.
x/gov/keeper/msg_server.go, x/feegrant/filtered_fee.go Minor typo corrections in comments without changes to exported entities.

Recent Review Details

Configuration used: .coderabbit.yml
Review profile: CHILL

Commits Files that changed from the base of the PR and between b5c2644 and 1112124.
Files selected for processing (1)
  • x/authz/README.md (2 hunks)
Additional Context Used
LanguageTool (107)
x/authz/README.md (107)

Near line 9: This sentence does not start with an uppercase letter.
Context: ...-- # x/authz ## Abstract x/authz is an implementation of a Cosmos SDK modul...


Near line 20: Possible spelling mistake found.
Context: ...e](#state) * Grant * GrantQueue * Messages ...


Near line 22: Possible spelling mistake found.
Context: ...ntqueue) * Messages * MsgGrant * [MsgRevoke](#msgrevok...


Near line 23: Possible spelling mistake found.
Context: ...ges) * MsgGrant * MsgRevoke * [MsgRevokeAll](#msgr...


Near line 24: Possible spelling mistake found.
Context: ...t) * MsgRevoke * MsgRevokeAll * [MsgExec](#msgexe...


Near line 25: Possible spelling mistake found.
Context: ... * MsgRevokeAll * MsgExec * [MsgPruneExpiredGrants...


Near line 26: Possible spelling mistake found.
Context: ...keall) * MsgExec * MsgPruneExpiredGrants * [Events](#ev...


Near line 37: Possible spelling mistake found.
Context: ...cepts ### Authorization and Grant The x/authz module defines interfaces and messages...


Near line 41: Possible missing comma found.
Context: ... and can be defined for any Msg service method even outside of the module where the Ms...


Near line 41: This phrase is redundant. Consider using “outside”.
Context: ...defined for any Msg service method even outside of the module where the Msg method is defi...


Near line 41: Possible spelling mistake found.
Context: ...here the Msg method is defined. See the SendAuthorization example in the next section for more d...


Near line 43: Possible spelling mistake found.
Context: ...ection for more details. Note: The authz module is different from the [auth (aut...


Near line 51: Possible spelling mistake found.
Context: ...Built-in Authorizations The Cosmos SDK x/authz module comes with following authorizat...


Near line 51: You might be missing the article “the” here.
Context: ... Cosmos SDK x/authz module comes with following authorization types: #### GenericAutho...


Near line 53: Possible spelling mistake found.
Context: ...th following authorization types: #### GenericAuthorization GenericAuthorization implements the ...


Near line 55: This sentence does not start with an uppercase letter.
Context: ...icAuthorization GenericAuthorization implements the Authorization interface that give...


Near line 65: This sentence does not start with an uppercase letter.
Context: ...c_authorization.go#L16-L29 ``` * msg stores Msg type URL. #### SendAuthorization ...


Near line 67: Possible spelling mistake found.
Context: ...``` * msg stores Msg type URL. #### SendAuthorization `SendAuthorization` implements the `Au...


Near line 69: This sentence does not start with an uppercase letter.
Context: ... SendAuthorization SendAuthorization implements the Authorization interface for the `...


Near line 69: Add a space between sentences.
Context: ...s the Authorization interface for the cosmos.bank.v1beta1.MsgSend Msg. * It takes a (positive) `SpendLi...


Near line 71: Possible spelling mistake found.
Context: ....MsgSendMsg. * It takes a (positive)SpendLimit` that specifies the maximum amount of t...


Near line 71: ‘Amount of’ should usually only be used with uncountable or mass nouns. Consider using “number” if this is not the case.
Context: ...SpendLimit that specifies the maximum amount of tokens the grantee can spend. The `S...


Near line 71: Possible spelling mistake found.
Context: ...nt of tokens the grantee can spend. The SpendLimit is updated as the tokens are spent. * ...


Near line 72: Possible spelling mistake found.
Context: ...ens are spent. * It takes an (optional) AllowList that specifies to which addresses a gr...


Near line 72: Possible missing article found.
Context: ...s to which addresses a grantee can send token. ```protobuf reference https://github....


Near line 82: This sentence does not start with an uppercase letter.
Context: ...ization.go#L29-L62 ``` * spend_limit keeps track of how many coins are left in the...


Near line 83: This sentence does not start with an uppercase letter.
Context: ...ft in the authorization. * allow_list specifies an optional list of addresses to whom t...


Near line 85: Possible spelling mistake found.
Context: ... tokens on behalf of the granter. #### StakeAuthorization StakeAuthorization implements the `A...


Near line 87: This sentence does not start with an uppercase letter.
Context: ...takeAuthorization StakeAuthorization implements the Authorization interface for messa...


Near line 87: Possible spelling mistake found.
Context: ...ain/build/modules/staking). It takes an AuthorizationType to specify whether you want to authori...


Near line 87: Possible spelling mistake. ‘authorise’ is British English.
Context: ...ionType` to specify whether you want to authorise delegating, undelegating or redelegatin...


Near line 87: Possible spelling mistake found.
Context: ...ether you want to authorise delegating, undelegating or redelegating (i.e. these have to be ...


Near line 87: Possible spelling mistake found.
Context: ...o authorise delegating, undelegating or redelegating (i.e. these have to be authorised separ...


Near line 87: Possible spelling mistake. ‘authorised’ is British English.
Context: ... or redelegating (i.e. these have to be authorised separately). It also takes a required `...


Near line 87: Possible spelling mistake found.
Context: ...d separately). It also takes a required MaxTokens that keeps track of a limit to the amo...


Near line 87: ‘Amount of’ should usually only be used with uncountable or mass nouns. Consider using “number” if this is not the case.
Context: ...ens` that keeps track of a limit to the amount of tokens that can be delegated/undeleg...


Near line 87: Possible spelling mistake found.
Context: ... amount of tokens that can be delegated/undelegated/redelegated. If left empty, the amount ...


Near line 87: Possible spelling mistake found.
Context: ...okens that can be delegated/undelegated/redelegated. If left empty, the amount is unlimited...


Near line 87: Possible spelling mistake found.
Context: ...imited. Additionally, this Msg takes an AllowList or a DenyList, which allows you to s...


Near line 87: Possible spelling mistake found.
Context: ...lly, this Msg takes an AllowList or a DenyList, which allows you to select which vali...


Near line 98: Consider a shorter alternative to avoid wordiness.
Context: ...ng/types/authz.go#L15-L35 ``` ### Gas In order to prevent DoS attacks, granting `StakeAut...


Near line 99: Possible spelling mistake found.
Context: ... order to prevent DoS attacks, granting StakeAuthorizations with x/authz incurs gas. `StakeAuth...


Near line 99: Possible spelling mistake found.
Context: ...ks, granting StakeAuthorizations with x/authz incurs gas. StakeAuthorization allow...


Near line 99: Possible spelling mistake found.
Context: ...horizations with x/authzincurs gas.StakeAuthorization` allows you to authorize another accoun...


Near line 99: Do not mix variants of the same word (‘authorize’ and ‘authorise’) within a single text.
Context: ...gas. StakeAuthorization allows you to authorize another account to delegate, undelegate...


Near line 99: Possible spelling mistake found.
Context: ... authorize another account to delegate, undelegate, or redelegate to validators. The autho...


Near line 99: Possible spelling mistake found.
Context: ...her account to delegate, undelegate, or redelegate to validators. The authorizer can defin...


Near line 99: This verb does not appear to agree with the subject. Consider using a different form.
Context: ...osmos SDK iterates over these lists and charge 10 gas for each validator in both of th...


Near line 99: After the number ‘10’, use a plural noun. Did you mean “gases”, “gasses”?
Context: ...iterates over these lists and charge 10 gas for each validator in both of the lists...


Near line 101: The preposition “of” seems more likely in this position.
Context: ...ts. Since the state maintaining a list for granter, grantee pair with same expirat...


Near line 101: The grammatical number of this noun doesn’t look right. Consider replacing it.
Context: ...maintaining a list for granter, grantee pair with same expiration, we are iterating ...


Near line 101: Possible spelling mistake found.
Context: ...nt (in case of any revoke of particular msgType) from the list and we are charging 20 ...


Near line 101: Use a comma before ‘and’ if it connects two independent clauses (unless they are closely connected and short).
Context: ...e of particular msgType) from the list and we are charging 20 gas per iteration. ...


Near line 101: After the number ‘20’, use a plural noun. Did you mean “gases”, “gasses”?
Context: ...`) from the list and we are charging 20 gas per iteration. ## State ### Grant Gr...


Near line 107: A comma may be missing after the conjunctive/linking adverb ‘Hence’.
Context: ... and Authorization type (its type URL). Hence we only allow one grant for the (grante...


Near line 117: Possible spelling mistake found.
Context: ...hz/v1beta1/authz.proto#L24-L32 ``` ### GrantQueue We are maintaining a queue for authz p...


Near line 119: Possible spelling mistake found.
Context: ...ntQueue We are maintaining a queue for authz pruning. Whenever a grant is created, a...


Near line 119: Possible spelling mistake found.
Context: ...nt is created, an item will be added to GrantQueue with a key of expiration, granter, gra...


Near line 121: Possible spelling mistake found.
Context: ...ey of expiration, granter, grantee. In EndBlock (which runs for every block) we contin...


Near line 121: You might be missing the article “the” here.
Context: ...red grants by forming a prefix key with current blocktime that passed the stored expira...


Near line 121: Possible spelling mistake found.
Context: ...ts by forming a prefix key with current blocktime that passed the stored expiration in `G...


Near line 121: Possible spelling mistake found.
Context: ...me that passed the stored expiration in GrantQueue, we iterate through all the matched re...


Near line 121: Possible spelling mistake found.
Context: ...te through all the matched records from GrantQueue and delete them from the GrantQueue ...


Near line 121: Possible spelling mistake found.
Context: ...m GrantQueue and delete them from the GrantQueue & Grants store. ```go reference htt...


Near line 121: An accent character was used instead of an apostrophe.
Context: ...and delete them from the GrantQueue & Grants store. ```go reference https://github....


Near line 127: Possible spelling mistake found.
Context: ...authz/keeper/keeper.go#L378-L403 ``` * GrantQueue: `0x02 | expiration_bytes | granter_add...


Near line 135: Possible spelling mistake found.
Context: ...x/authz/keeper/keys.go#L77-L93 ``` The GrantQueueItem object contains the list of type urls ...


Near line 135: Possible spelling mistake found.
Context: ...eItem` object contains the list of type urls between granter and grantee that expire...


Near line 139: It appears that a comma is missing.
Context: ...cated in the key. ## Messages In this section we describe the processing of messages ...


Near line 139: Possible spelling mistake found.
Context: ...ribe the processing of messages for the authz module. ### MsgGrant An authorization...


Near line 141: Possible spelling mistake found.
Context: ... of messages for the authz module. ### MsgGrant An authorization grant is created usin...


Near line 143: Possible spelling mistake found.
Context: ...uthorization grant is created using the MsgGrant message. If there is already a grant f...


Near line 152: This sentence does not start with an uppercase letter.
Context: ...The message handling should fail if: * both granter and grantee have the same addre...


Near line 153: This sentence does not start with an uppercase letter.
Context: ...er and grantee have the same address. * provided Expiration time is less than current ...


Near line 153: You might be missing the article “the” here.
Context: ...provided Expiration time is less than current unix timestamp (but a grant will be cre...


Near line 153: Possible spelling mistake found.
Context: ... Expiration time is less than current unix timestamp (but a grant will be created ...


Near line 154: This sentence does not start with an uppercase letter.
Context: ...ided since expiration is optional). * provided Grant.Authorization is not implemente...


Near line 154: Add a space between sentences.
Context: ...e expiration is optional). * provided Grant.Authorization is not implemented. * `Authorization.M...


Near line 155: This sentence does not start with an uppercase letter.
Context: ...emented. * Authorization.MsgTypeURL() is not defined in the router (there is no ...


Near line 157: Possible spelling mistake found.
Context: ... router to handle that Msg types). ### MsgRevoke A grant can be removed with the `MsgRe...


Near line 159: Possible spelling mistake found.
Context: ...Revoke A grant can be removed with the MsgRevoke message. ```protobuf reference https:...


Near line 167: This sentence does not start with an uppercase letter.
Context: ...The message handling should fail if: * both granter and grantee have the same addre...


Near line 168: This sentence does not start with an uppercase letter.
Context: ...er and grantee have the same address. * provided MsgTypeUrl is empty. NOTE: The `MsgE...


Near line 168: Possible spelling mistake found.
Context: ...antee have the same address. * provided MsgTypeUrl is empty. NOTE: The MsgExec message...


Near line 170: Possible spelling mistake found.
Context: ...vided MsgTypeUrl is empty. NOTE: The MsgExec message removes a grant if the grant h...


Near line 172: Possible spelling mistake found.
Context: ... a grant if the grant has expired. ### MsgRevokeAll The MsgRevokeAll message revokes all...


Near line 174: Possible spelling mistake found.
Context: ...ant has expired. ### MsgRevokeAll The MsgRevokeAll message revokes all grants issued by t...


Near line 182: This sentence does not start with an uppercase letter.
Context: ...The message handling should fail if: * the granter address is not provided or in...


Near line 183: This sentence does not start with an uppercase letter.
Context: ...address is not provided or invalid. * thegranter` does not have any active gran...


Near line 185: Possible spelling mistake found.
Context: ...` does not have any active grants. ### MsgExec When a grantee wants to execute a tran...


Near line 187: Possible spelling mistake found.
Context: ... on behalf of a granter, they must send MsgExec. ```protobuf reference https://github...


Near line 195: This sentence does not start with an uppercase letter.
Context: ...The message handling should fail if: * provided Authorization is not implemented. * g...


Near line 196: This sentence does not start with an uppercase letter.
Context: ...d Authorization is not implemented. * grantee doesn't have permission to run the tran...


Near line 197: This sentence does not start with an uppercase letter.
Context: ...ve permission to run the transaction. * if granted authorization is expired. ### ...


Near line 199: Possible spelling mistake found.
Context: ... granted authorization is expired. ### MsgPruneExpiredGrants Message that clean up 75 expired grant...


Near line 205: Possible spelling mistake found.
Context: ...lean up expired grants. ## Events The authz module emits proto events defined in [t...


Near line 205: Possible spelling mistake found.
Context: ...dule emits proto events defined in [the Protobuf reference](https://buf.build/cosmos/cos...


Near line 205: Add a space between sentences.
Context: ...vents defined in the Protobuf reference. ## Client ### CLI A user can query...


Near line 211: Possible spelling mistake found.
Context: ... A user can query and interact with the authz module using the CLI. #### Query The...


Near line 215: Possible spelling mistake found.
Context: ...e query commands allow users to query authz state. ```bash simd query authz --hel...


Near line 221: This sentence does not start with an uppercase letter.
Context: ...bash simd query authz --help ``` ##### grants The grants command allows users to q...


Near line 250: Possible spelling mistake found.
Context: ...ation: null ``` #### Transactions The tx commands allow users to interact with ...


Near line 250: Possible spelling mistake found.
Context: ...mmands allow users to interact with the authz module. ```bash simd tx authz --help ...


Near line 256: This sentence does not start with an uppercase letter.
Context: ...bash simd tx authz --help ##### exec The exec command allows a grantee to...


Near line 258: You might be missing the article “the” here.
Context: ...e to execute a transaction on behalf of granter. ```bash simd tx authz exec [tx-json...


Near line 300: Possible spelling mistake found.
Context: ...1.. ``` ### gRPC A user can query the authz module using gRPC endpoints. #### Gra...


Near line 342: Possible spelling mistake found.
Context: ...] } ### REST A user can query the `authz` module using REST endpoints. bash ...

Path-based Instructions (1)
x/authz/README.md (1)

Pattern **/*.md: "Assess the documentation for misspellings, grammatical errors, missing documentation and correctness"


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

Out of diff range and nitpick comments (41)
x/params/README.md (6)

Line range hint 7-7: Correct spelling to American English for consistency.

- favour
+ favor

Line range hint 13-13: Add an article for clarity.

- Subspace is an isolated namespace for a paramstore
+ Subspace is an isolated namespace for a paramstore

Line range hint 14-14: Remove unnecessary article.

- Keeper has a permission to access all existing spaces.
+ Keeper has permission to access all existing spaces.

Line range hint 18-18: Consider rephrasing to reduce wordiness.

- The params Keeper can be used to add a route to `x/gov` router in order to modify any parameter in case a proposal passes.
+ The params Keeper can add a route to the `x/gov` router to modify any parameter if a proposal passes.

Line range hint 20-20: Correct verb form to match the subject.

- The following contents explains how to use params module for master and user modules.
+ The following content explains how to use the params module for master and user modules.

Line range hint 32-32: Add a space between sentences for better readability.

- Then, those modules can have a reference to their specific parameter store through `Keeper.GetSubspace`. Example:
+ Then, those modules can have a reference to their specific parameter store through `Keeper.GetSubspace`. Example:
docs/architecture/PROCESS.md (2)

Line range hint 11-11: Add a comma for clarity.

- If the consensus came from a synchronous discussion then a short excerpt should be added to the ADR to explain the goals.
+ If the consensus came from a synchronous discussion, then a short excerpt should be added to the ADR to explain the goals.

Line range hint 23-23: Remove extra spaces.

- we still prefer to  merge it with a _rejected_ status.
+ we still prefer to merge it with a _rejected_ status.
docs/architecture/adr-034-account-rekeying.md (3)

Line range hint 13-13: Correct spelling mistake.

- Account rekeying is a process hat allows an account to replace its authentication pubkey with a new one.
+ Account rekeying is a process that allows an account to replace its authentication pubkey with a new one.

Line range hint 17-17: Use "cannot" for formal writing.

- it can not be updated.
+ it cannot be updated.

Line range hint 46-46: Remove repeated word.

- to compensate for this this externality
+ to compensate for this externality
x/auth/vesting/README.md (4)

Line range hint 9-9: Consider adding the article "a" before "vesting account" for grammatical correctness.


Line range hint 40-40: Consider replacing "is able to" with "can" for conciseness.


Line range hint 40-40: Consider adding a comma after "validators" to correctly separate the clauses.


613-613: Consider starting the sentence with an uppercase letter for consistency.

docs/architecture/adr-050-sign-mode-textual.md (16)

Line range hint 6-6: Possible spelling mistake found.

Consider changing "concept-ACKed" to "concept-acknowledged" for clarity and formality in documentation.


Line range hint 7-7: Only proper nouns start with an uppercase character (there are exceptions for headlines).

Consider changing "Change status to Accepted." to "change status to accepted." to maintain consistency with sentence casing in lists.


Line range hint 8-8: Possible spelling mistake found.

Consider changing "tx raw bytes" to "transaction raw bytes" for clarity and to avoid abbreviations in formal documents.


Line range hint 11-11: Possible spelling mistake found.

Consider changing "CBOR encoding" to "CBOR Encoding" if referring to a specific standard or technology, otherwise, ensure consistency in capitalization.


Line range hint 14-14: Possible spelling mistake found.

Consider changing "invertability" to "invertibility" for correct spelling.


Line range hint 15-15: Add a space between sentences.

Consider adding a space after "Title+Content." for better readability.


Line range hint 15-15: Only proper nouns start with an uppercase character (there are exceptions for headlines).

Consider changing "Change SignDoc from array to struct containing array." to "change SignDoc from array to struct containing array." to maintain consistency with sentence casing in lists.


Line range hint 30-30: Possible spelling mistake found.

Consider changing "SIGN_MODE_DIRECT" to "SignModeDirect" if referring to a code entity, or keep it in quotes if referring to a term.


Line range hint 34-34: This sentence does not start with an uppercase letter.

Consider capitalizing the beginning of the sentence: "Hardware cannot decode the protobuf sign bytes due to memory constraints..."


Line range hint 55-55: Possible spelling mistake found.

Consider changing "nul" to "null" if referring to the null character, to avoid confusion with a typo.


Line range hint 84-84: The correct preposition here is “on” or “about”.

Consider changing "of the original transaction" to "about the original transaction" for grammatical accuracy.


Line range hint 89-89: Although a hyphen is possible, it is not necessary in a compound modifier in which the first word is an adverb that ends in ‘ly’.

Consider changing "cryptographically-strong" to "cryptographically strong" to adhere to grammatical norms regarding hyphenation.


Line range hint 193-193: An accent character was used instead of an apostrophe.

Consider changing "don't" to "don't" using the correct apostrophe character for consistency and professionalism in documentation.


Line range hint 226-226: An accent character was used instead of an apostrophe.

Consider changing "sdk.Msg's" to "sdk.Msg's" using the correct apostrophe character for consistency and professionalism in documentation.


Line range hint 266-266: Consider changing the order of words to improve your wording.

Consider rephrasing "Application developers may choose to not follow default renderer value output for their own Msgs" to "Application developers may choose not to follow the default renderer value output for their own Msgs" for smoother readability.


Line range hint 313-313: In this context, ‘type’ should agree in number with the noun after ‘of’.

Consider changing "This type of updates require" to "These types of updates require" for grammatical correctness.

docs/architecture/adr-063-core-module-api.md (10)

Line range hint 15-16: Consider revising the sentence for clarity and completeness.

- A new core API is proposed as a way to develop cosmos-sdk applications that will eventually replace the existing `AppModule` and `sdk.Context` frameworks a set of core services and extension interfaces.
+ A new core API is proposed as a way to develop cosmos-sdk applications that will eventually replace the existing `AppModule` and `sdk.Context` frameworks with a set of core services and extension interfaces.

Line range hint 18-18: Start the list with an uppercase letter for consistency.

- * be simpler
+ * Be simpler

Line range hint 23-23: Fix the markdown link to ensure it is correctly formatted.

- * [ADR 033: Protobuf-based Inter-Module Communication](./adr-033-protobuf-inter-module-comm.md) clients.
+ * [ADR 033: Protobuf-based Inter-Module Communication](./adr-033-protobuf-inter-module-comm.md) for clients.

Line range hint 32-32: Consider using a hyphen for the compound adjective "third-party".

- * interface methods depend heavily on unstable third party dependencies, in particular Comet,
+ * interface methods depend heavily on unstable third-party dependencies, in particular Comet,

Line range hint 37-37: Start the list with an uppercase letter for consistency.

- * get store keys from the app
+ * Get store keys from the app

Line range hint 63-63: Start the list with an uppercase letter for consistency.

- * everything that a module wants to interact with in the state machine is a service
+ * Everything that a module wants to interact with in the state machine is a service

Line range hint 70-70: Consider using a hyphen for the compound adjective "non-stable".

- * the core API doesn't implement *any* functionality, it just defines types with specific non-stable versions of third party dependencies such as Comet
+ * the core API doesn't implement *any* functionality, it just defines types with specific non-stable versions of third-party dependencies such as Comet

Line range hint 195-195: Specify the language for the code block to enhance readability and syntax highlighting.

- ```go
+ ```go

Line range hint 222-222: Replace hard tabs with spaces to maintain consistency in indentation across the document.

- <hard tab>type AppModule interface {
+   type AppModule interface {

Line range hint 73-73: Ensure URLs are linked properly in markdown.

- * [ADR 033: Protobuf-based Inter-Module Communication](./adr-033-protobuf-inter-module-comm.md) clients.
+ * [ADR 033: Protobuf-based Inter-Module Communication](./adr-033-protobuf-inter-module-comm.md) clients.

Comment on lines +73 to 74
* Modules can now implement `appmodule.HasRegisterInterfaces`, `module.HasGRPCGateway` and `module.HasAminoCodec` when relevant.
* SDK modules now directly implement those extension interfaces on `AppModule` instead of `AppModuleBasic`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct the indentation of the unordered list items to improve readability and maintain consistency.

-    * Modules can now implement `appmodule.HasRegisterInterfaces`, `module.HasGRPCGateway` and `module.HasAminoCodec` when relevant.
-    * SDK modules now directly implement those extension interfaces on `AppModule` instead of `AppModuleBasic`.
+  * Modules can now implement `appmodule.HasRegisterInterfaces`, `module.HasGRPCGateway` and `module.HasAminoCodec` when relevant.
+  * SDK modules now directly implement those extension interfaces on `AppModule` instead of `AppModuleBasic`.

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
* Modules can now implement `appmodule.HasRegisterInterfaces`, `module.HasGRPCGateway` and `module.HasAminoCodec` when relevant.
* SDK modules now directly implement those extension interfaces on `AppModule` instead of `AppModuleBasic`.
* Modules can now implement `appmodule.HasRegisterInterfaces`, `module.HasGRPCGateway` and `module.HasAminoCodec` when relevant.
* SDK modules now directly implement those extension interfaces on `AppModule` instead of `AppModuleBasic`.

@@ -76,4 +76,4 @@ Modules often define parameters as a proto message. The generated struct can imp
* `KeyTable.RegisterParamSet()`: registers all parameters in the struct
* `Subspace.{Get, Set}ParamSet()`: Get to & Set from the struct

The implementor should be a pointer in order to use `GetParamSet()`.
The implementer should be a pointer in order to use `GetParamSet()`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider rephrasing to reduce wordiness.

- The implementer should be a pointer in order to use `GetParamSet()`.
+ The implementer should be a pointer to use `GetParamSet()`.

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
The implementer should be a pointer in order to use `GetParamSet()`.
The implementer should be a pointer to use `GetParamSet()`.

@@ -48,7 +48,7 @@ Ref: https://keepachangelog.com/en/1.0.0/

### API Breaking Changes

* [#16008](https://github.com/cosmos/cosmos-sdk/pull/16008) NewKeeper now takes in a KVStoreService instead of KVStoreKey, most functions use context.Context instead of sdk.Context and `IterateEvidence` callback function now returns an error to stop interation (`errors.ErrStopIterating`).
* [#16008](https://github.com/cosmos/cosmos-sdk/pull/16008) NewKeeper now takes in a KVStoreService instead of KVStoreKey, most functions use context.Context instead of sdk.Context and `IterateEvidence` callback function now returns an error to stop iteration (`errors.ErrStopIterating`).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a space between sentences for better readability.

- most functions use context.Context instead of sdk.Context and `IterateEvidence` callback function now returns an error to stop iteration (`errors.ErrStopIterating`).
+ most functions use context.Context instead of sdk.Context, and `IterateEvidence` callback function now returns an error to stop iteration (`errors.ErrStopIterating`).

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
* [#16008](https://github.com/cosmos/cosmos-sdk/pull/16008) NewKeeper now takes in a KVStoreService instead of KVStoreKey, most functions use context.Context instead of sdk.Context and `IterateEvidence` callback function now returns an error to stop iteration (`errors.ErrStopIterating`).
* [#16008](https://github.com/cosmos/cosmos-sdk/pull/16008) NewKeeper now takes in a KVStoreService instead of KVStoreKey, most functions use context.Context instead of sdk.Context, and `IterateEvidence` callback function now returns an error to stop iteration (`errors.ErrStopIterating`).

@@ -48,7 +48,7 @@

### API Breaking Changes

* [#16008](https://github.com/cosmos/cosmos-sdk/pull/16008) NewKeeper now takes in a KVStoreService instead of KVStoreKey, most functions use context.Context instead of sdk.Context and `IterateEvidence` callback function now returns an error to stop interation (`errors.ErrStopIterating`).
* [#16008](https://github.com/cosmos/cosmos-sdk/pull/16008) NewKeeper now takes in a KVStoreService instead of KVStoreKey, most functions use context.Context instead of sdk.Context and `IterateEvidence` callback function now returns an error to stop iteration (`errors.ErrStopIterating`).
* (keeper) [#15825](https://github.com/cosmos/cosmos-sdk/pull/15825) Evidence constructor now requires an `address.Codec` (`import "cosmossdk.io/core/address"`)
* [#16336](https://github.com/cosmos/cosmos-sdk/pull/16336) Use collections for state management:
* Removed: keeper `SetEvidence`, `GetEvidence`, `IterateEvidences`, `GetAllEvidences`, `MustMarshalEvidence`, `MustUnmarshalEvidence`, `MarshalEvidence`, `UnmarshalEvidence`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct indentation for unordered list items.

-    * Removed: keeper `SetEvidence`, `GetEvidence`, `IterateEvidences`, `GetAllEvidences`, `MustMarshalEvidence`, `MustUnmarshalEvidence`, `MarshalEvidence`, `UnmarshalEvidence`
+  * Removed: keeper `SetEvidence`, `GetEvidence`, `IterateEvidences`, `GetAllEvidences`, `MustMarshalEvidence`, `MustUnmarshalEvidence`, `MarshalEvidence`, `UnmarshalEvidence`

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
* Removed: keeper `SetEvidence`, `GetEvidence`, `IterateEvidences`, `GetAllEvidences`, `MustMarshalEvidence`, `MustUnmarshalEvidence`, `MarshalEvidence`, `UnmarshalEvidence`
* Removed: keeper `SetEvidence`, `GetEvidence`, `IterateEvidences`, `GetAllEvidences`, `MustMarshalEvidence`, `MustUnmarshalEvidence`, `MarshalEvidence`, `UnmarshalEvidence`

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

Out of diff range and nitpick comments (1)
x/authz/README.md (1)

Line range hint 9-9: Capitalize the first letter of the sentence.

- `x/authz` is an implementation of a Cosmos SDK module, per [ADR 30](https://github.com/cosmos/cosmos-sdk/blob/main/docs/architecture/adr-030-authz-module.md), that allows
+ `X/authz` is an implementation of a Cosmos SDK module, per [ADR 30](https://github.com/cosmos/cosmos-sdk/blob/main/docs/architecture/adr-030-authz-module.md), that allows

@@ -98,7 +98,7 @@ https://github.com/cosmos/cosmos-sdk/blob/v0.47.0-rc1/x/staking/types/authz.go#L

In order to prevent DoS attacks, granting `StakeAuthorization`s with `x/authz` incurs gas. `StakeAuthorization` allows you to authorize another account to delegate, undelegate, or redelegate to validators. The authorizer can define a list of validators they allow or deny delegations to. The Cosmos SDK iterates over these lists and charge 10 gas for each validator in both of the lists.

Since the state maintaining a list for granter, grantee pair with same expiration, we are iterating over the list to remove the grant (in case of any revoke of paritcular `msgType`) from the list and we are charging 20 gas per iteration.
Since the state maintaining a list for granter, grantee pair with same expiration, we are iterating over the list to remove the grant (in case of any revoke of particular `msgType`) from the list and we are charging 20 gas per iteration.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clarify the sentence structure and add a comma for better readability.

- Since the state maintaining a list for granter, grantee pair with same expiration, we are iterating over the list to remove the grant (in case of any revoke of particular `msgType`) from the list and we are charging 20 gas per iteration.
+ Since the state maintains a list for each granter-grantee pair with the same expiration, we iterate over the list to remove the grant (in case of any revoke of a particular `msgType`) from the list, and we charge 20 gas per iteration.

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
Since the state maintaining a list for granter, grantee pair with same expiration, we are iterating over the list to remove the grant (in case of any revoke of particular `msgType`) from the list and we are charging 20 gas per iteration.
Since the state maintains a list for each granter-grantee pair with the same expiration, we iterate over the list to remove the grant (in case of any revoke of a particular `msgType`) from the list, and we charge 20 gas per iteration.

@@ -124,7 +124,7 @@
https://github.com/cosmos/cosmos-sdk/blob/5f4ddc6f80f9707320eec42182184207fff3833a/x/authz/keeper/keeper.go#L378-L403
```

* GrantQueue: `0x02 | expiration_bytes | granter_address_len (1 byte) | granter_address_bytes | grantee_address_len (1 byte) | grantee_address_bytes -> ProtocalBuffer(GrantQueueItem)`
* GrantQueue: `0x02 | expiration_bytes | granter_address_len (1 byte) | granter_address_bytes | grantee_address_len (1 byte) | grantee_address_bytes -> ProtocolBuffer(GrantQueueItem)`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct the date format in the comment to match standard ISO 8601 format.

- The `expiration_bytes` are the expiration date in UTC with the format `"2006-01-02T15:04:05.000000000"`.
+ The `expiration_bytes` are the expiration date in UTC with the format `"YYYY-MM-DDTHH:MM:SS.sssZ"`.

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
* GrantQueue: `0x02 | expiration_bytes | granter_address_len (1 byte) | granter_address_bytes | grantee_address_len (1 byte) | grantee_address_bytes -> ProtocolBuffer(GrantQueueItem)`
* GrantQueue: `0x02 | expiration_bytes | granter_address_len (1 byte) | granter_address_bytes | grantee_address_len (1 byte) | grantee_address_bytes -> ProtocolBuffer(GrantQueueItem)`
- The `expiration_bytes` are the expiration date in UTC with the format `"YYYY-MM-DDTHH:MM:SS.sssZ"`.

@hieuvubk hieuvubk mentioned this pull request Apr 26, 2024
12 tasks
@julienrbrt julienrbrt added this pull request to the merge queue Apr 26, 2024
Merged via the queue into cosmos:main with commit 99dbdd5 Apr 26, 2024
63 of 64 checks passed
@hoangdv2429 hoangdv2429 deleted the chore/fix_all_typos branch April 26, 2024 11:20
meetrick pushed a commit to meetrick/cosmos-sdk that referenced this pull request Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants