Hey Allan, our openCore wasn’t reachable for the last 2 days so i was working on my Projects and Workflows offline.
Today when i opened OpenRPA and the server was available again all my work was reset to what seems to be 2 days ago.
Projects are gone, Workflows reset, deleted Projects are back existing, it looks exactly how it looked 2 days ago.
I haven’t changed anything in the settings in between.
Hi Allan,
I just did some testing and have to report a behavior which is really not ideal:
When you are not connected to OpenCore, because OpenCore is offline or your internet is down but you still have the correct URL set, all your work you do till you reconnect is automatically, without warning getting deleted. Atleast using a selfhosted OpenCore haven’t checked with the main version.
Steps to reproduce:
Setup Your OpenRPA to connect to your OpenCore and make sure the connection and synchronization works.
Close OpenRpa and take your PC off the internet.
Create a new project and edit some workflows in existing projects. Save all that.
Close OpenRpa and reconnect to the internet.
Start OpenRpa again and watch your changes being deleted and overridden.
I see why this is happening but it needs at least a warning so people can backup their offline changes. I didn’t lose to much work gladly but if id have a longer outage this would have been fatal.
Not without a copy of the .db file before it connected to OpenCore, unfortunately.
Originally, the reason for using a database locally was to ensure we could continue to run even if OpenCore was down. If it’s just down shortly, it does not matter, we have a copy in memory. But if it’s down for a longer time and it needs to restart, we needed a copy of everything. It was assumed you would not be working on OpenRPA if OpenCore was down, since the “truth” is inside OpenCore.
Later the idea came to allow OpenRPA to work completely without OpenCore (what we call offline mode). While doing that, I started adding basic “sync checks” into OpenRPA based on the _version of each object… so whoever has the highest _version wins when OpenRPA is reconnected to OpenCore.
This check has been known to sometimes mess up, so in case there is any doubt, it ALWAYS takes what OpenCore has.
wouldn’t it make sense to then have openrpa automatically create local git repos once a project/workflow that are created/saved (automtically just setting a generic commit message etc)? at least you get to have a backup automatically created locally, so it is easily reverted and synced with opencore when it is up.
of course, it is always good and a recommendation to just do a git init in your projects, but one can easily forget to init and even commit stuff to it.
That is EXACTLY what we want to add … @AndrewK helped implement a “provider layer” to how OpenRPA saves data. This means we can now replace using LiteDB or Files with Git instead. And since Opencore is also a Git server, we can store history both locally and inside Opencore.
Hi Allan,
yes i have seen that happening and also OpenRPA has asked me at a different time if i want to override something with different version.
This time so there was no warning, no question, nothing AND a brand new project that didn’t even exist in OpenCore before will be deleted, reproducible with the steps above. I can’t see how a version check would do that, since there is no version of it in OpenCore?
You are 100% correct. The check is supposed to be: if something only exists in OpenCore, download it; if something only exists in OpenRPA, upload it; if something exists in both places, use _version to decide whose is correct. Without the file before you connected it to OpenCore, I cannot help you troubleshoot WHY that did not work, but the result right now is, it’s gone. Not much I can do about that.
Sorry it was not clear. What I meant with my first reply was to explain that it was never MEANT to be that you work on a robot that is not connected to OpenCore, but over time we tried implementing it, so it’s possible, but it is not something that has been extensively tested.
Hi Allan,
No worries about the file i lost maybe 3 hours of work now that i figured the hard steps out. Just lets make sure this check works in the future, especially the part that keeps deleting new projects that where created offline.
I think we are not the only people using VPNs and sometimes forgetting to start them. In this case you would work offline by accident in the current setup. Maybe a real warning besides the little bar on the bottom left that you are not connected would be good too?