Select to view content in your preferred language

ArcGIS Maps SDK for Flutter - 200.8.0 compatibility notes for Flutter 3.38.x

99
0
yesterday
Labels (1)
kossiyovo
Esri Contributor
1 0 99

Flutter is evolving rapidly, and so is our SDK. With each new Flutter release, we strive to maintain compatibility and deliver a smooth integration experience.

Because Flutter versions often ship between our release cycles, each new release of our package is built and certified against the latest Flutter version available at that time. When Flutter introduces a new version between our releases, we’ll share guidance on compatibility with our most recent SDK.

Although we have not completed full certification across all supported devices, our high-level testing confirms that the 200.8.0 release works with Flutter 3.38.1 and later.

This post highlights key compatibility considerations and dependency requirements for supporting our SDK on Flutter 3.38.x.

1. argis_maps package

When using arcgis_maps 200.8.0 with Flutter 3.38.x, you may experience the following error:

Error:

Dependency 'androidx.browser:browser:1.9.0' requires Android Gradle plugin 8.9.1 or higher.
This build currently uses Android Gradle plugin 8.7.3.

This error is due to a conflict with the url_launcher_android dependency version 6.3.26 or later, which requires Android Gradle Plugin (AGP) 8.9.1 or higher.

How to fix this issue

You have two options:

Option 1: Upgrade the AGP

Update your Android project to use AGP 8.9.1 or newer.
This AGP version is compatible with url_launcher_android 6.3.26.

Option 2: Pin the compatible version of  url_launcher_android

If you prefer not to upgrade your Android Gradle Plugin, add the following override to your pubspec.yaml:

dependency_overrides:
url_launcher_android: 6.3.25 # or newer

 

2. arcgis_maps_toolkit

The following error may be experienced when using our toolkit on Flutter 3.38.x:

Error:

Type argument is not within its bounds: should be subtype of 'Any'

What is happening is that our toolkit depends on webview_flutter and its Android implementation (webview_flutter_android). Newest version of webview_flutter_android (4.10.5) generates Kotlin code that is incompatible with older Kotlin compiler versions.

How to fix this issue

You have two options:

Option 1: Upgrade Kotlin

Update your Android project to use Kotlin 2.2.0 or newer.
This Kotlin version is compatible with webview_flutter_android 4.10.5 and above.

Option 2: Pin the compatible WebView version

Add the following override to your pubspec.yaml:

dependency_overrides:
webview_flutter_android: 4.10.5 # or newer

Note:

This issue occurs due to a recent point release update to webview_flutter_android and can also affect projects using Flutter 3.35.