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
{{ message }}
This repository has been archived by the owner on Nov 8, 2018. It is now read-only.
This could be available as a refactoring operation for any await expression. In addition some cases may be identified with a diagnostic. Here is my list of [currently one] such case:
When two await expressions appear in sequence, the first one can almost always use ConfigureAwait(false).Edit: I misunderstood the behavior of continuations when I made this statement.
AFAIK, threading and asynchronous programming is not 100% related but I could be wrong. If you do the following under any context which has SynchronizationContext (e.g. ASP.NET, WPF, etc.), I'm sure you will get into trouble (assuming that GetAsync method will perform asynchronously):
varfoo=await _httpClient.GetAsync("http://localhost:5000").ConfigureAwait(false);// ... other code which is UI related if under WPF or HttpContext related code if under ASP.NET
As already written here DotNetAnalyzers/Proposals#26 this is tricky, but an important item to try and catch.
The text was updated successfully, but these errors were encountered: