[@nativescript/geolocation] iOS - This method can cause UI unresponsiveness if invoked on the main thread. Instead, consider waiting for the `-locationManagerDidChangeAuthorization:` callback and checking `authorizationStatus` first.

Open
#604 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
ios, typescript
Domain
mobile-dev

Research direction

Start by locating the iOS implementation for @nativescript/geolocation and the CoreLocation authorization call mentioned in the warning. Compare its behavior with the locationManagerDidChangeAuthorization callback and authorizationStatus check; done means the warning is addressed without breaking location permission handling.

Written by the indexing model from the issue text.

Description

CoreLocation - This method can cause UI unresponsiveness if invoked on the main thread. Instead, consider waiting for the -locationManagerDidChangeAuthorization: callback and checking authorizationStatus first.

Has Apple changed something that means it doesn't like this Library anymore?

In my application my Info.plist looks like this

   <key>NSLocationAlwaysAndWhenInUseUsageDescription</key>
    <string>Tracks your location and delivery accuracy</string>
    <key>UIBackgroundModes</key>
    <array>
      <string>location</string>
    </array>

I am using @nativescript/geolocation 9.0.0

Is there a plan to move this off the main thread? or can I do something to ensure it doesn't execute on the main thread?

Dominant language
TypeScript
Stars
206
Forks
123
Avg merge
2d 1h
Merged PRs (30d)
1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from NativeScript/plugins

All issues in NativeScript/plugins

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.