[MapProxy] Fw: Missing Content-Type header in WMS source

Magnus E magnus.account at gmail.com
Mon Oct 29 04:53:32 PDT 2012


Forwarding the message to the mailing list, forgot to include mapproxy at lists.osgeo.org in the To line.

From: Magnus E 
Sent: Monday, October 29, 2012 12:47 PM
To: Oliver Tonnhofer 
Subject: Re: [MapProxy] Missing Content-Type header in WMS source

A big thank you for your replies Oliver, they got me on the right track and it took me just a minute to solve the issue by simply commenting out line 62 in client\wms.py: self._check_resp(resp).  I thought the problem was much more complicated so yesterday I spent hours going through various .py files, trying to set the response header or mimetype somewhere. Your replies to me and André made me realize that the problem was not as complicated as I thought. Compliments on a great piece of software.

Magnus E.

-----Original Message----- 
From: Oliver Tonnhofer 
Sent: Monday, October 29, 2012 8:36 AM 
To: Magnus E 
Cc: mapproxy at lists.osgeo.org 
Subject: Re: [MapProxy] Missing Content-Type header in WMS source 


On 28.10.2012, at 15:12, Magnus E wrote:
> Is there any way of telling Mapproxy explicitly that the incoming content is a png image? The only requests I make are for png images, so it probably wouldn't complicate matters if I let Mapproxy somehow assume that the source content is always a png image when the Content-Type header is missing.

There is no configuration option for that. But maybe MapProxy is checking too much in this case? I can change this check to only compare the Content-Type if it is present. Other parts of MapProxy already handle data that is not a valid image and MapProxy also checks for the HTTP status code (2xx). 


Regards,
Oliver

-- 
Oliver Tonnhofer    | Omniscale GmbH & Co KG    | http://omniscale.de
http://mapproxy.org | https://github.com/olt    | @oltonn




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapproxy/attachments/20121029/ac3f9347/attachment.html>


More information about the MapProxy mailing list