`$interval.cancel()` called with a promise that was not generated by `$interval()`.
This error occurs when calling $interval.cancel() with a promise that was not generated by the $interval service. This can, for example, happen when calling then()/catch() on the returned promise, which creates a new promise, and pass that new promise to $interval.cancel().
Example of incorrect usage that leads to this error:
var promise = $interval(doSomething, 1000, 5).then(doSomethingElse);
$interval.cancel(promise);
To fix the example above, keep a reference to the promise returned by $interval() and pass that to $interval.cancel():
var promise = $interval(doSomething, 1000, 5);
var newPromise = promise.then(doSomethingElse);
$interval.cancel(promise);