I've added notification service extension to my project, and need to log something using my CustomLogger.swift class. Adding this class to the notification service's target membership (henceforth referred to as TM) simply does not work as it triggers a recursive stream of error. Anything class that is used in CustomLogger (that exists in the main project) is now required to be added to the extension's TM. This leads to a situation where almost every file in the project will have to be added to the extension's TM, rendering this infeasible.
I also tried simply importing the main app into the NotificationService class. However, this again triggers a stream of errors "Missing required module xyz", where xyz is any framework/library that the main project depends on. I add these to the "Embedded frameworks" in the extension, however, again this is infeasible as i would have to add all the frameworks that the main project depends on.
Any help is appreciated.