Station wallet "transaction rejected by user" error when signing — console reports WalletError: User denied #208

Closed
opened 2026-05-28 14:57:57 +00:00 by totdking · 13 comments
totdking commented 2026-05-28 14:57:57 +00:00 (Migrated from gitlab.com)
No description provided.
totdking commented 2026-05-28 15:00:21 +00:00 (Migrated from gitlab.com)

Issue Summary

When attempting to sign or broadcast a transaction using the Station wallet extension, the process fails with a "transaction rejected by user" error displayed in the UI. The browser console shows a WalletError indicating "User denied, extension popup was closed," even if the user did not explicitly close the popup or reject the transaction. Interestingly, the stack trace mentions KeplrExtension, suggesting a potential abstraction or configuration issue in how the wallet provider handles the Station extension.


Reproduction Steps

  1. Connect a Station wallet to the application
  2. Initiate any transaction (e.g., Swap, Place Limit, or Provide Liquidity)
  3. Wait for the Station extension popup to appear
  4. Observe that the transaction fails with "transaction rejected by user in the UI
  5. Check the browser console for the WalletError and stack trace

Expected Behavior

The transaction should be successfully signed and broadcast when the user approves it in the Station extension popup. If a rejection occurs, it should only be when the user explicitly cancels the action.


Actual Behavior

The transaction is immediately rejected with the following error logged in the console:

Terra Classic transaction error: WalletError: User denied, extension popup was closed.
    at _WalletError.wrap ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:5973:15)
    at async KeplrExtension.signAndBroadcastTx ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:6114:34)
    at async KeplrExtension.broadcastTx ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:5797:18)

The UI displays: transaction rejected by user.


Environment Details

Field Value
OS macOS
Browser Google Chrome (desktop)
Network localterra (local Docker) or mainnet
Frontend VITE_NETWORK=local npm run dev

Wallet / Device Details

  • Wallet: Station browser extension
  • Extension version: latest
  • Error Source: @goblinhunt/cosmes wallet integration

Console Logs

Terra Classic transaction error: WalletError: User denied, extension popup was closed.
    at _WalletError.wrap ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:5973:15)
    at async KeplrExtension.signAndBroadcastTx ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:6114:34)
    at async KeplrExtension.broadcastTx ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:5797:18)

Severity / Impact

Blocker: This blocks all on-chain interactions for users using the Station wallet. The reference to KeplrExtension in the stack trace for a Station wallet error suggests a significant bug in the wallet provider's extension detection or routing logic.

Still hinders the last checklist of https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/work_items/147 being fully verified due to lack of testing with station wallet.

cc: @PlasticDigits ~"blocker:launch"

### Issue Summary When attempting to sign or broadcast a transaction using the Station wallet extension, the process fails with a "transaction rejected by user" error displayed in the UI. The browser console shows a `WalletError` indicating "User denied, extension popup was closed," even if the user did not explicitly close the popup or reject the transaction. Interestingly, the stack trace mentions `KeplrExtension`, suggesting a potential abstraction or configuration issue in how the wallet provider handles the Station extension. --- ### Reproduction Steps 1. Connect a Station wallet to the application 2. Initiate any transaction (e.g., Swap, Place Limit, or Provide Liquidity) 3. Wait for the Station extension popup to appear 4. Observe that the transaction fails with "transaction rejected by user in the UI 5. Check the browser console for the `WalletError` and stack trace --- ### Expected Behavior The transaction should be successfully signed and broadcast when the user approves it in the Station extension popup. If a rejection occurs, it should only be when the user explicitly cancels the action. --- ### Actual Behavior The transaction is immediately rejected with the following error logged in the console: ``` Terra Classic transaction error: WalletError: User denied, extension popup was closed. at _WalletError.wrap ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:5973:15) at async KeplrExtension.signAndBroadcastTx ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:6114:34) at async KeplrExtension.broadcastTx ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:5797:18) ``` The UI displays: `transaction rejected by user`. --- ### Environment Details | Field | Value | |-------|-------| | OS | macOS | | Browser | Google Chrome (desktop) | | Network | `localterra` (local Docker) or `mainnet` | | Frontend | `VITE_NETWORK=local npm run dev` | --- ### Wallet / Device Details - **Wallet:** Station browser extension - **Extension version:** latest - **Error Source:** `@goblinhunt/cosmes` wallet integration --- ### Console Logs ``` Terra Classic transaction error: WalletError: User denied, extension popup was closed. at _WalletError.wrap ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:5973:15) at async KeplrExtension.signAndBroadcastTx ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:6114:34) at async KeplrExtension.broadcastTx ( @goblinhunt_cosmes_wallet.js?v=a78dd4be:5797:18) ``` --- ### Severity / Impact **Blocker:** This blocks all on-chain interactions for users using the Station wallet. The reference to `KeplrExtension` in the stack trace for a Station wallet error suggests a significant bug in the wallet provider's extension detection or routing logic. Still hinders the last checklist of https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/work_items/147 being fully verified due to lack of testing with station wallet. cc: @PlasticDigits ~"blocker:launch"
PlasticDigits commented 2026-05-29 02:49:30 +00:00 (Migrated from gitlab.com)

mentioned in commit 2d92b130f8

mentioned in commit 2d92b130f8f89d8bf12bc15da4d8293c12f5b0cc
PlasticDigits commented 2026-05-29 02:49:38 +00:00 (Migrated from gitlab.com)

Fix landed on main (2d92b13)

@Brouie — please verify Station extension signing on LocalTerra and mainnet (swap, place limit, provide liquidity).

Root cause

  • StationExtension is an alias of cosmes KeplrExtension (Keplr in stack traces is expected).
  • Station’s window.station.keplr shim mishandles signDirect and can return User denied, extension popup was closed even when the user did not reject.
  • Overlapping sign prompts and a second signAmino after approval (fee-guard retry) could also close the popup.

Changes

  1. Cosmes patch — StationController always uses useAminoSigning = true for extension connects (#208).
  2. applyStationKeplrShimSignDefaults() — preferNoSetFee / preferNoSetMemo on connect + before each broadcast.
  3. Mainnet Station — experimentalSuggestChain before/after connect (same gas steps as Keplr).
  4. withTerraWalletSignLock — serializes extension broadcastTx so only one popup is active.
  5. Removed amino re-sign retry after fee guard (single sign only; guard still surfaces undershoot copy).
  6. Retail errors — false popup-closed → actionable Station reconnect copy.

Docs / agents

Verification checklist

  • cd frontend-dapp && npm ci && npm run test:run (includes cosmesPatch127.test.ts, terraWalletSignLock.test.ts)
  • Connect Station extension on LocalTerra (VITE_NETWORK=local) — approve addNetwork if prompted (#207)
  • Connect Station extension on mainnet/testnet — approve Terra Classic chain update if prompted
  • Swap — sign once, tx broadcasts (no immediate “transaction rejected by user”)
  • Place limit (CW20 path) — both allowance + place msgs sign successfully
  • Provide liquidity — multi-tx sequence completes
  • Explicit Reject in Station still shows “Transaction rejected by user”
  • Console: no false WalletError: User denied, extension popup was closed on approve

Leaving issue open until Station QA on real hardware confirms.

## Fix landed on `main` (`2d92b13`) @Brouie — please verify Station extension signing on **LocalTerra** and **mainnet** (swap, place limit, provide liquidity). ### Root cause - `StationExtension` is an alias of cosmes `KeplrExtension` (Keplr in stack traces is expected). - Station’s `window.station.keplr` shim mishandles **`signDirect`** and can return **`User denied, extension popup was closed`** even when the user did not reject. - Overlapping sign prompts and a **second `signAmino`** after approval (fee-guard retry) could also close the popup. ### Changes 1. **Cosmes patch** — `StationController` always uses **`useAminoSigning = true`** for extension connects ([#208](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/issues/208)). 2. **`applyStationKeplrShimSignDefaults()`** — `preferNoSetFee` / `preferNoSetMemo` on connect + before each broadcast. 3. **Mainnet Station** — `experimentalSuggestChain` before/after connect (same gas steps as Keplr). 4. **`withTerraWalletSignLock`** — serializes extension `broadcastTx` so only one popup is active. 5. **Removed amino re-sign retry** after fee guard (single sign only; guard still surfaces undershoot copy). 6. **Retail errors** — false popup-closed → actionable Station reconnect copy. ### Docs / agents - [docs/frontend.md § Station extension signing](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/blob/main/docs/frontend.md#station-extension-signing) - [`skills/AGENTS_FRONTEND_STATION_SIGNING.md`](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/blob/main/skills/AGENTS_FRONTEND_STATION_SIGNING.md) ### Verification checklist - [ ] `cd frontend-dapp && npm ci && npm run test:run` (includes `cosmesPatch127.test.ts`, `terraWalletSignLock.test.ts`) - [ ] Connect **Station extension** on LocalTerra (`VITE_NETWORK=local`) — approve `addNetwork` if prompted ([#207](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/issues/207)) - [ ] Connect **Station extension** on mainnet/testnet — approve Terra Classic chain update if prompted - [ ] **Swap** — sign once, tx broadcasts (no immediate “transaction rejected by user”) - [ ] **Place limit** (CW20 path) — both allowance + place msgs sign successfully - [ ] **Provide liquidity** — multi-tx sequence completes - [ ] Explicit **Reject** in Station still shows “Transaction rejected by user” - [ ] Console: no false `WalletError: User denied, extension popup was closed` on approve Leaving issue **open** until Station QA on real hardware confirms.
PlasticDigits commented 2026-05-29 02:52:03 +00:00 (Migrated from gitlab.com)

mentioned in commit 25b4793913

mentioned in commit 25b479391377e5c2cf2b75b6ef44a37900ce4073
PlasticDigits commented 2026-05-29 02:52:59 +00:00 (Migrated from gitlab.com)

mentioned in commit 2607f15bc1

mentioned in commit 2607f15bc1dfe6f2e9996d98b4e56fe6426dff64
PlasticDigits commented 2026-05-29 02:53:00 +00:00 (Migrated from gitlab.com)

Fix landed on main (commit 2d92b13 + doc follow-up)

Station extension txs were routed through signDirect on mainnet and a second signAmino could run after the user already approved the first prompt. Station’s Keplr shim then often reported User denied, extension popup was closed even when the user intended to approve — stack traces showing KeplrExtension are expected (StationExtension is an alias).

What changed

  • Cosmes patch: StationController → useAminoSigning = true for all extension connects; one signAmino per tx (no fee-guard retry re-prompt).
  • applyStationKeplrShimSignDefaults() on Station connect + before every broadcastTerraExecuteContracts.
  • withTerraWalletSignLock serializes extension broadcastTx so overlapping popups cannot clobber each other.
  • Mainnet: experimentalSuggestChain before/after connect for Station (gas step refresh).
  • Retail errors: false popup-closed → actionable Station copy (not generic “rejected by user”).
  • Docs/skills: § Station extension signing, skills/AGENTS_FRONTEND_STATION_SIGNING.md.

Verification checklist

  • cd frontend-dapp && npm ci (patch applies: @goblinhunt/cosmes@0.0.71-ghunt.21 ✔)
  • npm run test:run — cosmesPatch127.test.ts, terraWalletSignLock.test.ts, terraBroadcast.test.ts
  • Mainnet + Station extension: connect → swap succeeds after approving one popup
  • LocalTerra + Station: connect (approve addNetwork / chain update if prompted) → swap / place limit / provide liquidity
  • Explicit reject still shows decline copy; no false popup-closed on happy path
  • Console: KeplrExtension in stack is OK when wallet type is Station

@brouie — please run the checklist above on your Station build (mainnet + local if available) and reply here. Leaving the issue open until verified.

/cc @PlasticDigits

## Fix landed on `main` (commit `2d92b13` + doc follow-up) Station extension txs were routed through **`signDirect`** on mainnet and a **second `signAmino`** could run after the user already approved the first prompt. Station’s Keplr shim then often reported **`User denied, extension popup was closed`** even when the user intended to approve — stack traces showing **`KeplrExtension`** are expected (`StationExtension` is an alias). ### What changed - **Cosmes patch:** `StationController` → **`useAminoSigning = true`** for all extension connects; **one** `signAmino` per tx (no fee-guard retry re-prompt). - **`applyStationKeplrShimSignDefaults()`** on Station connect + before every `broadcastTerraExecuteContracts`. - **`withTerraWalletSignLock`** serializes extension `broadcastTx` so overlapping popups cannot clobber each other. - **Mainnet:** `experimentalSuggestChain` before/after connect for Station (gas step refresh). - **Retail errors:** false popup-closed → actionable Station copy (not generic “rejected by user”). - **Docs/skills:** [§ Station extension signing](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/blob/main/docs/frontend.md#station-extension-signing), [`skills/AGENTS_FRONTEND_STATION_SIGNING.md`](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/blob/main/skills/AGENTS_FRONTEND_STATION_SIGNING.md). ### Verification checklist - [ ] `cd frontend-dapp && npm ci` (patch applies: `@goblinhunt/cosmes@0.0.71-ghunt.21 ✔`) - [ ] `npm run test:run` — `cosmesPatch127.test.ts`, `terraWalletSignLock.test.ts`, `terraBroadcast.test.ts` - [ ] **Mainnet + Station extension:** connect → swap succeeds after approving **one** popup - [ ] **LocalTerra + Station:** connect (approve `addNetwork` / chain update if prompted) → swap / place limit / provide liquidity - [ ] **Explicit reject** still shows decline copy; no false popup-closed on happy path - [ ] Console: `KeplrExtension` in stack is OK when wallet type is Station @brouie — please run the checklist above on your Station build (mainnet + local if available) and reply here. Leaving the issue **open** until verified. /cc @PlasticDigits
PlasticDigits commented 2026-05-30 07:07:55 +00:00 (Migrated from gitlab.com)

mentioned in issue #127

mentioned in issue #127
PlasticDigits (Migrated from gitlab.com) closed this issue 2026-05-30 09:05:56 +00:00
PlasticDigits commented 2026-05-30 09:05:57 +00:00 (Migrated from gitlab.com)

Closing as local testing cannot be done on station wallet, only other wallets. terrastation does not work properly with localterra.

Closing as local testing cannot be done on station wallet, only other wallets. terrastation does not work properly with localterra.
PlasticDigits commented 2026-06-12 05:05:54 +00:00 (Migrated from gitlab.com)

mentioned in issue #367

mentioned in issue #367
PlasticDigits commented 2026-08-18 23:53:09 +00:00 (Migrated from gitlab.com)

mentioned in issue #567

mentioned in issue #567
PlasticDigits commented 2026-08-19 01:07:34 +00:00 (Migrated from gitlab.com)

mentioned in merge request !1091

mentioned in merge request !1091
PlasticDigits commented 2026-08-27 00:20:45 +00:00 (Migrated from gitlab.com)

mentioned in issue #679

mentioned in issue #679
PlasticDigits commented 2026-08-27 00:20:55 +00:00 (Migrated from gitlab.com)

mentioned in issue #681

mentioned in issue #681
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
code/cl8y-dex-terraclassic#208
No description provided.