<div dir="ltr"><div>Hi,</div><div>I load the network plugin and try with it.</div><div><br></div><div>I don't understand the result , but is why a really don't now how work programmatically qgis.</div><div><br></div><div>I see when try to connetc to retrieve the list of layers , qgis send a classic getcapabilities request.</div><div>This is the url invoked:</div><div><a href="http://www502.regione.toscana.it/ows_ofc/com.rt.wms.RTmap/wms?map=owsofc&SERVICE=WMS&REQUEST=GetCapabilities">http://www502.regione.toscana.it/ows_ofc/com.rt.wms.RTmap/wms?map=owsofc&SERVICE=WMS&REQUEST=GetCapabilities</a></div><div><br></div><div>But when I try to add the choosed layer tothe map, I see from the network plugin that qgis resend another getcapabilites request.</div><div>Sincerelly I don't understand why qgis is need to request still a getcapabilites.</div><div>However meanwhile the first getcapabilies is read from network (this is reported from the plugin), instead the second getcapabilies is taken from the cache.</div><div>Infact, the plugin report me it is "used entry from cache".</div><div><br></div><div>I don't understand why this second getcapabilities is needed, but however I have the cace set to ZERO.</div><div>I have this set because when I work to change sometimes on the wms server to see the result I should empty the cache , so I prefer to have the cache to zero. To have always the last from the network.</div><div><br></div><div>So I try to re-enable a lot of cache size.</div><div><br></div><div>AND NOW IT WORK.</div><div>But sincerelly I don't like to MUST HAVe ALWAYS the cache enabled to have a workable wms.</div><div>Perhaps the real issue is to always use the cache without see that it is set so ZERO.</div><div><br></div><div>However thx for the help.</div><div><br></div><div>Andrea.</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Il giorno ven 5 lug 2019 alle ore 10:04 Richard Duivenvoorde <<a href="mailto:rdmailings@duif.net">rdmailings@duif.net</a>> ha scritto:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 05/07/2019 08.18, Alessandro Pasotti wrote:<br>
<br>
> On Fri, Jul 5, 2019 at 8:13 AM Andrea Peri <<a href="mailto:aperi2007@gmail.com" target="_blank">aperi2007@gmail.com</a><br>
>     <a href="http://www502.regione.toscana.it/ows_ofc/com.rt.wms.RTmap/wms?map=owsofc" rel="noreferrer" target="_blank">http://www502.regione.toscana.it/ows_ofc/com.rt.wms.RTmap/wms?map=owsofc</a><br>
> <br>
>     When I try to add it to a map canvas the connection return le list<br>
>     of layer .<br>
>     Choosing one and using the EPSG:3003.<br>
>     When Add to the canvas I see an error NOT VALID DATA SOURCE.<br>
> <br>
>     The same steps instead work correctly with the old QGIS 2.18.<br>
> <br>
>     Is this confirmed from some other one ?<br>
<br>
I'd say there is something wrong with the server (different endpoints?<br>
url rewriting? proxies?). Because depending on the time and version I<br>
get different results all the time:<br>
- started with QGIS Master and the normal WMS dialog: I saw 10 layers<br>
and could load the aerials<br>
- same session, I opened that node on the browser and then saw MUCH more<br>
layers (a lot of vector layers 'added') and could all load them<br>
- started 3.8 and saw the layers but could not load them<br>
- started master again and saw both in dialog and in browser only the 10<br>
layers<br>
- now I keep seeing only the 10 ortho's (and can load them both in<br>
Master and 3.8.0 which I have here.)<br>
<br>
This is the url QGIS fires:<br>
<a href="http://www502.regione.toscana.it/ows_ofc/com.rt.wms.RTmap/wms?map=owsofc&SERVICE=WMS&REQUEST=GetCapabilities" rel="noreferrer" target="_blank">http://www502.regione.toscana.it/ows_ofc/com.rt.wms.RTmap/wms?map=owsofc&SERVICE=WMS&REQUEST=GetCapabilities</a><br>
as curl command<br>
curl<br>
'<a href="http://www502.regione.toscana.it/ows_ofc/com.rt.wms.RTmap/wms?map=owsofc&SERVICE=WMS&REQUEST=GetCapabilities" rel="noreferrer" target="_blank">http://www502.regione.toscana.it/ows_ofc/com.rt.wms.RTmap/wms?map=owsofc&SERVICE=WMS&REQUEST=GetCapabilities</a>'<br>
-H 'User-Agent: Mozilla/5.0 QGIS/3.9.0-Master'  --compressed<br>
<br>
My guess is there is something with the service...<br>
<br>
Can you maybe sent me a saved project with a layer that does not load<br>
with you?<br>
Can you try to install the QGIS Network logger plugin to see and check<br>
the url's (and replay the urls in the browser)<br>
<br>
Regards,<br>
<br>
Richard<br>
</blockquote></div><br clear="all"><br>-- <br><div dir="ltr" class="gmail_signature">-----------------<br>Andrea Peri<br>. . . . . . . . . <br>qwerty àèìòù<br>-----------------<br></div>