From 85c4a9aebdb43a11e8a7331bba0aa2e8a19b3589 Mon Sep 17 00:00:00 2001 From: Zaki Date: Sun, 23 Aug 2026 19:08:03 +0100 Subject: [PATCH 1/2] cork: explain why cork scheduling fails under Sommelier v10 v10 retires the validator-delegate cork path. x/cork's msg server now requires signer == params.cork_authority with no fallback, so every cork steward submits is rejected with ErrUnauthorized -- steward sends signer: get_delegate_address() (somm_send.rs). Steward cannot simply be pointed at the authority: it loads its signing key from an on-disk FsKeyStore, so it cannot act for an authority held on a hardware wallet, which is the deployed configuration. The rejection surfaced as "cork submission failed. this may be a steward configuration problem." That sends operators to inspect local config when the cause is a chain-side authorization change, so the message now names the actual reason and gives the CLI invocation that does work: sommelier tx cork schedule-cork --from The generic message is kept for rejections that are not authorization failures. NOT COMPILED. `cargo check` cannot build this crate on any toolchain available here: modern rustc fails on the abandoned `traitobject` crate (E0119, same failure as gravity-bridge CI's rust-test job) and 1.60.0 cannot parse the manifest. Both files were verified to parse with rustfmt, so this is syntax-checked but not type-checked. The change is a doc comment plus an if/else yielding &str. The traitobject rot is pre-existing and unrelated; it needs fixing separately before this crate can build at all. Co-Authored-By: Claude Opus 5 (1M context) --- src/cork.rs | 20 ++++++++++++++++---- src/somm_send.rs | 13 +++++++++++++ 2 files changed, 29 insertions(+), 4 deletions(-) diff --git a/src/cork.rs b/src/cork.rs index 7863bdf8..ac912265 100644 --- a/src/cork.rs +++ b/src/cork.rs @@ -158,11 +158,23 @@ async fn handle_cork(cellar_id: &str, encoded_call: Vec, height: u64) -> Res "failed to schedule cork for cellar {}. code {}, raw log: {}", cellar_id, res.code, res.raw_log ); - return Err(Status::new( - Code::Internal, + // Sommelier v10 retired the validator-delegate cork path: the + // chain requires signer == params.cork_authority. A rejection + // here is far more likely to be that than a local misconfig, + // and the generic message sent operators looking in the wrong + // place, so name the likely cause explicitly. + let hint = if res.raw_log.contains("not the cork authority") + || res.raw_log.contains("unauthorized") + { + "this steward's delegate key is not the chain's cork_authority. \ + Since Sommelier v10 only that address may schedule corks; steward \ + cannot sign for an authority held on a hardware wallet. Schedule it \ + with: sommelier tx cork schedule-cork \ + --from " + } else { "cork submission failed. this may be a steward configuration problem." - .to_string(), - )); + }; + return Err(Status::new(Code::Internal, hint.to_string())); } debug!("cork response: {:?}", res); diff --git a/src/somm_send.rs b/src/somm_send.rs index ac9f781b..eccd8b27 100644 --- a/src/somm_send.rs +++ b/src/somm_send.rs @@ -80,6 +80,19 @@ pub async fn unsubscribe(cellar_id: String) -> Result --from pub async fn schedule_cork(cork: Cork, block_height: u64) -> Result { let msg = MsgScheduleCorkRequest { cork: Some(cork), From 42e0faee9effcc4a5eac4cd950d57d7f75bedb4d Mon Sep 17 00:00:00 2001 From: Zaki Date: Sun, 23 Aug 2026 20:18:14 +0100 Subject: [PATCH 2/2] cork: fence the CLI example as text so rustdoc does not run it CI caught what I could not: the doc comment's indented CLI invocation was treated by rustdoc as a Rust doctest, and rust-test failed with src/somm_send.rs - somm_send::schedule_cork (line 95) ... FAILED error: expected one of `!` or `::`, found `tx` Fenced as ```text so it is rendered, not compiled. This is exactly the failure mode the "NOT COMPILED" caveat on the previous commit was flagging -- cargo cannot build this crate on any locally available toolchain, so CI was the first thing able to type-check it. Co-Authored-By: Claude Opus 5 (1M context) --- src/somm_send.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/somm_send.rs b/src/somm_send.rs index eccd8b27..b0b2d5d7 100644 --- a/src/somm_send.rs +++ b/src/somm_send.rs @@ -92,7 +92,9 @@ pub async fn unsubscribe(cellar_id: String) -> Result --from +/// ```text +/// sommelier tx cork schedule-cork --from +/// ``` pub async fn schedule_cork(cork: Cork, block_height: u64) -> Result { let msg = MsgScheduleCorkRequest { cork: Some(cork),