-
Notifications
You must be signed in to change notification settings - Fork 147
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CFBundleShortVersionString & CFBundleVersion Sync while Build Generation for iOS #1956
Comments
If I'm understanding correctly, the issue is that your app extension version and your app version are not the same. Shorebird does not manipulate your app version or the versions of your app extensions. Are you suggesting that it should, or am I misunderstanding the problem? |
yeah you're correct but when we do normal build generation w/o shorebird, this issue doesn't happen. |
When you say "normal build generation", what do you mean exactly? How do you normally perform your builds? |
Without Shorebird I meant.
|
I would be useful to understand which versions the Runner.app and Runner.appx end up with after a normal flutter build vs. a shorebird build. It's not clear to me which version is correct. I presume 1.15.67 is the "correct" version and the appx is just lagging behind for some reason? I also wonder if
|
I don't think we have enough information to understand and fix this issue. Closing due to inactivity. |
Having the same problem, unable to release the app because of this |
Would love to help. If you build with |
@c0dezli @tirth-multipl So I use firebase messaging (fcm) for my push notifications. I need to also display small images inside of these notifications to better illustrate them. For that you need to add an extension to allow displaying images which is how the OP probably got here as well. Setup: https://firebase.google.com/docs/cloud-messaging/flutter/receive#step_3_-_use_the_extension_helper Since this is a different target than Runner. It doesn't have marketing version and current project version set by flutter: For OP it would be Now this usually isn't a problem because However shorebird sets this to false. It apparently requires it. When I tried to use export_options.plist with it enabled it failed. There is a way to sync the flutter version tho: 1. Create a debug and release config filecreate two new config files in xcode. Name them something like short extension name and debug/release 2. Include the flutter generated config to those configsdebug config:
release config:
replace the
|
This issue occurs to us when building using shorebird with The solution from @tpkowastaken didn't help (we're using flavors). @bryanoltman, Can we re-open this? |
Happy to. My current understanding is that Shorebird disables manageAppVersionAndBuildNumber. I'm not sure I remember why we do this. Shorebird needs to be able to read the exact app version of your app so that we can look up patches for it when requests come in from your app. Your app will send requests to Shorebird's servers such as "{app_id: 1234-abcd, version: "1.0.0+1"}". When you build your app, we record the release number that it had at time of building. I'm not sure if manageAppVersionAndBuildNumber was delaying this number setting until submission time or what. But it sounds like manageAppVersionAndBuildNumber does more than we understood it to. It doesn't just auto-manage the app version, it also manages the extension versions. Since Flutter doesn't set the extension versions itself, when you have manageAppVersionAndBuildNumber off and build with Flutter (which is what Shorebird does under the covers) an extension version won't get set. @bryanoltman do you remember why we set manageAppVersionAndBuildNumber to false? |
manageAppVersionAndBuildNumber causes Xcode to change the build number of the app after it has been packaged, meaning the version reported to shorebird the release created will be different than what the app reports once it has been released. |
Yeah, so I think our possible actions here are:
|
A 3rd option would be to teach |
Same issue here, are there any update o temporary solution? |
@bryanoltman do you agree that "option 3" is the correct path forward here? e.g. that I should file a bug with |
I have not been able to reproduce this issue, so I'm not totally sure. |
Which isn't to say there's not an issue here, but I attempted to reproduce by adding a notification extension to the Flutter counter app example and going through the shorebird release+patch flow, and I did not see this happen, so I think there's more to this than simply "the app has an extension" |
Can you check if you get the warnings when uploading to transporter? |
@AhmedLSayed9 happy to—I'm not sure I went that far before. Does everything work as intended up to that point? The original bug makes it seem like this should happen much earlier (when running |
I'm not sure but I get an email from Apple and warnings at transporter. I guess I have to test this again. |
Ok, I'm seeing the issue upon uploading using Transporter. Thanks! I'll look into it. |
It's possible running local validation would also trigger this? xcrun -sdk iphoneos Validation /path/to/App.{app or ipa} |
Error text, received via an email from Apple:
|
Exactly. |
Weirdly, this does not seem to be an issue when uploading a build created with Edit: trying now with our ExportOptions.plist |
Confirming that this happens with stock Flutter when passed an ExportOptions.plist generated by Shorebird. |
Fixed by #2620 |
The fix for this was just released with Shorebird v1.4.12 |
Love your work. Thank you! |
Description
CFBundleShortVersionString & CFBundleVersion are not sync when generating iOS build with shorebird. These are soft-warnings.⚠️
Steps To Reproduce
Expected Behavior
CFBundleShortVersionString & CFBundleVersion should sync when generating iOS build with shorebird.
Warnings
The text was updated successfully, but these errors were encountered: