[Qgis-user] WMS Problem in QGIS 3.10

Richard Duivenvoorde rdmailings at duif.net
Fri Nov 8 04:56:04 PST 2019


Hi Nick,

You are probably right: I tested in with master and all was ok. Created
a curl request for that request (using the QGIS networklogger plugin):

curl -vv
'https://environment.data.gov.uk/spatialdata/lidar-composite-digital-surface-model-dtm-1m/wms?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&BBOX=49.81411099999999692,-7.098008000000000095,55.83326399999999978,2.029743025539008983&CRS=EPSG:4326&WIDTH=769&HEIGHT=508&LAYERS=Footprint&STYLES=&FORMAT=image/jpeg&DPI=96&MAP_RESOLUTION=96&FORMAT_OPTIONS=dpi:96'
-H 'User-Agent: Mozilla/5.0 QGIS/3.11.0-Master'  --compressed --output
/tmp/foo.jpeg

Which looks fine. Then changing it to "Mozilla/5.0 QGIS/3.10.0-A Coruña"

curl -vv
'https://environment.data.gov.uk/spatialdata/lidar-composite-digital-surface-model-dtm-1m/wms?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&BBOX=49.81411099999999692,-7.098008000000000095,55.83326399999999978,2.029743025539008983&CRS=EPSG:4326&WIDTH=769&HEIGHT=508&LAYERS=Footprint&STYLES=&FORMAT=image/jpeg&DPI=96&MAP_RESOLUTION=96&FORMAT_OPTIONS=dpi:96'
-H 'User-Agent: Mozilla/5.0 QGIS/3.10.0-A Coruña'  --compressed --output
/tmp/foo.jpeg

And you will receive a 400/bad request from the server...

Note that next hackfest will be in:   's-Hertogenbosch ...
Mmm, a ' and a - in it, will probably also give issues :-)

You could try to install a nightlies build (which has 'master' as user
agent (see first curl)... or else another QGIS version with an easier
name :-) ?

In Settings/Network, you can set the first part of the User-Agent
used... It would probably better if the user would be able to set the
whole User-Agent string.

I also recall a discussion with an OSM sysadmin (not you is it?) which
complained about QGIS using a browser User-Agent string (but not
'listening' to cookies etc etc).

Regards,

Richard


On 08/11/2019 13.13, Nick Hopton wrote:
> I have problems with loading UK Environment Agency WMS layers. This has only
> arisen since I installed QGIS 3.10.
> 
> I understand that when QGIS makes a WMS request it adds the current version
> to the User-Agent string, so in version QGIS 3.10.0 this results in
> "Mozilla/5.0 QGIS/3.10.0-A Coruña" and that it might be the "ñ" character
> that's causing the request to be rejected.
> 
> For testing purposes here is a typical EA WMS request:
> 
> https://environment.data.gov.uk/spatialdata/lidar-composite-digital-surface-model-dtm-1m/wms
> 
> I've reported the problem to the EA, but I wonder if I should report it as a
> QGIS bug as well? 
> 
> All of the above assumes that it is the extended set character that is
> causing the problem and of course this might not be the case.
> 
> 
> 
> --
> Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-User-f4125267.html
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> 



More information about the Qgis-user mailing list