iOS-Extension-Demo icon indicating copy to clipboard operation
iOS-Extension-Demo copied to clipboard

crash with error "Cannot create an SQL store with a nil URL."

Open ghost opened this issue 10 years ago • 4 comments

When running DemoNotes on iOS 8.3 and 8.1 simulator, it crashes with "Cannot create an SQL store with a nil URL.". Am I missing some setting or is the app still buggy? I am using Xcode 6.3.1

ghost avatar Apr 30 '15 08:04 ghost

That error probably means you haven't configured app groups for the app, or the extension, or both. It's a necessary part of creating the URL where the persistent store file goes.

atomicbird avatar Apr 30 '15 17:04 atomicbird

Thanks for the information, would be good to have that in the readme-file. I set up the app group now and added it both for DemoNotes and the two extensions in the xcode project. Still I get the above error. Am I still missing something?

ghost avatar May 04 '15 11:05 ghost

Have the same issue.. Are we missing something?

vicchirino avatar May 07 '15 18:05 vicchirino

The only thing I know of that would cause a nil URL would be app groups not being configured properly. That means:

  • Turning on app groups in the project settings for the app and for all extensions
  • Making sure to use the correct app group name when calling containerURLForSecurityApplicationGroupIdentifier: (which I think is only in DemoSharedCode/DemoNoteManager.m).

I should update the README. I was thinking of this project as code people could use for reference, not as anything people would actually download and run as-is.

atomicbird avatar May 07 '15 18:05 atomicbird