Skip to content

Commit

Permalink
chore: spelling errors fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
github-merge-queue[bot] authored and github-actions[bot] committed Oct 31, 2024
1 parent 399c833 commit adee3bb
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 27 deletions.
4 changes: 2 additions & 2 deletions contrib/local-testnet.sh
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ do

sleep 1

# Create account keypair
# Create account key pair
interchain-security-pd keys add $PROV_KEY --home ${PROV_NODE_DIR} --keyring-backend test --output json > ${PROV_NODE_DIR}/${PROV_KEY}.json 2>&1
sleep 1

Expand Down Expand Up @@ -394,7 +394,7 @@ do

sleep 1

# Create account keypair
# Create account key pair
interchain-security-cd keys add $PROV_KEY --home ${CONS_NODE_DIR} --keyring-backend test --output json > ${CONS_NODE_DIR}/${PROV_KEY}.json 2>&1
sleep 1

Expand Down
22 changes: 11 additions & 11 deletions docs/docs/build/modules/02-provider.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ The provider module has the following functionalities:
- The customization of the consumer chains validator sets.
- The option for validators to opt in to validate the consumer chains they want.
- The distribution of rewards from consumer chains to the opted in validators.
- The slashing and jailing of validators commiting infractions on consumer chains based on cryptographic evidence.
- The slashing and jailing of validators committing infractions on consumer chains based on cryptographic evidence.

## State

Expand Down Expand Up @@ -144,7 +144,7 @@ Format: `byte(53) | len(clientId) | []byte(clientId) -> string`
Format: `byte(14) | []byte(consumerId) -> ConsumerGenesisState`


### Key Assingment
### Key Assignment

#### ConsumerValidators

Expand Down Expand Up @@ -375,7 +375,7 @@ The consumer module is an IBC application that implements the [IBC module callba

`OnChanOpenTry` validates the parameters of the _CCV channel_ -- an ordered IBC channel connected on the `provider` port
and with the counterparty port set to `consumer` -- and asserts that the counterparty version matches the expected version
(only verions `1` is supported).
(only versions `1` is supported).

If the validation passes, the provider module verifies that the underlying client is the expected client of the consumer chain
(i.e., the client created during the consumer chain launch) and that no other CCV channel exists for this consumer chain.
Expand Down Expand Up @@ -492,8 +492,8 @@ As a result, if the `power_shaping_parameters` are provided, then `power_shaping
To create a top-n consumer chain, the following steps are require:

- Create a opt-in consumer chain (via `MsgCreateConsumer`).
- Change the ownership of the consuemr chain to the gov module account address (via `MsgUpdateConsumer`).
- Change `power_shaping_parameters.top_N` to a value in `[50, 100]` trough a governance proposal with a `MsgUpdateConsumer` message.
- Change the ownership of the consumer chain to the gov module account address (via `MsgUpdateConsumer`).
- Change `power_shaping_parameters.top_N` to a value in `[50, 100]` through a governance proposal with a `MsgUpdateConsumer` message.

If the `initialization_parameters` field is set and `initialization_parameters.spawn_time > 0`, then the consumer chain will be scheduled to launch at `spawn_time`.

Expand Down Expand Up @@ -600,7 +600,7 @@ You can use the `list-consumer-chains` query to get the list of all consumer cha

The `consumer_key` field is optional.
It enables the validator to set the consensus public key to use on the consumer chain.
The validator can assing (or re-assing) this key also later via [MsgAssignConsumerKey](#msgassignconsumerkey).
The validator can assign (or re-assign) this key also later via [MsgAssignConsumerKey](#msgassignconsumerkey).

:::warning
Validators are strongly recommended to assign a separate key for each consumer chain
Expand Down Expand Up @@ -752,7 +752,7 @@ message MsgSetConsumerCommissionRate {

### MsgSubmitConsumerMisbehaviour

`MsgSubmitConsumerMisbehaviour` enables users to submit to the provider evidence of a light client attack that occured on a consumer chain.
`MsgSubmitConsumerMisbehaviour` enables users to submit to the provider evidence of a light client attack that occurred on a consumer chain.
This message can be submitted directly by users, e.g., via the CLI command `tx provider submit-consumer-misbehaviour`,
or by a relayer that can be set to automatically detect consumer chain misbehaviors, e.g., [Hermes](https://github.com/informalsystems/hermes).

Expand All @@ -762,7 +762,7 @@ the `chain_id` field is deprecated.
Users should use `consumer_id` instead.
You can use the `list-consumer-chains` query to get the list of all consumer chains and their consumer IDs.

For more details on reporting light client attacks that occured on consumer chains, check out the [guide on equivocation infractions](../../features/slashing.md#equivocation-infractions).
For more details on reporting light client attacks that occurred on consumer chains, check out the [guide on equivocation infractions](../../features/slashing.md#equivocation-infractions).

```proto
message MsgSubmitConsumerMisbehaviour {
Expand All @@ -781,7 +781,7 @@ message MsgSubmitConsumerMisbehaviour {

### MsgSubmitConsumerDoubleVoting

`MsgSubmitConsumerDoubleVoting` enables users to submit to the provider evidence of a double signing infraction that occured on a consumer chain.
`MsgSubmitConsumerDoubleVoting` enables users to submit to the provider evidence of a double signing infraction that occurred on a consumer chain.
This message can be submitted directly by users, e.g., via the CLI command `tx provider submit-consumer-double-voting`,
or by a relayer that can be set to automatically detect consumer chain misbehaviors, e.g., [Hermes](https://github.com/informalsystems/hermes).

Expand All @@ -791,7 +791,7 @@ the `chain_id` field is deprecated.
Users should use `consumer_id` instead.
You can use the `list-consumer-chains` query to get the list of all consumer chains and their consumer IDs.

For more details on reporting double signing infractions that occured on consumer chains, check out the [guide on equivocation infractions](../../features/slashing.md#equivocation-infractions).
For more details on reporting double signing infractions that occurred on consumer chains, check out the [guide on equivocation infractions](../../features/slashing.md#equivocation-infractions).

```proto
message MsgSubmitConsumerDoubleVoting {
Expand Down Expand Up @@ -835,7 +835,7 @@ In the `EndBlock` of the provider module the following actions are performed:
- Prune the no-longer needed public keys assigned by validators to use when validating on consumer chains.
- Send validator updates to the consensus engine.
The maximum number of validators is set through the [MaxProviderConsensusValidators](#maxproviderconsensusvalidators) param.
- At the begining of every epoch,
- At the beginning of every epoch,
- for every launched consumer chain, compute the next consumer validator set and send it to the consumer chain via an IBC packet;
- increment the VSC id.

Expand Down
6 changes: 3 additions & 3 deletions docs/docs/build/modules/03-consumer.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ The consumer module is an IBC application that implements the [IBC module callba
`OnChanOpenInit` first verifies that the CCV channel was not already created.
Then, it validates the channel parameters -- an ordered IBC channel connected on the `consumer` port
and with the counterparty port set to `provider` -- and asserts that the version matches the expected version
(only verions `1` is supported).
(only versions `1` is supported).

Finally, it verifies that the underlying client is the expected client of the provider chain
(i.e., provided in the consumer module genesis state).
Expand All @@ -226,7 +226,7 @@ Finally, it verifies that the underlying client is the expected client of the pr

`OnChanOpenAck` first verifies that the CCV channel was not already created.
Then it verifies that the counterparty version matches the expected version
(only verions `1` is supported).
(only versions `1` is supported).

If the verification passes, it stores the [ProviderFeePoolAddr](#providerfeepooladdrstr) in the state.

Expand Down Expand Up @@ -313,7 +313,7 @@ In the `EndBlock` of the consumer module the following actions are performed:
that was just upgraded to include the consumer module, then execute the [changeover logic](../../consumer-development/changeover-procedure.md).
- Otherwise, distribute block rewards internally and once every [BlocksPerDistributionTransmission](#blocksperdistributiontransmission) send
ICS rewards to the provider chain.
- Send slash packets to the provider chain reporting infractions validators commited on the consumer chain.
- Send slash packets to the provider chain reporting infractions validators committed on the consumer chain.
- Send to the consensus engine validator updates reveived from the provider chain.

## Hooks
Expand Down
18 changes: 9 additions & 9 deletions docs/figures/hypha-consumer-start-process.excalidraw
Original file line number Diff line number Diff line change
Expand Up @@ -6117,11 +6117,11 @@
"locked": false,
"fontSize": 20,
"fontFamily": 1,
"text": "Hz\nwe get the \nevidence and \nslash",
"text": "Hz\new get the \nevidence and \nslash",
"textAlign": "center",
"verticalAlign": "middle",
"containerId": "V2uHp_TDQ8ihrS_8j9zZZ",
"originalText": "Hz\nwe get the evidence and slash",
"originalText": "Hz\new get the evidence and slash",
"autoResize": true,
"lineHeight": 1.25
},
Expand Down Expand Up @@ -7482,7 +7482,7 @@
"locked": false,
"fontSize": 16,
"fontFamily": 1,
"text": "height at which \nwe receive\nthe evidence",
"text": "height at which \new receive\nthe evidence",
"textAlign": "center",
"verticalAlign": "middle",
"containerId": "s48-4wXmB4eSn25hza5zD",
Expand Down Expand Up @@ -17350,11 +17350,11 @@
"locked": false,
"fontSize": 16,
"fontFamily": 1,
"text": "LC figures\nout that\nconsumer chain\nbecame\nunsecore on\ntimestamp T\n\nThen, LC would need to\n\"deactivate\"\nof all headers that\nhave timestamp >= T.\n\nWe can keep getting\nupdates but not use \ntheir Merkle root. ",
"text": "LC figures\nout that\nconsumer chain\nbecame\nunsecore on\ntimestamp T\n\nThen, LC would need to\n\"deactivate\"\nof all headers that\nhave timestamp >= T.\n\new can keep getting\nupdates but not use \ntheir Merkle root. ",
"textAlign": "left",
"verticalAlign": "top",
"containerId": null,
"originalText": "LC figures\nout that\nconsumer chain\nbecame\nunsecore on\ntimestamp T\n\nThen, LC would need to\n\"deactivate\"\nof all headers that\nhave timestamp >= T.\n\nWe can keep getting\nupdates but not use \ntheir Merkle root. ",
"originalText": "LC figures\nout that\nconsumer chain\nbecame\nunsecore on\ntimestamp T\n\nThen, LC would need to\n\"deactivate\"\nof all headers that\nhave timestamp >= T.\n\new can keep getting\nupdates but not use \ntheir Merkle root. ",
"autoResize": true,
"lineHeight": 1.25
},
Expand Down Expand Up @@ -33824,11 +33824,11 @@
"locked": false,
"fontSize": 16,
"fontFamily": 1,
"text": "bogus header\n4. Febuary 2023\nsigned by Vm",
"text": "bogus header\n4. February 2023\nsigned by Vm",
"textAlign": "center",
"verticalAlign": "middle",
"containerId": "dr-C5qJTTjNBk139hzYmq",
"originalText": "bogus header\n4. Febuary 2023\nsigned by Vm",
"originalText": "bogus header\n4. February 2023\nsigned by Vm",
"autoResize": true,
"lineHeight": 1.25
},
Expand Down Expand Up @@ -39079,11 +39079,11 @@
"locked": false,
"fontSize": 36,
"fontFamily": 1,
"text": "powers and consumer\npublic keys the validators\nhad when they actually\nopted in to a\nconsumer chain at the\nbeginning of an epoch\nCurrently used by consumer\nchain.\nWE STORE THOSE for\neach validator",
"text": "powers and consumer\npublic keys the validators\nhad when they actually\nopted in to a\nconsumer chain at the\nbeginning of an epoch\nCurrently used by consumer\nchain.\new STORE THOSE for\neach validator",
"textAlign": "center",
"verticalAlign": "top",
"containerId": null,
"originalText": "powers and consumer\npublic keys the validators\nhad when they actually\nopted in to a\nconsumer chain at the\nbeginning of an epoch\nCurrently used by consumer\nchain.\nWE STORE THOSE for\neach validator",
"originalText": "powers and consumer\npublic keys the validators\nhad when they actually\nopted in to a\nconsumer chain at the\nbeginning of an epoch\nCurrently used by consumer\nchain.\new STORE THOSE for\neach validator",
"autoResize": true,
"lineHeight": 1.25
},
Expand Down
2 changes: 1 addition & 1 deletion scripts/test_doc/test_documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@
|----------|-------------------|
[TestRelayAndApplyDowntimePacket](../../tests/integration/slashing.go#L50) | TestRelayAndApplyDowntimePacket tests that downtime slash packets can be properly relayed from consumer to provider, handled by provider, with a VSC and jailing eventually effective on consumer and provider.<details><summary>Details</summary>* Set up CCV channels and retrieve consumer validators.<br>* Select a validator and create its consensus address.<br>* Retrieve the provider consensus address that corresponds to the consumer consensus address of the validator.<br>* The validator's current state is also retrieved, including its token balance,<br>* Set validator's signing information is to ensure it will be jailed for downtime.<br>* Create the slashing packet and send it from the consumer chain to the provider chain with a specified timeout.<br>* Receive the packet and verify that the validator was removed from the provider validator set.<br>* Relay VSC packets from the provider chain to each consumer chain and verify that the consumer chains correctly process these packets.<br>* Check the validator's balance and status on the provider chain to ensure it was jailed correctly but not slashed,<br>and its unjailing time is updated.<br>* Reset the outstanding downtime flag on the consumer chain, and ensure that the consumer<br>chain acknowledges receipt of the packet from the provider chain.<br><br>Note: This method does not test the actual slash packet sending logic for downtime<br>and double-signing, see TestValidatorDowntime and TestValidatorDoubleSigning for<br>those types of tests.</details> |
[TestSlashPacketAcknowledgement](../../tests/integration/slashing.go#L185) | TestSlashPacketAcknowledgement tests the handling of a slash packet acknowledgement.<details><summary>Details</summary>* Set up a provider and consumer chain, with channel initialization between them performed.<br>* Send a slash packet with randomized fields from the consumer to the provider.<br>* The provider processes the packet</details> |
[TestHandleSlashPacketDowntime](../../tests/integration/slashing.go#L236) | TestHandleSlashPacketDowntime tests the handling of a downtime related slash packet, with integration tests.<details><summary>Details</summary>* Retrieve a validator from provider chain's validators and checks if it's bonded.<br>* Set tThe signing information for the validator.<br>* The provider processes the downtime slashing packet from the consumer.<br>* Check that the validator has been jailed as a result of the downtime slashing packet being processed.<br>* Verify that the validator’s signing information is updated and that the jailing duration is set correctly.<br><br>Note that only downtime slash packets are processed by HandleSlashPacket.</details> |
[TestHandleSlashPacketDowntime](../../tests/integration/slashing.go#L236) | TestHandleSlashPacketDowntime tests the handling of a downtime related slash packet, with integration tests.<details><summary>Details</summary>* Retrieve a validator from provider chain's validators and checks if it's bonded.<br>* Set the signing information for the validator.<br>* The provider processes the downtime slashing packet from the consumer.<br>* Check that the validator has been jailed as a result of the downtime slashing packet being processed.<br>* Verify that the validator’s signing information is updated and that the jailing duration is set correctly.<br><br>Note that only downtime slash packets are processed by HandleSlashPacket.</details> |
[TestOnRecvSlashPacketErrors](../../tests/integration/slashing.go#L283) | TestOnRecvSlashPacketErrors tests errors for the OnRecvSlashPacket method in an integration testing setting.<details><summary>Details</summary>* Set up all CCV channels and expect panic if the channel is not established via dest channel of packet.<br>* After the correct channelID is added to the packet, a panic shouldn't occur anymore.<br>* Create an instance of SlashPacketData and then verify correct processing and error handling<br>for slashing packets received by the provider chain.<br>TODO: Move to unit tests.</details> |
[TestValidatorDowntime](../../tests/integration/slashing.go#L412) | TestValidatorDowntime tests if a slash packet is sent and if the outstanding slashing flag is switched when a validator has downtime on the slashing module.<details><summary>Details</summary>* Set up all CCV channel and send an empty VSC packet, then retrieve the address of a validator.<br>* Validator signs blocks for the duration of the signedBlocksWindow and a slash packet is constructed to be sent and committed.<br>* Simulate the validator missing blocks and then verify that the validator is jailed and the jailed time is correctly updated.<br>* Ensure that the missed block counters are reset.<br>* Check that there is a pending slash packet in the queue, and then send the pending packets.<br>* Check if slash record is created and verify that the consumer queue still contains the packet since no<br>acknowledgment has been received from the provider.<br>* Verify that the slash packet was sent and check that the outstanding slashing flag prevents the jailed validator to keep missing block.</details> |
[TestQueueAndSendSlashPacket](../../tests/integration/slashing.go#L533) | TestQueueAndSendSlashPacket tests the integration of QueueSlashPacket with SendPackets. In normal operation slash packets are queued in BeginBlock and sent in EndBlock.<details><summary>Details</summary>* Set up all CCV channels and then queue slash packets for both downtime and double-signing infractions.<br>* Check that the correct number of slash requests are stored in the queue, including duplicates for downtime infractions.<br>* Prepare the CCV channel for sending actual slash packets.<br>* Send the slash packets and check that the outstanding downtime flags are correctly set for validators that were slashed<br>for downtime infractions.<br>* Ensure that the pending data packets queue is empty.<br>TODO: Move to unit tests.</details> |
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/slashing.go
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ func (s *CCVTestSuite) TestSlashPacketAcknowledgement() {
// TestHandleSlashPacketDowntime tests the handling of a downtime related slash packet, with integration tests.
// @Long Description@
// * Retrieve a validator from provider chain's validators and checks if it's bonded.
// * Set tThe signing information for the validator.
// * Set the signing information for the validator.
// * The provider processes the downtime slashing packet from the consumer.
// * Check that the validator has been jailed as a result of the downtime slashing packet being processed.
// * Verify that the validator’s signing information is updated and that the jailing duration is set correctly.
Expand Down

0 comments on commit adee3bb

Please sign in to comment.