#23925 closed defect (fixed)
Cannot fetch a map of my small city: "bad request". In error popup - please provide a link where to download the data manually
Reported by: | anonymous | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | 24.09 |
Component: | Core | Version: | |
Keywords: | template_report | Cc: |
Description
What steps will reproduce the problem?
- Install on Gentoo Linux
- Try to fetch a small region (works on very small)
Error text:
The OSM server 'api.openstreetmap.org' reported a bad request. The area you tried to download is too big or your request was too large. Either request a smaller area or use an export file provided by the OSM community.
Good to have a link here for that export file from OSM community - I do not know where to download it.
Relative:URL: ^/trunk Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b Last:Changed Date: 2024-07-02 17:10:50 +0200 (Tue, 02 Jul 2024) Revision:19128 Build-Date:2024-07-03 01:31:15 URL:https://josm.openstreetmap.de/svn/trunk Identification: JOSM/1.5 (19128 en) Linux Gentoo Linux Memory Usage: 628 MB / 3960 MB (440 MB allocated, but free) Java version: 17.0.12+7, Eclipse Adoptium, OpenJDK 64-Bit Server VM Look and Feel: javax.swing.plaf.metal.MetalLookAndFeel Screen: :0.0 1366x768x[Multi depth]@60Hz (scaling 1.00×1.00) Maximum Screen Size: 1366×768 Best cursor sizes: 16×16→16×16, 32×32→32×32 Environment variable LANG: C.UTF8 System property file.encoding: UTF-8 System property sun.jnu.encoding: UTF-8 Locale info: en Numbers with default locale: 1234567890 -> 1234567890 VM arguments: [-Djava.library.path=/lib64, --add-exports=java.base/sun.security.action=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED] Last errors/warnings: - 00124.848 E: org.openstreetmap.josm.io.OsmApiException: ResponseCode=400, Error Header=<You requested too many nodes (limit is 50000). Either request a smaller area, or use planet.osm> - 00124.859 E: Bad Request - <html>The OSM server 'api.openstreetmap.org' reported a bad request.<br><br>The area you tried to download is too big or your request was too large.<br>Either request a smaller area or use an export file provided by the OSM community.</html> - 00155.473 E: org.openstreetmap.josm.io.OsmApiException: ResponseCode=400, Error Header=<You requested too many nodes (limit is 50000). Either request a smaller area, or use planet.osm> - 00155.477 E: Bad Request - <html>The OSM server 'api.openstreetmap.org' reported a bad request.<br><br>The area you tried to download is too big or your request was too large.<br>Either request a smaller area or use an export file provided by the OSM community.</html> - 00202.132 E: org.openstreetmap.josm.io.OsmApiException: ResponseCode=400, Error Header=<You requested too many nodes (limit is 50000). Either request a smaller area, or use planet.osm> - 00202.138 E: Bad Request - <html>The OSM server 'api.openstreetmap.org' reported a bad request.<br><br>The area you tried to download is too big or your request was too large.<br>Either request a smaller area or use an export file provided by the OSM community.</html>
Attachments (1)
Change History (13)
comment:1 by , 2 months ago
Resolution: | → wontfix |
---|---|
Status: | new → closed |
follow-up: 4 comment:3 by , 2 months ago
You can use Overpass, you can use GeoFabrik, you can use the actual planet.pbf, etc.
Please mention them in that error popup, with links.
And if limit 50000 is known before - can we show that info without the network call?
follow-up: 5 comment:4 by , 2 months ago
Replying to vitaly-zdanevich:
Please mention them in that error popup, with links.
The error message is direct from the server. We can parse it, but that is fragile. And so I'm disinclined to implement something that will eventually break.
And if limit 50000 is known before - can we show that info without the network call?
Only if we know that there are 50k nodes at the location in question. Which we do not know ahead of time.
comment:5 by , 2 months ago
Replying to taylor.smock:
Replying to vitaly-zdanevich:
Please mention them in that error popup, with links.
The error message is direct from the server. We can parse it, but that is fragile. And so I'm disinclined to implement something that will eventually break.
We have already a "try to make readable" in trunk/src/org/openstreetmap/josm/tools/ExceptionUtil.java. We can expand this. I think here explainBadRequest() is relevant. I think we didn't change this for a long time, so may be some extensions could be helpful.
The rule for this stuff is simple: When you know the message and it comes often then explain, otherwise pass through ;-) The class probably also contains some "can't happen anymore".
follow-up: 7 comment:6 by , 2 months ago
Resolution: | wontfix |
---|---|
Status: | closed → reopened |
It looks like we are actually writing the message ourselves. So I was wrong to close this as WONTFIX
anyway.
comment:7 by , 2 months ago
Replying to taylor.smock:
It looks like we are actually writing the message ourselves.
Only "append". The original message should have been in the dialog as well.
by , 2 months ago
Attachment: | 23925.patch added |
---|
comment:8 by , 2 months ago
Do you know if we have a good reason to not have clickable hyperlinks in HelpAwareOptionPane
?
follow-up: 10 comment:9 by , 2 months ago
Hmm,
- wasn't there when code was written,
- wasn't known to the developers,
- nobody thought it helps?
No, I have no idea why. 😽
P.S. I'd add a 'recommended' to the smaller area and something like 'if you know what you do' for the other options. Could prevent trouble...
comment:10 by , 2 months ago
Replying to stoecker:
P.S. I'd add a 'recommended' to the smaller area and something like 'if you know what you do' for the other options. Could prevent trouble...
Probably a good idea. :) I was thinking about adding recommended
to overpass, but recommending a smaller area is the better option.
comment:12 by , 2 months ago
Milestone: | → 24.09 |
---|
There are several different locations where you can download larger extracts from OSM.
You can use Overpass, you can use GeoFabrik, you can use the actual planet.pbf, etc.
I would recommend the first option since the other two options will use significantly more memory.