Files
bridge/internal
zeekay 3663252fd8 feat(broadcast): wire Polkadot author_submitExtrinsic + error classification
Add the substrate broadcast handler at internal/broadcast/dot.go:

- POST {"method":"author_submitExtrinsic","params":["0x<hex>"]} against
  the network's substrate RPC, return the 0x-prefixed extrinsic hash
  on success.
- DOTBroadcastError classification (retryable vs fatal) by substrate
  error code + message:
    Invalid::Future / AlreadyImported / pool-full / runtime-upgrade
        -> retryable (orchestrator polls again next tick)
    Invalid::Stale / Invalid::BadProof / Module(...)
        -> fatal (re-sign needed or pallet rejection)
- Default RPC endpoints: rpc.polkadot.io (mainnet),
  westend-rpc.polkadot.io (testnet), kusama-rpc.polkadot.io (canary).

Wire dispatch in client.go Broadcast switch: AddressTypeDOT lands in
broadcastDOT. ErrFamilyNotImplemented now reads BTC/SOL/TON/XRP only.

Tests cover happy-path, Stale/BadProof fatal, Future retryable,
AlreadyImported retryable, Module error fatal, 4xx-with-envelope, 5xx
without envelope, empty result, and error-string formatting.
2026-05-27 17:50:56 -07:00
..
2026-05-27 14:49:55 +02:00
2026-05-27 14:49:55 +02:00