Launch App

Sommelier Protocol Team Weekly Update #1

Welcome to the weekly Protocol team update on the Sommelier protocol upgrades! This week we continue with Informal's audit and the team's delivery of upgrades to the Sommelier Gravity Bridge.

Informal’s Audit on the Gravity Bridge: Logging errors at the highest possible error level

Informal systems carried out an audit on Althea’s bridge. This audit on the Althea’s bridge involved the exposure of some issues which I and the rest of the Sommelier Protocol team are resolving.

One of this issue is the ignoring of high-level errors thereby logging the result at the lowest trace level. For instance, if errors are ignored while communicating with Cosmos via GRPC or submitting a Cosmos transaction the validator will get slashed within a few hours.

Improved Error Handling for GRPC calls to Cosmos

The Sommelier protocol team has upped the log level for failed message relaying by the orchestrator from info! to error!. Also, error message for a failed GRPC call in Cosmos has been improved to include number of messages in the chunk and the types of messages the chunk contained.

This means that if an error occurs while communicating with Cosmos via GRPC, the application will panic and the process stopped, disallowing validator slashing.

In other news, the Sommelier Protocol Gravity bridge Application (Gorc) has been upgraded to Abscissa 0.6.0.beta.1.

Upgrading the Gravity-Bridge to Abscissa Beta

The Sommelier Protocol Gravity bridge Application uses Abscissa. Abscissa is a microframework for building Rust applications (either CLI tools or network/web services), aiming to provide a large number of features with a minimal number of dependencies, and with a strong focus on security.

The Abscissa framework comes with enormous benefits like application-level logging, unified error-handling subsystem with generic error type, support for colored terminal output and so on that won’t be available if the application is created from scratch with a command-line option parser like Gumdrop and Clap.

Upgrading Gorc to Abscissa Beta

Initial versions of Abscissa were built with Gumdrop. This is because Gumdrop is effectively a "custom derive first" crate and in that regard felt much more cohesive. Also, Gumdrop has lesser dependencies when compared to Clap. However, with the Clap version 3, Clap better conforms to the expected behavior for command-line applications and is more widely used by the Rust community and thus more likely to be maintained for a long time. For instance, Clap provides help support for nested commands, providing better help messages for subcommands.

Upgrading the Gorc (Gravity Orchestrator) application to Abscissa beta involves replacing the Gumdrop crate with Clap in the Gorc application.

Help support for Nested Commands

Gumdrop struggles with help in subcommands, thereby requiring an additional boilerplate from Abscissa. However, even with a boilerplate in place, it is still difficult to create a friendly help screen or get useful help messages for subcommands as seen in this issue opened by a user.

With this upgrade, when the user enters a wrong command, Clap suggests commands and also displays the subcommands of a command.

To learn more about Sommelier, please visit https://sommelier.finance/

To use Sommelier, try the Pairings App at https://app.sommelier.finance/

To participate in the community, please join the Telegram group https://t.me/getsomm or Discord https://discord.gg/ZcAYgSBxvY.

To follow the project on Github, please star the project https://github.com/PeggyJV/sommelier.

More articles


© 2024 Somm by Bajanss OÜ –Maakri 36-50, Tallinn, Estonia 10145

Bug Bounty
Privacy Policy
Documentation
Telegram
Discord
Twitter