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
When running with the first url, the program correctly prints the response and exits.
When using the second one, which returns a 401, the completion handler is never called and the program never exits.
Other error codes will also call the completion handler
It may be related or not, but if using a data task without completion handlers and URLSessionTaskDelegate, similarly urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?) is never called.
(I didn't have time to make sample code for this, might add later if needed)
The text was updated successfully, but these errors were encountered:
Environment
Swift version 5.1 (swift-5.1-RELEASE)
Target: x86_64-unknown-linux-gnu
Tested on docker using swift:5.1 image
Additional Detail from JIRA
md5: c519a9ec862920bbb3a54722a4e53bec
Issue Description:
Sample code to reproduce the issue:
When running with the first url, the program correctly prints the response and exits.
When using the second one, which returns a 401, the completion handler is never called and the program never exits.
Other error codes will also call the completion handler
It may be related or not, but if using a data task without completion handlers and
URLSessionTaskDelegate
, similarlyurlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?)
is never called.(I didn't have time to make sample code for this, might add later if needed)
The text was updated successfully, but these errors were encountered: