Skip to content

Android build fails on Flutter main, in flutter_local_notifications #771

Closed
@gnprice

Description

@gnprice

@sm-sayedi reported the following error trying to run the app on Android:

C:\Users\mahmo\AppData\Local\Pub\Cache\hosted\pub.dev\flutter_local_notifications-17.1.2\android\src\main\java\com\dexterous\flutterlocalnotifications\FlutterLocalNotificationsPlugin.java:1033: error: reference to bigLargeIcon is ambiguous
      bigPictureStyle.bigLargeIcon(null);
                     ^
  both method bigLargeIcon(Bitmap) in BigPictureStyle and method bigLargeIcon(Icon) in BigPictureStyle match

After some investigation, this is MaikuB/flutter_local_notifications#2329 . It occurs when running a Flutter version from commit flutter/flutter@f23dbc5 up through current main.

For now, the workaround is to use a slightly older Flutter version. For example:

$ cd your/flutter/tree
$ git reset --hard 74688cea3d14954277dd9342d4f9db838eee3050

to get the same commit that's currently our minimum, so the version that was tested when I did the most recent upgrade yesterday.

I pinged the author of the relevant upstream change in the Flutter Discord (in #hackers-android), and he's investigated and has a fix. So probably the package:flutter_local_notifications author will take that fix and make a release, and then we'll upgrade to that.

Metadata

Metadata

Assignees

Labels

a-AndroidIssues specific to Android, or requiring Android-specific work

Type

No type

Projects

Status

Done

Relationships

None yet

Development

No branches or pull requests

Issue actions