Version number ignored when building for iOS

Hi
I’m facing a strange error with my app version number and after 2 day of struggling I think I need some help.
Short version : I can’t update the version number of my iOS app.
So my question would be how do I increase the version number of an iOS capacitor App ?


Long version :
I’m trying to update one app on the App Store using Voltbuilder, however, it failed with the following error :

UserError: This version number has already been uploaded to the iTunes Store.
You need to update the value of 'version' in the 'widget' statement in config.xml.

So, based on what I could read on other forum, I tried to increase the version number everywhere I could (config.xml, Info.plist and package.json) with no success for all of this attempts, alone or combined.

More disturbing, if I increase the bundle number (CFBundleVersion in Info.plist), it return the following error :

UserError: ERROR: ERROR ITMS-90062: This bundle is invalid.
The value for key CFBundleShortVersionString [1.5] in the Info.plist file must contain a higher version than that of the previously approved version [1.5].
Please find more information about CFBundleShortVersionString at https://developer.apple.com/documentation/bundleresources/information_property_list/cfbundleshortversionstring

The current version on the app store is 1.5 and I’m trying to update it to 1.6. However, as far as I know, there is no mention of “1.5” in my code since I updated it to 1.6, letting me think that the version number (CFBundleShortVersionString in Info.plist) is ignored during the build.

That’s why I’m asking my question here : maybe there is an additional process in the voltbuilder build process that require specific attention with version number.

Therefore my question : how can I increase the version number of an iOS App with voltbuilder ?
Or how can I force the CFBundleShortVersionString to be used as version number ?

Did you try ios-CFBundleVersion in the widget part of config.xml?

Thanks for your reply.
Yes, I tested that too, as well as CFBundleVersion.

However, despite having tested that by despair, I think config.xml is not the way to set version number in capacitor app. From what I understand, capacitor use capacitor.config.json as a config file (and not config.xml), and version number might be defined in Info.plist with the key CFBundleShortVersionString, but even if I edit this value nothing happen.

You’re correct. The correct way to set the version is in package.json. I have to apologize, the error is misleading and I don’t believe you’re actually having a problem with the version, but with the upload itself. Can you attempt to update the version again using package.json, upload, and then share the log with support@volt.build? That should allow us to help get you going.

Thanks for your help. I tested to update the version using package.json, got the same error, and sent the mail with the log this morning.

UserError: This version number has already been uploaded to the iTunes Store.
You need to update the value of 'version' in the 'widget' statement in config.xml.