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

fix: spelling and grammatical errors #4095

Closed
wants to merge 8 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/auto_request_review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
reviewers:
# The default reviewers
defaults:
# Example of Github Team. Github team must have write access to repo.
# Example of Github Team. Github team must have to write access to the repo.
# NOTE: This assigned the team itself, not members of the team. The Github
# team auto PR assignment will then turn this into individuals
- team:celestia-core # This is the Github Team
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pr-review-requester.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: pr-review-requester

on:
# pull_request_target is used to allow forks write permissions when running
# pull_request_target is used to allow forks to write permissions when running
# this workflow. With the pull_request trigger, forks do not have any write
# access for security reasons, however write access is needed in order to
# request reviews. Since this workflow is simply requesting reviewers, it is
Expand All @@ -14,7 +14,7 @@ jobs:
uses: celestiaorg/.github/.github/workflows/[email protected]
secrets: inherit
# write access for issues and pull requests is needed because the called
# workflow requires write access to issues and pull requests and the
# workflow requires to write access to issues and pull requests and the
# permissions must match
permissions:
issues: write
Expand Down
4 changes: 2 additions & 2 deletions app/ante/tx_size_gas.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ func init() {

// ConsumeTxSizeGasDecorator will take in parameters and consume gas proportional
// to the size of tx before calling next AnteHandler. Note, the gas costs will be
// slightly over estimated due to the fact that any given signing account may need
// slightly overestimated due to the fact that any given signing account may need
// to be retrieved from state.
//
// CONTRACT: If simulate=true, then signatures must either be completely filled
// in or empty.
// CONTRACT: To use this decorator, signatures of transaction must be represented
// CONTRACT: To use this decorator, signatures of a transaction must be represented
// as legacytx.StdSignature otherwise simulate mode will incorrectly estimate gas cost.

// The code was copied from celestia's fork of the cosmos-sdk:
Expand Down
6 changes: 3 additions & 3 deletions app/benchmarks/benchmark_msg_send_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ func BenchmarkPrepareProposal_MsgSend_1(b *testing.B) {

func BenchmarkPrepareProposal_MsgSend_8MB(b *testing.B) {
// a full 8mb block equals to around 31645 msg send transactions.
// using 31645 to let prepare proposal choose the maximum
// using 31645 to let prepare a proposal choose the maximum
testApp, rawTxs := generateMsgSendTransactions(b, 31645)

blockData := &tmproto.Data{
Expand Down Expand Up @@ -174,7 +174,7 @@ func BenchmarkProcessProposal_MsgSend_1(b *testing.B) {

func BenchmarkProcessProposal_MsgSend_8MB(b *testing.B) {
// a full 8mb block equals to around 31645 msg send transactions.
// using 31645 to let prepare proposal choose the maximum
// using 31645 to let prepare a proposal choose the maximum
testApp, rawTxs := generateMsgSendTransactions(b, 31645)

blockData := &tmproto.Data{
Expand Down Expand Up @@ -281,7 +281,7 @@ func BenchmarkProcessProposal_MsgSend_8MB_Find_Half_Sec(b *testing.B) {
}
}

// generateMsgSendTransactions creates a test app then generates a number
// generateMsgSendTransactions creates a test app and then generates a number
// of valid msg send transactions.
func generateMsgSendTransactions(b *testing.B, count int) (*app.App, [][]byte) {
account := "test"
Expand Down
8 changes: 4 additions & 4 deletions app/benchmarks/results.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

This document contains the results of the benchmarks defined under `app/benchmarks`.

The benchmarks were run on a Macbook Pro M3 MAX with 16 cores 48GB RAM.
The benchmarks were run on a Macbook Pro M3 MAX with 16 cores and 48GB RAM.

The benchmarks will be run using an in memory DB, then a local db, goleveldb.

Expand Down Expand Up @@ -33,7 +33,7 @@ An `8MB` block containing 31645 `sendMsg` messages takes 5,04 s (5049140917 ns)

A single `processProposal` of a `sendMsg` message takes 0.0002313 **ns** to execute and it uses 101110 gas.

An `8MB` block containing 31645 `sendMsg` messages takes 5,17 s (5179850250 ns) to execute. The total gas used 1,843,040,790 gas.
An `8MB` block containing 31645 `sendMsg` messages takes 5,17 s (5179850250 ns) to execute. The total gas used was 1,843,040,790 gas.

For the processing time of a block full of `sendMsg`, we benchmarked how much time they take depending on the number of transactions, and we have the following results:

Expand Down Expand Up @@ -641,13 +641,13 @@ The transactions in an `8MB` block containing 31645 `sendMsg` messages take 7,50

A single `prepareProposal` of a `sendMsg` message takes 0.0003943 **ns** to execute and it uses 101110 gas.

An `8MB` block containing 31645 `sendMsg` messages takes 5,2 s (5242159792 ns) to execute. The total gas used 1843040790 gas.
An `8MB` block containing 31645 `sendMsg` messages takes 5,2 s (5242159792 ns) to execute. The total gas used was 1843040790 gas.

#### ProcessProposal

A single `processProposal` of a `sendMsg` message takes 0.0003010 **ns** to execute and it uses 101110 gas.

An `8MB` block containing 31645 `sendMsg` messages takes 5,21 s (5214205041 ns) to execute. The total gas used 1843040790 gas.
An `8MB` block containing 31645 `sendMsg` messages takes 5,21 s (5214205041 ns) to execute. The total gas used was 1843040790 gas.

### `PFB` benchmarks

Expand Down
8 changes: 4 additions & 4 deletions app/errors/insufficient_gas_price.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
)

var (
// This is relatively brittle. It would be better if going below the min gas price
// This is relatively brittle. It would be better if going below the minimum gas price
// had a specific error type.
regexpMinGasPrice = regexp.MustCompile(`insufficient fees; got: \d+utia required: \d+utia`)
regexpInt = regexp.MustCompile(`[0-9]+`)
Expand Down Expand Up @@ -50,13 +50,13 @@ func ParseInsufficientMinGasPrice(err error, gasPrice float64, gasLimit uint64)
}

// catch rare condition that required is zero. This should theoretically
// never happen as a min gas price of zero should always be accepted.
// never happens as a minimum gas price of zero should always be accepted.
if required == 0 {
return 0, errors.New("unexpected case: required gas price is zero (why was an error returned)")
}

// calculate the actual min gas price of the node based on the difference
// between the got and required values. If gas price was zero, we need to use
// calculate the actual minimum gas price of the node based on the difference
// between the got and required values. If the gas price was zero, we need to use
// the gasLimit to infer this.
if gasPrice == 0 || got == 0 {
if gasLimit == 0 {
Expand Down
2 changes: 1 addition & 1 deletion app/module/configurator.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
// Configurator implements the module.Configurator interface.
var _ module.Configurator = Configurator{}

// Configurator is a struct used at startup to register all the message and
// Configurator is a struct used at startup to register all the messages and
// query servers for all modules. It allows the module to register any migrations from
// one consensus version of the module to the next. Finally it maps all the messages
// to the app versions that they are accepted in. This then gets used in the antehandler
Expand Down
4 changes: 2 additions & 2 deletions app/module/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
)

// Manager defines a module manager that provides the high level utility for
// Manager defines a module manager that provides the high-level utility for
// managing and executing operations for a group of modules. This implementation
// was originally inspired by the module manager defined in Cosmos SDK but this
// implementation maps the state machine version to different versions of the
Expand All @@ -24,7 +24,7 @@ type Manager struct {
versionedModules map[uint64]map[string]sdkmodule.AppModule
// uniqueModuleVersions is a mapping of module name -> module consensus
// version -> the range of app versions this particular module operates
// over. The first element in the array represent the fromVersion and the
// over. The first element in the array represents the fromVersion and the
// last the toVersion (this is inclusive).
uniqueModuleVersions map[string]map[uint64][2]uint64
allModules []sdkmodule.AppModule
Expand Down
Loading