@sentio/sdk 1.16.3 → 1.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (149) hide show
  1. package/lib/aptos-processor.d.ts +21 -0
  2. package/lib/aptos-processor.js +65 -0
  3. package/lib/aptos-processor.js.map +1 -0
  4. package/lib/bind-options.d.ts +2 -0
  5. package/lib/bind-options.js +4 -1
  6. package/lib/bind-options.js.map +1 -1
  7. package/lib/builtin/eacaggregatorproxy/index.d.ts +2 -0
  8. package/lib/builtin/eacaggregatorproxy/index.js +22 -0
  9. package/lib/builtin/eacaggregatorproxy/index.js.map +1 -0
  10. package/lib/builtin/eacaggregatorproxy/test-utils.d.ts +6 -0
  11. package/lib/builtin/eacaggregatorproxy/test-utils.js +57 -0
  12. package/lib/builtin/eacaggregatorproxy/test-utils.js.map +1 -0
  13. package/lib/builtin/internal/EACAggregatorProxy.d.ts +460 -0
  14. package/lib/builtin/internal/EACAggregatorProxy.js +3 -0
  15. package/lib/builtin/internal/EACAggregatorProxy.js.map +1 -0
  16. package/lib/builtin/internal/eacaggregatorproxy_processor.d.ts +317 -0
  17. package/lib/builtin/internal/eacaggregatorproxy_processor.js +813 -0
  18. package/lib/builtin/internal/eacaggregatorproxy_processor.js.map +1 -0
  19. package/lib/builtin/internal/factories/EACAggregatorProxy__factory.d.ts +46 -0
  20. package/lib/builtin/internal/factories/EACAggregatorProxy__factory.js +527 -0
  21. package/lib/builtin/internal/factories/EACAggregatorProxy__factory.js.map +1 -0
  22. package/lib/builtin/internal/factories/index.d.ts +1 -0
  23. package/lib/builtin/internal/factories/index.js +3 -1
  24. package/lib/builtin/internal/factories/index.js.map +1 -1
  25. package/lib/builtin/internal/index.d.ts +2 -0
  26. package/lib/builtin/internal/index.js +3 -1
  27. package/lib/builtin/internal/index.js.map +1 -1
  28. package/lib/context.d.ts +5 -0
  29. package/lib/context.js +15 -3
  30. package/lib/context.js.map +1 -1
  31. package/lib/gen/processor/protos/processor.d.ts +2 -0
  32. package/lib/gen/processor/protos/processor.js +19 -0
  33. package/lib/gen/processor/protos/processor.js.map +1 -1
  34. package/lib/index.d.ts +2 -1
  35. package/lib/index.js +4 -1
  36. package/lib/index.js.map +1 -1
  37. package/lib/meter.js +17 -0
  38. package/lib/meter.js.map +1 -1
  39. package/lib/numberish.js +7 -0
  40. package/lib/numberish.js.map +1 -1
  41. package/lib/processor-state.d.ts +2 -0
  42. package/lib/processor-state.js +1 -0
  43. package/lib/processor-state.js.map +1 -1
  44. package/lib/service.js +47 -0
  45. package/lib/service.js.map +1 -1
  46. package/lib/solana/builtin/spl-token-processor.d.ts +16 -1
  47. package/lib/solana/builtin/spl-token-processor.js +120 -0
  48. package/lib/solana/builtin/spl-token-processor.js.map +1 -1
  49. package/lib/solana/builtin/types.d.ts +97 -0
  50. package/lib/solana/builtin/types.js.map +1 -1
  51. package/lib/test/{mirrorworld.d.ts → aptos.test.d.ts} +0 -0
  52. package/lib/test/aptos.test.js +142 -0
  53. package/lib/test/aptos.test.js.map +1 -0
  54. package/lib/test/erc20-template.test.js +21 -2
  55. package/lib/test/erc20-template.test.js.map +1 -1
  56. package/lib/test/erc20.js +4 -5
  57. package/lib/test/erc20.js.map +1 -1
  58. package/lib/test/erc20.test.js +0 -13
  59. package/lib/test/erc20.test.js.map +1 -1
  60. package/lib/test/{tic-tac-toe.d.ts → error-capture.test.d.ts} +0 -0
  61. package/lib/test/error-capture.test.js +76 -0
  62. package/lib/test/error-capture.test.js.map +1 -0
  63. package/lib/test/solana.test.js +1 -17
  64. package/lib/test/solana.test.js.map +1 -1
  65. package/lib/test/souffl3.d.ts +1 -0
  66. package/lib/test/souffl3.js +24 -0
  67. package/lib/test/souffl3.js.map +1 -0
  68. package/lib/test/sui.test.js +28 -1
  69. package/lib/test/sui.test.js.map +1 -1
  70. package/lib/test/test-provider.d.ts +1 -1
  71. package/lib/test/test-provider.js +11 -5
  72. package/lib/test/test-provider.js.map +1 -1
  73. package/lib/test/types/{game_wallet.d.ts → basic_1.d.ts} +2 -21
  74. package/lib/test/types/basic_1.js +66 -0
  75. package/lib/test/types/basic_1.js.map +1 -0
  76. package/lib/test/types/basic_1_processor.d.ts +13 -0
  77. package/lib/test/types/basic_1_processor.js +41 -0
  78. package/lib/test/types/basic_1_processor.js.map +1 -0
  79. package/lib/utils/chainlink-oracles-goerli.csv +8 -0
  80. package/lib/utils/chainlink-oracles.csv +217 -0
  81. package/lib/utils/dex-price.d.ts +22 -0
  82. package/lib/utils/dex-price.js +114 -0
  83. package/lib/utils/dex-price.js.map +1 -0
  84. package/lib/utils/dex-price.test.d.ts +1 -0
  85. package/lib/utils/dex-price.test.js +22 -0
  86. package/lib/utils/dex-price.test.js.map +1 -0
  87. package/lib/utils/erc20.d.ts +1 -0
  88. package/lib/utils/erc20.js +7 -3
  89. package/lib/utils/erc20.js.map +1 -1
  90. package/lib/utils/index.d.ts +3 -1
  91. package/lib/utils/index.js +6 -1
  92. package/lib/utils/index.js.map +1 -1
  93. package/package.json +3 -3
  94. package/src/abis/EACAggregatorProxy.json +227 -0
  95. package/src/aptos-processor.ts +75 -0
  96. package/src/bind-options.ts +1 -0
  97. package/src/builtin/eacaggregatorproxy/index.ts +6 -0
  98. package/src/builtin/eacaggregatorproxy/test-utils.ts +89 -0
  99. package/src/builtin/internal/EACAggregatorProxy.ts +861 -0
  100. package/src/builtin/internal/eacaggregatorproxy_processor.ts +1417 -0
  101. package/src/builtin/internal/factories/EACAggregatorProxy__factory.ts +533 -0
  102. package/src/builtin/internal/factories/index.ts +1 -0
  103. package/src/builtin/internal/index.ts +2 -0
  104. package/src/context.ts +15 -2
  105. package/src/gen/processor/protos/processor.ts +20 -0
  106. package/src/index.ts +2 -1
  107. package/src/meter.ts +18 -2
  108. package/src/numberish.ts +7 -0
  109. package/src/processor-state.ts +3 -0
  110. package/src/service.ts +51 -0
  111. package/src/solana/builtin/spl-token-processor.ts +137 -1
  112. package/src/solana/builtin/types.ts +11 -0
  113. package/src/test/abis/solana/basic_1.json +62 -0
  114. package/src/test/aptos.test.ts +148 -0
  115. package/src/test/erc20-template.test.ts +26 -3
  116. package/src/test/erc20.test.ts +1 -15
  117. package/src/test/erc20.ts +4 -5
  118. package/src/test/error-capture.test.ts +82 -0
  119. package/src/test/solana.test.ts +1 -18
  120. package/src/test/souffl3.ts +24 -0
  121. package/src/test/sui.test.ts +31 -2
  122. package/src/test/test-provider.ts +11 -5
  123. package/src/test/types/basic_1.ts +62 -0
  124. package/src/test/types/basic_1_processor.ts +41 -0
  125. package/src/utils/chainlink-oracles-goerli.csv +8 -0
  126. package/src/utils/chainlink-oracles.csv +217 -0
  127. package/src/utils/dex-price.test.ts +24 -0
  128. package/src/utils/dex-price.ts +136 -0
  129. package/src/utils/erc20.ts +5 -1
  130. package/src/utils/index.ts +3 -1
  131. package/lib/test/erc20-template.d.ts +0 -1
  132. package/lib/test/erc20-template.js +0 -23
  133. package/lib/test/erc20-template.js.map +0 -1
  134. package/lib/test/mirrorworld.js +0 -42
  135. package/lib/test/mirrorworld.js.map +0 -1
  136. package/lib/test/tic-tac-toe.js +0 -31
  137. package/lib/test/tic-tac-toe.js.map +0 -1
  138. package/lib/test/types/game_wallet.js +0 -1396
  139. package/lib/test/types/game_wallet.js.map +0 -1
  140. package/lib/test/types/game_wallet_processor.d.ts +0 -107
  141. package/lib/test/types/game_wallet_processor.js +0 -105
  142. package/lib/test/types/game_wallet_processor.js.map +0 -1
  143. package/src/test/abis/solana/mirrorworld.json +0 -1392
  144. package/src/test/erc20-template.ts +0 -25
  145. package/src/test/mirrorworld.ts +0 -40
  146. package/src/test/sentio.yaml +0 -4
  147. package/src/test/tic-tac-toe.ts +0 -31
  148. package/src/test/types/game_wallet.ts +0 -1392
  149. package/src/test/types/game_wallet_processor.ts +0 -113
@@ -0,0 +1,227 @@
1
+ [
2
+ {
3
+ "inputs": [
4
+ { "internalType": "address", "name": "_aggregator", "type": "address" },
5
+ { "internalType": "address", "name": "_accessController", "type": "address" }
6
+ ],
7
+ "stateMutability": "nonpayable",
8
+ "type": "constructor"
9
+ },
10
+ {
11
+ "anonymous": false,
12
+ "inputs": [
13
+ { "indexed": true, "internalType": "int256", "name": "current", "type": "int256" },
14
+ { "indexed": true, "internalType": "uint256", "name": "roundId", "type": "uint256" },
15
+ { "indexed": false, "internalType": "uint256", "name": "updatedAt", "type": "uint256" }
16
+ ],
17
+ "name": "AnswerUpdated",
18
+ "type": "event"
19
+ },
20
+ {
21
+ "anonymous": false,
22
+ "inputs": [
23
+ { "indexed": true, "internalType": "uint256", "name": "roundId", "type": "uint256" },
24
+ { "indexed": true, "internalType": "address", "name": "startedBy", "type": "address" },
25
+ { "indexed": false, "internalType": "uint256", "name": "startedAt", "type": "uint256" }
26
+ ],
27
+ "name": "NewRound",
28
+ "type": "event"
29
+ },
30
+ {
31
+ "anonymous": false,
32
+ "inputs": [
33
+ { "indexed": true, "internalType": "address", "name": "from", "type": "address" },
34
+ { "indexed": true, "internalType": "address", "name": "to", "type": "address" }
35
+ ],
36
+ "name": "OwnershipTransferRequested",
37
+ "type": "event"
38
+ },
39
+ {
40
+ "anonymous": false,
41
+ "inputs": [
42
+ { "indexed": true, "internalType": "address", "name": "from", "type": "address" },
43
+ { "indexed": true, "internalType": "address", "name": "to", "type": "address" }
44
+ ],
45
+ "name": "OwnershipTransferred",
46
+ "type": "event"
47
+ },
48
+ { "inputs": [], "name": "acceptOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" },
49
+ {
50
+ "inputs": [],
51
+ "name": "accessController",
52
+ "outputs": [{ "internalType": "contract AccessControllerInterface", "name": "", "type": "address" }],
53
+ "stateMutability": "view",
54
+ "type": "function"
55
+ },
56
+ {
57
+ "inputs": [],
58
+ "name": "aggregator",
59
+ "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
60
+ "stateMutability": "view",
61
+ "type": "function"
62
+ },
63
+ {
64
+ "inputs": [{ "internalType": "address", "name": "_aggregator", "type": "address" }],
65
+ "name": "confirmAggregator",
66
+ "outputs": [],
67
+ "stateMutability": "nonpayable",
68
+ "type": "function"
69
+ },
70
+ {
71
+ "inputs": [],
72
+ "name": "decimals",
73
+ "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }],
74
+ "stateMutability": "view",
75
+ "type": "function"
76
+ },
77
+ {
78
+ "inputs": [],
79
+ "name": "description",
80
+ "outputs": [{ "internalType": "string", "name": "", "type": "string" }],
81
+ "stateMutability": "view",
82
+ "type": "function"
83
+ },
84
+ {
85
+ "inputs": [{ "internalType": "uint256", "name": "_roundId", "type": "uint256" }],
86
+ "name": "getAnswer",
87
+ "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }],
88
+ "stateMutability": "view",
89
+ "type": "function"
90
+ },
91
+ {
92
+ "inputs": [{ "internalType": "uint80", "name": "_roundId", "type": "uint80" }],
93
+ "name": "getRoundData",
94
+ "outputs": [
95
+ { "internalType": "uint80", "name": "roundId", "type": "uint80" },
96
+ { "internalType": "int256", "name": "answer", "type": "int256" },
97
+ { "internalType": "uint256", "name": "startedAt", "type": "uint256" },
98
+ { "internalType": "uint256", "name": "updatedAt", "type": "uint256" },
99
+ { "internalType": "uint80", "name": "answeredInRound", "type": "uint80" }
100
+ ],
101
+ "stateMutability": "view",
102
+ "type": "function"
103
+ },
104
+ {
105
+ "inputs": [{ "internalType": "uint256", "name": "_roundId", "type": "uint256" }],
106
+ "name": "getTimestamp",
107
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
108
+ "stateMutability": "view",
109
+ "type": "function"
110
+ },
111
+ {
112
+ "inputs": [],
113
+ "name": "latestAnswer",
114
+ "outputs": [{ "internalType": "int256", "name": "", "type": "int256" }],
115
+ "stateMutability": "view",
116
+ "type": "function"
117
+ },
118
+ {
119
+ "inputs": [],
120
+ "name": "latestRound",
121
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
122
+ "stateMutability": "view",
123
+ "type": "function"
124
+ },
125
+ {
126
+ "inputs": [],
127
+ "name": "latestRoundData",
128
+ "outputs": [
129
+ { "internalType": "uint80", "name": "roundId", "type": "uint80" },
130
+ { "internalType": "int256", "name": "answer", "type": "int256" },
131
+ { "internalType": "uint256", "name": "startedAt", "type": "uint256" },
132
+ { "internalType": "uint256", "name": "updatedAt", "type": "uint256" },
133
+ { "internalType": "uint80", "name": "answeredInRound", "type": "uint80" }
134
+ ],
135
+ "stateMutability": "view",
136
+ "type": "function"
137
+ },
138
+ {
139
+ "inputs": [],
140
+ "name": "latestTimestamp",
141
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
142
+ "stateMutability": "view",
143
+ "type": "function"
144
+ },
145
+ {
146
+ "inputs": [],
147
+ "name": "owner",
148
+ "outputs": [{ "internalType": "address payable", "name": "", "type": "address" }],
149
+ "stateMutability": "view",
150
+ "type": "function"
151
+ },
152
+ {
153
+ "inputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }],
154
+ "name": "phaseAggregators",
155
+ "outputs": [{ "internalType": "contract AggregatorV2V3Interface", "name": "", "type": "address" }],
156
+ "stateMutability": "view",
157
+ "type": "function"
158
+ },
159
+ {
160
+ "inputs": [],
161
+ "name": "phaseId",
162
+ "outputs": [{ "internalType": "uint16", "name": "", "type": "uint16" }],
163
+ "stateMutability": "view",
164
+ "type": "function"
165
+ },
166
+ {
167
+ "inputs": [{ "internalType": "address", "name": "_aggregator", "type": "address" }],
168
+ "name": "proposeAggregator",
169
+ "outputs": [],
170
+ "stateMutability": "nonpayable",
171
+ "type": "function"
172
+ },
173
+ {
174
+ "inputs": [],
175
+ "name": "proposedAggregator",
176
+ "outputs": [{ "internalType": "contract AggregatorV2V3Interface", "name": "", "type": "address" }],
177
+ "stateMutability": "view",
178
+ "type": "function"
179
+ },
180
+ {
181
+ "inputs": [{ "internalType": "uint80", "name": "_roundId", "type": "uint80" }],
182
+ "name": "proposedGetRoundData",
183
+ "outputs": [
184
+ { "internalType": "uint80", "name": "roundId", "type": "uint80" },
185
+ { "internalType": "int256", "name": "answer", "type": "int256" },
186
+ { "internalType": "uint256", "name": "startedAt", "type": "uint256" },
187
+ { "internalType": "uint256", "name": "updatedAt", "type": "uint256" },
188
+ { "internalType": "uint80", "name": "answeredInRound", "type": "uint80" }
189
+ ],
190
+ "stateMutability": "view",
191
+ "type": "function"
192
+ },
193
+ {
194
+ "inputs": [],
195
+ "name": "proposedLatestRoundData",
196
+ "outputs": [
197
+ { "internalType": "uint80", "name": "roundId", "type": "uint80" },
198
+ { "internalType": "int256", "name": "answer", "type": "int256" },
199
+ { "internalType": "uint256", "name": "startedAt", "type": "uint256" },
200
+ { "internalType": "uint256", "name": "updatedAt", "type": "uint256" },
201
+ { "internalType": "uint80", "name": "answeredInRound", "type": "uint80" }
202
+ ],
203
+ "stateMutability": "view",
204
+ "type": "function"
205
+ },
206
+ {
207
+ "inputs": [{ "internalType": "address", "name": "_accessController", "type": "address" }],
208
+ "name": "setController",
209
+ "outputs": [],
210
+ "stateMutability": "nonpayable",
211
+ "type": "function"
212
+ },
213
+ {
214
+ "inputs": [{ "internalType": "address", "name": "_to", "type": "address" }],
215
+ "name": "transferOwnership",
216
+ "outputs": [],
217
+ "stateMutability": "nonpayable",
218
+ "type": "function"
219
+ },
220
+ {
221
+ "inputs": [],
222
+ "name": "version",
223
+ "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }],
224
+ "stateMutability": "view",
225
+ "type": "function"
226
+ }
227
+ ]
@@ -0,0 +1,75 @@
1
+ import { AptosBindOptions } from './bind-options'
2
+ import { AptosContext } from './context'
3
+ import { ProcessResult } from './index'
4
+ import Long from 'long'
5
+
6
+ type IndexConfigure = {
7
+ startSeqNumber: Long
8
+ endSeqNumber?: Long
9
+ }
10
+
11
+ export class AptosBaseProcessor {
12
+ public transactionHanlder: (transaction: any, ctx: AptosContext) => void
13
+ address: string
14
+ config: IndexConfigure = { startSeqNumber: new Long(0) }
15
+
16
+ constructor(options: AptosBindOptions) {
17
+ if (options) {
18
+ this.bind(options)
19
+ }
20
+ global.PROCESSOR_STATE.aptosProcessors.push(this)
21
+ }
22
+
23
+ bind(options: AptosBindOptions) {
24
+ this.address = options.address
25
+ if (options.startBlock) {
26
+ this.startSlot(options.startBlock)
27
+ }
28
+ if (options.endBlock) {
29
+ this.endBlock(options.endBlock)
30
+ }
31
+ }
32
+
33
+ public onTransaction(handler: (transaction: any, ctx: AptosContext) => void) {
34
+ if (!this.isBind()) {
35
+ throw new Error("Processor doesn't bind to an address")
36
+ }
37
+
38
+ this.transactionHanlder = handler
39
+
40
+ return this
41
+ }
42
+
43
+ public handleTransaction(txn: any): ProcessResult | null {
44
+ const ctx = new AptosContext(this.address)
45
+
46
+ if (txn) {
47
+ this.transactionHanlder(txn, ctx)
48
+ }
49
+ return {
50
+ gauges: ctx.gauges,
51
+ counters: ctx.counters,
52
+ logs: [],
53
+ }
54
+ }
55
+
56
+ public isBind() {
57
+ return this.address !== null
58
+ }
59
+
60
+ public startSlot(startSlot: Long | number) {
61
+ if (typeof startSlot === 'number') {
62
+ startSlot = Long.fromNumber(startSlot)
63
+ }
64
+ this.config.startSeqNumber = startSlot
65
+ return this
66
+ }
67
+
68
+ public endBlock(endBlock: Long | number) {
69
+ if (typeof endBlock === 'number') {
70
+ endBlock = Long.fromNumber(endBlock)
71
+ }
72
+ this.config.endSeqNumber = endBlock
73
+ return this
74
+ }
75
+ }
@@ -41,3 +41,4 @@ export class SolanaBindOptions extends BindOptions {
41
41
  }
42
42
 
43
43
  export class SuiBindOptions extends BindOptions {}
44
+ export class AptosBindOptions extends BindOptions {}
@@ -0,0 +1,6 @@
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+
5
+ export * from "../internal/eacaggregatorproxy_processor";
6
+ export * from "../internal/EACAggregatorProxy";
@@ -0,0 +1,89 @@
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ import { Log } from "@ethersproject/providers";
5
+ import {
6
+ getEACAggregatorProxyContract,
7
+ AnswerUpdatedEventObject,
8
+ NewRoundEventObject,
9
+ OwnershipTransferRequestedEventObject,
10
+ OwnershipTransferredEventObject,
11
+ } from ".";
12
+ const mockField = {
13
+ blockHash:
14
+ "0x0000000000000000000000000000000000000000000000000000000000000000",
15
+ blockNumber: 0,
16
+ logIndex: 0,
17
+ removed: false,
18
+ transactionHash:
19
+ "0x0000000000000000000000000000000000000000000000000000000000000000",
20
+ transactionIndex: 0,
21
+ };
22
+
23
+ export function mockAnswerUpdatedLog(
24
+ contractAddress: string,
25
+ event: AnswerUpdatedEventObject
26
+ ): Log {
27
+ const contract = getEACAggregatorProxyContract(contractAddress);
28
+ const encodedLog = contract.rawContract.interface.encodeEventLog(
29
+ contract.rawContract.interface.getEvent("AnswerUpdated"),
30
+ Object.values(event)
31
+ );
32
+ return {
33
+ ...mockField,
34
+ address: contractAddress,
35
+ data: encodedLog.data,
36
+ topics: encodedLog.topics,
37
+ };
38
+ }
39
+
40
+ export function mockNewRoundLog(
41
+ contractAddress: string,
42
+ event: NewRoundEventObject
43
+ ): Log {
44
+ const contract = getEACAggregatorProxyContract(contractAddress);
45
+ const encodedLog = contract.rawContract.interface.encodeEventLog(
46
+ contract.rawContract.interface.getEvent("NewRound"),
47
+ Object.values(event)
48
+ );
49
+ return {
50
+ ...mockField,
51
+ address: contractAddress,
52
+ data: encodedLog.data,
53
+ topics: encodedLog.topics,
54
+ };
55
+ }
56
+
57
+ export function mockOwnershipTransferRequestedLog(
58
+ contractAddress: string,
59
+ event: OwnershipTransferRequestedEventObject
60
+ ): Log {
61
+ const contract = getEACAggregatorProxyContract(contractAddress);
62
+ const encodedLog = contract.rawContract.interface.encodeEventLog(
63
+ contract.rawContract.interface.getEvent("OwnershipTransferRequested"),
64
+ Object.values(event)
65
+ );
66
+ return {
67
+ ...mockField,
68
+ address: contractAddress,
69
+ data: encodedLog.data,
70
+ topics: encodedLog.topics,
71
+ };
72
+ }
73
+
74
+ export function mockOwnershipTransferredLog(
75
+ contractAddress: string,
76
+ event: OwnershipTransferredEventObject
77
+ ): Log {
78
+ const contract = getEACAggregatorProxyContract(contractAddress);
79
+ const encodedLog = contract.rawContract.interface.encodeEventLog(
80
+ contract.rawContract.interface.getEvent("OwnershipTransferred"),
81
+ Object.values(event)
82
+ );
83
+ return {
84
+ ...mockField,
85
+ address: contractAddress,
86
+ data: encodedLog.data,
87
+ topics: encodedLog.topics,
88
+ };
89
+ }