kalilistic / PlayerTrack

Keep track of players you meet.
MIT License
16 stars 9 forks source link

Plugin fails to initialize with LiteDB ENSURE: page type must be data page error #66

Closed kalilistic closed 1 year ago

kalilistic commented 2 years ago

PlayerTrack - 2.5.1.0

2022-06-06 15:12:45.887 -07:00 [ERR] [PlayerTrack] Failed to initialize plugin.
System.Exception: LiteDB ENSURE: page type must be data page
   at LiteDB.Constants.ENSURE(Boolean conditional, String message)
   at LiteDB.Engine.DataPage..ctor(PageBuffer buffer)
   at LiteDB.Engine.BasePage.ReadPage[T](PageBuffer buffer)
   at LiteDB.Engine.Snapshot.ReadPage[T](UInt32 pageID, FileOrigin& origin, Int64& position, Int32& walVersion)
   at LiteDB.Engine.Snapshot.GetPage[T](UInt32 pageID, FileOrigin& origin, Int64& position, Int32& walVersion)
   at LiteDB.Engine.DataService.Read(PageAddress address)+MoveNext()
   at LiteDB.Engine.BufferReader..ctor(IEnumerable`1 source, Boolean utcDate)
   at LiteDB.Engine.DatafileLookup.Load(PageAddress rawId)
   at LiteDB.Engine.BasePipe.LoadDocument(IEnumerable`1 nodes)+MoveNext()
   at LiteDB.Engine.QueryPipe.Select(IEnumerable`1 source, BsonExpression select)+MoveNext()
   at LiteDB.Engine.QueryExecutor.<>c__DisplayClass10_0.<<ExecuteQuery>g__RunQuery|0>d.MoveNext()
   at LiteDB.BsonDataReader.Read()
   at LiteDB.LiteQueryable`1.ToDocuments()+MoveNext()
   at System.Linq.Enumerable.SelectEnumerableIterator`2.ToList()
   at PlayerTrack.PlayerService.MergeKeyDuplicates()
   at PlayerTrack.PlayerService.LoadPlayers()
   at PlayerTrack.PlayerService..ctor(PlayerTrackPlugin plugin)
   at PlayerTrack.PlayerTrackPlugin.<.ctor>b__5_0()

Related issue with LiteDB? https://github.com/mbdavid/LiteDB/issues/1940

kalilistic commented 1 year ago

Fixed with v3 (changed DBs).