Skip to content

Conversation

@dkhawk
Copy link
Collaborator

@dkhawk dkhawk commented Nov 5, 2025

Fixes a crash where IllegalStateException: Method addObserver must be called on the main thread was thrown during Google Maps initialization on certain Android devices after upgrading the library. This addresses the issue reported in #789.

Fixes #792 🦕

…zation

Fixes a crash where `IllegalStateException: Method addObserver must be called on the main thread`
was thrown during Google Maps initialization on certain Android devices after
upgrading the library. This addresses the issue reported in #789.
@googlemaps-bot
Copy link
Contributor

Code Coverage

There is no coverage information present for the Files changed

kikoso and others added 2 commits November 14, 2025 17:11
Replaced GlobalScope with a custom CoroutineScope in MapsComposeApplication to ensure better lifecycle management for coroutines. Also clarified the comment regarding SDK initialization.
Copy link
Collaborator Author

@dkhawk dkhawk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dkhawk dkhawk merged commit f606fd9 into main Nov 14, 2025
9 checks passed
@dkhawk dkhawk deleted the fix/more-initialization-improvements branch November 14, 2025 20:37
googlemaps-bot pushed a commit that referenced this pull request Nov 14, 2025
## [6.12.2](v6.12.1...v6.12.2) (2025-11-14)

### Bug Fixes

* Address exception on main thread during map initialization ([#793](#793)) ([f606fd9](f606fd9))
@googlemaps-bot
Copy link
Contributor

🎉 This PR is included in version 6.12.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants