Skip to content
This repository has been archived by the owner on Dec 23, 2024. It is now read-only.

Commit

Permalink
feat(otel): register fhelib errors in their span
Browse files Browse the repository at this point in the history
  • Loading branch information
youben11 committed Feb 16, 2024
1 parent 26b8be0 commit f9ca732
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions fhevm/precompiles.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ func FheLibRun(environment EVMEnvironment, caller common.Address, addr common.Ad
if ctx := environment.OtelContext(); ctx != nil {
_, span := otel.Tracer("fhevm").Start(ctx, fheLibMethod.name)
ret, err = fheLibMethod.Run(environment, caller, addr, input, readOnly, span)
if err != nil {
span.RecordError(err)
}
span.End()
} else {
ret, err = fheLibMethod.Run(environment, caller, addr, input, readOnly, nil)
Expand Down

0 comments on commit f9ca732

Please sign in to comment.