skip to Main Content

I’m trying to upload an app to the AppStore for testing with TestFlight.

At the end of the upload, I obtain a message stating:

This bundle is invalid. The value for key CFBundleVersion [2-15] in the Info.plist file must be a period-separated list of at most three non-negative integers. Please find more…

There is no CFBundleVersionin my Info.plist. I can see it only in the Target Properties. I checked every other Info.plist of the packages I import with SPM or Carthage and they use <key>CFBundleVersion</key><string>1</string>.

I tried to change the value in the Target Properties, using a simple digit, but this doesn’t help.
I tried adding CFBundleVersion and other CFBundle* keys in the Info.plist, but that didn’t help either.

What is stopping my upload?

enter image description here

enter image description here

My Info.plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>UIApplicationSceneManifest</key>
    <dict>
        <key>UIApplicationSupportsMultipleScenes</key>
        <false/>
        <key>UISceneConfigurations</key>
        <dict>
        <key>UIWindowSceneSessionRoleApplication</key>
        <array>
            <dict>
                <key>UISceneConfigurationName</key>
                <string>Default Configuration</string>
                <key>UISceneDelegateClassName</key>
               <string>$(PRODUCT_MODULE_NAME).SceneDelegate</string>
            </dict>
        </array>
    </dict>
    </dict>
    <key>UIViewControllerBasedStatusBarAppearance</key>
    <false/>
</dict>
</plist>

2

Answers


  1. Chosen as BEST ANSWER

    I finally discover that in a binary xcframework downloaded with Carthage CFBundleVersion was "2-15". I didn't notice before because grep showed me the content of the other imported Info.plist files, but only Binary file .../Info.plist matches for this xcframework and I skipped it.

    Updated the binary xcframework, I was able to upload the app.


  2. Yes, there is. Because you’re viewing the plist file in Property List mode. You can change the view mode to Source Code to see the key CFBundleVersion

    In your project, right click on Info.plist file -> Open As -> Source Code

    It’s something like:

    <key>CFBundleVersion</key>
        <string>$(CURRENT_PROJECT_VERSION)</string>
    

    And you may need to double-check the current version in Project -> Targets -> General. Its location is in Identity section.

    enter image description here

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search