On Oct 20, 2012, at 1:15 PM, Koen van der Drift <koenvanderdr...@gmail.com> 
wrote:

> 
> On Oct 20, 2012, at 12:53 PM, Gary L. Wade <garyw...@desisoftsystems.com> 
> wrote:
> 
>> At the time when you call waitUntilAllOperationsAreFinished, no operations 
>> have been added, so there's nothing to wait on. Add the operation to the 
>> queue first and then call wait.
>> --
> 
> I tried that too, but then it just stays in the operation and never finishes:
> 
> start import
> begin of importRecords in operation
> 
> and nothing else, it just sits there.
> 
> - Koen.

So it hans, because inside my import code is the following:

            dispatch_sync(dispatch_get_main_queue(), ^{
                AppDelegate *appController = [[NSApplication sharedApplication] 
delegate];
                NSManagedObjectContext  *mainContext = [appController 
managedObjectContext];
                
                NSLog(@"test");


which was suggested in another question I had to be able to call 
executeFetchRequest on the mainContext from another thread.

Maybe that doesn't work well with calling waitUntilFinished?

- Koen.
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to