The bundle at 'my_app.app/ResearchKit/ResearchKit/Info.plist' does not contain a bundle executable

我们两清 提交于 2021-01-27 13:11:49

问题


Update XCode Version: 8.2 iOS Target: 9

Hopefully some can point out to me that this is not a bug. Very simply I pulled the latest stable version of researckKit, and I dropped the .xcodeproj file into my new iOS project, added the embedded binary. I created a couple steps that look fine in the simulator. My app builds fine and even the archive validates OK. Upload to app store is fine, but then I am receiving emails from the app store with 6 entries all look about the same, for 6 different Info.plist files inside the ReserachKit framework:

Unexpected CFBundleExecutable Key - The bundle at 'my_app.app/ResearchKit/ResearchKit/Info.plist' does not contain a bundle executable. If this bundle intentionally does not contain an executable, consider removing the CFBundleExecutable key from its Info.plist and using a CFBundlePackageType of BNDL. If this bundle is part of a third-party framework, consider contacting the developer of the framework for an update to address this issue.

I have found quite a few answers on Stack Overflow, many people agreeing to do what was suggested in the error message: simply remove the CFBundleExecutable Key from the .plist files. I tried that, but then my archive will not even validate with the following error:

iTunes Store operation failed. Invalid Bundle Structure - The binary file 'my_app.app/Frameworks/ResearchKit.framework/ResearchKit' is not permitted. Your app can’t contain standalone executables or libraries, other than the CFBundleExecutable of supported bundles. Refer to the Bundle Programming Guide at https://developer.apple.com/go/?id=bundle-structure for information on the iOS app bundle structure.

** UPDATE **

Granted I pulled a fresh version of the ResearchKit framework from github for this project. So instead I just tried a copy of a version of ResearchKit from another Xcode Project that I have successfully deployed on the app store recently, i figure if it worked for that app it should go through for this app. But Alas, I am getting the same email error from the App Store about the Unexpected CFBundleExecutable Key.

Again this is an apple-supported free framework. There are simple instructions for how to use it on the github page, which I followed. I have used it before and submitted an app with this framework recently, which had no problems and is currently active in Test Flight Beta Testing. I also filed an issue on the GitHub project page.


回答1:


I met this problem like yours,and I fixed it by:

  • Remove Executable file in ResearchKit
  • Find info.plist in ResearchKit,do:
    delete info.plist in ResearchKit. Or you can add Bundle version,Bundle identifier,Bundle versions in this info.plist,they should be same as your parameters in your own info.plist
  • check Target - Info - URL Types,check if there is illegal identifier



回答2:


I contacted Apple Technical Support and they helped me solve the problem. Like I had suspected it was NOT necessary to alter the ResearchKit framework in any way for this to work correctly.

For me, the issue was that I was copying the entire source code, test cases, Xcode projects, and the rest of ResearchKit into the app.

I must have done this at an early step and didn't realize. What was helpful for me was to go to the Build Phases tab in XCode and look in the different sections. My error was that I had the researchkit framework in the sections: Link Binary With LIbraries and Copy Bundle Resources. I needed to remove those.

The correct configuration, which you get by dragging the xcodeproj file to the project and embedding the binary will just add on line to the Target Dependencies and Embed frameworks sections in Build Phases.

Here is a screenshot of my corrected configuration:



来源:https://stackoverflow.com/questions/42973992/the-bundle-at-my-app-app-researchkit-researchkit-info-plist-does-not-contain-a

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!