From ff2305a89fd8cb3d96e8b9199f5b9d9893fb3229 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrgen=20Eckel?= Date: Wed, 6 Mar 2024 08:38:45 +0100 Subject: [PATCH] removed machine attestation thread (to comply with testing-race conditions becoming apparent on the CI) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jürgen Eckel --- x/machine/keeper/msg_server_attest_machine.go | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/x/machine/keeper/msg_server_attest_machine.go b/x/machine/keeper/msg_server_attest_machine.go index a13449a..b8fd34e 100644 --- a/x/machine/keeper/msg_server_attest_machine.go +++ b/x/machine/keeper/msg_server_attest_machine.go @@ -44,16 +44,13 @@ func (k msgServer) AttestMachine(goCtx context.Context, msg *types.MsgAttestMach scheme := params.AssetRegistryScheme domain := params.AssetRegistryDomain path := params.AssetRegistryPath - util.TerminationWaitGroup.Add(1) - go func() { - defer util.TerminationWaitGroup.Done() - localErr := util.IssueMachineNFT(goCtx, msg.Machine, scheme, domain, path) - if localErr != nil { - util.GetAppLogger().Error(ctx, "Machine NFT issuance failed : "+localErr.Error()) - } else { - util.GetAppLogger().Info(ctx, "Machine NFT issuance successful: "+msg.Machine.String()) - } - }() + localErr := util.IssueMachineNFT(goCtx, msg.Machine, scheme, domain, path) + if localErr != nil { + util.GetAppLogger().Error(ctx, "Machine NFT issuance failed : "+localErr.Error()) + } else { + util.GetAppLogger().Info(ctx, "Machine NFT issuance successful: "+msg.Machine.String()) + } + } else { util.GetAppLogger().Info(ctx, "Not block proposer: skipping Machine NFT issuance") }