0

What could be causing this error? I am using Xcode version 8.

/Users/package/workspace/apps-72dfa722-8/cordova/platforms/ios/dcc-mobile-sample/Plugins/cordova.plugins.diagnostic/Diagnostic.m:826:25: error: no known class method for selector 'isPedometerEventTrackingAvailable' return [CMPedometer isPedometerEventTrackingAvailable]; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/package/workspace/apps-72dfa722-8/cordova/platforms/ios/dcc-mobile-sample/Plugins/cordova.plugins.diagnostic/Diagnostic.m:826:12: warning: incompatible pointer to integer conversion returning 'id' from a function with result type 'BOOL' (aka 'signed char') [-Wint-conversion] return [CMPedometer isPedometerEventTrackingAvailable]; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 2 warnings and 1 error generated.

1
  • Looks like issue is with accessing iOS CMPedometer/Core Motion API from Cordova. Commented Dec 12, 2016 at 16:50

1 Answer 1

1

The issue is with cordova-plugin-diagnostic, the latest version of which adds support for new functionality in iOS 10 - see this issue.

  • Make double sure you are building with XCode 8 for iOS 10
  • Ensure that you're using an up-to-date version of cordova-ios platform - latest is @4.3.1. Check with cordova platform ls
  • Ensure that Core Motion framework is present in your Xcode project - if not, add it.
  • Try building and running the plugin example project
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.