@@ -119,7 +119,8 @@ func (act SaveActor) saveBazelInvocation(
119
119
buildRecord * ent.Build ,
120
120
metrics * ent.Metrics ,
121
121
tests []* ent.TestCollection ,
122
- targets []* ent.TargetPair ) (* ent.BazelInvocation , error ) {
122
+ targets []* ent.TargetPair ,
123
+ ) (* ent.BazelInvocation , error ) {
123
124
create := act .db .BazelInvocation .Create ().
124
125
SetInvocationID (uuid .MustParse (summary .InvocationID )).
125
126
SetStartedAt (summary .StartedAt ).
@@ -192,7 +193,7 @@ func (act SaveActor) saveOutputGroup(ctx context.Context, ouputGroup summary.Out
192
193
SetName (ouputGroup .Name ).
193
194
SetIncomplete (ouputGroup .Incomplete ).
194
195
AddInlineFiles (inlineFiles ... ).
195
- //TODO: implement named set of files logic to recursively add files to this collection
196
+ // TODO: implement named set of files logic to recursively add files to this collection
196
197
Save (ctx )
197
198
}
198
199
@@ -225,8 +226,8 @@ func (act SaveActor) saveTargetCompletion(ctx context.Context, targetCompletion
225
226
}
226
227
227
228
func (act SaveActor ) saveTargetPair (ctx context.Context , targetPair summary.TargetPair , label string ) (* ent.TargetPair , error ) {
228
- var configuration = targetPair .Configuration
229
- var completion = targetPair .Completion
229
+ configuration : = targetPair .Configuration
230
+ completion : = targetPair .Completion
230
231
231
232
targetConfiguration , err := act .saveTargetConfiguration (ctx , configuration )
232
233
if err != nil {
@@ -259,7 +260,7 @@ func (act SaveActor) saveTargetPair(ctx context.Context, targetPair summary.Targ
259
260
// ironically, MapBulkCreate doesn't work for the map(string)TargetPair. Its expecting an int index, not a label.
260
261
func (act SaveActor ) saveTargets (ctx context.Context , summary * summary.Summary ) ([]* ent.TargetPair , error ) {
261
262
var result []* ent.TargetPair = make ([]* ent.TargetPair , len (summary .Targets ))
262
- var i = 0
263
+ i : = 0
263
264
for label , pair := range summary .Targets {
264
265
targetPair , err := act .saveTargetPair (ctx , pair , label )
265
266
if err != nil {
@@ -354,7 +355,7 @@ func (act SaveActor) saveTestResults(ctx context.Context, testResults []summary.
354
355
SetTestAttemptDuration (testResult .TestAttemptDuration ).
355
356
SetTestAttemptStart (testResult .TestAttemptStart ).
356
357
SetExecutionInfo (executionInfo )
357
- //TODO: implement test action output AddTestActionOutput()
358
+ // TODO: implement test action output AddTestActionOutput()
358
359
}).Save (ctx )
359
360
}
360
361
@@ -381,7 +382,7 @@ func (act SaveActor) saveTestCollection(ctx context.Context, testCollection summ
381
382
382
383
func (act SaveActor ) saveTests (ctx context.Context , summary * summary.Summary ) ([]* ent.TestCollection , error ) {
383
384
var result []* ent.TestCollection = make ([]* ent.TestCollection , len (summary .Tests ))
384
- var i = 0
385
+ i : = 0
385
386
for label , collection := range summary .Tests {
386
387
testCollection , err := act .saveTestCollection (ctx , collection , label )
387
388
if err != nil {
@@ -420,7 +421,7 @@ func (act SaveActor) saveRunnerCounts(ctx context.Context, runnerCounts []summar
420
421
return act .db .RunnerCount .MapCreateBulk (runnerCounts , func (create * ent.RunnerCountCreate , i int ) {
421
422
runnerCount := runnerCounts [i ]
422
423
create .
423
- //TODO is there a better type for unsigned int?
424
+ // TODO is there a better type for unsigned int?
424
425
SetActionsExecuted (int64 (runnerCount .Count )).
425
426
SetName (runnerCount .Name ).
426
427
SetExecKind (runnerCount .ExecKind )
@@ -464,7 +465,7 @@ func (act SaveActor) saveActionSummary(ctx context.Context, actionSummary summar
464
465
Save (ctx )
465
466
}
466
467
func (act SaveActor ) saveBuildGraphMetrics (ctx context.Context , buildGraphMetrics summary.BuildGraphMetrics ) (* ent.BuildGraphMetrics , error ) {
467
- //TODO:implement EvalutionStats once they exist on the proto
468
+ // TODO:implement EvalutionStats once they exist on the proto
468
469
return act .db .BuildGraphMetrics .Create ().
469
470
SetActionLookupValueCount (buildGraphMetrics .ActionLookupValueCount ).
470
471
SetActionLookupValueCountNotIncludingAspects (buildGraphMetrics .ActionLookupValueCountNotIncludingAspects ).
@@ -529,6 +530,7 @@ func (act SaveActor) savePackageMetrics(ctx context.Context, packageMetrics summ
529
530
AddPackageLoadMetrics (packageLoadMetrics ... ).
530
531
Save (ctx )
531
532
}
533
+
532
534
func (act SaveActor ) saveCumulativeMetrics (ctx context.Context , cumulativeMetrics summary.CumulativeMetrics ) (* ent.CumulativeMetrics , error ) {
533
535
return act .db .CumulativeMetrics .Create ().
534
536
SetNumAnalyses (cumulativeMetrics .NumAnalyses ).
0 commit comments