-com.apple.CoreData.ConcurrencyDebug 1 not working in FileProvider extensions

I discovered a multithreading mistake in my use of NSManagedObjects recently and was surprised that I wasn't alerted to this during development, since I had -com.apple.CoreData.ConcurrencyDebug 1 set under "arguments passed on launch" for my macOS and iOS FileProvider extensions. I confirmed that the expected log stating CoreData: annotation: Core Data multi-threading assertions enabled. is NOT present when running these targets (but does appear as expected on my main macOS and iOS applications).

Can anyone advise me on how to get this concurrency debugging functionality to work on my FileProvider extension(s)?

Thanks

Post not yet marked as solved Up vote post of SuperLinkMan Down vote post of SuperLinkMan
492 views

Replies

--You Can Check the typos in com.apple.CoreData.ConcurrencyDebug Make sure there are no typos or spaces that might be causing the argument to not be passed correctly. -- Clean Your Project And Rebuild It Maybe Sometime it causes problem -- Ensure that you are setting up your Core Data stack correctly in your FileProvider extension targets. Make sure you're using the appropriate concurrency types for your managed object contexts. -- It's possible that the debug log output is not being shown due to log verbosity settings. Make sure your logging settings are set to show debug messages. You can adjust the log level in Xcode by navigating to "Product" > "Scheme" > "Edit Scheme" and selecting "Run" from the left-hand menu. Then, under the "Arguments" tab, ensure that "OS_ACTIVITY_MODE" is set to "default". -- If you are explicitly configuring Core Data's stack or contexts in your FileProvider extension, ensure that you're not accidentally overriding or suppressing the debugging settings somewhere in your code. -- Make sure you are using a version of Xcode and iOS/macOS that are compatible with the Core Data concurrency debugging features. Newer versions of Xcode or iOS/macOS might introduce changes that affect debugging behavior.

well these things might help you

  • Thanks for the suggestions. Fortunately I have the concurrency debugging working in my main application targets for both platforms and my entire Core Data stack is in a shared framework between them all, so it makes it easier to rule out some potential issues. I've checked all of these suggestions and none of them resolve the issue for me. Have you had this feature work for you in any kind of application extension - I haven't been able to find out if this feature works at all in extensions.

  • least you can try

Add a Comment