Skip to content

GMUDefaultClusterRenderer uses UIView API off main thread #544

Description

@JamesWBitRip

Calling GMUClusterManager.cluster() from a background queue causes UIKit violations due to GMUDefaultClusterRenderer internally accessing UIView and CALayer properties off the main thread.

Steps to Reproduce:
1. Use GMUDefaultClusterRenderer in a Swift app
2. Call .cluster() from a background queue
3. Observe runtime warnings:
• -[UIView bounds] must be used from main thread only
• -[UIView layer] must be used from main thread only

Suggested Fix:
Ensure all UIKit access in GMUDefaultClusterRenderer is performed on the main thread, or document that .cluster() must be called on the main thread when using GMUDefaultClusterRenderer.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    triage meI really want to be triaged.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions