[OSM-talk] Informationfreeway defaults to sea if tile unloadable, e.g. due to proxy being unreachable

80n 80n80n at gmail.com
Fri Aug 17 10:16:18 BST 2007

The reason for serving a sea tile on error was to avoid serving black tiles
around the outside of the map at very low zoom levels (1, 2, 3,...)

I don't know why, but OpenLayers tries to request tiles with addresses like
y=-1 if you pan outside the normal boundaries of the planet.  If we could
fix that then it would be possible to serve up a proper 404 tile when there
really is a 404.

And your point about falling back to another proxy is a good one.  I'll look
into that.

On 8/17/07, D Tucny <d at tucny.com> wrote:
> Hi Folks,
> I've been noticing recently that for me, when using informationfreeway
> that with the default layer selection of 'The Map' random tiles are showing
> as sea, but, if I choose direct, they don't show as sea anymore, which is
> what I've been doing...
> In an attempt to isolate the problem, rather than just always using dev
> direct which isn't very dev friendly, I just tried each of the layers in
> turn to find out what was giving sea... What appears to be causing it is
> that for some reason I'm not able to resolve osm.sandos.se from here, so,
> attempts to load tiles from that proxy are failing and the javascript is
> just putting a sea tile in place instead, thanks to this snippet of code it
> would seem...
> OpenLayers.Util.onImageLoadError = function() {
>       this.src='http://www.informationfreeway.org/images/emptysea.png'
>    }
> I'm not really sure how openlayers works or javascript generally, but,
> would it not be possible for this error handler to instead of just
> displaying a sea tile at the first sign of a problem, perhaps try another
> proxy first? I'm not sure, but, isn't it very unlikely that any error would
> actually be due to the tile being sea? I've tried a few random bits of sea
> directly from dev, and it does seem to be serving a blank sea tile even
> though there are no tiles on disk according to the info page, rather than
> actually returning any form of error...
> d
> _______________________________________________
> talk mailing list
> talk at openstreetmap.org
> http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/talk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/talk/attachments/20070817/d76c17ba/attachment.html>

More information about the talk mailing list