Swift 2 Xcode 7.2.1 游乐场错误 - 文件 "Logs" 无法保存在文件夹 "Library" 中

Swift 2 Xcode 7.2.1 Playground Error - File "Logs" couldn't be saved in the folder "Library"

当我创建一个新的 Playground 文件时,出现 "The file “Logs” couldn’t be saved in the folder “Library” because a file with the same name already exists." 错误。当我打开一个现有的 playground 文件时,同样的事情发生了。

该错误仅发生在 Playground 中,任何项目文件中均无错误。

我做了研究并关注了 this and this。在按照这两个教程中的所有内容进行操作后,我确实重新启动了我的笔记本电脑,但错误仍然存​​在。

我没有删除 ~/Library/Caches/com.apple.dt.Xcode 但如前所述 here 因为这是一个巨大的文件,我仍然不确定这是否可行。

查看下面的屏幕截图。

希望对您有所帮助。谢谢。

我刚找到这个答案here,希望对您有所帮助。

  1. 重新启动您的机器(并且不要使用 Xcode - 否则以后可能会出现错误)
  2. 删除~/Library/Developer/XCPGDevices的内容(通常它包含一个目录,其名称是模拟设备的UDID)
  3. 开始 Xcode 并打开一个 iOS 游乐场。这重新创建了 ~/Library/Developer/XCPGDevices.
  4. 的内容