AvaProtocol / xcm-demo

Javascript usage of OAK’s XCM automation with parachains including Moonbeam, Astar and Mangata.
https://docs.oak.tech/docs/xcm/integration-overview/
4 stars 5 forks source link

Update @oak-network/adapter version #117

Closed imstar15 closed 2 months ago

imstar15 commented 2 months ago
  1. Update @oak-network/adapter version 0.2.9
  2. Listen messageQueue.Processed for moonriver runtime-3000

Log:

1. Transfer TUR to the derivative account on turing: 

b) The balance of derivative account is 63251543069 blanck, no need to top it up with reserve transfer ...

2. One-time proxy setup on moonriver

a) Add a proxy for Rocstar If there is none setup on moonriver

oakChainData.paraId:  2114
Proxy address 0xb75c336f52636c15bf0254dacd66520b3ad53f09 for paraId: 2023 and proxyType: Any already exists; skipping creation ...

b) Topping up the proxy account on moonriver with DEV ...

moonbaseProxyBalance: 1,627,775,205,227,900,000

Moonbase proxy account balance is 1627775205227900000 blanck, no need to top it up with reserve transfer ...

User Rocstar turing address: 67RKQFDRWRFnY7RrkvR7N1kNpZiXa9P2qdLtwxYZFDjs4dAr, moonriver address: 0x5446cFF2194E84f79513ACf6C8980D6e60747253

3. Execute an XCM from moonriver to turing ...

a). Create a payload to store in Turing’s task ...

b). Send extrinsic from moonriver to turing to schedule task. Listen to TaskScheduled event on turing chain ...
Listen XCMP task events
Send extrinsic from moonriver to schedule task. extrinsic: 0x6b060301010009210103010100092101f3cb5483000000000000000000000000f9023c01000828269666000000008028966600000000030101009d1f030101000921030102009d1f040a00141354778000000000000000000000c9016d015446cff2194e84f79513acf6c8980d6e6074725301581501000000000000000000000000000000000000000000000000000000000000a72f549a1a12b9b49f30a7f3aeb1f4e96389c5d8000000000000000000000000000000000000000000000000000000000000000010d09de08a0003404ac76cad8a03401462a8aefb02000100030a11484d16e701000101070a39b33b0116e7010000
status.type Ready
status.type Broadcast
status.type InBlock
        automationTime:TaskScheduled:: (phase={"applyExtrinsic":0})
                        AccountId32: 69u5cUthTu41aCnNo37fnWJ7wtWTm4cuFoz7jSQ4CcHWAZWt
                        Bytes: 0x353437303638382d302d31
                        Option<AccountId32>: 
Found the event and retrieved TaskId, 5470688-0-1

Keep Listening automationTime.TaskExecuted until 2024-07-16 15:50:00(1721116200) to verify that the task(taskId: 5470688-0-1) will be successfully triggered ...
status.type Finalized
        automationTime:TaskExecuted:: (phase=Initialization)
                        AccountId32: 69u5cUthTu41aCnNo37fnWJ7wtWTm4cuFoz7jSQ4CcHWAZWt
                        Bytes: 0x353437303638382d302d31
XcmpMessageSent event:  {
  phase: 'Initialization',
  event: {
    method: 'XcmpMessageSent',
    section: 'xcmpQueue',
    index: '0x2804',
    data: {
      messageHash: '0x939332f92fa7c026f39d9f5f2b0529886988c62422dea2ca448130eb3291f4e0'
    }
  },
  topics: []
}
messageHash:  0x939332f92fa7c026f39d9f5f2b0529886988c62422dea2ca448130eb3291f4e0

4. Listen messageQueue.Processed event with messageHash(0x939332f92fa7c026f39d9f5f2b0529886988c62422dea2ca448130eb3291f4e0) and find ethereum.Executed event on Parachain...
        messageQueue:Processed:: (phase=Initialization)
                        H256: 0x939332f92fa7c026f39d9f5f2b0529886988c62422dea2ca448130eb3291f4e0
                        {"_enum":{"Here":"Null","Parent":"Null","Sibling":"u32"}}: {"sibling":2114}
                        {"refTime":"Compact<u64>","proofSize":"Compact<u64>"}: {"refTime":813047000,"proofSize":28376}
                        bool: true
ethereum.Executed event:  {"from":"0x5446cff2194e84f79513acf6c8980d6e60747253","to":"0xa72f549a1a12b9b49f30a7f3aeb1f4e96389c5d8","transactionHash":"0x3c20c0f5a34861dbc3693c85f319b650ed61496f82a989793986fec09d6cb238","exitReason":{"Succeed":"Stopped"},"extraData":""}
socket-security[bot] commented 2 months ago

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/@oak-network/adapter@0.2.9 Transitive: network +15 28.9 MB chrisli30

🚮 Removed packages: npm/@oak-network/adapter@0.2.6

View full report↗︎