HttpClient - task was cancelled - How to get the exact error message?

前端 未结 4 1989
没有蜡笔的小新
没有蜡笔的小新 2021-01-31 01:44

I have the following test code. I always get the \"Task was cancelled\" error after looping 316934 or 361992 times.

If I am not wrong, there are two possible reasons why

4条回答
  •  攒了一身酷
    2021-01-31 02:46

    Don't dispose the instance of HttpClient you're using. Weird but fixed for me this problem.

提交回复
热议问题