Skip to content

Firebase messaging onResume and onMessage broken on iOS since Flutter 1.7.4 #36201

@JaspervanRiet

Description

@JaspervanRiet

On Flutter's dev channel (and all other channels), Firebase Messaging's onResume and onMessage callbacks are broken on iOS as of 1.7.4. We have done extensive testing, and it works fine with v1.6.3, and even v1.6.7. onLaunch works fine, and all callbacks work fine on Android. The callbacks are not called at all, and the following error can be found in the iOS logs:

SpringBoard(UserNotificationsServer)[52] <Notice>: [com.ourapp.someapp] Application foreground
launch action for notification response action com.apple.UNNotificationDefaultActionIdentifier
recieved action response <BSActionResponse: 0x2839cde00; error:
<NSError: 0x2834c37e0; domain: BSActionErrorDomain; code: 4> {
    description = "The operation couldn\M-b\M^@\M^Yt be completed. (BSActionErrorDomain error 4.)";
}>

Every now and then it shows error 1 instead of error 4. This error is terribly documented online (not at all), but I recognise it from when we had our iOS app configurated wrong for push notifications. Our configuration is fine now. We build via a build server, so we still have all the logs. We built a version on June 20st (from now on referred to as A), and a version on June 21st (B). A was v1.6.3, B was v1.7.4. We've since tested v1.6.7, and that version is fine too. Version A calls the callbacks and works fine. Version B does not. The issue is not related to our code since on our current HEAD, the callbacks still only work < v1.7.4.

Now, we have had to revert back to Flutter v1.6.7, meaning we no longer have access to app bundles and TransferableTypedData, which is, of course, a major blocker for our work.

Flutter version for A:

Flutter 1.6.3 • channel beta • https://github.com/flutter/flutter.git
Framework • revision bc7bc94083 (4 weeks ago) • 2019-05-23 10:29:07 -0700
Engine • revision 8dc3a4cde2
Tools • Dart 2.3.2 (build 2.3.2-dev.0.0 e3edfd36b2)

Flutter version for B:

Flutter 1.7.4 • channel dev • https://github.com/flutter/flutter.git
Framework • revision dfecafa4ab (7 days ago) • 2019-06-14 09:46:23 -0700
Engine • revision 2589785b5c
Tools • Dart 2.4.0

Firebase messaging version: 5.1.0, but applies to every version since at least 5.0.1 (that's as far as we went)

Metadata

Metadata

Assignees

Labels

c: regressionIt was better in the past than it is nowp: firebase_messagingThe Firebase Messaging pluginpackageflutter/packages repository. See also p: labels.platform-iosiOS applications specifically

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions