You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Version Information
Version of Akka.NET? Akka.NET v1.5.16, Akka.Analyzers v0.2.2
Describe the bug
This code is currently flagged as an error by AK1002:
ReceiveAsync<StopActor>(async p =>{try{varactorSelection=Context.System.ActorSelection(p.ActorPath);varactorRef=awaitactorSelection.ResolveOne(p.Timeout);varstopped=awaitactorRef.GracefulStop(p.Timeout);// AK1002 false positive occurs hereif(stopped)Sender.Tell(newCommandResponse($"Successfully terminated [{p.ActorPath}] within [{p.Timeout}]"));elseSender.Tell(newErroredCommandResponse($"Failed to terminate [{p.ActorPath}] within [{p.Timeout}]"));}catch(ActorNotFoundException){Sender.Tell(newCommandResponse($"No actor found at [{p.ActorPath}] - no termination required"));}catch(Exceptione){Sender.Tell(newErroredCommandResponse($"Could not complete actor termination due to [{e.Message}]"));}});
This is just an actor await-ing on a GracefulStop, not on its own graceful stop.
Expected behavior
Should not be flagged.
Actual behavior
Is flagged.
The text was updated successfully, but these errors were encountered:
Version Information
Version of Akka.NET? Akka.NET v1.5.16, Akka.Analyzers v0.2.2
Describe the bug
This code is currently flagged as an error by
AK1002
:This is just an actor
await
-ing on aGracefulStop
, not on its own graceful stop.Expected behavior
Should not be flagged.
Actual behavior
Is flagged.
The text was updated successfully, but these errors were encountered: