Skip to content

Crash after v2.15.0 update #1372

Description

@skelsan

app.log

What happened?

  1. Open Stability Matrix.
  2. Go to anywhere (Settings, Inference, Checkpoint Manager, etc).
  3. See the crash.

Exception Details

Exception

LiteAsyncException: LiteDB encounter an error. Details in the inner exception.
LiteException: Detected loop in FindAll({0})

Sentry ID

00000000

Stack Trace

   at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
--- End of stack trace from previous location ---
   at System.Lazy`1.CreateValue()
   at StabilityMatrix.Core.Database.LiteDbContext.get_CivitModels()
   at StabilityMatrix.Core.Services.ModelIndexService.RefreshIndexParallelCore()
   at StabilityMatrix.Core.Services.ModelIndexService.<BackgroundRefreshIndex>b__29_0()
   at AsyncAwaitBestPractices.SafeFireAndForgetExtensions.HandleSafeFireAndForget[TException](Task task, Boolean continueOnCapturedContext, Action`1 onException)```
```   at LiteDB.Constants.ENSURE(Boolean conditional, String format, Object[] args)
   at LiteDB.Engine.IndexService.FindAll(CollectionIndex index, Int32 order)+MoveNext()
   at LiteDB.LinqExtensions.<>c__DisplayClass2_0`2.<<DistinctBy>g___|0>d.MoveNext()
   at LiteDB.Engine.LiteEngine.<>c__DisplayClass5_0.<EnsureIndex>b__0(TransactionService transaction)
   at LiteDB.Engine.LiteEngine.AutoTransaction[T](Func`2 fn)
   at LiteDB.Engine.LiteEngine.RebuildContent(IFileReader reader)
   at LiteDB.Engine.RebuildService.Rebuild(RebuildOptions options)
   at LiteDB.Engine.LiteEngine.Rebuild(RebuildOptions options)
   at LiteDB.SharedEngine.Rebuild(RebuildOptions options)
   at LiteDB.Async.LiteDatabaseAsync.<>c__DisplayClass37_0`1.<EnqueueAsync>g__Function|0()```


### Version

v2.15.0

### What Operating System are you using?

Windows

Activity

  1. added
    bugSomething isn't working
    crashBugs involving the app crashing to desktop
    on Sep 8, 2025
  2. johnnykorm commented on Sep 8, 2025

    @johnnykorm

    Same problem after update!

  3. mohnjiles commented on Sep 8, 2025

    @mohnjiles
    Member

    Sorry about that, if you rename or delete the StabilityMatrix.db file in your SM install folder, it should fix this.

    This db holds civitai api and github caches, so no need to worry about data loss deleting this file.

  4. skelsan commented on Sep 8, 2025

    @skelsan
    Author

    @mohnjiles
    Yeah, I already had some thoughts about this file, thank you for confirming that. It's good that it doesn't contain anything more important.
    Considering that all other users will encounter the same problem after the update, they should be notified about it somehow. Or will you release a quick fix?

    By the way, the redesigned Checkpoint Manager and Model Browser are awesome. Thanks.

  5. Scordem commented on Sep 8, 2025

    @Scordem

    Same here.

  6. johnwickstyle commented on Sep 8, 2025

    @johnwickstyle

    Try to run in an administrator
    or
    right click on StabilityMatrix folder
    go to property
    go to security
    change permissions for User to full control (Allow all check marks)
    may be it works for you.

  7. miurgh commented on Sep 8, 2025

    @miurgh

    same

  8. skelsan commented on Sep 8, 2025

    @skelsan
    Author

    To @johnwickstyle
    No matter how much I trust the app's developers, I won't give it unnecessary permissions or run it as an administrator.

    Deleting the old database file worked for me, as @mohnjiles suggested.

  9. mohnjiles commented on Sep 8, 2025

    @mohnjiles
    Member

    To @johnwickstyle No matter how much I trust the app's developers, I won't give it unnecessary permissions or run it as an administrator.

    Deleting the old database file worked for me, as @mohnjiles suggested.

    Yep deleting the db is the "intended fix" for now until we release a patch.

    I also don't recommend anyone run SM as admin regardless 😄 usually causes more problems down the line. It is designed to run primarily in user-space, with very few exceptions around the HIP SDK stuff for AMD users that we'll prompt you for elevation if necessary.

  10. Judas87Swiff commented on Sep 8, 2025

    @Judas87Swiff

    Even more crashing AFTER deleting StabilityMatrix.db , only other thing I installed was Face Detailer via Stability Matrix's Inference pop-up prompt window that appears only on fresh Comfyui installs, 'that' successfully installed -it didn't crash- then on restart of Stability Matrix after launching that nearly fresh (only installed whatever SM prompts for to install Face Detailer) ComfyUi install from prior to SM app update it was fine... until I went into Inference panel, then error appears below.

    Extra note:
    Just opening Inference Panel without ComfyUi launched doesn't cause any issues.

    Extra extra note...
    The ComfyUI version I'm using is displayed as "master@97652d2" but, oddly my other older installation on "master@bcbd788" works fine.

    stabilitymatrix-log-2025-09-08-15-57-45.zip

    Error Log
    "

    Exception

    ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')

    Sentry ID

    00000000

    Stack Trace

    at System.Collections.Generic.List`1.get_Item(Int32 index) at System.Collections.ObjectModel.Collection`1.System.Collections.IList.get_Item(Int32 index) at Avalonia.Controls.ItemsSourceView`1.GetAt(Int32 index) at Avalonia.Controls.Selection.SelectedItems`1.GetEnumerator()+MoveNext() at System.Linq.Enumerable.<ToArray>g__EnumerableToArray|314_0[TSource](IEnumerable`1 source) at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source) at Avalonia.Controls.Selection.InternalSelectionModel.OnSelectionChanged(Object sender, SelectionModelSelectionChangedEventArgs e) at Avalonia.Controls.Selection.SelectionModel`1.CommitOperation(Operation operation, Boolean raisePropertyChanged) at Avalonia.Controls.Selection.InternalSelectionModel.OnSourceCollectionChangeFinished() at Avalonia.Controls.Utils.CollectionChangedEventManager.Entry.<Avalonia.Utilities.IWeakEventSubscriber<System.Collections.Specialized.NotifyCollectionChangedEventArgs>.OnEvent>g__Notify|6_0(INotifyCollectionChanged incc, NotifyCollectionChangedEventArgs args, WeakReference`1[] listeners) at Avalonia.Threading.DispatcherOperation.InvokeCore() at Avalonia.Threading.DispatcherOperation.Execute() at Avalonia.Threading.Dispatcher.ExecuteJob(DispatcherOperation job) at Avalonia.Threading.Dispatcher.ExecuteJobsCore(Boolean fromExplicitBackgroundProcessingCallback) at Avalonia.Threading.Dispatcher.Signaled() at Avalonia.Win32.Win32Platform.WndProc(IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam) at Avalonia.Win32.Interop.UnmanagedMethods.DispatchMessage(MSG& lpmsg) at Avalonia.Win32.Win32DispatcherImpl.RunLoop(CancellationToken cancellationToken) at Avalonia.Threading.DispatcherFrame.Run(IControlledDispatcherImpl impl) at Avalonia.Threading.Dispatcher.PushFrame(DispatcherFrame frame) at Avalonia.Threading.Dispatcher.MainLoop(CancellationToken cancellationToken) at Avalonia.Controls.ApplicationLifetimes.ClassicDesktopStyleApplicationLifetime.StartCore(String[] args) at StabilityMatrix.Avalonia.Program.Main(String[] args)
    "

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcrashBugs involving the app crashing to desktop

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions