streetcomplete / StreetComplete

Easy to use OpenStreetMap editor for Android
https://streetcomplete.app
GNU General Public License v3.0
3.89k stars 356 forks source link

Display number of quests until next advance in ranking #2541

Closed andrewferguson closed 3 years ago

andrewferguson commented 3 years ago

Background

So, firstly, I'm really enjoying using this app. It's really fun to complete quests and watch the achievements increase / ranking decrease. This feature request is an extension to this.

Use case

It would be nice to be able to visualise where I am on the local / worldwide rankings. For example, right now I'm 96 in the UK, 2091 worldwide, but that doesn't give me perspective of how many more quests I need to complete to advance to the next ranking. I think knowing this would be a great motivator for people to continue completing quests. It certainly would for me!

Proposed Solution

The easiest method that I can think of would be to have the ranking list, along with the user at each ranking spot and the number of quests that user has completed, available at a separate website. Tapping on the Rank in country or Global rank sections in the My Profile section would then open that website in the user's default browser.

An example of what this website could look like (with fake user profiles) is below. Please ignore my terrible UI design skills! streetcomplete_ranking_feature_request

The main issue I can think of with this approach is that it requires maintaining a separate webpage that can fetch / process / display this information. I can understand why that would be an issue. An alternative approach would be a feature within the app itself, whereby tapping on the Rank in country or Global rank sections in the My Profile section would display a pop-up with words to the effect of You are nnn quests away from advancing a rank. The only concern I have with this approach would be potential user confusion due to the fact that the number of quests needed to advance a rank could change if the user above them completes more quests, ie: "Yesterday it said I needed to complete 50 quests to advance a rank but now it says I need to complete 75!"

Legal / Privacy Concerns

I've read through StreetComplete's privacy policy and I don't think that this feature request would violate it. My understanding is that the current implementation of the ranking system is based upon the data in OSM rather than a separate database kept on StreetComplete servers, so this would just be displaying publicly-available aggregated information.

andrewferguson commented 3 years ago

Well, not even a minute after I submit this feature request do I realise that there is a streetcomplete/sc-statistics-service repository. Is this what I am looking for? Is it already hosted somewhere? And if not, can it be hosted by a third-party (ie: someone like me)?

matkoniecz commented 3 years ago

Is it already hosted somewhere?

Yes, and is is used by all StreetComplete installations to synchronise statistics. So if you move to a new phone, reinstall app or use multiple phones you will not lose stars/achievements/ranks.

andrewferguson commented 3 years ago

Interesting. I've looked at the code for the API and it seems it is orientated towards just being accessed by the StreetComplete app:

/* when/if https://github.com/openstreetmap/openstreetmap-website/pull/2145 or similar is 
 * merged, we might add a proper check here, requiring each user to prove to this API that 
 * this user actually has an access token for the user it tries to get the statistics for. */
if (!startsWith($_SERVER['HTTP_USER_AGENT'], "StreetComplete")) {
    returnError(403, 'This is not a public API');
}

While I completely understand the desire / need to keep the API to only the app (to avoid unnecessary bandwidth / requests from non-app users), the comment about that code doesn't make sense to me - my understanding is that the rankings are compiled from publicly-available OSM data, and therefore no form of authentication should be needed to access the data, since all this data is already public. Or am I missing something?

What I'll probably end up doing is running a copy of streetcomplete/sc-statistics-service, and adding a simple dashboard to display the results. Before I do so, it would be good to get an answer on the above question re: user privacy, as if that is an issue I will put it behind a firewall / login. Ideally, though, that's something I'd like to avoid (simply because of the extra hassle involved).

mnalis commented 3 years ago

One issue I see with publicly accessible leaderboard, is that it is taking gamification factor a little too much - I'm afraid that some users might start mapping non-surveyed data, just so they can climb the publicly available scoreboard, even if they are entering data that has not been surveyed on-site, and might even be incorrect.

That has happened a lot in the past with other services (just search the web for "gamification problems", there are a lot more articles about it).

I think StreetComplete is currently in the sweet spot - it provides just enough incentive for users to keep mapping, but not enough so they lose the goal of improving the OSM map from their sight and make climbing the ranks and earning stars their only/main priority.

I would thus recommend against doing public leaderboard - it might turn StreetComplete to Pokemon Go with side effect of corrupting OSM database with false data, instead of being beneficial to OSM. That is much bigger problem (even if only a fraction of users are affected) than any possible benefits it might bring.

HolgerJeromin commented 3 years ago

my understanding is that the rankings are compiled from publicly-available OSM data, and therefore no form of authentication should be needed to access the data, since all this data is already public. Or am I missing something?

https://neis-one.org/2017/11/public-profiles-on-hdyc/

matkoniecz commented 3 years ago

my understanding is that the rankings are compiled from publicly-available OSM data, and therefore no form of authentication should be needed to access the data, since all this data is already public. Or am I missing something?

There is also no obligation to make it public and prominently displayed to everyone. Note also that processed public data can be more problematic/dangerous than unprocessed raw data.

Note also linked https://github.com/openstreetmap/openstreetmap-website/pull/2145 and https://wiki.openstreetmap.org/wiki/GDPR - it is possible that this data should not be public.

andrewferguson commented 3 years ago

That makes sense and is something that I hadn't considered. I don't believe that there are any issues with my running my own private / internal leaderboard just for my own use, so that's what I think I'll do. I have some questions about the setup of that, but now that I know about the separate streetcomplete/sc-statistics-service repo I'll ask such questions there.