libcloud-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] hldh214 opened a new pull request #1277: fix scheme issue in https case
Date Mon, 28 Jan 2019 13:29:28 GMT
hldh214 opened a new pull request #1277: fix scheme issue in https case
URL: https://github.com/apache/libcloud/pull/1277
 
 
   ## fix scheme issue in https case
   
   ### Description
   
   Hello everyone, first apologize my poor english
   
   im beginner and i have a question about http proxy(https://libcloud.readthedocs.io/en/latest/other/using-http-proxy.html)
   
   from here: https://github.com/apache/libcloud/blob/trunk/libcloud/http.py#L117
   ```python
   if parsed.scheme != 'http':
       raise ValueError('Only http proxies are supported')
   ```
   
   i guess this code means we cant use proxy on https requests, sounds not cool for nowadays
   
   from here: https://github.com/apache/libcloud/blob/trunk/libcloud/http.py#L102
   ```python
   self.session.proxies = {
       # requests assume `self.proxy_scheme` as http/https protocol
       # so if we want proxy our https request
       # we need 2 add `'https': 'http://127.0.0.1:1080'` instead of `http` k/v pair
       self.proxy_scheme: proxy_url
   }
   ```
   
   i dont know if this `self.proxy_scheme` has other meaning or not
   please let me know if i have any misunderstand or mistake, Thanks <3
   
   
   
   ### Status
   
   - done, ready for review
   
   ### Checklist (tick everything that applies)
   
   - [x] [Code linting](http://libcloud.readthedocs.org/en/latest/development.html#code-style-guide)
(required, can be done after the PR checks)
   - [x] Documentation
   - [x] [Tests](http://libcloud.readthedocs.org/en/latest/testing.html)
   - [x] [ICLA](http://libcloud.readthedocs.org/en/latest/development.html#contributing-bigger-changes)
(required for bigger changes)
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message