Which types of files can images.get_serving_url() serve?
I'm interested to know which types of files can be served by GAE's image server.
Or better yet, the location of a list/tuple of these types stored in the libr开发者_C百科ary somewhere (to automatically support future formats).
While Java library offers Enum Image.Format
listing all the Image formats usable by the images api, Python does not seem to offer this kind of information.
Looking at the source code, the list of supported image format is hardcoded as for example:
if img_format not in ("BMP", "GIF", "ICO", "JPEG", "PNG", "TIFF"):
raise apiproxy_errors.ApplicationError(
images_service_pb.ImagesServiceError.NOT_IMAGE)
It looks like a legit reason to file a new feature request.
精彩评论