-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat!: refactor
IConsensus
interface
- Loading branch information
Showing
13 changed files
with
444 additions
and
565 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
--- | ||
"@cartesi/rollups": major | ||
--- | ||
|
||
Refactored the `IConsensus` interface for better interaction with the Cartesi Rollups node. | ||
Added `InputIndexOutOfRange` error to `ICartesiDApp` interface to improve UX of voucher execution. | ||
Updated the `AbstractConsensus` contract to partially implement the new `IConsensus` interface. | ||
Updated the `Authority` contract to implement the new `IConsensus` interface. | ||
Updated the `CartesiDApp` contract to call `getEpochHash` instead of `getClaim`, and to not call `join`. | ||
Replaced the `bytes context` field from the `Proof` structure with an `InputRange inputRange` field. | ||
Removed the `getHistory`, `setHistory` and `migrateHistoryToConsensus` functions and `NewHistory` event from the `Authority` contract. | ||
Contracts that implemented the old `IConsensus` interface and wish to implement the new one must be adapted. | ||
Contracts that implement the new `IConsensus` interface are not backwards compatible with old `CartesiDApp` contracts, since they expect the consensus to expose a `join` function. | ||
Components that would call the `getClaim` function must now call the `getEpochHash` function while passing an input range instead of a "context" blob. | ||
Components that would call the `join` function should not call it anymore, as it is no longer declared in the new interface. | ||
Components that would listen to the `ApplicationJoined` event should not listen to it anymore, as it is no longer declared in the new interface. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.