Skip to content

Commit

Permalink
fix: decrease the need for sendPacket delay (almost fixed)
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelfig committed May 2, 2020
1 parent 6653937 commit 9f65899
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions packages/cosmic-swingset/lib/ag-solo/vats/ibc.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,15 @@ const DEFAULT_PACKET_TIMEOUT = 1000;
// only way to create channels.
const FIXME_ALLOW_NAIVE_RELAYS = true;

// FIXME: We need to delay to a later block to work around
// a relayer race condition (no sendPacket too soon after
// a channelOpenAck).
// We need to delay to a later block because packets
// cannot be sent before the channel ack is complete
// (no sendPacket within a channelOpenAck).
//
// I[2020-05-01|15:32:43.721] - listening to tx events from ibc0...
// I[2020-05-01|15:32:43.721] - listening to block events from ibc0...
// Error: no transactions returned with query
// no transactions returned with query
// [exits]
const FIXME_SENDPACKET_DELAY_S = 10; // fail <=3, work >=4
// FIXME: We might be fix within the relayer, which currently
// fails with:
// cannot update client with ID ibczeroclient: header blocktime
// ≤ latest client state block time (X ≤ X): invalid block header
const FIXME_SENDPACKET_DELAY_S = 1;

/**
* @typedef {import('@agoric/swingset-vat/src/vats/network').ProtocolHandler} ProtocolHandler
Expand Down

0 comments on commit 9f65899

Please sign in to comment.