Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
This rule is triggered when the void
return type is used in an async function definition.
Value | |
---|---|
Rule ID | AZF0001 |
Severity | Error |
Defining async
functions with a void
return type make it impossible for the Functions runtime to track invocation completion or catch and handle exceptions thrown by the function method.
Refer to this article for general async void
information: https://msdn.microsoft.com/magazine/jj991977.aspx
To fix violations, change the function's return type from void
to Task
and make the necessary code changes to appropriately return a Task
.
This rule should not be suppressed. Use of async void
will lead to unpredictable behavior.