(lldb) bt all thread #1, queue = 'com.apple.main-thread' frame #0: 0x00000001b40ee8c4 libsystem_kernel.dylib`mach_msg_trap + 8 frame #1: 0x00000001b40edcc8 libsystem_kernel.dylib`mach_msg + 72 frame #2: 0x000000018971874c CoreFoundation`__CFRunLoopServiceMachPort + 376 frame #3: 0x0000000189712bd0 CoreFoundation`__CFRunLoopRun + 1176 frame #4: 0x0000000189712200 CoreFoundation`CFRunLoopRunSpecific + 572 frame #5: 0x000000019f80d598 GraphicsServices`GSEventRunModal + 160 frame #6: 0x000000018bfd8004 UIKitCore`-[UIApplication _run] + 1052 frame #7: 0x000000018bfdd5d8 UIKitCore`UIApplicationMain + 164 frame #8: 0x0000000100959dc8 Todo`main at AppDelegate.swift:40:7 frame #9: 0x00000001893f1598 libdyld.dylib`start + 4 thread #3 frame #0: 0x00000001cf07f86c libsystem_pthread.dylib`start_wqthread thread #5 frame #0: 0x00000001cf07f86c libsystem_pthread.dylib`start_wqthread thread #6, name = 'com.apple.uikit.eventfetch-thread' frame #0: 0x00000001b40ee8c4 libsystem_kernel.dylib`mach_msg_trap + 8 frame #1: 0x00000001b40edcc8 libsystem_kernel.dylib`mach_msg + 72 frame #2: 0x000000018971874c CoreFoundation`__CFRunLoopServiceMachPort + 376 frame #3: 0x0000000189712bd0 CoreFoundation`__CFRunLoopRun + 1176 frame #4: 0x0000000189712200 CoreFoundation`CFRunLoopRunSpecific + 572 frame #5: 0x000000018a91c278 Foundation`-[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 228 frame #6: 0x000000018a91c158 Foundation`-[NSRunLoop(NSRunLoop) runUntilDate:] + 88 frame #7: 0x000000018c0839fc UIKitCore`-[UIEventFetcher threadMain] + 504 frame #8: 0x000000018aa78c48 Foundation`__NSThread__start__ + 848 frame #9: 0x00000001cf07ab70 libsystem_pthread.dylib`_pthread_start + 288 thread #7, queue = 'com.apple.root.user-initiated-qos' frame #0: 0x00000001980a84e8 libsystem_malloc.dylib`tiny_free_list_add_ptr + 176 frame #1: 0x00000001980a911c libsystem_malloc.dylib`tiny_free_no_lock + 548 frame #2: 0x00000001980aa3f0 libsystem_malloc.dylib`free_tiny + 352 frame #3: 0x000000018a92a098 Foundation`-[NSConcreteMapTable dealloc] + 108 frame #4: 0x000000019cfde584 libobjc.A.dylib`AutoreleasePoolPage::releaseUntil(objc_object**) + 200 frame #5: 0x000000019cfde460 libobjc.A.dylib`objc_autoreleasePoolPop + 208 frame #6: 0x00000001024495dc libdispatch.dylib`_dispatch_last_resort_autorelease_pool_pop + 40 frame #7: 0x000000010245b540 libdispatch.dylib`_dispatch_root_queue_drain + 1432 frame #8: 0x000000010245ba48 libdispatch.dylib`_dispatch_worker_thread2 + 152 frame #9: 0x00000001cf07c568 libsystem_pthread.dylib`_pthread_wqthread + 212 thread #9, name = 'Timer (Couchbase Lite Core)' frame #0: 0x00000001b411172c libsystem_kernel.dylib`__psynch_cvwait + 8 frame #1: 0x00000001cf077c88 libsystem_pthread.dylib`_pthread_cond_wait$VARIANT$armv81 + 1180 frame #2: 0x000000019d05bea4 libc++.1.dylib`std::__1::condition_variable::__do_timed_wait(std::__1::unique_lock&, std::__1::chrono::time_point > >) + 96 frame #3: 0x0000000101061208 CouchbaseLiteSwift`std::__1::cv_status std::__1::condition_variable::wait_for >(this=0x00000002808647a8, __lk=0x000000016f566ef8, __d=0x000000016f566de0) at __mutex_base:468:9 frame #4: 0x0000000101060f00 CouchbaseLiteSwift`void std::__1::condition_variable::__do_timed_wait(this=0x00000002808647a8, __lk=0x000000016f566ef8, __tp=time_point > > @ 0x000000016f566df8) at __mutex_base:523:5 frame #5: 0x000000010105e38c CouchbaseLiteSwift`std::__1::cv_status std::__1::condition_variable::wait_until > >(this=0x00000002808647a8, __lk=0x000000016f566ef8, __t=0x000000016f566ec0) at __mutex_base:426:5 frame #6: 0x000000010105df98 CouchbaseLiteSwift`litecore::actor::Timer::Manager::run(this=0x0000000280864750) at Timer.cc:68:28 frame #7: 0x000000010105fd70 CouchbaseLiteSwift`litecore::actor::Timer::Manager::Manager(this=0x0000000283868c18)::$_0::operator()() const at Timer.cc:34:24 frame #8: 0x000000010105fd0c CouchbaseLiteSwift`decltype(__f=0x0000000283868c18)::$_0>(fp)()) std::__1::__invoke(litecore::actor::Timer::Manager::Manager()::$_0&&) at type_traits:3747:1 frame #9: 0x000000010105fb84 CouchbaseLiteSwift`void std::__1::__thread_execute >, litecore::actor::Timer::Manager::Manager()::$_0>(__t=size=2, (null)=__tuple_indices<> @ 0x000000016f566f6f)::$_0>&, std::__1::__tuple_indices<>) at thread:280:5 frame #10: 0x000000010105f210 CouchbaseLiteSwift`void* std::__1::__thread_proxy >, litecore::actor::Timer::Manager::Manager()::$_0> >(__vp=0x0000000283868c10) at thread:291:5 frame #11: 0x00000001cf07ab70 libsystem_pthread.dylib`_pthread_start + 288 thread #10, name = 'com.apple.CFStream.LegacyThread' frame #0: 0x00000001b40ee8c4 libsystem_kernel.dylib`mach_msg_trap + 8 frame #1: 0x00000001b40edcc8 libsystem_kernel.dylib`mach_msg + 72 frame #2: 0x000000018971874c CoreFoundation`__CFRunLoopServiceMachPort + 376 frame #3: 0x0000000189712bd0 CoreFoundation`__CFRunLoopRun + 1176 frame #4: 0x0000000189712200 CoreFoundation`CFRunLoopRunSpecific + 572 frame #5: 0x00000001897348b4 CoreFoundation`_legacyStreamRunLoop_workThread + 260 frame #6: 0x00000001cf07ab70 libsystem_pthread.dylib`_pthread_start + 288 thread #11, name = 'com.apple.NSURLConnectionLoader' frame #0: 0x00000001b40ee8c4 libsystem_kernel.dylib`mach_msg_trap + 8 frame #1: 0x00000001b40edcc8 libsystem_kernel.dylib`mach_msg + 72 frame #2: 0x000000018971874c CoreFoundation`__CFRunLoopServiceMachPort + 376 frame #3: 0x0000000189712bd0 CoreFoundation`__CFRunLoopRun + 1176 frame #4: 0x0000000189712200 CoreFoundation`CFRunLoopRunSpecific + 572 frame #5: 0x0000000189f9c9a4 CFNetwork`___lldb_unnamed_symbol11120$$CFNetwork + 552 frame #6: 0x000000018aa78c48 Foundation`__NSThread__start__ + 848 frame #7: 0x00000001cf07ab70 libsystem_pthread.dylib`_pthread_start + 288 * thread #12, queue = 'COUCHBASE_DB_QUEUE', stop reason = EXC_BAD_ACCESS (code=1, address=0x2108a5544a48) frame #0: 0x00000001010c3e50 CouchbaseLiteSwift`std::__1::__hash_node_base*>::__hash(this=0x00002108a5544a40) const at __hash_table:87:55 frame #1: 0x00000001010c392c CouchbaseLiteSwift`std::__1::pair*>, bool> std::__1::__hash_table, std::__1::equal_to, std::__1::allocator >::__emplace_unique_key_args(this=0x000000010ad0cb30, __k=0x000000016f939c00, __args=0x000000016f939c00) at __hash_table:2117:24 frame #2: 0x00000001010c382c CouchbaseLiteSwift`std::__1::__hash_table, std::__1::equal_to, std::__1::allocator >::__insert_unique(this=0x000000010ad0cb30, __x=0x000000016f939c00) at __hash_table:1165:16 frame #3: 0x00000001010c37bc CouchbaseLiteSwift`std::__1::unordered_set, std::__1::equal_to, std::__1::allocator >::insert(this=0x000000010ad0cb30 size=3, __x=0x000000016f939c00) at unordered_set:577:26 * frame #4: 0x00000001010c3408 CouchbaseLiteSwift`litecore::DataFile::registerQuery(this=0x000000010ad0ca80, query=0x0000000280f5c180) at DataFile.hh:121:59 frame #5: 0x00000001010c3388 CouchbaseLiteSwift`litecore::Query::Query(this=0x0000000280f5c180, keyStore=0x000000010a80bdc0, expression=slice @ 0x000000016f939c90, language=kJSON) at Query.cc:37:29 frame #6: 0x0000000100fa0120 CouchbaseLiteSwift`litecore::SQLiteQuery::SQLiteQuery(this=0x0000000280f5c180, keyStore=0x000000010a80bdc0, queryStr=slice @ 0x000000016f93a128, language=kJSON) at SQLiteQuery.cc:59:10 frame #7: 0x0000000100f9f158 CouchbaseLiteSwift`litecore::SQLiteQuery::SQLiteQuery(this=0x0000000280f5c180, keyStore=0x000000010a80bdc0, queryStr=slice @ 0x000000016f93a180, language=kJSON) at SQLiteQuery.cc:60:9 frame #8: 0x0000000100f9f0e4 CouchbaseLiteSwift`litecore::SQLiteKeyStore::compileQuery(this=0x000000010a80bdc0, selectorExpression=slice @ 0x000000016f93a1f8, language=kJSON) at SQLiteQuery.cc:518:20 frame #9: 0x0000000100f4f7f0 CouchbaseLiteSwift`c4Query::c4Query(this=0x0000000280b65040, db=0x000000010ad0a500, language=kC4JSONQuery, queryExpression=(buf = 0x000000010a088000, size = 60)) at c4Query.hh:42:35 frame #10: 0x0000000100f4f6e0 CouchbaseLiteSwift`c4Query::c4Query(this=0x0000000280b65040, db=0x000000010ad0a500, language=kC4JSONQuery, queryExpression=(buf = 0x000000010a088000, size = 60)) at c4Query.hh:43:5 frame #11: 0x0000000100f4f5e4 CouchbaseLiteSwift`c4query_new2::$_0::operator(this=0x000000016f93a3f0)() const at c4Query.cc:53:31 frame #12: 0x0000000100f4f580 CouchbaseLiteSwift`c4Query* fleece::function_ref::callback_fn(callable=6166914032) at function_ref.hh:59:12 frame #13: 0x0000000100f4f524 CouchbaseLiteSwift`fleece::function_ref::operator(this=0x000000016f93a3b8)() const at function_ref.hh:72:12 frame #14: 0x0000000100f4ae14 CouchbaseLiteSwift`c4Query* c4Internal::tryCatch(outError=0x000000016f93a4b0, fn=function_ref @ 0x000000016f93a3b8)>) at c4ExceptionUtils.hh:60:20 frame #15: 0x0000000100f4ade0 CouchbaseLiteSwift`::c4query_new2(database=0x000000010ad0a500, language=kC4JSONQuery, expression=(buf = 0x000000010a088000, size = 60), outErrorPos=0x0000000000000000, outError=0x000000016f93a4b0) at c4Query.cc:51:12 frame #16: 0x0000000100f4af08 CouchbaseLiteSwift`::c4query_new(database=0x000000010ad0a500, expression=(buf = 0x000000010a088000, size = 60), error=0x000000016f93a4b0) at c4Query.cc:64:12 frame #17: 0x0000000101385db0 CouchbaseLiteSwift`-[CBLQuery check:](self=, _cmd=, outError=) + 232 [opt] frame #18: 0x0000000101385804 CouchbaseLiteSwift`-[CBLQuery execute:](self=0x0000000282ff4840, _cmd=, outError=0x000000016f93a5a8) + 48 [opt] frame #19: 0x0000000100e3445c CouchbaseLiteSwift`Query.execute(self=) at Query.swift:56:47 [opt] frame #20: 0x00000001009423a4 Todo`DBManager.executeQuery(query=0x000000028144f400, self=0x0000000283423b40) at TasksViewController.swift:563:33 frame #21: 0x0000000100941fa8 Todo`DBManager._runQuery(self=0x0000000283423b40) at TasksViewController.swift:534:29 frame #22: 0x0000000100941a0c Todo`closure #1 in DBManager.runQuery(self=0x0000000283423b40) at TasksViewController.swift:521:13 frame #23: 0x0000000100941310 Todo`thunk for @callee_guaranteed () -> () at :0 frame #24: 0x0000000100941334 Todo`thunk for @escaping @callee_guaranteed () -> () at :0 frame #25: 0x00000001024495fc libdispatch.dylib`_dispatch_client_callout + 16 frame #26: 0x0000000102458818 libdispatch.dylib`_dispatch_lane_barrier_sync_invoke_and_complete + 124 frame #27: 0x0000000100941994 Todo`DBManager.runQuery(self=0x0000000283423b40) at TasksViewController.swift:520:17 frame #28: 0x0000000100934ddc Todo`TasksViewController.performDBQuery(self=0x000000010ab128d0) at TasksViewController.swift:59:27 frame #29: 0x0000000100934f4c Todo`closure #1 in TasksViewController.performDBQuery(self=0x000000010ab128d0) at TasksViewController.swift:62:20 frame #30: 0x0000000100928f44 Todo`thunk for @escaping @callee_guaranteed () -> () at :0 frame #31: 0x0000000102447db8 libdispatch.dylib`_dispatch_call_block_and_release + 24 frame #32: 0x00000001024495fc libdispatch.dylib`_dispatch_client_callout + 16 frame #33: 0x000000010244bd98 libdispatch.dylib`_dispatch_queue_override_invoke + 888 frame #34: 0x000000010245b120 libdispatch.dylib`_dispatch_root_queue_drain + 376 frame #35: 0x000000010245ba48 libdispatch.dylib`_dispatch_worker_thread2 + 152 frame #36: 0x00000001cf07c568 libsystem_pthread.dylib`_pthread_wqthread + 212 thread #13 frame #0: 0x00000001cf07f86c libsystem_pthread.dylib`start_wqthread thread #14 frame #0: 0x00000001cf07f86c libsystem_pthread.dylib`start_wqthread (lldb)