代码之家  ›  专栏  ›  技术社区  ›  Jan D.M.

“此时无法安装此应用程序”错误xcode

  •  0
  • Jan D.M.  · 技术社区  · 6 年前

    当我尝试运行我的flutter应用程序时,构建成功,但当xcode尝试在模拟器上自动安装此构建时,会发生以下错误:

    The parent bundle has the same identifier
         (com.abc.def) as sub-bundle at 
        /Users/jan/Library/Developer/CoreSimulator/Devices/DFF35FBB-FE6C-462E-80964BFBFAF57291/data/Library/Caches/com.apple.mobile.installd.staging/temp.zyu9i6/extracted/Runner.app/Frameworks/App.framework
    

    由于这个错误,我已经坚持了几天了。我在万维网上找不到这个问题的答案。

    我已经尝试删除模拟器的所有内容和设置,但这并不能解决问题。清理项目也不是解决方案。

    谢谢!

    1 回复  |  直到 6 年前
        1
  •  0
  •   Jan D.M.    6 年前

    这个问题的答案是: https://github.com/flutter/flutter/issues/25090#issuecomment-449042782

    您需要更改此文件中的cfbundleIdentifier:

    ios/Flutter/AppFrameworkInfo.plist
    

    将“.app”添加到颤振bundleid“xxx”中:

    <key>CFBundleIdentifier</key> <string>XXX.app</string>
    

    使用“xxx”您自己的bundle-id。