I'm using custom siri intents in my iOS and Watch app. Before working up to supporting full background execution in the intent extension I'm trying to always use a 'continueInApp' response code in the intent handler in my app extension. This works fine on iOS but on watchOS, the WKExtensionDelegate's handleActivity method is being called twice in quick succession each time I use Siri on the Watch to run my shortcut/intent.
I've tried passing a custom NSUserActivity when creating my response object, and by adding a timestamp in there I'm pretty confident that the intent handler is only being called once. But I see two calls to the handleActivity method in my extension delegate.
I'm not using the handleIntent extension delegate method. That never seems to be called and I suspect it might be for the non-custom SiriKit intents prior to iOS 12.
- (void)handleSelectTimerProfile:(nonnull POMSelectTimerProfileIntent *)intent completion:(nonnull void (^)(POMSelectTimerProfileIntentResponse * _Nonnull))completion
{
completion([[POMSelectTimerProfileIntentResponse alloc] initWithCode:POMSelectTimerProfileIntentResponseCodeContinueInApp
userActivity:nil]);
}
It doesn't seem to matter whether my 'confirm' or 'handle' method uses the continueInApp response code.