Questions tagged [watchos-2]

watchOS 2 is the second version of Apple's operating system for Apple Watch and is the successor to watchOS. It was announced at the company's Apple Worldwide Developers Conference (WWDC) on June 8, 2015, and was released on September 21, 2015.

WatchOS 2 is Apple's operating system for the Apple Watch. It was introduced on June 8th at the Worldwide Developer Conference (WWDC) 2015.

WatchOS 2 brings many new features and improvements, some of which are:

  • Standalone Apps for the Watch
  • Connecting to known Wireless Networks
  • Complications
  • Time Travel
  • Clock Kit

WatchOS 2 was released to the general public on September 21, 2015 along with iOS 9.

You can find more information here.

839 questions
39
votes
4 answers

Detecting available API iOS vs. watchOS in Swift

#available does not seem to work when differentiating between watchOS and iOS. Here is an example of code shared between iOS & watchOS: lazy var session: WCSession = { let session = WCSession.defaultSession() session.delegate = self …
Cezar
  • 690
  • 1
  • 8
  • 17
38
votes
1 answer

secTaskDiagnoseEntitlements MISSING keychain entitlements: no stored taskRef found

In two applications which have WatchKit app extensions, I receive the following error in the device log more than ten times on startup. secTaskDiagnoseEntitlements MISSING keychain entitlements: no stored taskRef found Folks over at the Apple…
Justin Domnitz
  • 3,217
  • 27
  • 34
33
votes
2 answers

Where and When to get data for Watch Complication

After working with complications for a few days, I feel confident saying the following about the update process for updates that happen at a prescribed interval: The system calls requestedUpdateDidBegin() This is where you can determine if your…
El Tea
  • 1,206
  • 12
  • 21
29
votes
2 answers

Using Core Data with watchOS 2.0

I made an iOS/Apple Watch app with WatchKit 1.0 that uses a shared group container and a custom framework to access the same Core Data store. Now, in the transition guide for watchOS 2.0, Apple says this: If your existing Watch app and iOS app use…
Becky Hansmeyer
  • 712
  • 6
  • 24
27
votes
2 answers

iOS get heart rate from Apple Watch in near real time

I need to make an app that records heart rate data in near real time and send this data to a server as soon as possible. First I took this approach: Watch os 2.0 beta: access heart beat rate In fact it is working fine. There is new heart rate data…
user2529173
  • 1,884
  • 6
  • 30
  • 43
24
votes
1 answer

iTunes Connect - Invalid Swift Support - The Watch OS application has Swift libraries at both

After archiving and uploading my app (using Xcode 7.2.1) to iTunes Connect I receive an email from iTunes Connect saying: Invalid Swift Support - The Watch OS application has Swift libraries at both /Payload/Today's …
Steffen D. Sommer
  • 2,896
  • 2
  • 24
  • 47
24
votes
3 answers

WatchOS: Should UI updates from the extension be called on the main thread?

For iOS apps, UI updating is done from the main thread exclusively - not doing so is never recommended and can lead to unexpected behaviour. In watchOS, the OS is structured with a watch extension, and an app - as different 'containers'. Usually, UI…
Jordan Smith
  • 10,310
  • 7
  • 68
  • 114
24
votes
13 answers

WCSession sendMessage:replyHandler error code 7014 (WCErrorCodeDeliveryFailed)

I have a Watch OS 2 application that communicates with the iOS app via WCSession method sendMessage:replyHandler:errorHandler: The iOS application reply correctly but time to time I get the error with code 7014 of domain WCErrorDomain: "Payload…
gsempe
  • 5,371
  • 2
  • 25
  • 29
23
votes
5 answers

NSUserDefaults not working on Xcode beta with Watch OS2

I just installed the latest beta of Xcode to try Swift 2 and the improvements made to the Apple Watch development section. I'm actually having an hard time figuring out WHY this basic NSUserDefaults method to share informations between iOS and Watch…
Sara Canducci
  • 6,231
  • 5
  • 19
  • 24
22
votes
2 answers

What is the flow for updating complication data for Apple Watch?

I've been following a lot of tutorials on the internet to learn how to set up the complication. I have no problem getting the complication set up as expected. Until the initial timeline entries expire. After 12 hours, I do not know how to update it…
swiftyboi
  • 2,965
  • 4
  • 25
  • 52
20
votes
1 answer

How to get the current location in watchOS 2?

I need to fetch the user current location for the WatchKit App in watchOS 2. How do I do this?
Jyothi
  • 384
  • 1
  • 3
  • 10
20
votes
2 answers

Xcode 7 supporting watch OS1 and OS2

I have been fiddling with Xcode 7 for sometime now, I get to know that it supports only Swift 2 and there is no way to support Swift 1.0 or 1.2 in Xcode 7. This is fine. Now coming to WatchOS, can I have two targets one for WatchOS1 and one for…
Satheesh
  • 10,998
  • 6
  • 50
  • 93
19
votes
4 answers

Cannot run app on real Apple Watch

my configuration: Apple Watch (WatchOS 2.0.1), iPhone 5S (iOS 9.1) Xcode 7.1 on MacOS X El Capitan. I can run my app on the iPhone just fine. However, when I try to run my app on the Apple Watch, it seems like it's not possible. What I see in the…
ajpallares
  • 777
  • 4
  • 16
18
votes
3 answers

WatchOS Unit Testing

I am building an app for Apple Watch and want to write a simple unit test. I looked around and didn't find a single way to add a unit testing bundle for watchOS code. Xcode supports unit tests for iOS, macOS and even tvOS but not for watchOS. Has…
sam
  • 3,441
  • 2
  • 33
  • 42
16
votes
3 answers

How to prevent the Apple Watch from going to sleep?

We are working on an Apple Watch project, but the watch goes to sleep if uninterrupted with. Is there any way to prevent it from going to sleep?
user3229261
  • 169
  • 1
  • 7
1
2 3
55 56