Issues loading file for iOS Content Blocker

I'm trying to load a file I've save for my iOS Content blocker but I keep getting this log and it won't work. This is my code and log I'm getting, can someone please help me find the issue?

Thanks

Optional(Error Domain=NSCocoaErrorDomain Code=4097 "connection to service named com.apple.SafariServices.ContentBlockerLoader" UserInfo={NSDebugDescription=connection to service named com.apple.SafariServices.ContentBlockerLoader})


import UIKit

import MobileCoreServices

class ActionRequestHandler: NSObject, NSExtensionRequestHandling {

func beginRequestWithExtensionContext(context: NSExtensionContext) {

let attachment = NSItemProvider(contentsOfURL: NSBundle.mainBundle().URLForResource("blockerList", withExtension: "json"))!

let item = NSExtensionItem()

item.attachments = [attachment]

if let urlToFile = BlackListManager.sharedInstance.urlToFile(), userFile = NSItemProvider(contentsOfURL: urlToFile) {

item.attachments = [userFile]

}

print(item.attachments)

context.completeRequestReturningItems([item], completionHandler: { expired in

print("%@", expired)

})

}

}

Did you solve this? I'm having the same problem.

Thanks

Have te same issue,apple supported cant help me for a month. What about solution?

Issues loading file for iOS Content Blocker
 
 
Q