ropensci / osmdata

R package for downloading OpenStreetMap data
https://docs.ropensci.org/osmdata
314 stars 45 forks source link

[BUG] getbb returns HTTP Error 502 from Nominatim #331

Open mooibroekd opened 1 year ago

mooibroekd commented 1 year ago

I cannot get getbb to work correctly as it returns a 502 error. I am also not sure if it is related to ports being blocked or not being accessible, so I would appreciate if someone else could confirm.

library(osmdata)
#> Data (c) OpenStreetMap contributors, ODbL 1.0. https://www.openstreetmap.org/copyright
bb <- getbb("Barcelona")
#> Error in `httr2::req_perform()`:
#> ! HTTP 502 Bad Gateway.
#> Backtrace:
#>     ▆
#>  1. └─osmdata::getbb("Barcelona")
#>  2.   └─osmdata:::get_nominatim_query(...)
#>  3.     └─httr2::req_perform(req)
#>  4.       └─httr2:::resp_abort(resp, error_body(req, resp), call = error_call)
#>  5.         └─rlang::abort(...)

Created on 2023-09-03 with reprex v2.0.2

mpadge commented 1 year ago

Could be related to #405. Can you make sure you've got latest version (>= 0.2.5.2)? That should fix

mooibroekd commented 1 year ago

Installed version is the one from CRAN and is listed as 0.2.5. I assume I need to install the development version?

mpadge commented 1 year ago

Yep, remotes::install_github("ropensci/osmdata") should do the trick. Let me know

mooibroekd commented 1 year ago

Yes, the development version fixes the problem. When will this be released on CRAN?

mpadge commented 1 year ago

asap - i'll take this an incentive and endeavour to get it up this week. Thanks