Код: Выделить всё
objc[XXXXX]: Class _TtC6SQLite6Backup is implemented in both /System/Library/PrivateFrameworks/LinkServices.framework/LinkServices (0x20263ad48) and /private/var/containers/Bundle/Application/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/SobrietyHelper.app/SobrietyHelper (0xXXXXXXXX). One of the two will be used. Which one is undefined.
objc[XXXXX]: Class _TtC6SQLite10Connection is implemented in both /System/Library/PrivateFrameworks/LinkServices.framework/LinkServices (0x20142f7a8) and /private/var/containers/Bundle/Application/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/SobrietyHelper.app/SobrietyHelper (0xXXXXXXXX). One of the two will be used. Which one is undefined.
objc[XXXXX]: Class _TtC6SQLite9Statement is implemented in both /System/Library/PrivateFrameworks/LinkServices.framework/LinkServices (0x20142f878) and /private/var/containers/Bundle/Application/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/SobrietyHelper.app/SobrietyHelper (0xXXXXXXXX). One of the two will be used. Which one is undefined.
objc[XXXXX]: Class _TtC6SQLite13DateFunctions is implemented in both /System/Library/PrivateFrameworks/LinkServices.framework/LinkServices (0x20263acb0) and /private/var/containers/Bundle/Application/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/SobrietyHelper.app/SobrietyHelper (0xXXXXXXXX). One of the two will be used. Which one is undefined.
objc[XXXXX]: Class _TtC6SQLite12TableBuilder is implemented in both /System/Library/PrivateFrameworks/LinkServices.framework/LinkServices (0x20263ab10) and /private/var/containers/Bundle/Application/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/SobrietyHelper.app/SobrietyHelper (0xXXXXXXXX). One of the two will be used. Which one is undefined.
Код: Выделить всё
import CoreData
import Amplify
import AWSDataStorePlugin
struct PersistenceController {
static let shared = PersistenceController()
static var preview: PersistenceController = {
let result = PersistenceController(inMemory: true)
let viewContext = result.container.viewContext
// Create sample data for preview
let newGoal = Goal(context: viewContext)
newGoal.goalDays = 30
newGoal.startDate = Date()
let newRecord = DrinkRecord(context: viewContext)
newRecord.count = 3
newRecord.date = Date()
do {
try viewContext.save()
} catch {
let nsError = error as NSError
fatalError("Unresolved error \(nsError), \(nsError.userInfo)")
}
return result
}()
let container: NSPersistentContainer
init(inMemory: Bool = false) {
container = NSPersistentContainer(name: "SobrietyHelper")
if inMemory {
container.persistentStoreDescriptions.first!.url = URL(fileURLWithPath: "/dev/null")
}
container.loadPersistentStores(completionHandler: { (storeDescription, error) in
if let error = error as NSError? {
fatalError("Unresolved error \(error), \(error.userInfo)")
}
})
container.viewContext.automaticallyMergesChangesFromParent = true
// Amplify configuration
configureAmplify()
}
private func configureAmplify() {
do {
try Amplify.add(plugin: AWSDataStorePlugin(modelRegistration: AmplifyModels()))
try Amplify.configure()
print("Amplify configured with DataStore plugin")
} catch {
print("An error occurred setting up Amplify: \(error)")
}
}
}
Чистая сборка: выполнил очистку и пересборку проекта.
Симулятор Сброс: удалено все содержимое и настройки в симуляторе.
Проверено на наличие повторяющихся библиотек: проверено в Link Binary With Libraries и не обнаружено дубликатов.
Выполнен поиск. для SQLite в проекте: используется команда find и поиск Xcode, но нет явных ссылок на SQLite.swift.
Вопросы:
Это дублирующая реализация класса критическая проблема для моего приложения?
Как устранить эту ошибку, чтобы избежать потенциальных проблем во время выполнения?
Существуют ли какие-либо известные проблемы с Amplify и Core Интеграция данных, которая может вызвать это?
Будем очень признательны за любые идеи и предложения!
Заранее спасибо!
Подробнее здесь: https://stackoverflow.com/questions/786 ... xcode-proj