[mapserver-dev] GetFeatureInfo problems

Fabian Schindler fabian.schindler at eox.at
Tue Mar 5 02:13:58 PST 2013


Dear devs,

I just stumbled over what I think is a bug in both the templating
mechanism aswell as the msIO system (or the Python mapscript interface
to it). I added a minimal map, template and script in the attachment.

Basically what I do is the following:
 - Dynamically create a map with one layer
 - Set up an html template
 - Add a shape (feature) to the layer
 - Dispatch a WMS 1.3 GetFeatureInfo request

When the request "hits" the feature, all is well and I get a correct
template response. On the other hand, when I "miss" the feature no
templates are rendered, even the header and footer are left out; which I
consider the first bug.

The second problem is when I try to retrieve the bytes from the
installed stdout buffer (+content type):

msIO_stripStdoutBufferContentType: General error message. Corrupt
Content-Type header.

If I use `msIO_getStdoutBufferBytes()` instead, I get the following:
'Content-Type: text/html\r\n\r\n' so it seems that the header is
correct, but the response content is simply missing.

I get correct (still empty) responses when I use other response formats
like GML or text/plain.

Is there a possibility to get the correct content-type / response from
such degenerated messages?

Regards
Fabian
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20130305/1ad81797/attachment.html>
-------------- next part --------------
MAP

STATUS ON
EXTENT -180 -90 180 90
SIZE 400 300
IMAGETYPE png24

CONFIG MS_ERRORFILE "stderr"

WEB
  METADATA
    "ows_onlineresource" ""
    "ows_enable_request" "*"
    "ows_feature_info_mime_type" "text/html"
  END
END

PROJECTION
  "init=epsg:4326"
END


END
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.py
Type: text/x-python
Size: 1660 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20130305/1ad81797/attachment.py>


More information about the mapserver-dev mailing list