properly loads the image and detects corrupted images
This commit is contained in:
@@ -532,6 +532,7 @@ def render_worldtile(chunks, colstart, colend, rowstart, rowend, path):
|
|||||||
for col, row, chunkfile in chunks:
|
for col, row, chunkfile in chunks:
|
||||||
try:
|
try:
|
||||||
chunkimg = Image.open(chunkfile)
|
chunkimg = Image.open(chunkfile)
|
||||||
|
chunkimg.load()
|
||||||
except IOError, e:
|
except IOError, e:
|
||||||
print "Error opening file", chunkfile
|
print "Error opening file", chunkfile
|
||||||
print "Attempting to re-generate it..."
|
print "Attempting to re-generate it..."
|
||||||
|
|||||||
Reference in New Issue
Block a user