Skip to content

Wrong description language for Nearby upload #2663

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

Open
nicolas-raoul opened this issue Mar 19, 2019 · 2 comments
Open

Wrong description language for Nearby upload #2663

nicolas-raoul opened this issue Mar 19, 2019 · 2 comments

Comments

@nicolas-raoul
Copy link
Member

Steps to reproduce:

  1. Change the sandbox item's geolocation to somewhere near you (or use FakeGPS or scroll to its current location and press "Search in this area") and change its "instance of" to "embassy", remove its "image" if it has one.
  2. Change your Android language to Hebrew (might work with other non-English languages)
  3. Open the app, tap "Nearby"
  4. Find the sandbox item
  5. Tap the + and upload a picture for it.
  6. The proposed description is in Upper Sorbian instead of Hebrew.

There are two problems with this:

Screenshot_20190313-123015

@nicolas-raoul
Copy link
Member Author

nicolas-raoul commented Mar 21, 2019

Another example:
description should not be set to en, it should be set to ja because the description is in Japanese.
Screenshot_20190321-114650

@nicolas-raoul
Copy link
Member Author

I think the cause of the problem is that the SPARQL request coalesces languages, and we have no way to know what language was used:

 SAMPLE(COALESCE(?itemLabelPreferredLanguage, ?itemLabelAnyLanguage)) as ?label

As you can see, the label in language itemLabelPreferredLanguage is used if it exists, but if it does not exist, a label in any other language is used (randomly and we don't know which one).

Solution

When the user proceed with uploading a picture for that nearby item, we should run another request on that particular item only, that gets us all language-label pairs, and either take only the one we had displayed to the user, or even add all of them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant