-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Closed
Labels
r: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-toolOwned by Flutter Tool teamOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.
Description
There's two errors thrown by Xcode 15.3 when submitting Flutter apps built with native_assets to the App Store.
First is:
This bundle is invalid. The bundle at path Payload/Runner.app/Frameworks/sherpa_onnx_dart.framework has an invalid CFBundleIdentifier 'io.flutter.flutter.native_assets.sherpa_onnx_dart' There are invalid characters(characters that are not dots, hyphen and alphanumerics) that have been replaced with their code point 'io.flutter.flutter.native\\u005fassets.sherpa\\u005fonnx\\u005fdart' CFBundleIdentifier must be present, must contain only alphanumerics, dots, hyphens and must not end with a dot.
Per the Apple reference, underscores can't be used in CFBundleIdentifier, so perhaps we could replace hyphens with underscores here, e.g.
<key>CFBundleIdentifier</key>
<string>io.flutter.flutter.native-assets.${name.replaceAll("_", "-")}</string>
The second issue is similar, the generated Info.plist does not contain an entry for MinimumOSVersion, so trying to publish via XCode will throw the following error:
Asset validation failed. Missing Info.plist value. A value for the key 'MinimumOSVersion' in bundle Runner.app/Frameworks/sherpa-onnx-dart.framework is required.
Workaround is to add the following to native_assets_host.dart
<key>MinimumOSVersion</key>
<string>13.0</string>
I haven't submitted a PR because I suspect there's a broader fix to the native_assets framework build process to consume some user-specified configuration (e.g. this may be contemplated by this issue here.
Originally posted by @nmfisher in #129757 (comment)
Metadata
Metadata
Assignees
Labels
r: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-toolOwned by Flutter Tool teamOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.