From 19bc874e26b3257ccf48e93bd454153e5ca8be88 Mon Sep 17 00:00:00 2001 From: Turadg Aleahmad Date: Tue, 4 Jun 2024 13:14:10 -0700 Subject: [PATCH] chore: remove deposit() from Cosmos acct interface --- packages/orchestration/src/cosmos-api.ts | 2 -- packages/orchestration/src/exos/chainAccountKit.js | 13 +++---------- .../src/exos/cosmosOrchestrationAccount.js | 6 ++++-- 3 files changed, 7 insertions(+), 14 deletions(-) diff --git a/packages/orchestration/src/cosmos-api.ts b/packages/orchestration/src/cosmos-api.ts index da0f7646df4..134628e4462 100644 --- a/packages/orchestration/src/cosmos-api.ts +++ b/packages/orchestration/src/cosmos-api.ts @@ -196,8 +196,6 @@ export interface IcaAccount { msgs: AnyJson[], opts?: Partial>, ) => Promise; - /** deposit payment from zoe to the account*/ - deposit: (payment: Payment) => Promise; /** get Purse for a brand to .withdraw() a Payment from the account */ getPurse: (brand: Brand) => Promise; /** diff --git a/packages/orchestration/src/exos/chainAccountKit.js b/packages/orchestration/src/exos/chainAccountKit.js index 562702359e5..01f3d92afe5 100644 --- a/packages/orchestration/src/exos/chainAccountKit.js +++ b/packages/orchestration/src/exos/chainAccountKit.js @@ -1,15 +1,15 @@ /** @file ChainAccount exo */ import { NonNullish } from '@agoric/assert'; +import { PurseShape } from '@agoric/ertp'; import { makeTracer } from '@agoric/internal'; import { V as E } from '@agoric/vow/vat.js'; import { M } from '@endo/patterns'; -import { PaymentShape, PurseShape } from '@agoric/ertp'; -import { findAddressField } from '../utils/address.js'; import { - ConnectionHandlerI, ChainAddressShape, + ConnectionHandlerI, Proto3Shape, } from '../typeGuards.js'; +import { findAddressField } from '../utils/address.js'; import { makeTxPacket, parseTxPacket } from '../utils/packet.js'; /** @@ -40,7 +40,6 @@ export const ChainAccountI = M.interface('ChainAccount', { .optional(M.record()) .returns(M.promise()), close: M.callWhen().returns(M.undefined()), - deposit: M.callWhen(PaymentShape).returns(M.undefined()), getPurse: M.callWhen().returns(PurseShape), }); @@ -136,12 +135,6 @@ export const prepareChainAccountKit = zone => if (!connection) throw Fail`connection not available`; await E(connection).close(); }, - async deposit(payment) { - console.log('deposit got', payment); - console.error( - 'FIXME deposit noop until https://github.com/Agoric/agoric-sdk/issues/9193', - ); - }, /** * get Purse for a brand to .withdraw() a Payment from the account * diff --git a/packages/orchestration/src/exos/cosmosOrchestrationAccount.js b/packages/orchestration/src/exos/cosmosOrchestrationAccount.js index cd5bc18e941..f1c10cb24ac 100644 --- a/packages/orchestration/src/exos/cosmosOrchestrationAccount.js +++ b/packages/orchestration/src/exos/cosmosOrchestrationAccount.js @@ -302,8 +302,10 @@ export const prepareCosmosOrchestrationAccountKit = ( expect(result, trivialDelegateResponse, 'MsgDelegateResponse'); }, async deposit(payment) { - const { helper } = this.facets; - return E(helper.owned()).deposit(payment); + trace('deposit', payment); + console.error( + 'FIXME deposit noop until https://github.com/Agoric/agoric-sdk/issues/9193', + ); }, async getBalances() { throw Error('not yet implemented');