<HTML dir=ltr><HEAD><TITLE>Re: [OSM-talk] [OSM-dev] Online/offline slippy map finished.</TITLE>
<META http-equiv=Content-Type content="text/html; charset=unicode">
<META content="MSHTML 6.00.2900.3314" name=GENERATOR></HEAD>
<BODY>
<DIV id=idOWAReplyText47672 dir=ltr>
<DIV dir=ltr><FONT face="Times New Roman" color=#000000 size=3>lol, thank you Sebastian for that code. I have tested it on Windows XP and the only problem is that images are not shown, everything else seems to be in place. I don't think it's because of using / instead of \. Apparently the HttpServer only delivers the first bytes of the PNG files, and then closes the connection. I have tried to add the file length and proper file type in the header but it still closes the connection too soon.</FONT></DIV>
<DIV dir=ltr><FONT face="Times New Roman" color=#000000 size=3></FONT> </DIV>
<DIV dir=ltr><FONT face="Times New Roman" color=#000000 size=3>wget.exe is unable to get the whole image file either.</FONT></DIV>
<DIV dir=ltr>I'll keep on trying, lol</DIV>
<DIV dir=ltr> </DIV>
<DIV dir=ltr>Cheers,</DIV>
<DIV dir=ltr>Lucas<BR>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>De:</B> talk-bounces@openstreetmap.org en nombre de Sebastian Spaeth<BR><B>Enviado el:</B> vie 09/05/2008 14:01<BR><B>Para:</B> Nick Black<BR><B>CC:</B> Openstreetmap Dev list; OSM Talk List<BR><B>Asunto:</B> Re: [OSM-talk] [OSM-dev] Online/offline slippy map finished.<BR></FONT><BR></DIV></DIV>
<DIV>
<P><FONT size=2>Nick Black wrote:<BR>> Great idea - this could be really useful.<BR>><BR>> I get lots of errors running on OS X 10.5.2 though:<BR><BR>>   File "./pymap", line 47, in do_GET<BR>>     if e.errno == os.errno.ENOENT:<BR>> AttributeError: 'module' object has no attribute 'errno'<BR>> ----------------------------------------<BR><BR>I guess this should work on all (unixy) OS then:<BR><BR>-import urllib,re,os,sys,stat<BR>+import urllib,re,os,sys,stat,errno<BR>-     if e.errno != os.errno.EEXIST<BR>+     if e.errno != errno.EEXIST<BR>-           if e.errno == os.errno.ENOENT<BR>+           if e.errno == errno.ENOENT<BR><BR><BR>I updated the tar ball on dev.openstreetmap.org as well.<BR><BR>spaetz<BR><BR>_______________________________________________<BR>talk mailing list<BR>talk@openstreetmap.org<BR><A href="http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/talk">http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/talk</A><BR></FONT></P></DIV></BODY></HTML>