@@ -55,8 +55,8 @@ func getEthAddress(addr address.Address) string {
55
55
}
56
56
57
57
func (t * Task ) getActorAddress (ctx context.Context , address address.Address , tsk types.TipSetKey ) address.Address {
58
- actor , _ := t .node .Actor (ctx , address , tsk )
59
- if actor .Address != nil {
58
+ actor , err := t .node .Actor (ctx , address , tsk )
59
+ if err == nil && actor != nil && actor .Address != nil {
60
60
return * actor .Address
61
61
}
62
62
return address
@@ -119,12 +119,25 @@ func (t *Task) ProcessTipSets(ctx context.Context, current *types.TipSet, execut
119
119
if ! util .IsEVMMessage (ctx , t .node , parentMsg .Message , current .Key ()) {
120
120
continue
121
121
}
122
- transactionHash , err := ethtypes .EthHashFromCid (parentMsg .Cid )
122
+ messageHash , err := ethtypes .EthHashFromCid (parentMsg .Cid )
123
123
if err != nil {
124
124
log .Errorf ("Error at finding hash: [cid: %v] err: %v" , parentMsg .Cid , err )
125
125
errs = append (errs , err )
126
126
continue
127
127
}
128
+ txn , err := t .node .EthGetTransactionByHash (ctx , & messageHash )
129
+ if err != nil {
130
+ log .Errorf ("Error at getting transaction: [hash: %v] err: %v" , messageHash , err )
131
+ errs = append (errs , err )
132
+ continue
133
+ }
134
+
135
+ if txn == nil {
136
+ log .Errorf ("transaction: [hash: %v] is null" , messageHash )
137
+ continue
138
+ }
139
+ transactionHash := txn .Hash .String ()
140
+
128
141
for _ , child := range util .GetChildMessagesOf (parentMsg ) {
129
142
fromCode , _ := getActorCode (ctx , child .Message .From )
130
143
var fromActorCode string
@@ -152,7 +165,7 @@ func (t *Task) ProcessTipSets(ctx context.Context, current *types.TipSet, execut
152
165
153
166
traceObj := & fevm.FEVMTrace {
154
167
Height : int64 (parentMsg .Height ),
155
- TransactionHash : transactionHash . String () ,
168
+ TransactionHash : transactionHash ,
156
169
MessageStateRoot : parentMsg .StateRoot .String (),
157
170
MessageCid : parentMsg .Cid .String (),
158
171
TraceCid : getMessageTraceCid (child .Message ).String (),
0 commit comments