ddvk / rmfakecloud

host your own cloud for the remarkable
GNU Affero General Public License v3.0
759 stars 62 forks source link

Onboarding process on /sync/v4 #326

Open lowgos opened 5 days ago

lowgos commented 5 days ago

Hello everyone,

It seems there is a problem with latest versions and first-time rmfakecloud users. We are trying (with my friend) to make rmfakecloud work with my remarkable 2 which is on the latest beta v3.15.2.1.

Bug

An error happens while syncing after the whole connecting process is done. It appears at the bottom of the screen and no synchronization happens.

Details

We checked the logs on the remarkable itself and it seems an unexpected 404 happens, which leads to the crash and prevents any synchronization. After looking at the rmfakecloud logs it seems the 404 error happens because "No root file found, assuming this is a new account".

After a lookup in this project's issues we found #311 inside which people discuss about the fact that the onboarding process might have some differences from v3 to v4. Though it wasn't a problem for @martinetd we aren't so lucky on our side as we have a fresh rmfakecloud. @nemunaire noted that the problem is related to https://github.com/ddvk/rmfakecloud/commit/98c7da86c4359ec631a6960807175a386afdb22d which matches our findings.

The reason I'm making this issue is because I think the problem isn't tracked as most users of rmfakecloud won't get the problem because they already have a primed "fake" cloud.

Now, if I understand things right, all new users are going to fall into this pit, at least people using latest version which include v4 sync routes.

Post Scriptum

Feel free to point me to an issue tracking my problem that I might have missed. As the issue #311 is closed.

Post Post Scriptum

@nemunaire I love your pseudo :heart:

Eeems commented 5 days ago

https://support.remarkable.com/s/article/End-user-agreement-for-Opt-In-Beta

Program eligibility. Due to the risky nature of Software development, You may not have any third party software installed on your reMarkable paper tablet while participating in this Program.

You are in breach of the EULA if you install third party software while using the beta.

lowgos commented 5 days ago

https://support.remarkable.com/s/article/End-user-agreement-for-Opt-In-Beta

Program eligibility. Due to the risky nature of Software development, You may not have any third party software installed on your reMarkable paper tablet while participating in this Program.

You are in breach of the EULA if you install third party software while using the beta.

Bummer, I'm going to revert to the main release then. But I don't think this matters to this issue though, I would still like it to be kept open.

Thanks for taking the time to warn me @Eeems!

martinetd commented 4 days ago

(not an actual fix but) I've read somewhere someone suggesting to "init" the rmfakecloud with rmapi (just push any document), you might want to try that as a workaround if you haven't yet found a solution.

For an actual fix we'd need traces of what the rm actually does with the "real" cloud service on init (e.g. make it go through a reverse proxy to dump things or something), that might be a while until someone can do that... If the rmapi put thing works with no ill effect we could try to just init an empty root and return that if there was nothing found for the v4 sync API?

varchaar commented 4 days ago

I reverted https://github.com/ddvk/rmfakecloud/commit/98c7da86c4359ec631a6960807175a386afdb22d on my instance and managed to make it work with a RMPP on 3.14.4.0. It's a hack but it works ;)

nemunaire commented 3 days ago

Hi @lowgos, many thanks for your kind and detailed issue report. And thanks a lot, @varchaar, for testing with the commit reverted and giving your feedback.

To ensure that previous reMarkable releases continue to work, I made a pull request that changes the behavior only for the current synchronization route in #327.