-
Notifications
You must be signed in to change notification settings - Fork 104
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
Channels not restored on recovery (Android vs iOS) #231
Comments
It's by design: running 2 lightning nodes at the same time with the same keys is not well supported (by the Lightning protocol, it's not specific to us), so to avoid issues with users who have the Android app and want to try it out on iOS we chose to use different derivation paths for the Android and iOS applications. |
Unfortunately, this is a very poor choice from a user experience perspective. It defeats the only reason the recovery seeds exist in the first place - to allow recovery to another device. The fact that this is not documented anywhere (neither in the app nor on the project website) makes things even worse. Last but not least, the argumentation for this "feature" could also be used against migrating the seed from one Android instance to another or from one iOS instance to another. And the fact this is allowed there but not when switching platforms also violates the principle of least surprise. |
This issue is temporary and specific to the state of the current Android implementation vs iOS. As mentioned in the readme, we do not use the same Lightning engine on the Android app and the iOS app (the Android app is older) hence the different derivation path to prevent compatibility issues. Once the Android app has migrated and uses the same new engine as the iOS app, the same seed will generate the same wallet on both environment and channels will be restored as expected. I'll add an entry in the FAQ in the meantime. |
Does this mean that the old Android version and the new Android version will have incompatible seeds? |
Yes they are incompatible. However the new Android version will still contain the old engine (as well as the new) in order to be able to restore and use old channels, and at some point close them. That will last for a while. Once most users have migrated to new channels I think the old engine will be removed. |
Thanks for your explanation! @dpad85 |
What's the status of this? I'd like to migrate my iOs wallet to GrapheneOS one day :-) |
We're getting close 😃. It has been delayed a bit because we are not just changing the lightning engine to lightning-kmp). The new Android version will also be using dual-funding where channels are funded by both parties (your wallet and the ACINQ node). This enables trustless swap-ins: deposits are now sent to an address belonging to Phoenix (path 84'/1'/1') and then automatically fund new channels in cooperation with the peer. Dual-funding also prepares splices, which will be another great feature. All this is a lot of changes and we'd rather publish it in one update, if possible. And it means that we have to wait for it to be 100% ready before we can release the new Android version. By the way you can already test the new android app with dual funding here (it's a separate Testnet app).
Note: it will work but the payments history will be lost. I don't think we'll have time to find a cross-platform data migration solution. |
Good stuff, looking forward! Payment history is overrated :-) |
Is this still an issue in v2? (For reference, the history feature request seems to be tracked in #141) |
And what happens if you restore from Android to another Android, but then open the old wallet by mistake while the new one is running? I think this FAQ section covers the question above: https://phoenix.acinq.co/faq#can-i-run-two-phoenix-apps-with-the-same-seed However, in my opinion, what needs to happen is that this is stated more clearly in the FAQ section called "Restoring a wallet". Right now, this section only has 3 subsections:
Only the 2nd subsection above links to the initial "Can I run two phoenix aps with the same seed" part. How about adding another subsection here about migration from old to new phone? Is this FAQ in github so that we can propose PRs to it? |
Sorry for the confusion, this issue should have been closed since the 2.0 release which supports cross platform migration.
It's already covered by the first entry. The wording in the title could be shorter and more generic though to address more normal use cases, we'll fix that. |
Thanks, but take in account that first entry does not link to the "you should NOT run two instances of Phoenix simultaneously with the same seed" sentence that next section includes, don't forget that. |
Channels were not restored on recovery when I moved the recovery seed from Android Phoenix to iOS Phoenix.
Steps to reproduce:
Maybe you even don't have to open some channels and just try to figure out why the NodeID is different (I suppose it is meant to be the same after recovery).
The text was updated successfully, but these errors were encountered: