XCode 4.3 无法加载持久存储 UserDictionary.sqlite

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/11040681/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-15 00:36:30  来源:igfitidea点击:

XCode 4.3 Unable to load persistent store UserDictionary.sqlite

iphoneiosxcodestorepersistent

提问by JonathanC

I have been working on an iOS app for some time, all of a sudden I am getting the following crash every time I run the app in the iOS 5.1 Simulator.

我已经在 iOS 应用程序上工作了一段时间,每次我在 iOS 5.1 模拟器中运行该应用程序时,突然间我都会遇到以下崩溃。

The App does not use Core Data and I am not sure what brought this about.

该应用程序不使用核心数据,我不确定是什么导致了这一点。

I have deleted the app from the simulator, done Clean, and a rebuild but nothing seems to help.

我已经从模拟器中删除了该应用程序,完成了清理和重建,但似乎没有任何帮助。

Unable to load persistent store at URL 'file://localhost/Users/jcottrell/Library/Application%20Support/iPhone%20Simulator/5.1/Library/Keyboard/UserDictionary.sqlite' ({
    metadata =     {
        NSPersistenceFrameworkVersion = 407;
        NSStoreModelVersionHashes =         {
            UserDictionaryEntry = <f0c9025b 602122f9 37a4e274 bdaacec1 b9a66f83 fca5c43b bed5e80a 6baee338>;
        };
        NSStoreModelVersionHashesVersion = 3;
        NSStoreModelVersionIdentifiers =         (
            ""
        );
        NSStoreType = SQLite;
        NSStoreUUID = "43DABF34-7F7E-4FE9-B78D-8AF64292A967";
        "_NSAutoVacuumLevel" = 2;
    };
    reason = "The model used to open the store is incompatible with the one used to create the store";
})

回答by JonathanC

I have fixed the problem. I clicked 'iOS Simulator' -> Reset Content and Settings

我已经解决了这个问题。我点击了“iOS模拟器”->重置内容和设置

回答by Dan Rosenstark

Delete the file you mentioned: /Users/jcottrell/Library/Application%20Support/iPhone%20Simulator/5.1/Library/Keyboard/UserDictionary.sqliteand the accompanying plist. This is a simulator-only problem, so you can ignore it.

删除您提到的文件:/Users/jcottrell/Library/Application%20Support/iPhone%20Simulator/5.1/Library/Keyboard/UserDictionary.sqlite以及随附的plist. 这是一个仅限模拟器的问题,因此您可以忽略它。