multithreading - NSProgressIndicator built-in animation raises CA_ASSERT_MAIN_THREAD_TRANSACTIONS -


this looks bug in either nsprogressindicator or xcode 9 me:

  • run xcode 9 beta 1 or beta 4, in macos 10.12.6.
  • file > new project, macos, cocoa app, objective-c or swift, arc or not, no storyboards, latest (10.13) sdk.
  • in app target's environment, set ca_assert_main_thread_transactions=1.
  • in app delegate, add iboutlet progressindicator.
  • in nib, add nsprogressindicator window, connect outlet. leave checkbox indeterminate switched on.
  • in -applicationdidfinishlaunching, call -startanimation: on progressindicator.
  • build , run.

expected result:

progress indicator should happily show indeterminate progress, because did on main thread.

actual result:

app crashes, citing ca_assert_main_thread_transactions, when -startanimation: called.

you can see in tiny demo project.

did wrong? expected result incorrect?

p.s. asked on apple's developer forums, still awaiting moderator approval after 2 working days, deleted , came here instead :(

update: still lacking explanation, filed apple bug 33593575.

this bug in nsprogressindicator. bug report (thank filing!) marked duplicate of earlier bug, resolved in macos 10.13.


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -