Bug report #5212

Proxy settings ignored for layers

Added by Andrew DeMerchant almost 12 years ago. Updated over 6 years ago.

Status:Closed
Priority:Normal
Assignee:Alessandro Pasotti
Category:Network
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:Yes Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:14949

Description

Proxy settings are ignored when trying to add a vector layer that is on the web, ie:

http://geonb.snb.ca/ArcGIS/rest/services/GeoNB_ENV_Flood/MapServer/3/query?text=0&geometry=&geometryType=esriGeometryEnvelope&inSR=&spatialRel=esriSpatialRelIntersects&where=&returnGeometry=true&outSR=&outFields=&f=pjson

If I use a direct connection to the internet, this works fine. But I've watched my proxy server while trying with the proxy settings, and I've seen no activity by QGIS.

The settings work fine for getting/using plugins. Just not for this...


Related issues

Related to QGIS Application - Bug report #8600: QGIS 2.0 not working with NTLM proxy Closed 2013-09-12
Duplicated by QGIS Application - Bug report #14616: GDAL does not take care of Proxy settings Closed 2016-04-05

Associated revisions

Revision d8fc6e87
Added by Alessandro Pasotti over 6 years ago

[bugfix] Apply proxy configuration to OGR connections

Fixes #5212 Proxy settings ignored for layers

History

#1 Updated by Paolo Cavallini over 11 years ago

  • Target version set to Version 2.0.0

#2 Updated by Giovanni Manghi over 10 years ago

  • Status changed from Open to Feedback
  • Target version changed from Version 2.0.0 to 70

still true with qgis 2.0?

#3 Updated by Giovanni Manghi over 10 years ago

  • Category set to Network

#4 Updated by Andrew DeMerchant over 10 years ago

Doesn't appear to work any better in 2.0 for me...It looks like it's behaving exactly like before - no attempt to connect to my proxy at all, and it's giving an error.

#5 Updated by Giovanni Manghi over 10 years ago

  • Affected QGIS version changed from 1.7.4 to 2.0.1
  • Status changed from Feedback to Open

#6 Updated by Jeremy Palmer over 10 years ago

This ticket might relate #8600. Note the plugin installer is not working correctly with the proxy server in 2.0 now.

#7 Updated by Jürgen Fischer over 10 years ago

The proxy settings only apply to networks requests QGIS does directly, not those done via OGR. I think OGR uses libcurl for that. Try setting the CURLOPTPROXY environment variable (or http_proxy).

#8 Updated by Andrew DeMerchant over 10 years ago

I can tell you that the plugin installer worked fine with my proxy settings, for what it's worth.

#9 Updated by Andrew DeMerchant over 10 years ago

The http_proxy environment variable did the trick - not sure how you can handle that all within QGIS, but that definitely made this work for me...

#10 Updated by Jürgen Fischer over 10 years ago

  • Target version changed from 70 to Future Release - High Priority

#11 Updated by Marco Lechner almost 8 years ago

  • Affected QGIS version changed from 2.0.1 to 2.14.0

version 2.14.0 is still affected
see #14616

#12 Updated by Marco Lechner almost 8 years ago

Could it be an apropriate solution to set GDAL_HTTP_PROXY ([[https://trac.osgeo.org/gdal/wiki/ConfigOptions#GDAL_HTTP_PROXY]]) somehow in [[https://github.com/qgis/QGIS/blob/master/src/providers/gdal/qgsgdalprovider.cpp]] even this will overwrite eventually set http_proxy variables?

#13 Updated by Giovanni Manghi almost 7 years ago

  • Regression? set to No
  • Easy fix? set to No

#14 Updated by Alessandro Pasotti over 6 years ago

  • Assignee set to Alessandro Pasotti
  • Description updated (diff)
  • Affected QGIS version changed from 2.14.0 to master

#15 Updated by Alessandro Pasotti over 6 years ago

  • Status changed from Open to In Progress
  • Pull Request or Patch supplied changed from No to Yes

#16 Updated by Anonymous over 6 years ago

  • Status changed from In Progress to Closed
  • % Done changed from 0 to 100

Also available in: Atom PDF