Skip to content
CAI
Software that uses CAICheck a score

Baseflow/flutter-geolocator

66.7

Adequate · 19 September 2026

7k

lines of production code

Dart

with Java, C++, Objective-C, C

1

measurement over time

CAI band scale
CAI lens gauges

What this system is

This system is a federated Flutter plugin suite that provides cross-platform geolocation services, supporting Android, iOS, macOS, Linux, Windows, and Web. It exposes a unified API for checking permissions, retrieving current and last known positions, and streaming real-time location updates. The architecture delegates platform-specific logic to dedicated packages while maintaining a shared interface for consistent data models and error handling.

How it got here

2018 — Federated plugin architecture migration

10 changes.

The project underwent a major restructuring to migrate from a monolithic plugin to a federated architecture, splitting platform-specific logic into separate endorsed packages for Android, Apple, Web, and Windows. This involved removing the legacy Dart and native implementations while establishing a shared platform interface and updating dependencies to version 14.0.3.

2020 — platform interface abstraction

16 changes.

This period focused on establishing the GeolocatorPlatform interface to decouple core location logic from platform-specific implementations. The work involved defining standardized enums, error types, and data models, alongside implementing the MethodChannelGeolocator bridge and comprehensive unit tests to ensure robust cross-platform support.

2021–2022 — multi-platform expansion and refactoring

13 changes.

This period focused on expanding the geolocator plugin to support Windows, Linux, and Apple platforms, alongside significant refactoring of the Android and web implementations. The Android backend was restructured to use a dedicated foreground service for improved stability and background tracking, while the web implementation introduced configurable caching and abstracted permission management. Comprehensive example applications and unit tests were added across all new and updated platforms to ensure consistent functionality and coverage.

Features

Initial Linux example application for geolocator

Adds a complete example application for the geolocator\_linux plugin, enabling users to run and test the plugin on Linux desktop. The entry includes the Flutter Dart code (main.dart) demonstrating permission handling and location updates, along with the necessary Linux native project files (CMakeLists.txt, main.cc, my\_application.cc) to build and run the app on the platform.

_geolocator\linux/example · high confidence

Initial Linux implementation for geolocator

Adds the \geolocator\_linux\ package, providing the first official Linux backend for the geolocator plugin. This implementation leverages the GeoClue2 D-Bus service to retrieve current and last-known positions, and includes a GNOME-specific variant that detects the GNOME desktop environment, monitors location service status via GSettings, and allows users to open the system Location Settings directly.

_geolocator\linux · high confidence

Initial Windows support for the geolocator plugin

This change introduces the official Windows implementation of the geolocator plugin, allowing Flutter applications to access location services on Windows. The package includes the native C++ plugin code, a CMake build configuration, and a complete example application demonstrating usage. It registers with the Flutter engine to handle method calls for checking permissions, retrieving current and last known positions, and monitoring location service status.

_geolocator\windows · high confidence

Initial implementation of MethodChannelGeolocator platform interface

This change introduces the \MethodChannelGeolocator\ class, which serves as the concrete implementation of the \GeolocatorPlatform\ interface for communicating with native platforms via method and event channels. It provides the core functionality for location services, including checking and requesting permissions, retrieving the last known position, getting the current position with optional timeout support, monitoring location service status, and streaming real-time position updates. The implementation handles platform exceptions and manages stream lifecycle to ensure robust interaction with the underlying device hardware.

_geolocator\_platform\interface/lib/src/implementations · high confidence

Introduce GeolocatorPlatform interface with location service and permission APIs

The platform interface for the geolocator plugin is now defined in \geolocator\_platform\_interface/lib/src/geolocator\_platform\_interface.dart\, establishing the contract for platform-specific implementations. This interface exposes core location capabilities including checking and requesting permissions (\checkPermission\, \requestPermission\), verifying if location services are enabled (\isLocationServiceEnabled\), retrieving the last known position (\getLastKnownPosition\), fetching the current position (\getCurrentPosition\), and listening to location changes (\getPositionStream\). It also introduces a stream for monitoring location service status changes (\getServiceStatusStream\) and supports iOS 14+ temporary precise location requests (\requestTemporaryFullAccuracy\). Platform plugins must extend this abstract class to provide the actual device location functionality.

_geolocator\_platform\interface/lib/src · high confidence

Migration to federated plugin architecture

The repository has been restructured from a single monolithic package into a federated plugin architecture. The main \geolocator\ package now serves as the app-facing entry point, delegating platform-specific logic to separate endorsed packages: \geolocator\_android\, \geolocator\_apple\, \geolocator\_web\, and \geolocator\_windows\. This change introduces support for Windows and Web platforms alongside existing Android and iOS/macOS support, while \geolocator\_platform\_interface\ defines the shared interface for all implementations.

(repo-wide) · high confidence

New example app demonstrating Geolocator core features

The geolocator example application has been updated to a new implementation that showcases core location functionalities. Users can now view a live stream of position updates, retrieve the current position, and access the last known position. The app includes platform-specific actions, allowing iOS users to check location accuracy and request temporary full accuracy, while Android and Windows users can open location settings. It also handles permission states and location service status, providing clear feedback on whether location services are enabled or if permissions have been denied.

geolocator/example · high confidence

New example app for geolocator\_apple

The geolocator\_apple example application has been introduced, providing a complete Flutter UI to demonstrate the plugin's capabilities. This demo app allows users to test core geolocation features such as retrieving the current and last known positions, monitoring location updates, and checking service status. It also includes platform-specific actions for iOS, such as requesting temporary full accuracy and viewing location accuracy, alongside standard actions like opening app settings.

_geolocator\_apple/example, geolocator\web/example · high confidence

The platform interface now exposes four new enums to standardize location data handling: LocationAccuracy (with values like lowest, low, medium, high, best, bestForNavigation, and reduced), LocationAccuracyStatus (reduced, precise, unknown) for iOS 14+ precise location support, LocationPermission (denied, deniedForever, whileInUse, always, unableToDetermine) for permission states, and ServiceStatus (disabled, enabled) for native location service states. These enums replace previous ad-hoc representations and provide a consistent API for developers to check permissions, request specific accuracy levels, and monitor service status across platforms.

_geolocator\_platform\interface/lib/src/enums · high confidence

Web platform now supports configurable location caching via WebSettings

The geolocator\_web plugin introduces a new \WebSettings\ class that allows users to control the \maximumAge\ of cached location updates on the web platform. This setting is passed through to the underlying HTML5 Geolocation API, enabling developers to specify how old a cached position can be before the browser must fetch a fresh one. The plugin also registers itself as the default web implementation, handling permission requests and position streaming while exposing platform-specific settings alongside standard location options.

_geolocator\web/lib · high confidence

Windows example app for Geolocator

An example application for the Geolocator plugin on Windows has been added, providing a user interface to demonstrate core location features. Users can now test retrieving the current and last known positions, monitor location accuracy, and manage location service permissions directly within a Windows environment.

_geolocator\windows/example · high confidence

iOS and macOS location plugin initialization

The geolocator\_apple package introduces the native iOS and macOS implementation for the geolocator plugin. This includes the core plugin registration, permission handling, and location service management via Objective-C handlers. Key features include support for background location updates, accuracy authorization requests (iOS 14+), and the inclusion of a privacy manifest for App Store compliance. The implementation also adds support for macOS, using \requestAlwaysAuthorization\ and handling location settings specific to Apple platforms.

_geolocator\apple · high confidence

Removals

Removal of Android example project files

The Android example project files, including the AndroidManifest.xml, MainActivity.java, and .gitignore, have been deleted from the example/android directory. This removes the specific Android configuration and entry point code for the geolocator example app.

example/android · high confidence

Removal of FlutterGeolocator class implementation

The \FlutterGeolocator\ class, which previously provided static methods for retrieving the current position and listening to position change streams via platform channels, has been removed from the library. This deletion eliminates the core API for accessing device location data in this package.

lib · high confidence

Removal of iOS Geolocator plugin implementation

The iOS-specific implementation for the geolocator plugin has been removed. This includes the deletion of the Objective-C registration file (FlutterGeolocatorPlugin.m) and the Swift plugin class (SwiftFlutterGeolocatorPlugin.swift), which previously handled method channel communication and returned the iOS system version. Consequently, the iOS platform is no longer supported by this plugin in its current state.

ios · high confidence

Removal of legacy Flutter Geolocator example app

The example application located in example/lib/main.dart has been removed. This file contained the previous implementation of the Flutter Geolocator plugin, including the main entry point, state management for position updates, and the user interface displaying the current location. Its deletion indicates that the example app is no longer maintained or has been replaced by a different structure in this location.

example/lib · high confidence

Removal of legacy Position model class

The \Position\ model class in \lib/models/position.dart\ has been removed from the codebase. This class previously handled the deserialization of location data from platform messages via a \fromMap\ method, including default values for optional fields like altitude and accuracy. Its deletion suggests a refactoring of how location data is structured or passed between the Dart layer and native platform implementations.

lib/models · high confidence

Removed legacy Android geolocator plugin implementation

The Android source files for the \flutter\_geolocator\ plugin (including \FlutterGeolocatorPlugin.java\, \LocationMapper.java\, and \AndroidManifest.xml\) have been deleted. This removes the legacy Java-based implementation that handled location permissions and fused location provider interactions, likely as part of a migration to a new plugin structure or platform channel approach.

android · high confidence

Behavioural changes

Add integer-to-permission conversion extension

A new extension method \toLocationPermission()\ is now available on integer values, allowing native platform permission codes (0–3) to be safely converted into the corresponding \LocationPermission\ enum values (\denied\, \deniedForever\, \whileInUse\, \always\). This simplifies handling permission status updates from native platforms by providing a direct mapping and throwing an \InvalidPermissionException\ for unrecognized codes.

_geolocator\_platform\interface/lib/src/extensions · high confidence

Android example app migrated to Flutter V2 embedding

The Android example application has been updated to use the Flutter V2 Android embedding. This migration introduces a new \MainActivity\ that extends \FlutterActivity\, updates the \AndroidManifest.xml\ to include the \flutterEmbedding\ v2 metadata, and adds a \NormalTheme\ for the application window. Additionally, the app now explicitly declares the \FOREGROUND\_SERVICE\_LOCATION\ permission alongside existing location permissions, and includes standard debug/profile manifests for internet access.

geolocator/example/android · high confidence

Android example app updates to Gradle 9.1.0 and adds foreground location permissions

The geolocator\_android example app has been updated to use Gradle 9.1.0 and now includes the FOREGROUND\_SERVICE\_LOCATION and FOREGROUND\_SERVICE permissions in its AndroidManifest.xml to support foreground location services.

_geolocator\android · high confidence

Android location service implementation refactored for foreground support and stability

The Android platform code has been restructured to introduce a dedicated foreground service (GeolocatorLocationService) for location updates, replacing the previous activity-bound approach. This change enables reliable background location tracking on modern Android versions by managing a persistent foreground notification and wake locks. The refactoring also improves stability by fixing service lifecycle issues, such as preventing activity leaks and ensuring proper unbinding of the service connection, while introducing new error handling and notification configuration options for users.

_geolocator\android/android · high confidence

Enhanced Position model with accuracy flags and new LocationSettings configuration

The location data model now distinguishes between a measured zero value and an unmeasured placeholder for accuracy, altitude, heading, and speed by introducing boolean flags (hasAccuracy, hasAltitude, hasAltitudeAccuracy, hasHeading, hasHeadingAccuracy, hasSpeed, hasSpeedAccuracy) alongside their respective numeric fields. This prevents users from incorrectly treating unavailable data as valid zero measurements. Additionally, the Position class now includes optional floor, altitude accuracy, heading accuracy, and speed accuracy fields, as well as an isMocked indicator. A new LocationSettings class allows configuration of location accuracy, distance filter, and time limit for location updates.

_geolocator\_platform\interface/lib/src/models · high confidence

Export geolocator platform interface components

The geolocator\_platform\_interface library now exposes its internal source files (enums, errors, geolocator platform interface, extensions, and models) through a single entry point, allowing consumers to import these specific components directly from the main library file.

_geolocator\_platform\interface/lib · high confidence

Introduction of specific exception types for geolocation errors

The geolocator platform interface now exposes distinct exception classes to provide clearer error handling for users. New types include ActivityMissingException for Android background context issues, AlreadySubscribedException when multiple position streams are active, InvalidPermissionException for unknown permission values, LocationServiceDisabledException when device services are off, PermissionDefinitionsNotFoundException for missing manifest/plist entries, PermissionDeniedException for user-denied access, PermissionRequestInProgressException for overlapping requests, and PositionUpdateException for general update failures. These are exported via the errors.dart barrel file.

_geolocator\_platform\interface/lib/src/errors · high confidence

New example app for Android geolocator features

The example application for the Android geolocator plugin has been replaced with a new implementation. This update introduces a modern UI using the Baseflow plugin template and demonstrates specific Android capabilities, including location accuracy retrieval, temporary full accuracy requests, and service status monitoring, providing users with a clearer reference for integrating these features.

_geolocator\android/example · high confidence

Refactored web geolocation with abstracted permission and geolocation managers

The web platform implementation has been restructured to separate concerns into abstract interfaces and specific HTML-based implementations. A new \GeolocationManager\ interface and \HtmlGeolocationManager\ implementation now handle position retrieval and watching, supporting \maximumAge\ for cached positions. Additionally, a \PermissionsManager\ interface and \HtmlPermissionsManager\ implementation abstract the browser's Permission API for querying geolocation access status. Utility functions in \utils.dart\ handle the conversion of browser-specific objects to the common \Position\ and \LocationPermission\ types, ensuring consistent behavior across the platform.

_geolocator\web/lib/src · high confidence

Removal of legacy iOS Runner configuration files

The example iOS project has removed the \AppDelegate.swift\, \Runner-Bridging-Header.h\, and \.gitignore\ files. This eliminates the manual plugin registration logic and associated build artifacts, indicating a shift to a newer iOS project structure or tooling that handles these aspects automatically.

example/ios · high confidence

Test coverage

Added tests for LocationAccuracy and LocationPermission enum values; Added tests for Position model equality and unmeasured value handling; Added tests for integer-to-permission extension; Added unit tests for MethodChannelGeolocator implementation; Added unit tests for geolocator error exceptions; Added unit tests for geolocator\_web plugin; Added unit tests for the Linux geolocator implementation; Added unit tests for the geolocator platform interface; Removed example widget test.

Dependencies

Geolocator plugin suite updated to version 14.0.3 with platform-specific dependency bumps

The geolocator plugin and its platform implementations have been updated to version 14.0.3, raising the Dart SDK constraint to ^3.5.0 across all packages. This release includes significant dependency updates: geolocator\_android now depends on geolocator\_platform\_interface ^4.1.0 and uses Android Gradle Plugin 9.0.1 with androidx.core:core 1.16.0 and play-services-location 21.2.0; geolocator\_apple is updated to version 2.3.14; geolocator\_web is updated to 4.1.4 with web ^1.0.0; geolocator\_linux is updated to 0.2.6 with package\_info\_plus ^10.0.0; and geolocator\_windows is updated to 0.2.5. The example apps have been migrated to the new Flutter plugin structure with updated Gradle configurations and SDK constraints.

(dependencies) · high confidence

Geolocator updated to version 14.0.3 with dependency bumps

The geolocator package has been updated to version 14.0.3, which includes updates to its federated platform dependencies: geolocator\_platform\_interface to 4.2.8, geolocator\_android to 5.0.3, geolocator\_apple to 2.3.14, geolocator\_linux to 0.2.6, geolocator\_web to 4.1.4, and the linter tool flutter\_lints to 6.0.0.

geolocator · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Baseline

  • First survey — no prior run to compare against. CAI 67.

Lenses

  • Code Health 96
  • Architecture 100
  • Maturity 52
  • Readiness 77
  • Security 70
  • Domain Modelling 100

Changes since last survey

  • 300 commits — 257 feature/other, 43 fixes

By area

  • geolocator_android/CHANGELOG.md — 35 commits
  • geolocator/CHANGELOG.md — 32 commits
  • geolocator_android/android — 27 commits
  • geolocator_apple/CHANGELOG.md — 18 commits
  • geolocator_platform_interface/CHANGELOG.md — 18 commits
  • .github/workflows — 17 commits
  • geolocator/example — 15 commits
  • geolocator/README.md — 13 commits
  • geolocator_android/example — 9 commits
  • geolocator_apple/example — 9 commits
  • geolocator_linux/CHANGELOG.md — 8 commits
  • geolocator_linux/pubspec.yaml — 8 commits
  • geolocator_linux/example — 6 commits
  • geolocator_platform_interface/lib — 6 commits
  • geolocator_web/CHANGELOG.md — 6 commits
  • geolocator_windows/CHANGELOG.md — 6 commits
  • geolocator_android/pubspec.yaml — 5 commits
  • geolocator_apple/apple — 5 commits
  • geolocator_apple/ios — 5 commits
  • geolocator_web/example — 5 commits

Notable commits

  • fix: - fixed an issue where the is service location would fail an not report anything (#1184)
  • fix: Android API Level 31 deprecation fixes (#830)
  • fix: Bug fix to unbind the Android service connection (#1002)
  • fix: Fix 1341 (#1343)
  • fix: Fix Android (#905)
  • fix: Fix Nullpointer in getLocationAccuracy on Android (#1108)
  • fix: Fix activity type propagation (#1271)
  • fix: Fix android deprecation warnings (#1648)
  • fix: Fix build error and warnings (#1340)
  • fix: Fix cast exception (#906)
  • fix: Fix deprecation warning and move Android compile arguments (#1131)
  • fix: Fix format mistake in CHANGELOG
  • fix: Fix geolocator_web (#921)
  • fix: Fix inaccurate location readings (#1324)
  • fix: Fix position property bug (#1415)
  • fix: Fix symbolic links (#984)
  • fix: Fix unsafe service cast (#1025)
  • fix: Fix: iOS location manager background geolocation settings overridden by getCurrentPosition (#1169)
  • fix: Fixed deprecation warning
  • fix: Fixed deprecation warning in example
  • …and 280 more

Architecture

  • 0 containers · 1 bounded contexts · 0 dependency edges (baseline)

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

Baseflow/flutter-geolocator was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 19 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 209f35634ec7616cf822f8854a109b1f7782941a — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-13a154b7f5d1.