I would like to monitor events for Decoding errors.
In the EventMonitor protocol I couldn't find and method useful. DecodableResponseSerializer class would only throw the error without using the eventMonitor mechanism. throw AFError.responseSerializationFailed(reason: .decodingFailed(error: error))
How can I achieve this globally in one single place instead of checking the error at each request response result?
This can be done by implementing request(_:didParseResponse:) which is called whenever a DataRequest or UploadRequest serializes a response. DownloadRequest has a similar event.