diff --git a/extkafka/partition_attack_elect_new_leader.go b/extkafka/partition_attack_elect_new_leader.go index 976e712..e3d5602 100644 --- a/extkafka/partition_attack_elect_new_leader.go +++ b/extkafka/partition_attack_elect_new_leader.go @@ -132,7 +132,7 @@ func (f kafkaBrokerElectNewLeaderAttack) Start(ctx context.Context, state *Kafka Level: extutil.Ptr(action_kit_api.Warn), Message: fmt.Sprintf("Error while electing leader for topic '%s', partition %d, error is: %s", t, partition, result.Err.Error()), }) - errs = append(errs, result.Err) + errs = append(errs, errors.New(fmt.Sprintf("Error while electing leader for topic '%s', partition %d, error is: %s", t, partition, result.Err.Error()))) } else { messages = append(messages, action_kit_api.Message{ Level: extutil.Ptr(action_kit_api.Info),