Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Cannot recover conversations and messages #561

Open
hookie256 opened this issue Dec 10, 2024 · 3 comments
Open

Bug: Cannot recover conversations and messages #561

hookie256 opened this issue Dec 10, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@hookie256
Copy link

Describe the bug

I installed the app and created DM and group conversations. However, when I uninstall the app or initialize the client on another device, I can no longer load my conversations. When I fetch the list of conversations, it returns an empty array.
Thanks!

Expected behavior

I dont know how to recover conversations....or is this a feature?

Steps to reproduce the bug

No response

@hookie256 hookie256 added the bug Something isn't working label Dec 10, 2024
@alexrisch
Copy link
Contributor

Hello @hookie256!

Thank you for reaching out!
This is because of the forward secrecy that was introduced with the V3 SDK/V3 Xmtp Protocol, so it is a feature

There are docs in the works around this and how to handle it here

A bit of an in depth look into the why this happens:
User logs in to the application this user has an InboxId of 123456
This is also an installation id of 7890
Then a few days later the user logins in to a different device they would get a new installation id lets say 2345

The encryption is actually done on the installation level, so installation 2345 would not be able to decode previous messages that went to 7890, but both installations will be able to decode new messages going to the InboxId

To display the older messages you can use the history sync server to pull in the older messages

@hookie256
Copy link
Author

I am using React Native, so could you provide me with some sample code for reference? It seems like the support above is only for the browser.

@nplasterer
Copy link
Contributor

👋 @hookie256 the history sync server is currently disabled in the most recent RN SDK as we work on a few performance improvements. Hope to have it reenabled later this week.
However your conversations should still show up in your new installation after about 30 minutes after logging in. You may see them show up slowly as your new installation gets added to your existing conversations as other users come online and "add you". But the conversations will be empty shells with no messages. To speed this up and bring along the messages we have a history sync server that you can run from your past installations by just calling syncAllConversations it however will require your old and new installations to both be accessible. If for some reason your loose your installation you will still be able to recover your conversations but you messages will be lost. We've got some more indepth documentation incoming soon. cc @jhaaaa

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants