cauli icon indicating copy to clipboard operation
cauli copied to clipboard

A timeout via the session is wrongly stored as cancelled in the storage

Open brototyp opened this issue 6 years ago • 1 comments

Reproduction

  • Configure the URLSession in the example application to a very low timeout
    lazy var urlSession: URLSession = {
        var configuration = URLSessionConfiguration.default
        configuration.timeoutIntervalForRequest = 1.0
        return URLSession(configuration: configuration, delegate: self, delegateQueue: nil)
    }()
  • Configure the Network Link Conditioner to 100% packet loss
  • Perform the api.ipify.org request
  • After the request fails, check the request in the InspectorFloret

Expected behavior

  • The InspectorFloret shows it as having a timeout

Observer behavior

  • The InspectorFloret shows this request as being cancelled

brototyp avatar Feb 28 '19 18:02 brototyp

Honestly ... I am not sure if it is a bug from out side or from apples side. If I try to reproduce this issue and break into the public func urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?) { function, the error there states, that the task was cancelled. What to you two think about this bug, @pstued & @Shukuyen ?

brototyp avatar Feb 28 '19 19:02 brototyp