Skip to content

Commit 972e838

Browse files
committed
Merge branch 'main' into rtinianov_verifyReports
2 parents e0fd2da + aac8c79 commit 972e838

2 files changed

Lines changed: 12 additions & 4 deletions

File tree

.github/workflows/validate-submodule.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ permissions: {}
44
on:
55
pull_request:
66
types: [opened, synchronize, reopened]
7-
branches: [capabilities-development]
87
push:
98
branches: [capabilities-development]
109

1110
jobs:
1211
validate-submodule:
12+
if: github.event_name == 'push' || github.base_ref == 'capabilities-development'
1313
permissions:
1414
contents: read
1515
runs-on: ubuntu-latest

packages/cre-sdk-examples/src/workflows/log-trigger/index.ts

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import {
55
type EVMLog,
66
getNetwork,
77
handler,
8+
logTriggerConfig,
89
protoBigIntToBigint,
910
Runner,
1011
type Runtime,
@@ -74,11 +75,18 @@ const initWorkflow = (config: Config) => {
7475
return 'success'
7576
}
7677

78+
// keccak256("MessageEmitted(address,uint256,string)")
79+
const MESSAGE_EMITTED_TOPIC =
80+
'0xc799f359194674b273986b8c03283265390f642b631c04e6526b99d0d8f4c38d' as `0x${string}`
81+
7782
return [
7883
handler(
79-
evmClient.logTrigger({
80-
addresses: [config.evms[0].messageEmitterAddress],
81-
}),
84+
evmClient.logTrigger(
85+
logTriggerConfig({
86+
addresses: [config.evms[0].messageEmitterAddress as `0x${string}`],
87+
topics: [[MESSAGE_EMITTED_TOPIC]],
88+
}),
89+
),
8290
onLogTrigger,
8391
),
8492
]

0 commit comments

Comments
 (0)