title: NSUbiquitousKeyValueStore failing on macOS Sierra
body: <p>When I call NSUbiquitousKeyValueStore's synchronize method after running my app directly from Xcode on macOS Sierra, it returns false and following error is printed in Console.app:</p>
  
  <blockquote>
    <p>Refusing TCCAccessRequest for service kTCCServiceUbiquity from client
    com.apple.dt.Xcode in background session</p>
  </blockquote>
  
  <p>As far as I can tell, changed keys are not saved to iCloud. They are remembered in memory locally but lost after app re-launch.</p>
  
  <p>I believe all my entitlements are set correctly (iCloud KVS enabled in Capabalities of the project, all checked). Do I need to archive &amp; export my app in order to debug / test iCloud on macOS? </p>
  
  <p>Any ideas how to fix / workaround this? </p>