title: Why does NSOperation disable automatic key-value observing?
body: <p>When working with a custom <code>NSOperation</code> subclass I noticed that the automatic key-value observing is disabled by the <code>[NSOperation automaticallyNotifiesObserversForKey]</code> class method (which returns <code>NO</code> at least for some key paths). Because of that the code inside of <code>NSOperation</code> subclasses is littered by manual calls to <code>willChangeValueForKey:</code> and <code>didChange…</code>, as visible in many code samples on the web.</p>
  
  <p>Why does <code>NSOperation</code> do that? With automatic KVO support people could simply declare properties for the operation lifecycle flags (<code>isExecuting</code> etc.) and trigger the KVO events through the accessors, ie. the following code:</p>
  
  <pre><code>[self willChangeValueForKey:@"isExecuting"];
  executing = NO;
  [self didChangeValueForKey:@"isExecuting"];
  [self willChangeValueForKey:@"isFinished"];
  finished = YES;
  [self didChangeValueForKey:@"isFinished"];
  </code></pre>
  
  <p>…could be replaced by this:</p>
  
  <pre><code>[self setIsExecuting:NO];
  [self setIsFinished:YES];
  </code></pre>
  
  <p>Is there a catch somewhere? I just overrode the <code>automaticallyNotifiesObserversForKey</code> to return <code>YES</code> and things seem to work fine.</p>