[Tilecache] TileCache with 2 layers & Java Servlet (Jon)
Christopher Schmidt
crschmidt at metacarta.com
Wed Jun 20 07:37:47 EDT 2007
On Wed, Jun 20, 2007 at 08:48:03AM +0100, Jon Blower wrote:
> if sys.platform.startswith("java"): # Detects Jython
> from java.io import File
> def canRead(path):
> return File(path).canRead()
> def canWrite(path):
> return File(path).canWrite()
> else:
> def canRead(path):
> return os.access(path, os.R_OK)
> def canWrite(path):
> return os.access(path, os.W_OK)
>
> (Chris, perhaps these changes could be incorporated into the trunk if
> you have time?) Unless other things have changed in TileCache, this
> should work. If you try this, please let me know how you get on!
Does no platform understand that os is supposed to wrap this stuff for
you? Sigh. It seems like this same thing comes up in IronPython as
well. Oh hey, what do you know: "(The similarity of the two approaches
is not surprising considering that Jim Hugunin is the author of both.)"
Grargh.
I've patched TileCache to do this, though I implemented it in a
slightly different way. I'm going to try adn get IronPython up and
running and patch TileCache for that too, and then fix the threshold
bug, and release a final cut of the 1.x branch as 1.9 sometime next
week, after which I'll go ahead and start refactoring for 2.0 in a
branch.
Regards,
--
Christopher Schmidt
MetaCarta
More information about the Tilecache
mailing list