Use @cosmjs/utils in this project

This commit is contained in:
Simon Warta 2020-06-09 17:45:48 +02:00
parent e582313b17
commit 4cca97651b
18 changed files with 17 additions and 22 deletions

View File

@ -41,10 +41,10 @@
"dependencies": {
"@cosmjs/crypto": "^0.8.0",
"@cosmjs/sdk38": "^0.8.0",
"@cosmjs/utils": "^0.8.0",
"@iov/bcp": "^2.3.2",
"@iov/encoding": "^2.3.2",
"@iov/stream": "^2.3.2",
"@iov/utils": "^2.3.2",
"bn.js": "^5.1.1",
"fast-deep-equal": "^3.1.1",
"readonly-date": "^1.0.0",

View File

@ -1,5 +1,6 @@
import { Random, Secp256k1, Secp256k1Signature, Sha256 } from "@cosmjs/crypto";
import { decodeSignature } from "@cosmjs/sdk38";
import { assert } from "@cosmjs/utils";
import {
Account,
Address,
@ -20,7 +21,6 @@ import {
} from "@iov/bcp";
import { Bech32, fromBase64 } from "@iov/encoding";
import { HdPaths, Secp256k1HdWallet, UserProfile } from "@iov/keycontrol";
import { assert } from "@iov/utils";
import BN from "bn.js";
import { CosmosConnection, TokenConfiguration } from "./cosmosconnection";

View File

@ -41,8 +41,8 @@
"@cosmjs/cosmwasm": "^0.8.0",
"@cosmjs/crypto": "^0.8.0",
"@cosmjs/sdk38": "^0.8.0",
"@cosmjs/utils": "^0.8.0",
"@iov/encoding": "^2.3.2",
"@iov/utils": "^2.3.2",
"axios": "^0.19.2",
"babylon": "^6.18.0",
"colors": "^1.3.3",

View File

@ -118,7 +118,7 @@ export function main(originalArgs: readonly string[]): void {
"Uint64",
],
],
["@iov/utils", ["assert", "sleep"]],
["@cosmjs/utils", ["assert", "sleep"]],
]);
console.info(colors.green("Initializing session for you. Have fun!"));

View File

@ -38,8 +38,8 @@
"dependencies": {
"@cosmjs/crypto": "^0.8.0",
"@cosmjs/sdk38": "^0.8.0",
"@cosmjs/utils": "^0.8.0",
"@iov/encoding": "^2.3.2",
"@iov/utils": "^2.3.2",
"axios": "^0.19.0",
"fast-deep-equal": "^3.1.1",
"pako": "^1.0.11"

View File

@ -1,7 +1,7 @@
/* eslint-disable @typescript-eslint/camelcase */
import { Coin, CosmosSdkTx, isMsgSend, makeSignBytes, MsgSend, Secp256k1Pen } from "@cosmjs/sdk38";
import { assert, sleep } from "@cosmjs/utils";
import { Uint53 } from "@iov/encoding";
import { assert, sleep } from "@iov/utils";
import { CosmWasmClient } from "./cosmwasmclient";
import { isMsgExecuteContract, isMsgInstantiateContract } from "./msgs";

View File

@ -1,8 +1,8 @@
/* eslint-disable @typescript-eslint/camelcase */
import { Sha256 } from "@cosmjs/crypto";
import { makeSignBytes, MsgSend, Secp256k1Pen, StdFee } from "@cosmjs/sdk38";
import { assert, sleep } from "@cosmjs/utils";
import { Bech32, fromHex, fromUtf8, toAscii, toBase64 } from "@iov/encoding";
import { assert, sleep } from "@iov/utils";
import { ReadonlyDate } from "readonly-date";
import { Code, CosmWasmClient, PrivateCosmWasmClient } from "./cosmwasmclient";

View File

@ -15,8 +15,8 @@ import {
StdSignature,
StdTx,
} from "@cosmjs/sdk38";
import { assert, sleep } from "@cosmjs/utils";
import { Bech32, fromAscii, fromBase64, fromHex, toAscii, toBase64, toHex } from "@iov/encoding";
import { assert, sleep } from "@iov/utils";
import { ReadonlyDate } from "readonly-date";
import { findAttribute, parseLogs } from "./logs";

View File

@ -1,7 +1,7 @@
import { Sha256 } from "@cosmjs/crypto";
import { Coin, Secp256k1Pen } from "@cosmjs/sdk38";
import { assert } from "@cosmjs/utils";
import { toHex } from "@iov/encoding";
import { assert } from "@iov/utils";
import { PrivateCosmWasmClient } from "./cosmwasmclient";
import { RestClient } from "./restclient";

View File

@ -37,8 +37,8 @@
"dependencies": {
"@cosmjs/crypto": "^0.8.0",
"@cosmjs/sdk38": "^0.8.0",
"@cosmjs/utils": "^0.8.0",
"@iov/encoding": "^2.3.2",
"@iov/utils": "^2.3.2",
"@koa/cors": "^3.0.0",
"axios": "^0.19.0",
"koa": "^2.11.0",

View File

@ -1,7 +1,7 @@
import { Random } from "@cosmjs/crypto";
import { CosmosClient } from "@cosmjs/sdk38";
import { assert } from "@cosmjs/utils";
import { Bech32 } from "@iov/encoding";
import { assert } from "@iov/utils";
import { Faucet } from "./faucet";
import { TokenConfiguration } from "./types";

View File

@ -1,5 +1,5 @@
import { CosmosClient, Pen, SigningCosmosClient } from "@cosmjs/sdk38";
import { sleep } from "@iov/utils";
import { sleep } from "@cosmjs/utils";
import { debugAccount, logAccountsState, logSendJob } from "./debugging";
import { createPens } from "./profile";

View File

@ -37,8 +37,8 @@
},
"dependencies": {
"@cosmjs/crypto": "^0.8.0",
"@cosmjs/utils": "^0.8.0",
"@iov/encoding": "^2.3.2",
"@iov/utils": "^2.3.2",
"axios": "^0.19.0",
"fast-deep-equal": "^3.1.1"
},

View File

@ -1,6 +1,6 @@
/* eslint-disable @typescript-eslint/camelcase */
import { assert, sleep } from "@cosmjs/utils";
import { Uint53 } from "@iov/encoding";
import { assert, sleep } from "@iov/utils";
import { Coin } from "./coins";
import { CosmosClient } from "./cosmosclient";

View File

@ -1,5 +1,5 @@
/* eslint-disable @typescript-eslint/camelcase */
import { sleep } from "@iov/utils";
import { sleep } from "@cosmjs/utils";
import { ReadonlyDate } from "readonly-date";
import { CosmosClient, PrivateCosmWasmClient } from "./cosmosclient";

View File

@ -1,6 +1,6 @@
/* eslint-disable @typescript-eslint/camelcase */
import { assert, sleep } from "@cosmjs/utils";
import { fromBase64 } from "@iov/encoding";
import { assert, sleep } from "@iov/utils";
import { ReadonlyDate } from "readonly-date";
import { rawSecp256k1PubkeyToAddress } from "./address";

View File

@ -1,4 +1,4 @@
import { assert } from "@iov/utils";
import { assert } from "@cosmjs/utils";
import { Coin } from "./coins";
import { PrivateCosmWasmClient } from "./cosmosclient";

View File

@ -157,11 +157,6 @@
dependencies:
xstream "^11.10.0"
"@iov/utils@^2.3.2":
version "2.3.2"
resolved "https://registry.yarnpkg.com/@iov/utils/-/utils-2.3.2.tgz#a499ec304b4febaeb3af309dedbb30e14a09c91e"
integrity sha512-mtdZ8zh/LGjwA72HofOc8JF3KN1Rc1jwaQATePLDwIIJRw0AJXx2GLRBBRjja41huuw9ND0E2mQWlYLtYsNnUA==
"@koa/cors@^3.0.0":
version "3.0.0"
resolved "https://registry.yarnpkg.com/@koa/cors/-/cors-3.0.0.tgz#df021b4df2dadf1e2b04d7c8ddf93ba2d42519cb"