Id: Graceful degredation of fields when services like nominatim are unavailable

Created on 31 Jul 2017  路  8Comments  路  Source: openstreetmap/iD

m
The user clicks on this address field but cannot open it to enter anything at all.

field wontfix-low-impact

Most helpful comment

If it returns 503, then put "503: Service Not Available" with the address box. Otherwise it becomes your bug to users viewing it.

Ok, we can leave open as a nice-to-have issue, but I don't think this is very high priority.

We could replace whatever it is that depends on the service with a friendly message like "Country lookup failed, try again later". We wouldn't really need a refresh button, because the field refreshes every time the user clicks on another feature.

Some places where we could support graceful degradation when a service is unavailable include:

  • nominatim: address, combo (network), input (telephone) fields, Location panel
  • wikipedia: wikipedia and localized fields (until we do #2457)

Probably many others too - everything iD does can be interrupted when the internet is not working.

All 8 comments

Looks like something is blocking you from using nominatim, so iD has no idea what country you are in. If you open the developer tools, do you see any errors?

Request URL:https://nominatim.openstreetmap.org/reverse?addressdetails=1&format=json&lat=24.141345534019226&lon=120.87380491293462&zoom=13
Request Method:GET
Status Code:503 Service Unavailable
Remote Address:193.63.75.109:443
Referrer Policy:no-referrer-when-downgrade
Response Headers
view source
Connection:close
Content-Length:393
Content-Type:text/html; charset=iso-8859-1
Date:Mon, 31 Jul 2017 14:53:49 GMT
Server:Apache/2.4.18 (Ubuntu)
Request Headers
view source
accept:application/json,/
Accept-Encoding:gzip, deflate, br
Accept-Language:en-US,en;q=0.8,zh-TW;q=0.6
Connection:keep-alive
Host:nominatim.openstreetmap.org
Origin:http://www.openstreetmap.org
Referer:http://www.openstreetmap.org/id
User-Agent:Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.104 Safari/537.36
Query String Parameters
view source
view URL encoded
addressdetails:1
format:json
lat:24.141345534019226
lon:120.87380491293462
zoom:13

It usually works after clicking on other things after a while.
So maybe check the logs there and see why it is returning 503s perhaps.

I also get 503's on the first request, but if i refresh the URL, it comes back just fine.

Yeah, 503 errors are really outside our control. It looks like the nominatim server is just running slow today. When I tried clicking on a building, it took 4 seconds for the address info to appear. Going to close here, as there isn't anything we can do about it.

If it returns 503, then put "503: Service Not Available" with the address box. Otherwise it becomes your bug
to users viewing it.
You can even also add a tiny [retry] button.

If it returns 503, then put "503: Service Not Available" with the address box. Otherwise it becomes your bug to users viewing it.

Ok, we can leave open as a nice-to-have issue, but I don't think this is very high priority.

We could replace whatever it is that depends on the service with a friendly message like "Country lookup failed, try again later". We wouldn't really need a refresh button, because the field refreshes every time the user clicks on another feature.

Some places where we could support graceful degradation when a service is unavailable include:

  • nominatim: address, combo (network), input (telephone) fields, Location panel
  • wikipedia: wikipedia and localized fields (until we do #2457)

Probably many others too - everything iD does can be interrupted when the internet is not working.

Closing this as low-impact. Now that we have #6941, there are fewer instances where nominatim failures interrupt editing. iD's other integrated services tend to be more reliable.

Was this page helpful?
0 / 5 - 0 ratings