diff --git a/CHANGELOG.md b/CHANGELOG.md index f054fab1..b4ceaf4b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,8 @@ - @cosmjs/cosmwasm: `ContractDetails` was removed in favour of just `Contract`. The missing `init_msg` is now available via the contract's code history (see `getContractCodeHistory`). +- @cosmjs/cosmwasm: Remove `SigningCallback` in favour of the `OfflineSigner` + interface. - @cosmjs/sdk38: Rename `CosmosClient.getNonce` method to `.getSequence`. - @cosmjs/sdk38: Remove `RestClient` class in favour of new modular `LcdClient` class. @@ -37,3 +39,6 @@ words. - @cosmjs/sdk38: The new `Secp256k1Wallet.serialize` and `.deserialize` allow encrypted serialization of the wallet. +- @cosmjs/sdk38: Remove the obsolete `upload`, `init`, `exec` properties from + `FeeTable`. @cosmjs/cosmwasm has its own `FeeTable` with those properties. +- @cosmjs/sdk38: Rename package to @cosmjs/launchpad. diff --git a/packages/cli/src/cli.ts b/packages/cli/src/cli.ts index a19172c8..1bee333e 100644 --- a/packages/cli/src/cli.ts +++ b/packages/cli/src/cli.ts @@ -52,7 +52,6 @@ export function main(originalArgs: readonly string[]): void { "ExecuteResult", "FeeTable", "InstantiateResult", - "SigningCallback", "SigningCosmWasmClient", "UploadMeta", "UploadResult", diff --git a/packages/cosmwasm/src/index.ts b/packages/cosmwasm/src/index.ts index 9b946c60..52a495d9 100644 --- a/packages/cosmwasm/src/index.ts +++ b/packages/cosmwasm/src/index.ts @@ -25,7 +25,6 @@ export { InstantiateOptions, InstantiateResult, MigrateResult, - SigningCallback, SigningCosmWasmClient, UploadMeta, UploadResult, diff --git a/packages/cosmwasm/src/signingcosmwasmclient.ts b/packages/cosmwasm/src/signingcosmwasmclient.ts index 4d3d9781..febecbba 100644 --- a/packages/cosmwasm/src/signingcosmwasmclient.ts +++ b/packages/cosmwasm/src/signingcosmwasmclient.ts @@ -13,7 +13,6 @@ import { PostTxFailure, PostTxResult, StdFee, - StdSignature, StdTx, } from "@cosmjs/launchpad"; import { Uint53 } from "@cosmjs/math"; @@ -31,10 +30,9 @@ import { MsgUpdateAdmin, } from "./msgs"; -export interface SigningCallback { - (signBytes: Uint8Array): Promise; -} - +/** + * Those fees are used by the higher level methods of SigningCosmWasmClient + */ export interface FeeTable { readonly upload: StdFee; readonly init: StdFee; diff --git a/packages/cosmwasm/types/index.d.ts b/packages/cosmwasm/types/index.d.ts index 9b838544..1b875e29 100644 --- a/packages/cosmwasm/types/index.d.ts +++ b/packages/cosmwasm/types/index.d.ts @@ -24,7 +24,6 @@ export { InstantiateOptions, InstantiateResult, MigrateResult, - SigningCallback, SigningCosmWasmClient, UploadMeta, UploadResult, diff --git a/packages/cosmwasm/types/signingcosmwasmclient.d.ts b/packages/cosmwasm/types/signingcosmwasmclient.d.ts index d7408acd..c42c7ff4 100644 --- a/packages/cosmwasm/types/signingcosmwasmclient.d.ts +++ b/packages/cosmwasm/types/signingcosmwasmclient.d.ts @@ -1,17 +1,9 @@ -import { - BroadcastMode, - Coin, - Msg, - OfflineSigner, - PostTxResult, - StdFee, - StdSignature, -} from "@cosmjs/launchpad"; +import { BroadcastMode, Coin, Msg, OfflineSigner, PostTxResult, StdFee } from "@cosmjs/launchpad"; import { Account, CosmWasmClient, GetSequenceResult } from "./cosmwasmclient"; import { Log } from "./logs"; -export interface SigningCallback { - (signBytes: Uint8Array): Promise; -} +/** + * Those fees are used by the higher level methods of SigningCosmWasmClient + */ export interface FeeTable { readonly upload: StdFee; readonly init: StdFee; diff --git a/packages/launchpad/src/signingcosmosclient.ts b/packages/launchpad/src/signingcosmosclient.ts index d901425a..cd9eb6d8 100644 --- a/packages/launchpad/src/signingcosmosclient.ts +++ b/packages/launchpad/src/signingcosmosclient.ts @@ -7,26 +7,14 @@ import { Msg, MsgSend } from "./msgs"; import { StdFee, StdTx } from "./types"; import { OfflineSigner } from "./wallet"; +/** + * Those fees are used by the higher level methods of SigningCosmosClient + */ export interface FeeTable { - readonly upload: StdFee; - readonly init: StdFee; - readonly exec: StdFee; readonly send: StdFee; } const defaultFees: FeeTable = { - upload: { - amount: coins(25000, "ucosm"), - gas: "1000000", // one million - }, - init: { - amount: coins(12500, "ucosm"), - gas: "500000", // 500k - }, - exec: { - amount: coins(5000, "ucosm"), - gas: "200000", // 200k - }, send: { amount: coins(2000, "ucosm"), gas: "80000", // 80k diff --git a/packages/launchpad/types/signingcosmosclient.d.ts b/packages/launchpad/types/signingcosmosclient.d.ts index d9947075..7add9e98 100644 --- a/packages/launchpad/types/signingcosmosclient.d.ts +++ b/packages/launchpad/types/signingcosmosclient.d.ts @@ -4,10 +4,10 @@ import { BroadcastMode } from "./lcdapi"; import { Msg } from "./msgs"; import { StdFee } from "./types"; import { OfflineSigner } from "./wallet"; +/** + * Those fees are used by the higher level methods of SigningCosmosClient + */ export interface FeeTable { - readonly upload: StdFee; - readonly init: StdFee; - readonly exec: StdFee; readonly send: StdFee; } export declare class SigningCosmosClient extends CosmosClient {