AWSSDK.SimpleEmail Throwing Error - TaskCanceledException: A task was canceled. #2106
-
Describe the bugI am using latest version (3.7.1.127) of AWSSDK.SimpleEmailV2. I am trying to retrieve the SES account-level suppression list using AWS SDK in .Net Core: Below is my code:
But it doesn't seem to be working. The request takes too long and then returns empty response or below error if I remove try/catch:
Expected BehaviorIt should return the request suppression list. Current BehaviorThrowing error "A task was canceled." Reproduction StepsThe above mentioned code can be used for reproduction in any .net core project. Possible SolutionNo response Additional Information/ContextNo response AWS .NET SDK and/or Package version usedAWSSDK.SimpleEmailV2 -Version 3.7.1.127 Targeted .NET Platform.Net 6 Operating System and versionWindows 11 |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
@naveedahmed1 In this case, the
You may also try enabling detailed verbose logging so that detailed wire logs are emitted (try adding minimal code below if using the console application): Amazon.AWSConfigs.LoggingConfig.LogResponses = Amazon.ResponseLoggingOption.Always;
Amazon.AWSConfigs.LoggingConfig.LogTo = Amazon.LoggingOptions.SystemDiagnostics;
Amazon.AWSConfigs.AddTraceListener("Amazon", new System.Diagnostics.ConsoleTraceListener()); Thanks, |
Beta Was this translation helpful? Give feedback.
-
I was using |
Beta Was this translation helpful? Give feedback.
-
Hello! Reopening this discussion to make it searchable. |
Beta Was this translation helpful? Give feedback.
I was using
awsConfig.DefaultClientConfig.UseHttp = true;
which was causing the issue. Removing it fixed the issue and everything seems to be working perfectly now. Thanks