Skip to content

Conversation

@skyethepinkcat
Copy link

When trying to use nheko on my personal matrix instance, I ran into an issue where some invalid event (I believe it was entirely empty) had been added at some point, and each time I tried to login with nheko rather than working as intended, it would give me the repeating error:

[db] [error] failed to save state after initial sync: mdb_put: MDB_BAD_VALSIZE: Unsupported size of key/DB name/data, or wrong DUPFIXED size

on each initial sync. I was able to solve this issue by simply having nheko ignore the error with a try catch statement. I'm not certain if this is the best way to do it, but it fixes it for me and I haven't seen any errors after using it.

@deepbluev7
Copy link
Member

Sorry, I kinda missed this! I am a bit confused how you even got that far though. In theory this should throw if there is any event without a type: https://github.com/Nheko-Reborn/mtxclient/blob/master/include/mtx/events_impl.hpp#L282

I would prefer if mtxclient already filtered events like that out. If you can reproduce this, can you try fixing it there?

#include "UserSettingsPage.h"
#include "Utils.h"
#include "encryption/Olm.h"
#include <typeinfo>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This include seems unnecessary?

@deepbluev7
Copy link
Member

I guess it is possible that this check now is incomplete: https://github.com/Nheko-Reborn/mtxclient/blob/master/include/mtx/events_impl.hpp#LL269C39-L269C39

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants