Summary: | Use libproxy to autofill proxy list | ||
---|---|---|---|
Product: | Telepathy | Reporter: | Jonny Lamb <jonny.lamb> |
Component: | butterfly | Assignee: | Telepathy bugs list <telepathy-bugs> |
Status: | RESOLVED FIXED | QA Contact: | Telepathy bugs list <telepathy-bugs> |
Severity: | normal | ||
Priority: | medium | CC: | olivier |
Version: | git master | Keywords: | patch |
Hardware: | Other | ||
OS: | All | ||
URL: | http://git.collabora.co.uk/?p=user/jonny/telepathy-butterfly.git;a=shortlog;h=refs/heads/proxies | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Bug Depends on: | 22508 | ||
Bug Blocks: |
Description
Jonny Lamb
2010-03-16 19:22:07 UTC
+ # libproxy documentation states: + # + # * The format of the returned proxy strings are as follows: + # * - http://[username:password@]proxy:port + # * - socks://[username:password@]proxy:port + # * - direct:// + # + # We've already removed socks proxies, and dealt with direct:// + # above, so the only other option is http://. Actually, the documentation on the website state there maybe other proxying protocols returned such as rstp:// see http://code.google.com/p/libproxy/wiki/HowTo So it maybe best to filter the list to only keep http:// here instead : + # Remove socks proxies that papyon doesn't support. + proxies = [p for p in proxies if not proxy.startswith('socks')] Also, be sure to mention in the NEWS file and announce the suggested dependency on python-libproxy (In reply to comment #1) > Actually, the documentation on the website state there maybe other proxying > protocols returned such as rstp:// see > http://code.google.com/p/libproxy/wiki/HowTo > So it maybe best to filter the list to only keep http:// here instead : Good catch, I clearly didn't read it well enough. I've appended another commit to fix this. > Also, be sure to mention in the NEWS file and announce the suggested dependency > on python-libproxy I will when I merge the branch. There has already been another release since I wrote it and I don't want to deal with NEWS conflicts. Directly when trying to connect : ERROR:Butterfly.Connection:Failed to create Connection Traceback (most recent call last): File "/home/olivier/Projects/telepathy-butterfly/butterfly/connection.py", line 104, in __init__ self._use_next_proxy() File "/home/olivier/Projects/telepathy-butterfly/butterfly/connection.py", line 174, in _use_next_proxy del self._proxies['http'] KeyError: 'http' Erreur de segmentation (In reply to comment #3) > KeyError: 'http' sigh, fixed. I merged this and updated NEWS. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.