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
I'm trying to use a DVR Session with Alamofire but using it to initialize a Manager generates an unrecognized selector exception.
This conversation deals with my use case, but the advice ("Just create a session delegate, then create your custom session, and pass both in.") doesn't seem to work. Since DVR's Session is a subclass of NSURLSession I would expect that you could ask for its delegate but it's breaking for some reason.
letdelegate=Manager.SessionDelegate()letbackingSession=NSURLSession(configuration:NSURLSessionConfiguration.defaultSessionConfiguration(), delegate: delegate, delegateQueue:nil)letmaybeBundle=NSBundle.allBundles().filter{ $0.bundlePath.lowercaseString.containsString("xctest")}.first
if let bundle = maybeBundle {letsession=Session(outputDirectory:"~/Desktop/DVR/", cassetteName: cassetteName, testBundle: bundle, backingSession: backingSession)}
The text was updated successfully, but these errors were encountered:
I'm having the same issue as @jefflovejapan is having. I created the objects as advised (Session delegate and custom session), but if the moment I instantiate the Alamofire.Manager with both, I get this error: "[DVR.Session delegate]: unrecognized selector sent to instance (instance address)".
I'm trying to use a DVR
Session
with Alamofire but using it to initialize aManager
generates anunrecognized selector
exception.This conversation deals with my use case, but the advice ("Just create a session delegate, then create your custom session, and pass both in.") doesn't seem to work. Since DVR's
Session
is a subclass ofNSURLSession
I would expect that you could ask for itsdelegate
but it's breaking for some reason.The text was updated successfully, but these errors were encountered: