我在去年在 Xcode 8 中构建的 Xcode 项目中遇到了这个错误,现在我试图在 Xcode 9 GM 中打开它。
编辑仔细检查,我注意到它没有使用 GM,我使用的是 Xcode 9.1 beta 2。下面的解决方案有效!
错误:
/Users/XXXX/Documents/App Development/Final Apps/XXXX/Base.lproj/Main.storyboard: Internal error. Please file a bug at bugreport.apple.com and attach "/var/folders/ln/n28_nbyn2cg9_5dfqfsj8_7w0000gn/T/IB-agent-diagnostics_2017-10-04_21-24-39_279000".
我已经尝试过其他类似帖子的建议:
如果我转到错误消息指向的文件夹,我看到的内容为:
CoreSimulatorLogs Document.storyboard Log.txt system.log
在 Log.txt 中,我看到了这个:
Failed to compile nib consisting of IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBProxyObject, IBUIBarButtonItem, IBUIBarButtonItem, IBUIBarButtonItem, IBUIBarButtonItem, IBUIBarButtonItem, IBUIBarButtonItem, IBUICollectionViewController, IBUINavigationBar, IBUINavigationBar, IBUINavigationBar, IBUINavigationBar, IBUINavigationBar, IBUINavigationController, IBUINavigationController, IBUINavigationController, IBUINavigationController, IBUINavigationController, IBUINavigationItem, IBUINavigationItem, IBUINavigationItem, IBUINavigationItem, IBUINavigationItem, IBUIStoryboardEmbedSegueTemplate, IBUIStoryboardEmbedSegueTemplate, IBUIStoryboardShowSegueTemplate, IBUITabBar, IBUITabBarController, IBUITabBarItem, IBUITabBarItem, IBUITabBarItem, IBUITabBarItem, IBUITabBarItem, IBUITableViewController, IBUIViewController, IBUIViewController, and IBUIViewController.
Exception name: NSInvalidArgumentException
Exception reason: System-provided UIImage instances cannot be encoded in NIBs - raised for instance '<UIImage: 0x7f945db51a90>, {18, 20}'
Exception backtrace:
0. CoreFoundation 0x000000010800d023 __exceptionPreprocess
1. libobjc.A.dylib 0x0000000106de3f41 objc_exception_throw
2. IBCocoaTouchToolFoundation 0x0000000103071a8a -[IBCocoaTouchToolNibFactory nibCoder:willEncodeObject:]
3. IBCocoaTouchToolFoundation 0x0000000103071b77 -[IBCocoaTouchToolNibFactory nibCoder:willEncodeObject:forObject:forKey:]
4. UIKit 0x00000001038111f5 -[UINibEncoder replacementObjectForObject:forKey:]
5. UIKit 0x0000000103811d4d -[UINibEncoder encodeObject:forKey:]
6. UIKit 0x0000000103a4a6de -[UITabBarItem encodeWithCoder:]
7. UIKit 0x0000000103811ea0 -[UINibEncoder encodeObject:forKey:]
8. IBCocoaTouchToolFoundation 0x000000010305ed41 -[UIViewControllerTemplate encodeWithCoder:]
9. IBCocoaTouchToolFoundation 0x0000000103055018 -[UINavigationControllerTemplate encodeWithCoder:]
10. UIKit 0x0000000103811ea0 -[UINibEncoder encodeObject:forKey:]
11. UIKit 0x0000000103811354 -[UINibEncoder serializeArray:]
12. UIKit 0x0000000103811ea0 -[UINibEncoder encodeObject:forKey:]
13. IBCocoaTouchToolFoundation 0x000000010305ef3c -[UIViewControllerTemplate encodeWithCoder:]
14. IBCocoaTouchToolFoundation 0x00000001030704d9 -[UITabBarControllerTemplate encodeWithCoder:]
15. IBCocoaTouchToolFoundation 0x0000000103071e57 -[UIClassSwapper(IBHooksFor6767205) designTimeEncodeWithCoder:]
16. UIKit 0x0000000103811ea0 -[UINibEncoder encodeObject:forKey:]
17. UIKit 0x0000000103811354 -[UINibEncoder serializeArray:]
18. UIKit 0x0000000103811ea0 -[UINibEncoder encodeObject:forKey:]
19. IBCocoaTouchToolFoundation 0x000000010307166c -[IBCocoaTouchToolNibFactory encodeNibContentWithCoder:]
20. IBCocoaTouchToolFoundation 0x0000000103071801 -[IBCocoaTouchToolNibFactory nibDataWithMinimumCompatibility:]
21. IBCocoaTouchToolFoundation 0x0000000103071d43 +[IBCocoaTouchToolNibFactory nibDataFromObjects:customClasses:topLevelObjects:traitStorageLists:accessibilityConfigurations:connections:keyValuePairs:visibleWindows:minimumCompatibility:]
22. IBCocoaTouchToolFoundation 0x00000001030379d5 -[IBCocoaTouchTool compileNibForRequest:minimumCompatibility:layoutInfo:imagesToImageNames:]
23. IBFoundation 0x000000010640009b __80-[IBMessageReceiveChannel deliverMessage:toTarget:withArguments:context:result:]_block_invoke
24. IBFoundation 0x00000001063ffe98 -[IBMessageReceiveChannel deliverMessage:toTarget:withArguments:context:result:]
25. IBFoundation 0x00000001063ff80a __88-[IBMessageReceiveChannel runBlockingReceiveLoopNotifyingQueue:notifyingTarget:context:]_block_invoke
26. libdispatch.dylib 0x000000010cf352b5 _dispatch_client_callout
27. libdispatch.dylib 0x000000010cf40999 _dispatch_sync_thread_bound_invoke
28. libdispatch.dylib 0x000000010cf352b5 _dispatch_client_callout
29. libdispatch.dylib 0x000000010cf3f496 _dispatch_main_queue_callback_4CF
30. CoreFoundation 0x0000000107fcfd79 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__
31. CoreFoundation 0x0000000107f94422 __CFRunLoopRun
32. CoreFoundation 0x0000000107f93849 CFRunLoopRunSpecific
33. Foundation 0x00000001067dfe5e -[NSRunLoop(NSRunLoop) runMode:beforeDate:]
34. IBFoundation 0x00000001063c1cf5 -[IBAbstractPlatformTool startServingReceiveChannel:]
35. IBFoundation 0x00000001063c1fb0 -[IBAbstractPlatformTool startServingWriteDescriptor:readDescriptor:]
36. IBFoundation 0x00000001063c2ac9 +[IBAbstractPlatformTool main]
37. ??? 0x0000000102f9aba7 ???
38. libdyld.dylib 0x000000010cfa9d81 start
Exception info:{
}
我不知道如何进行。有什么建议吗?
这个错误是什么意思?
System-provided UIImage instances cannot be encoded in NIBs - raised for instance '<UIImage: 0x7f945db51a90>, {18, 20}'
最佳答案
来自 Xcode 9.1 beta 2 发行说明:
Interface Builder
A UITabBarItem configured as a system item in a storyboard or xib causes a build failure. (34197132)
Workaround: Configure as a custom item in Interface Builder, then reset the tab bar item to the desired system item in the awakeFromNib method of the view controller.
我遇到了与您相同的问题,这似乎是原因,因为日志指向我的一个 UITabBarItems。
编辑:我可以确认它有效。将所有系统 TabBarItems 更改为自定义,它将编译! EDIT2:你确定你没有使用 9.1 beta 吗?因为我在今天之前从未遇到过这个问题,当时我测试 Xcode 9.1 beta 2(在之前使用 Xcode 9 之后)。
关于ios - 构建应用程序时 Xcode 9 Main.storyboard 错误 "Internal error. Please file a bug at bugreport.apple.com and attach ",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46576573/
我需要在客户计算机上运行Ruby应用程序。通常需要几天才能完成(复制大备份文件)。问题是如果启用sleep,它会中断应用程序。否则,计算机将持续运行数周,直到我下次访问为止。有什么方法可以防止执行期间休眠并让Windows在执行后休眠吗?欢迎任何疯狂的想法;-) 最佳答案 Here建议使用SetThreadExecutionStateWinAPI函数,使应用程序能够通知系统它正在使用中,从而防止系统在应用程序运行时进入休眠状态或关闭显示。像这样的东西:require'Win32API'ES_AWAYMODE_REQUIRED=0x0
我正在尝试测试是否存在表单。我是Rails新手。我的new.html.erb_spec.rb文件的内容是:require'spec_helper'describe"messages/new.html.erb"doit"shouldrendertheform"dorender'/messages/new.html.erb'reponse.shouldhave_form_putting_to(@message)with_submit_buttonendendView本身,new.html.erb,有代码:当我运行rspec时,它失败了:1)messages/new.html.erbshou
我在从html页面生成PDF时遇到问题。我正在使用PDFkit。在安装它的过程中,我注意到我需要wkhtmltopdf。所以我也安装了它。我做了PDFkit的文档所说的一切......现在我在尝试加载PDF时遇到了这个错误。这里是错误:commandfailed:"/usr/local/bin/wkhtmltopdf""--margin-right""0.75in""--page-size""Letter""--margin-top""0.75in""--margin-bottom""0.75in""--encoding""UTF-8""--margin-left""0.75in""-
大约一年前,我决定确保每个包含非唯一文本的Flash通知都将从模块中的方法中获取文本。我这样做的最初原因是为了避免一遍又一遍地输入相同的字符串。如果我想更改措辞,我可以在一个地方轻松完成,而且一遍又一遍地重复同一件事而出现拼写错误的可能性也会降低。我最终得到的是这样的:moduleMessagesdefformat_error_messages(errors)errors.map{|attribute,message|"Error:#{attribute.to_s.titleize}#{message}."}enddeferror_message_could_not_find(obje
Rackup通过Rack的默认处理程序成功运行任何Rack应用程序。例如:classRackAppdefcall(environment)['200',{'Content-Type'=>'text/html'},["Helloworld"]]endendrunRackApp.new但是当最后一行更改为使用Rack的内置CGI处理程序时,rackup给出“NoMethodErrorat/undefinedmethod`call'fornil:NilClass”:Rack::Handler::CGI.runRackApp.newRack的其他内置处理程序也提出了同样的反对意见。例如Rack
我想用ruby编写一个小的命令行实用程序并将其作为gem分发。我知道安装后,Guard、Sass和Thor等某些gem可以从命令行自行运行。为了让gem像二进制文件一样可用,我需要在我的gemspec中指定什么。 最佳答案 Gem::Specification.newdo|s|...s.executable='name_of_executable'...endhttp://docs.rubygems.org/read/chapter/20 关于ruby-在Ruby中编写命令行实用程序
为了将Cucumber用于命令行脚本,我按照提供的说明安装了arubagem。它在我的Gemfile中,我可以验证是否安装了正确的版本并且我已经包含了require'aruba/cucumber'在'features/env.rb'中为了确保它能正常工作,我写了以下场景:@announceScenario:Testingcucumber/arubaGivenablankslateThentheoutputfrom"ls-la"shouldcontain"drw"假设事情应该失败。它确实失败了,但失败的原因是错误的:@announceScenario:Testingcucumber/ar
我构建了两个需要相互通信和发送文件的Rails应用程序。例如,一个Rails应用程序会发送请求以查看其他应用程序数据库中的表。然后另一个应用程序将呈现该表的json并将其发回。我还希望一个应用程序将存储在其公共(public)目录中的文本文件发送到另一个应用程序的公共(public)目录。我从来没有做过这样的事情,所以我什至不知道从哪里开始。任何帮助,将不胜感激。谢谢! 最佳答案 无论Rails是什么,几乎所有Web应用程序都有您的要求,大多数现代Web应用程序都需要相互通信。但是有一个小小的理解需要你坚持下去,网站不应直接访问彼此
我尝试运行2.x应用程序。我使用rvm并为此应用程序设置其他版本的ruby:$rvmuseree-1.8.7-head我尝试运行服务器,然后出现很多错误:$script/serverNOTE:Gem.source_indexisdeprecated,useSpecification.Itwillberemovedonorafter2011-11-01.Gem.source_indexcalledfrom/Users/serg/rails_projects_terminal/work_proj/spohelp/config/../vendor/rails/railties/lib/r
刚入门rails,开始慢慢理解。有人可以解释或给我一些关于在application_controller中编码的好处或时间和原因的想法吗?有哪些用例。您如何为Rails应用程序使用应用程序Controller?我不想在那里放太多代码,因为据我了解,每个请求都会调用此Controller。这是真的? 最佳答案 ApplicationController实际上是您应用程序中的每个其他Controller都将从中继承的类(尽管这不是强制性的)。我同意不要用太多代码弄乱它并保持干净整洁的态度,尽管在某些情况下ApplicationContr