@@ -39,11 +39,13 @@ func (v *validator) SubmitAttestation(ctx context.Context, slot types.Slot, pubK
39
39
var b strings.Builder
40
40
if err := b .WriteByte (byte (roleAttester )); err != nil {
41
41
log .WithError (err ).Error ("Could not write role byte for lock key" )
42
+ traceutil .AnnotateError (span , err )
42
43
return
43
44
}
44
45
_ , err := b .Write (pubKey [:])
45
46
if err != nil {
46
47
log .WithError (err ).Error ("Could not write pubkey bytes for lock key" )
48
+ traceutil .AnnotateError (span , err )
47
49
return
48
50
}
49
51
lock := mputil .NewMultilock (b .String ())
@@ -58,6 +60,7 @@ func (v *validator) SubmitAttestation(ctx context.Context, slot types.Slot, pubK
58
60
if v .emitAccountMetrics {
59
61
ValidatorAttestFailVec .WithLabelValues (fmtKey ).Inc ()
60
62
}
63
+ traceutil .AnnotateError (span , err )
61
64
return
62
65
}
63
66
if len (duty .Committee ) == 0 {
@@ -75,6 +78,7 @@ func (v *validator) SubmitAttestation(ctx context.Context, slot types.Slot, pubK
75
78
if v .emitAccountMetrics {
76
79
ValidatorAttestFailVec .WithLabelValues (fmtKey ).Inc ()
77
80
}
81
+ traceutil .AnnotateError (span , err )
78
82
return
79
83
}
80
84
@@ -89,6 +93,7 @@ func (v *validator) SubmitAttestation(ctx context.Context, slot types.Slot, pubK
89
93
if v .emitAccountMetrics {
90
94
ValidatorAttestFailVec .WithLabelValues (fmtKey ).Inc ()
91
95
}
96
+ traceutil .AnnotateError (span , err )
92
97
return
93
98
}
94
99
@@ -98,6 +103,7 @@ func (v *validator) SubmitAttestation(ctx context.Context, slot types.Slot, pubK
98
103
if v .emitAccountMetrics {
99
104
ValidatorAttestFailVec .WithLabelValues (fmtKey ).Inc ()
100
105
}
106
+ traceutil .AnnotateError (span , err )
101
107
return
102
108
}
103
109
@@ -133,6 +139,7 @@ func (v *validator) SubmitAttestation(ctx context.Context, slot types.Slot, pubK
133
139
log .WithFields (
134
140
attestationLogFields (pubKey , indexedAtt ),
135
141
).Debug ("Attempted slashable attestation details" )
142
+ traceutil .AnnotateError (span , err )
136
143
return
137
144
}
138
145
attResp , err := v .validatorClient .ProposeAttestation (ctx , attestation )
@@ -141,6 +148,7 @@ func (v *validator) SubmitAttestation(ctx context.Context, slot types.Slot, pubK
141
148
if v .emitAccountMetrics {
142
149
ValidatorAttestFailVec .WithLabelValues (fmtKey ).Inc ()
143
150
}
151
+ traceutil .AnnotateError (span , err )
144
152
return
145
153
}
146
154
@@ -149,6 +157,7 @@ func (v *validator) SubmitAttestation(ctx context.Context, slot types.Slot, pubK
149
157
if v .emitAccountMetrics {
150
158
ValidatorAttestFailVec .WithLabelValues (fmtKey ).Inc ()
151
159
}
160
+ traceutil .AnnotateError (span , err )
152
161
return
153
162
}
154
163
0 commit comments