Bug report #14595

WMS layer can be loaded but is not displayed

Added by klaudio collaku about 8 years ago. Updated about 8 years ago.

Status:Closed
Priority:Normal
Assignee:-
Category:Web Services clients/WMS
Affected QGIS version:2.12.1 Regression?:No
Operating System:windows Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:22563

Description

I am trying to import WMS from geoserver link to QGIS 2.8.4 & the latest 2.12.1:
http://geoportal.asig.gov.al/Services/host/host.ashx?url=http://localhost:8080/geoserver/asig/wmsx%x%

QGIS get the request and show the layers of the workspace, and also the get info. My problem is that the layer is not visible in the view.

It works fine with version 2.2:

wms1.png (344 KB) Giovanni Manghi, 2016-04-09 08:43 AM

History

#1 Updated by Jukka Rahkonen about 8 years ago

Server address is returning for me just "The resource you are looking for might have been removed, had its name changed, or is temporarily unavailable."

#3 Updated by Jukka Rahkonen about 8 years ago

That service seems to redirect GetCapabilities request and my QGIS 2.12 never gets GetCapabilities. I could test the service with OpenJUMP and it does get maps but only if the advertised GetMap URL is omitted. I hope that these findings help in debugging.

Response to the original GetCapabilities
----------------------------------------

HTTP/1.1 302 Found
Cache-Control: private
Transfer-Encoding: chunked
Content-Type: text/html; charset=utf-8
Location: /Services/host/host.ashx?url=http://localhost:8080/geoserver/asig/wms&SERVICE=WMS&REQUEST=GetCapabilities&AspxAutoDetectCookieSupport=1
Server: Microsoft-IIS/8.5
X-AspNet-Version: 4.0.30319
X-Powered-By: ASP.NET
Date: Fri, 01 Apr 2016 14:17:48 GMT
Connection: Keep-Alive
Set-Cookie: AspxAutoDetectCookieSupport=1; path=/
Age: 0

This reads GetCapabilities with a browser
-----------------------------------------

http://geoportal.asig.gov.al/Services/host/host.ashx?url=http://localhost:8080/geoserver/asig/wms&REQUEST=GetCapabilities&version=1.3.0

This gets a map
---------------
http://geoportal.asig.gov.al/Services/host/host.ashx?url=http://localhost:8080/geoserver/asig/wms&REQUEST=GetMap&SERVICE=WMS&VERSION=1.1.1&WIDTH=1143&HEIGHT=602&LAYERS=kufi_admin&TRANSPARENT=TRUE&FORMAT=image%2Fpng&BBOX=96772.62253920198,4381348.390199999,761038.957460799,4731206.9498000005&SRS=EPSG:32634&STYLES=

#4 Updated by Anita Graser about 8 years ago

Seems to work fine in master. Can you update and try again?

#5 Updated by Anita Graser about 8 years ago

  • Subject changed from wms not to WMS layer can be loaded but is not displayed

#6 Updated by Jukka Rahkonen about 8 years ago

I installed version 2.14.1 with OSGeo4W and made a new trial.

- I can create connection and read GetCapabilities with URL http://geoportal.asig.gov.al/Services/host/host.ashx?url=http://localhost:8080/geoserver/asig/wms
- I can't read layers from the service. If I select for example layer "kufi_admin" and press the Add button I can see immediately a red warning in the project window:

Invalid Layer: Raster layer Provider is not valid (provider: wms, URI: contextualWMSLegend=0&crs=EPSG:4326&dpiMode=7&featureCount=10&format=image/png&layers=kufi_admin&styles=&url=http://geoportal.asig.gov.al/Services/host/host.ashx?url%3Dhttp://localhost:8080/geoserver/asig/wms

From to log of my local proxy I can see that QGIS is sending GetCapabilies and it receives the response which is evident because the layer list is created. However, pressing the Add-button does not lead to any http-request but the errow message that I posted above comes immediately. The message in the message log window is not very informative:

"Download of capabilities failed: Protocol "" is unknown"

#7 Updated by Giovanni Manghi about 8 years ago

  • File wms1.png added
  • Target version deleted (Future Release - Nice to have)
  • Assignee deleted (klaudio collaku)
  • Status changed from Open to Feedback

no apparent problems here on master, see attached image.

#8 Updated by Jukka Rahkonen about 8 years ago

Works for my too now with the same QGIS version 2.14.1.
For my mind this means that the problem exists but it is fuzzy and it happens sometimes, in some environments, but sometimes not.

What I did was to change my proxy settings from company proxy into local proxy and back to company proxy. After these actions GetMaps work and I do not get any more the "Download of capabilities failed: Protocol "" is unknown" errors. I do not believe that this is a workaround that works for everybody but hopefully helps with debugging. What gets refreshed when proxy settings are changed?

#9 Updated by klaudio collaku about 8 years ago

  • % Done changed from 0 to 100
  • Status changed from Feedback to Closed
  • Target version set to Version 2.14

Also available in: Atom PDF