Openbullet 1 problem

my pc accidentally shutdown in the middle when openbullet 1 was running and now it not starting with the database

I get this error-

[FATAL][Application.Current.DispatcherUnhandledException] UHANDLED EXCEPTION
System.Windows.Markup.XamlParseException: The invocation of the constructor on type ‘OpenBullet.MainWindow’ that matches the specified binding constraints threw an exception. —> System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary.
at System.Collections.Generic.Dictionary2.get_Item(TKey key) at LiteDB.IndexService.<FindAll>d__13.MoveNext() at LiteDB.LinqExtensions.<>c__DisplayClass2_02.<g___|0>d.MoveNext()
at LiteDB.QueryCursor.Fetch(TransactionService trans, DataService data, BsonReader bsonReader)
at LiteDB.LiteEngine.d__9.MoveNext()
at LiteDB.LiteEngine.d__13.MoveNext()
at LiteDB.LiteCollection1.<Find>d__17.MoveNext() at System.Collections.ObjectModel.ObservableCollection1.CopyFrom(IEnumerable1 collection) at System.Collections.ObjectModel.ObservableCollection1…ctor(IEnumerable1 collection) at OpenBullet.ViewModels.HitsDBViewModel.RefreshList() in C:\projects\openbullet\OpenBullet\ViewModels\HitsDBViewModel.cs:line 131 at OpenBullet.Views.Main.HitsDB..ctor() in C:\projects\openbullet\OpenBullet\Views\Main\HitsDB.xaml.cs:line 48 at OpenBullet.MainWindow..ctor() in C:\projects\openbullet\OpenBullet\MainWindow.xaml.cs:line 235 --- End of inner exception stack trace --- at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, IXamlObjectWriterFactory writerFactory, Boolean skipJournaledProperties, Object rootObject, XamlObjectWriterSettings settings, Uri baseUri) at System.Windows.Markup.WpfXamlLoader.LoadBaml(XamlReader xamlReader, Boolean skipJournaledProperties, Object rootObject, XamlAccessLevel accessLevel, Uri baseUri) at System.Windows.Markup.XamlReader.LoadBaml(Stream stream, ParserContext parserContext, Object parent, Boolean closeStream) at System.Windows.Application.LoadBamlStreamWithSyncInfo(Stream stream, ParserContext pc) at System.Windows.Application.LoadComponent(Uri resourceLocator, Boolean bSkipJournaledProperties) at System.Windows.Application.DoStartup() at System.Windows.Application.<.ctor>b__1_0(Object unused) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs) at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)[FATAL][AppDomain.CurrentDomain.UnhandledException] UHANDLED EXCEPTION System.Windows.Markup.XamlParseException: The invocation of the constructor on type 'OpenBullet.MainWindow' that matches the specified binding constraints threw an exception. ---> System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary. at System.Collections.Generic.Dictionary2.get_Item(TKey key)
at LiteDB.IndexService.d__13.MoveNext()
at LiteDB.LinqExtensions.<>c__DisplayClass2_02.<<DistinctBy>g___|0>d.MoveNext() at LiteDB.QueryCursor.Fetch(TransactionService trans, DataService data, BsonReader bsonReader) at LiteDB.LiteEngine.<Find>d__9.MoveNext() at LiteDB.LiteEngine.<Find>d__13.MoveNext() at LiteDB.LiteCollection1.d__17.MoveNext()
at System.Collections.ObjectModel.ObservableCollection1.CopyFrom(IEnumerable1 collection)
at System.Collections.ObjectModel.ObservableCollection1..ctor(IEnumerable1 collection)
at OpenBullet.ViewModels.HitsDBViewModel.RefreshList() in C:\projects\openbullet\OpenBullet\ViewModels\HitsDBViewModel.cs:line 131
at OpenBullet.Views.Main.HitsDB…ctor() in C:\projects\openbullet\OpenBullet\Views\Main\HitsDB.xaml.cs:line 48
at OpenBullet.MainWindow…ctor() in C:\projects\openbullet\OpenBullet\MainWindow.xaml.cs:line 235
— End of inner exception stack trace —
at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, IXamlObjectWriterFactory writerFactory, Boolean skipJournaledProperties, Object rootObject, XamlObjectWriterSettings settings, Uri baseUri)
at System.Windows.Markup.WpfXamlLoader.LoadBaml(XamlReader xamlReader, Boolean skipJournaledProperties, Object rootObject, XamlAccessLevel accessLevel, Uri baseUri)
at System.Windows.Markup.XamlReader.LoadBaml(Stream stream, ParserContext parserContext, Object parent, Boolean closeStream)
at System.Windows.Application.LoadBamlStreamWithSyncInfo(Stream stream, ParserContext pc)
at System.Windows.Application.LoadComponent(Uri resourceLocator, Boolean bSkipJournaledProperties)
at System.Windows.Application.DoStartup()
at System.Windows.Application.<.ctor>b__1_0(Object unused)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.DispatcherOperation.InvokeImpl()
at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(Object state)
at MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(Object obj)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at MS.Internal.CulturePreservingExecutionContext.Run(CulturePreservingExecutionContext executionContext, ContextCallback callback, Object state)
at System.Windows.Threading.DispatcherOperation.Invoke()
at System.Windows.Threading.Dispatcher.ProcessQueue()
at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)
at System.Windows.Application.RunDispatcher(Object ignore)
at System.Windows.Application.RunInternal(Window window)
at System.Windows.Application.Run(Window window)
at OpenBullet.App.Main()

The database is corrupt. This happens when OB gets interrupted while it writes to the db. OB1 is known to have these problems, please switch to OB2 and you won’t have this issue anymore.

@Ruri I have so many hits there like 100k how do I export it?

You can’t, sadly. Maybe open it with a text editor and hope some stuff is in cleartext. Use OB2 from now on. Although a guy had success with a particular fix, let me find it.

EDIT:
Found it!

hello i face the same problem, it seems that i can’t acces this thread , anyone could help please ?

Should be back online now

1 Like