Some of the static maps returned by the Google Maps API are in RGBA mode. These images cannot be saved as .jpg files.
How to replicate this issue:
Delete the cache folder (/mapscache/)
Run the example.py script
Observe the following error message:
File "/home/mhubrich/GooMPy/goompy/__init__.py", line 78, in _grab_tile
tile.save(filename)
File "/usr/local/lib/python2.7/dist-packages/PIL/Image.py", line 1930, in save
save_handler(self, fp, filename)
File "/usr/local/lib/python2.7/dist-packages/PIL/JpegImagePlugin.py", line 607, in _save
raise IOError("cannot write mode %s as JPEG" % im.mode)
IOError: cannot write mode RGBA as JPEG
Some of the static maps returned by the Google Maps API are in RGBA mode. These images cannot be saved as .jpg files.
How to replicate this issue:
/mapscache/
)example.py
script