Skip to content
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

[BUG] Error 404 with WMTS map #1284

Closed
kttary opened this issue Jun 21, 2022 · 8 comments
Closed

[BUG] Error 404 with WMTS map #1284

kttary opened this issue Jun 21, 2022 · 8 comments
Labels
bug This issue reports broken functionality or another error invalid This bug could not be reproduced or does not exist, or is very low quality

Comments

@kttary
Copy link

kttary commented Jun 21, 2022

I add a WMTS base map tile and flutter map ramdomly throw _network_image_io.dart (lines 121: rethrow). The exception message is HTTP request failed, statusCode: 404, https://xxx/webmercator/5/25/14.png. The tile 5/25/14.png does exists on the server. Another time it throw another error, Connection closed while receiving data. What could be causing this problem and how to skip this error by just showing an empty tile image for example?

@kttary kttary added bug This issue reports broken functionality or another error needs triage This new bug report needs reproducing and prioritizing labels Jun 21, 2022
@ibrierley
Copy link
Collaborator

A 404 usually means that the file doesn't exist, so you need to try and figure why the server thinks it doesn't.

@JaffaKetchup
Copy link
Member

As @ibrierley said, 404 is the Not Found HTTP error code.
Can you guarantee the image you are requesting actually exists? Try opening the erroring tile in a browser by typing in the URL

@kttary
Copy link
Author

kttary commented Jun 21, 2022

i did open the erroring image via browser and it returning the single image on my browser. any options to pass the error without throwing an error?

@kttary
Copy link
Author

kttary commented Jun 21, 2022

i did open the erroring image via browser and it returning the single image on my browser. any options to pass the error without throwing an error?
tile

@JaffaKetchup
Copy link
Member

I'd recommend using the DevTools (network tab) to see what requests are actually made and check those.

@JaffaKetchup
Copy link
Member

Closing this now, as I'm pretty sure it's not a bug in flutter_map. Hope you found a solution!

@JaffaKetchup JaffaKetchup closed this as not planned Won't fix, can't repro, duplicate, stale Jun 23, 2022
@JaffaKetchup JaffaKetchup added invalid This bug could not be reproduced or does not exist, or is very low quality non-fatal and removed needs triage This new bug report needs reproducing and prioritizing labels Jun 23, 2022
@JaffaKetchup JaffaKetchup changed the title Error on _network_image_io.dart [BUG] Error 404 with WMTS map Jun 27, 2022
@kttary
Copy link
Author

kttary commented Jul 3, 2022

I think this is because poor connection or wms my server performance, sometime it is not deliver the image timely and produce the error. It also happen to OSM sometimes. Not exactly error 404 but it throw throw _network_image_io.dart. Back to my question, is it possible to just return a blank image for example in case this error occur? I think my problem similar to #1203

@JaffaKetchup
Copy link
Member

@kttary You may be able to use the errorImage parameter in TileLayerOptions? #1203 will have to wait a while, as it's low priority as a feature request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue reports broken functionality or another error invalid This bug could not be reproduced or does not exist, or is very low quality
Projects
None yet
Development

No branches or pull requests

3 participants