-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Enable synchronisation of favourites #2750
Comments
OsmAnd doesn't delete missing favorites on purpose in order to not loose anything wanted. Full synchronization of favorites will require mechanism how user can undelete favorites and this is not discussed how to implement yet. Today it is possible to recompile osmand https://github.com/osmandapp/Osmand/blob/master/OsmAnd/src/net/osmand/plus/FavouritesDbHelper.java#L76 |
I had already looked at the source code to figure out what's happening. Your suggestion for another workaround is indeed possible, but then I have to root all devices as an app or user can't access the internal file without root privileges. |
Agree, we need to enable somekind of developer settings which will be easy to set in the app. One of that setting should be use only external storage for favorites, so it will be easy to synchronize. |
+1 for me, would be a great feature |
+1 for me too - I plan on the tablet and bike with the phone |
Friendly bump here (I also use it for both car driving and biking, so that would be really useful) +1 |
+1 for me also, have it on three devices anyhow, getting a better synchronization would be more than "nice to have" for me. |
Maybe the following can be helpful: See the latest new feature on https://overpass-turbo.eu ... You can store now your queries in an API by openstreetmap.org! That means: log in with your OSM account and have some storing space for small data sets. Maybe it is possible to store the favourites.gpx file there as well? |
Would be really interested to have this feature. Having the ability to move preferences/settings/favorites between devices will save users lots of effort with new or multiple devices. |
+1, this is really a missing feature. |
This is the weakest link in Osmand, an otherwise amazing project. A lot of us are building huge GPX datasets and rarely backing them up, let alone syncing, because of this problem. Not only "nice to have" but needed urgently. |
I agree, it is something that has been missing for a really long time. Optional sync of user data with cloud is almost the standard now and GPX are exactly the kind of data users need to sync and back up. It is accumulated sporadically and over long time, edited on different devices, not audited often and you usually can't predict when you will need to find that place you marked two years ago. Countless times I saved a POI just in case, long time passed, then I needed it - and of course it was on another device, lost due to device reset and/or my failure to back it up. I would see it as optionally automatic Dropbox/Google Drive synchronization. Those who want to be extra careful about not overwriting existing GPX from the cloud can leave it off and keep doing it manually. Casual users will just turn it on and forget about it. Some people will combine the approach - setting up sync but periodically exporting GPX manually after important edits. I don't think undelete functionality is really necessary to implement before cloud sync. |
+1, absolutely necessary for travelling |
+1 would like to sync as well... |
+1 absolutely necessary |
+1 transitioning between phones is a pain, and loss of trek data hurts |
+1 without this "favorites" are effectively tied to the device and are therefore temporary. |
Very important for me, too. I have over 300 favourites which I use and change constantly and there is no way to sync them on different devices and no save place to store them constantly. |
+1 from me |
PSA: Please avoid "+1" messages on GitHub issues, that's what the reactions (the "+☺" above comments) are for. Otherwise subscribers end up with a lot of pointless notifications. |
I tried to ask for this in #2636, but was misunderstood / didn't find the right words. All it'd take is to have seperate files for each favourite. Because these files are so small it could just be added and the favourites.gpx could be left as is. An additional folder "favourites" with subfolders of groups that would be in sync with the content of favourites.gpx and prioritized if there are conflicts. Could be an add-on "Favourite Sync Folder" or an option in the developer add-on. P.S.: I can sync favourites.gpx itself, but this doesn't handle conflicts, if both devices add a favourite without being online. |
any updates on this request? |
Yes, it is planned for 2019 |
Please make synchronization. |
Hey! Nextcloud Maps development is currently in progress. There already is a REST API to manipulate favourites. It would be great to create an OsmAnd plugin able to sync favourites with Nextcloud Maps. Being able to sync with a privacy-friendly solution as Nextcloud Maps would be a killer feature IMHO. This API has been discussed in nextcloud/maps#30 If I find time and motivation, I could do it in a few months. If someone wants to do it, feel free to ask for some changes in Maps favourites API if necessary. |
I also have multiple devices running OSMand and keeping the favorites synced is very labor intensive. This would be a very nice feature to have. |
Any update on this, or a roadmap we can look at? (sorry to start 2020 with a push!) |
Just a thought ... but in the interim whilst this is hopefully being sorted - |
I have the same issue. The internal database should update itself with respect to the changes in |
Might I propose a solution based on DecSync? I uses the filesystem to synchronize the favorites, like others suggested. But it is designed in such a way that there are no file conflicts. Disclaimer: I made it myself. |
I have now actually made a proof of concept of OsmAnd DecSync, which is an OsmAnd plugin that uses DecSync to synchronize the favorites! Note that it is a proof of concept, as it requires root and heavy manual intervention, as there is currently no way for a plugin to access the favorites. To make it work correctly, this access has to be added. It is sufficient to add a method to get the time of the latest update and a way to access Furthermore, the plugin makes use of ids to identify favorites and categories, but OsmAnd cannot store them. Is is possible to add this possibility? Currently, the plugin guesses based on the name,color etc., but storing it directly would make it simpler. |
@vshcherb Any update on the introduction of the methods "Last time favorites has changed" and "Access to raw Favorites.gpx.gz"? |
@39aldo39 -- it is actually possible to configure OsmAnd to write its data to shared memory which is accessible by other apps without requiring root access. |
Indeed, this provides one-way synchronization. The favourites.gpx file is updated every time a favourite is added/modified/deleted, so the OsmAnd favourites can be shared with other applications via this file. The other direction (updating favourites in OsmAnd without user interaction) is still not possible in an automated way. |
Thanks for the information! I would still prefer it if it wasn't necessary, but it is still acceptable. I updated the plugin to work using the shared memory functionality! The setup is a bit more complicated, but after that it should work automatically. I have even published a v0.2 release with an APK to make it easier to try out! |
Same problem. I wrote a node.js utility that converts my Google Earth favorites into GPX, then pushes to PROPOSED SOLUTIONS:
<extensions>
<osmand:background>circle</osmand:background>
<osmand:action>REMOVE</osmand:action> // or UPDATE, whatever
</extensions> |
@DamianoPantani what if you move them to a category called trash and keep it disabled? yes, we also could treat special coordinates to delete points like lat/lon=0.0001/0.0001 or tag in extension |
@vshcherb that would do the trick but I can only move favorites manually. Can I do it from the |
Hm... than I think I'm wrong with that idea and it needs to be implemented first. |
Another year, same question: |
Depends what's real and what's not real synchronization, updating / adding points - works but deleting points is not yet. |
Meanwhile OsmAnd has a backup/restore feature and OsmAnd Pro has a cloud feature. So technically you can just backup your favorites (or tracks, markers, settings, ...) on one device to the cloud and restore it on another device from the cloud. This is quite similar to a synchronization. If deletion doesn't work yet this is a pity, though. |
Once we implement timestamp tracking / deleting points / incremental synchronization, all possible solutions will benefit from it. |
"quite similar" is ecactly not "my" definition of "real" sync. For just copying files around I dont need a "pro"-version, using the osmand cloud. |
I would like to add that a sync feature would also allow to share favorites with a partner. Are there other people interested in an integration with next cloud? |
I´m interested in every solution that will give me the possibility to sync favourites - and in the best case also tracks - between cloud and my devices! |
OP still has the best idea to begin resolving this whole issue:
Forget database access, and ADB, and anything Nextcloud-specific, for now. Just make |
There is one large drawback: OsmAnd only adds favorites from this file but never deletes them if they aren't contained in favorites.gpx. |
Yes, that was exactly my point... If |
Could be a good start indeed, I will have a look at the |
im wait sync too |
@julien-nc I would love that, any way I can support? Similar discussion is ongoing for Organic Maps, if both implement sync I would be one very happy deGoogler :) |
@dmpr0 -- fantastic that this is closed! Which PR implements this? |
Free Cloud backup is available, export into file is available too, any other option currently not planned. |
(This request resembles #1613 but the export/import from that issue would not be sufficient)
This request: please make it possible to synchronize favorites among devices. This is not a request to implement the synchronization itself - I can understand that it is impossible for Osmand to support all possible solutions (external SD card, DropBox, OneDrive, Google Drive...). But the way Osmand handles favorites at the moment makes it very cumbersome to perform any form of synchronization, even with a third-party app. The request is to modify the Osmand behaviour to allow for easy synchronisation, and preferably allow automated synchronisation (e.g., via a third-party app).
Some background: I'm a huge fan of Osmand and I'm using it extensively on holidays. It's great to have an offline map/navigation app. I use the favourites a lot to mark the location of hotels, train stations and other points that I want to visit, have to change trains or buses etc. Especially in countries where you cannot read or understand the local language, having a map that tells you whether you are close to your target is very practical. So while traveling I tend to add, move, remove and rename favorites a lot.
I'm using Osmand on two or three devices (tablet, new phone for safe areas, old phone as backup and for less secure areas), more or less at the same time. The tablet is great for planning itineraries, the phones for navigation and ad-hoc route planning, and the tablet is also a backup in case the battery of the phone is empty. But then it should be easy to distribute changes to the favourites made on one device to the other two.
With the current Osmand version that is impossible, or at least it is a nightmare.
Exporting the favourites is possible. Go to the list of favourites and use the share option to export the file. It is possible to save the favourites.gpx to Dropbox, or to save the file to an external location (memory card/USB stick that is connected via USB). (It is not possible (on Android 5.x) to save the favourites to a file on the internal/external SD card, probably because of security issues).
The main problem is importing the favourites, because Osmand always prefers the data on favourites that is stored in its internal database. There are several ways to import the favourites.gpx:
The last one works, but it is quite cumbersome and there's plenty of room for error.
Personally, I would prefer a third-party app solution: create an app that synchronizes two versions of a favourites.gpx (allowing for changes in both versions), and updating the collection of favourites in Osmand. (I could make such an app, I've built similar software.) Such an app could automate the process, but... Osmand won't allow that. If only all favourites were writen to the favourites.gpx, then such an app could read the data without user intervention. If only Osmand would (have an option to) use the data from the external (favourites.gpx) file if it exists instead of from the internal data file, then modifications could be communicated automatically to Osmand. If only there was a way (e.g., via the Osmand api) to reinitialise the favourites from the external data, then such an app could do its work without the user having to force Osmand to stop.
The text was updated successfully, but these errors were encountered: