-
Notifications
You must be signed in to change notification settings - Fork 206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(orchestration): chain NameHub #9323
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,305 @@ | ||
/** | ||
* Generated using gRPC queries to local simulated chains | ||
* See {@link https://github.com/Agoric/agoric-sdk/blob/43e0249502171e82460be7cf4bad8baf5db5aafd/packages/cosmic-proto/test/snapshots/test-chain-info.js.md | snapshots} and | ||
* their {@link https://github.com/Agoric/agoric-sdk/blob/43e0249502171e82460be7cf4bad8baf5db5aafd/packages/cosmic-proto/test/test-chain-info.js | source test}. | ||
|
||
* // TODO check in some portion of above code | ||
*/ | ||
export const mockChainInfo = { | ||
agoric: { | ||
icaParams: { | ||
allowMessages: [ | ||
'/agoric.*', | ||
'/ibc.*', | ||
'/cosmos.[a-rt-z]*', | ||
'/cosmos.s[a-su-z]*', | ||
], | ||
hostEnabled: true, | ||
}, | ||
icqParams: { | ||
hostEnabled: false, | ||
}, | ||
chainId: 'agoriclocal', | ||
bondDenom: 'ubld', | ||
denoms: [ | ||
{ | ||
denom: 'ubld', | ||
native: true, | ||
}, | ||
{ | ||
denom: 'uist', | ||
native: true, | ||
}, | ||
{ | ||
baseDenom: 'uion', | ||
denom: | ||
'ibc/F7E92EE59B5428793F3EF5C1A4CB2494F61A9D0C9A69469D02390714A1372E16', | ||
path: 'transfer/channel-0', | ||
}, | ||
{ | ||
baseDenom: 'uosmo', | ||
denom: | ||
'ibc/ED07A3391A112B175915CD8FAF43A2DA8E4790EDE12566649D0C2F97716B8518', | ||
path: 'transfer/channel-0', | ||
}, | ||
{ | ||
baseDenom: 'uatom', | ||
denom: | ||
'ibc/C4CFF46FD6DE35CA4CF4CE031E643C8FDC9BA4B99AE598E9B0ED98FE3A2319F9', | ||
path: 'transfer/channel-1', | ||
}, | ||
], | ||
connections: [ | ||
{ | ||
chainId: 'osmosis-test', | ||
connectionInfo: { | ||
clientId: '07-tendermint-2', | ||
counterparty: { | ||
clientId: '07-tendermint-2', | ||
connectionId: 'connection-1', | ||
}, | ||
id: 'connection-0', | ||
state: 'STATE_OPEN', | ||
}, | ||
lastUpdated: { | ||
revisionHeight: 831n, | ||
Comment on lines
+64
to
+65
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. how often do you expect this to get updated? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Pretty frequently, I believe with every block (of the chain with the shorter avg block time). I recognize this likely makes it a poor candidate to put into state, given our anticipated update frequency/governance, but some messages seem like they rely on it for preventing an unbound timeout:
More on /**
* Height is a monotonically increasing data type
* that can be compared against another Height for the purposes of updating and
* freezing clients
*
* Normally the RevisionHeight is incremented at each height while keeping
* RevisionNumber the same. However some consensus algorithms may choose to
* reset the height in certain conditions e.g. hard forks, state-machine
* breaking changes In these cases, the RevisionNumber is incremented so that
* height continues to be monitonically increasing even as the RevisionHeight
* gets reset
*/
export interface Height {
/** the revision that the client is currently on */
revisionNumber: bigint;
/** the height within the given revision */
revisionHeight: bigint;
} For For A clever approach might be to approximate timeout height based on a target block duration (of the chain with the shorter avg block times), using using a historical revisionHeight and the timestamp is was saved at. This is likely too clever, and doesn't account for things like chain halting upgrades or target block time drift. P.S. created #9324 to capture this work, as |
||
revisionNumber: 0n, | ||
}, | ||
transferChannels: [ | ||
{ | ||
counterpartyChannelId: 'channel-1', | ||
counterpartyPortId: 'transfer', | ||
ordering: 'ORDER_UNORDERED', | ||
sourceChannelId: 'channel-0', | ||
sourcePortId: 'transfer', | ||
state: 'STATE_OPEN', | ||
version: 'ics20-1', | ||
}, | ||
], | ||
}, | ||
{ | ||
chainId: 'gaia-test', | ||
connectionInfo: { | ||
clientId: '07-tendermint-3', | ||
counterparty: { | ||
clientId: '07-tendermint-2', | ||
connectionId: 'connection-1', | ||
}, | ||
id: 'connection-1', | ||
state: 'STATE_OPEN', | ||
}, | ||
lastUpdated: { | ||
revisionHeight: 854n, | ||
revisionNumber: 0n, | ||
}, | ||
transferChannels: [ | ||
{ | ||
counterpartyChannelId: 'channel-1', | ||
counterpartyPortId: 'transfer', | ||
ordering: 'ORDER_UNORDERED', | ||
sourceChannelId: 'channel-1', | ||
sourcePortId: 'transfer', | ||
state: 'STATE_OPEN', | ||
version: 'ics20-1', | ||
}, | ||
], | ||
}, | ||
], | ||
}, | ||
cosmos: { | ||
icaParams: { | ||
allowMessages: [], | ||
hostEnabled: true, | ||
}, | ||
icqParams: { | ||
hostEnabled: false, | ||
}, | ||
chainId: 'gaia-test', | ||
bondDenom: 'uatom', | ||
denoms: [ | ||
{ | ||
denom: 'uatom', | ||
native: true, | ||
}, | ||
{ | ||
baseDenom: 'uion', | ||
denom: | ||
'ibc/F7E92EE59B5428793F3EF5C1A4CB2494F61A9D0C9A69469D02390714A1372E16', | ||
path: 'transfer/channel-0', | ||
}, | ||
{ | ||
baseDenom: 'uosmo', | ||
denom: | ||
'ibc/ED07A3391A112B175915CD8FAF43A2DA8E4790EDE12566649D0C2F97716B8518', | ||
path: 'transfer/channel-0', | ||
}, | ||
{ | ||
baseDenom: 'ubld', | ||
denom: | ||
'ibc/E7827844CB818EE9C4DB2C159F1543FF62B26213B44CE8029D5CEFE52F0EE596', | ||
path: 'transfer/channel-1', | ||
}, | ||
{ | ||
baseDenom: 'uist', | ||
denom: | ||
'ibc/16CD81E12F05F5397CA2D580B4BA786A12A8F48B6FB3823D82EBE95D80B5287B', | ||
path: 'transfer/channel-1', | ||
}, | ||
], | ||
connections: [ | ||
{ | ||
chainId: 'osmosis-test', | ||
connectionInfo: { | ||
clientId: '07-tendermint-0', | ||
counterparty: { | ||
clientId: '07-tendermint-0', | ||
connectionId: 'connection-0', | ||
}, | ||
id: 'connection-0', | ||
state: 'STATE_OPEN', | ||
}, | ||
lastUpdated: { | ||
revisionHeight: 12056n, | ||
revisionNumber: 0n, | ||
}, | ||
transferChannels: [ | ||
{ | ||
counterpartyChannelId: 'channel-0', | ||
counterpartyPortId: 'transfer', | ||
ordering: 'ORDER_UNORDERED', | ||
sourceChannelId: 'channel-0', | ||
sourcePortId: 'transfer', | ||
state: 'STATE_OPEN', | ||
version: 'ics20-1', | ||
}, | ||
], | ||
}, | ||
{ | ||
chainId: 'agoriclocal', | ||
connectionInfo: { | ||
clientId: '07-tendermint-2', | ||
counterparty: { | ||
clientId: '07-tendermint-3', | ||
connectionId: 'connection-1', | ||
}, | ||
id: 'connection-1', | ||
state: 'STATE_OPEN', | ||
}, | ||
lastUpdated: { | ||
revisionHeight: 113n, | ||
revisionNumber: 0n, | ||
}, | ||
transferChannels: [ | ||
{ | ||
counterpartyChannelId: 'channel-1', | ||
counterpartyPortId: 'transfer', | ||
ordering: 'ORDER_UNORDERED', | ||
sourceChannelId: 'channel-1', | ||
sourcePortId: 'transfer', | ||
state: 'STATE_OPEN', | ||
version: 'ics20-1', | ||
}, | ||
], | ||
}, | ||
], | ||
}, | ||
osmosis: { | ||
icaParams: { | ||
allowMessages: ['*'], | ||
hostEnabled: true, | ||
}, | ||
icqParams: { | ||
allowQueries: [ | ||
'/cosmos.bank.v1beta1.Query/Balance', | ||
'/cosmos.staking.v1beta1.Query/Delegation', | ||
], | ||
hostEnabled: true, | ||
}, | ||
chainId: 'osmosis-test', | ||
bondDenom: 'uosmo', | ||
denoms: [ | ||
{ | ||
denom: 'uion', | ||
native: true, | ||
}, | ||
{ | ||
denom: 'uosmo', | ||
native: true, | ||
}, | ||
{ | ||
baseDenom: 'uatom', | ||
denom: | ||
'ibc/27394FB092D2ECCD56123C74F36E4C1F926001CEADA9CA97EA622B25F41E5EB2', | ||
path: 'transfer/channel-0', | ||
}, | ||
{ | ||
baseDenom: 'ubld', | ||
denom: | ||
'ibc/E7827844CB818EE9C4DB2C159F1543FF62B26213B44CE8029D5CEFE52F0EE596', | ||
path: 'transfer/channel-1', | ||
}, | ||
{ | ||
baseDenom: 'uist', | ||
denom: | ||
'ibc/16CD81E12F05F5397CA2D580B4BA786A12A8F48B6FB3823D82EBE95D80B5287B', | ||
path: 'transfer/channel-1', | ||
}, | ||
], | ||
connections: [ | ||
{ | ||
chainId: 'gaia-test', | ||
connectionInfo: { | ||
clientId: '07-tendermint-0', | ||
counterparty: { | ||
clientId: '07-tendermint-0', | ||
connectionId: 'connection-0', | ||
}, | ||
id: 'connection-0', | ||
state: 'STATE_OPEN', | ||
}, | ||
lastUpdated: { | ||
revisionHeight: 7836n, | ||
revisionNumber: 0n, | ||
}, | ||
transferChannels: [ | ||
{ | ||
counterpartyChannelId: 'channel-0', | ||
counterpartyPortId: 'transfer', | ||
ordering: 'ORDER_UNORDERED', | ||
sourceChannelId: 'channel-0', | ||
sourcePortId: 'transfer', | ||
state: 'STATE_OPEN', | ||
version: 'ics20-1', | ||
}, | ||
], | ||
}, | ||
{ | ||
chainId: 'agoriclocal', | ||
connectionInfo: { | ||
clientId: '07-tendermint-2', | ||
counterparty: { | ||
clientId: '07-tendermint-2', | ||
connectionId: 'connection-0', | ||
}, | ||
id: 'connection-1', | ||
state: 'STATE_OPEN', | ||
}, | ||
lastUpdated: { | ||
revisionHeight: 110n, | ||
revisionNumber: 0n, | ||
}, | ||
transferChannels: [ | ||
{ | ||
counterpartyChannelId: 'channel-0', | ||
counterpartyPortId: 'transfer', | ||
ordering: 'ORDER_UNORDERED', | ||
sourceChannelId: 'channel-1', | ||
sourcePortId: 'transfer', | ||
state: 'STATE_OPEN', | ||
version: 'ics20-1', | ||
}, | ||
], | ||
}, | ||
], | ||
}, | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
channel 0 goes to the cosmos hub, according to https://mapofzones.com/zones/agoric-3/peers?columnKey=ibcVolumeIn&period=24h
or is this about emerynet or something?