Bug#717563:
Hey Kay, the patch against python-debianbts has been applied and the package uploaded: do you mind update your patch against reportbug to include it? thanks! On Wed, Dec 26, 2018 at 4:16 PM Sandro Tosi wrote: > > control: block -1 by 914057 > > On Fri, Nov 30, 2018 at 9:09 PM Kay Mccormick wrote: > > > > I managed to fix this (at least for the get_bugs case) but it required > > changes > > to python-debianbts package. > > > > I have included two patches for feedback. There are some caveats: > > > > * Other method calls need to be patched in reportbug/debbugs.py. > > * pysimplesoap will use alternatve http transport libraries if httplib2 is > > unavailable, and proxy support is unavailable for some of the other > > transports such as urllib2. > > * reportbug uses urllib2 over httplib2, and pysimplesoap uses httplib2 over > > urllib2, but i don't think httplib2 is a dependency of reportbug - > > therefore, that must changed also or pysimplesoap wont pick it up. > > i see you opened 914057 - let's first see how the python-debianbts > maintainer reacts (we need low-level support first anyway). > > Thanks, > > -- > Sandro "morph" Tosi > My website: http://sandrotosi.me/ > Me at Debian: http://wiki.debian.org/SandroTosi > G+: https://plus.google.com/u/0/+SandroTosi -- Sandro "morph" Tosi My website: http://sandrotosi.me/ Me at Debian: http://wiki.debian.org/SandroTosi G+: https://plus.google.com/u/0/+SandroTosi
Bug#717563:
control: block -1 by 914057 On Fri, Nov 30, 2018 at 9:09 PM Kay Mccormick wrote: > > I managed to fix this (at least for the get_bugs case) but it required changes > to python-debianbts package. > > I have included two patches for feedback. There are some caveats: > > * Other method calls need to be patched in reportbug/debbugs.py. > * pysimplesoap will use alternatve http transport libraries if httplib2 is > unavailable, and proxy support is unavailable for some of the other > transports such as urllib2. > * reportbug uses urllib2 over httplib2, and pysimplesoap uses httplib2 over > urllib2, but i don't think httplib2 is a dependency of reportbug - therefore, > that must changed also or pysimplesoap wont pick it up. i see you opened 914057 - let's first see how the python-debianbts maintainer reacts (we need low-level support first anyway). Thanks, -- Sandro "morph" Tosi My website: http://sandrotosi.me/ Me at Debian: http://wiki.debian.org/SandroTosi G+: https://plus.google.com/u/0/+SandroTosi
Bug#717563:
I managed to fix this (at least for the get_bugs case) but it required changes to python-debianbts package. I have included two patches for feedback. There are some caveats: * Other method calls need to be patched in reportbug/debbugs.py. * pysimplesoap will use alternatve http transport libraries if httplib2 is unavailable, and proxy support is unavailable for some of the other transports such as urllib2. * reportbug uses urllib2 over httplib2, and pysimplesoap uses httplib2 over urllib2, but i don't think httplib2 is a dependency of reportbug - therefore, that must changed also or pysimplesoap wont pick it up. diff --git a/reportbug/checkversions.py b/reportbug/checkversions.py index d94bf76..c37399d 100644 --- a/reportbug/checkversions.py +++ b/reportbug/checkversions.py @@ -84,7 +84,7 @@ def get_versions_available(package, timeout, dists=None, http_proxy=None, arch=' # or to binary packages available on the current arch url += '=source,all,' + arch try: -page = open_url(url) +page = open_url(url, http_proxy, timeout) except NoNetwork: return {} except urllib.error.HTTPError as x: diff --git a/reportbug/debbugs.py b/reportbug/debbugs.py index 92db224..c6bd6d0 100644 --- a/reportbug/debbugs.py +++ b/reportbug/debbugs.py @@ -1069,6 +1069,13 @@ def get_reports(package, timeout, system='debian', mirrors=None, version=None, pkg_filter = 'src' else: pkg_filter = 'package' +if http_proxy: +from urllib.parse import urlparse +parsed_url = urlparse(http_proxy) +# Probably ought to use more info for the proxy, if applicable. +debianbts.set_soap_proxy(dict(proxy_host=parsed_url.hostname, + proxy_port=parsed_url.port)) + bugs = debianbts.get_bugs(pkg_filter, package) else: bugs = list(map(int, package)) diff --git a/reportbug/urlutils.py b/reportbug/urlutils.py index c16e48c..a3f2e20 100644 --- a/reportbug/urlutils.py +++ b/reportbug/urlutils.py @@ -146,6 +146,7 @@ def open_url(url, http_proxy=None, timeout=60): proxies = urllib.request.getproxies() if http_proxy: proxies['http'] = http_proxy +proxies['https'] = http_proxy try: page = urlopen(url, proxies, timeout) debian-bts.patch Description: Binary data
Bug#717563:
debianbts.get_bugs does not support passing of proxy into SoapClient. I would try to fix this but I am not sure right now of the correct approach. pysimplesoap uses httplib2 if it is available and if a specific transport library is not specified in the call to get_http_wrapper, which it is not in this application. See patch above for other changes to reportbug to support proxy handling. Take note that the patch sets the proxy for 'https' to the proxy specified for 'http'. Reportbug itself only allows to specify a single proxy for http, so this was required to support proxying for https. Probably another argument should be added to reportbug for https proxy configuration, in order to prevent simply using the http proxy, which may not be correct. On the other hand, I believe the environment configuration could be changed (i.e. stuff the proxy information into os.environ for the duration of the reportbug session). This would reduce in fewer code changes, which can be considered a good thing. I dont know what approach people wish to take, but part of this is a defect in debianbts which is another package.
Bug#717563: (no subject)
diff --git a/reportbug/checkversions.py b/reportbug/checkversions.py index d94bf76..c37399d 100644 --- a/reportbug/checkversions.py +++ b/reportbug/checkversions.py @@ -84,7 +84,7 @@ def get_versions_available(package, timeout, dists=None, http_proxy=None, arch=' # or to binary packages available on the current arch url += '=source,all,' + arch try: -page = open_url(url) +page = open_url(url, http_proxy, timeout) except NoNetwork: return {} except urllib.error.HTTPError as x: diff --git a/reportbug/urlutils.py b/reportbug/urlutils.py index c16e48c..a3f2e20 100644 --- a/reportbug/urlutils.py +++ b/reportbug/urlutils.py @@ -146,6 +146,7 @@ def open_url(url, http_proxy=None, timeout=60): proxies = urllib.request.getproxies() if http_proxy: proxies['http'] = http_proxy +proxies['https'] = http_proxy try: page = urlopen(url, proxies, timeout)
Bug#717563: (no subject)
diff --git a/reportbug/checkversions.py b/reportbug/checkversions.py index d94bf76..c37399d 100644 --- a/reportbug/checkversions.py +++ b/reportbug/checkversions.py @@ -84,7 +84,7 @@ def get_versions_available(package, timeout, dists=None, http_proxy=None, arch=' # or to binary packages available on the current arch url += '=source,all,' + arch try: -page = open_url(url) +page = open_url(url, http_proxy, timeout) except NoNetwork: return {} except urllib.error.HTTPError as x: diff --git a/reportbug/urlutils.py b/reportbug/urlutils.py index c16e48c..a3f2e20 100644 --- a/reportbug/urlutils.py +++ b/reportbug/urlutils.py @@ -146,6 +146,7 @@ def open_url(url, http_proxy=None, timeout=60): proxies = urllib.request.getproxies() if http_proxy: proxies['http'] = http_proxy +proxies['https'] = http_proxy try: page = urlopen(url, proxies, timeout)
Bug#717563: re: reportbug: web access thru proxy not available
I think I found where the bug is: https://github.com/ProgVal/reportbug/blob/19fb757df622419f39360627060c9bd0304e0e25/reportbug/debbugs.py#L1209 reportbugs calls debianbts without setting an http_proxy variable to it. A way to fix this would be by setting up the proxy before each call to the debianbts library like so: debianbts._soap_client_kwargs['proxy'] = http_proxy I tried fixing it myself but then I ran into a problem of "proxy is not supported with urllib2 transport", thrown by pysimplesoap. Somehow I need to change the requests provider of it so it can take proxy. This probably request the help of the maintainer of debianbts. On Wed, 1 Mar 2017 15:50:09 -0300 (UYT) =?utf-8?B?SXbDoW4=?= Baldo < iba...@adinet.com.uy> wrote: > Still happens with 7.1.4: > > $ LANG=C.UTF-8 reportbug sane-utils > Unable to init server: Could not connect: Connection refused > Unable to init server: Could not connect: Connection refused > *** Welcome to reportbug. Use ? for help at prompts. *** > Note: bug reports are publicly archived (including the email address of the submitter). > Detected character set: UTF-8 > Please change your locale if this is incorrect. > > Using 'Ivan Baldo' as your from address. > Getting status for sane-utils... > Verifying package integrity... > Checking for newer versions at madison, incoming.debian.org and http://ftp-master.debian.org/new.html > > Your version (1.0.25-3) of sane-utils appears to be out of date. > The following newer release(s) are available in the Debian archive: > experimental: 1.0.26~git20151121-1 > Do you still want to file a report [y|N|q|?]? y > Will send report to Debian (per lsb_release). > Querying Debian BTS for reports on sane-backends (source)... > Unable to connect to Debian BTS (error: "OSError(101, 'Network is unreachable')"); continue [y|N|?]? n >
Bug#717563: reportbug: web access thru proxy not available
Still happens with 7.1.4: $ LANG=C.UTF-8 reportbug sane-utils Unable to init server: Could not connect: Connection refused Unable to init server: Could not connect: Connection refused *** Welcome to reportbug. Use ? for help at prompts. *** Note: bug reports are publicly archived (including the email address of the submitter). Detected character set: UTF-8 Please change your locale if this is incorrect. Using 'Ivan Baldo' as your from address. Getting status for sane-utils... Verifying package integrity... Checking for newer versions at madison, incoming.debian.org and http://ftp-master.debian.org/new.html Your version (1.0.25-3) of sane-utils appears to be out of date. The following newer release(s) are available in the Debian archive: experimental: 1.0.26~git20151121-1 Do you still want to file a report [y|N|q|?]? y Will send report to Debian (per lsb_release). Querying Debian BTS for reports on sane-backends (source)... Unable to connect to Debian BTS (error: "OSError(101, 'Network is unreachable')"); continue [y|N|?]? n
Bug#717563: reportbug: web access thru proxy not available
Sorry, I checked to roughly... > > > Running querybts with strace results in: > > > > > > nicolas@my-machine:~$ strace -e trace=connect querybts > > > --proxy=http://172.16.0.66:8080/ -b reportbug > > > > I don't see the error you report, with Reportbug version “6.6.6”. The > > connection succeeds and the ‘querybts’ command continues successfully. > > with version 6.6.6 I cannot reproduce the issue anymore: works for me, > thanks! Unfortunately I have to go with Olaf: It works when I have the HTTP_PROXY environment variable set. Unsetting it and using only the '--proxy' option does _not_ work: 'querybts' always tries to connect directly, not via the given proxy server. Sorry for confusion. Kind regards, Nicolas signature.asc Description: Digital signature
Bug#717563: reportbug: web access thru proxy not available
Sorry, the bug still exists: Please enter the name of your proxy server. It should only use this parameter if you are behind a firewall. The PROXY argument should be formatted as a valid HTTP URL, including (if necessary) a port number; for example, http://192.168.1.1:3128/. Just press ENTER if you don't have one or don't know. http://user:p...@proxy.example.com:8080 Default preferences file written. To reconfigure, re-run reportbug with the "--configure" option. Running 'reportbug' as root is probably insecure! Continue [y|N|q|?]? y Please enter the name of the package in which you have found a problem, or type 'other' to report a more general problem. If you don't know what package the bug is in, please contact debian-u...@lists.debian.org for assistance. reportbug *** Welcome to reportbug. Use ? for help at prompts. *** Note: bug reports are publicly archived (including the email address of the submitter). Detected character set: UTF-8 Please change your locale if this is incorrect. Using 'Olaf Zaplinski' as your from address. Getting status for reportbug... Checking for newer versions at madison, incoming.debian.org and http://ftp-master.debian.org/new.html Will send report to Debian (per lsb_release). Querying Debian BTS for reports on reportbug (source)... Unable to connect to Debian BTS; continue [y|N|?]?
Bug#717563: reportbug: web access thru proxy not available
Dear Ben, > > Running querybts with strace results in: > > > > nicolas@my-machine:~$ strace -e trace=connect querybts > > --proxy=http://172.16.0.66:8080/ -b reportbug > > I don't see the error you report, with Reportbug version “6.6.6”. The > connection succeeds and the ‘querybts’ command continues successfully. with version 6.6.6 I cannot reproduce the issue anymore: works for me, thanks! Nicolas -- gpg key id: 55a0ce7f, epost: nicolas@(hjem.rpa.no|ip6.li) ↳ fpr: 18ed 52db e34f 860e e9fb c82b 7d97 0932 55a0 ce7f -- frykten for herren er opphav til kunnskap -- signature.asc Description: Digital signature
Bug#717563: reportbug: web access thru proxy not available
Control: tags -1 + moreinfo Control: found -1 reportbug/6.6.3 On 31-Oct-2013, Nicolas Schier wrote: > Running querybts with strace results in: > > nicolas@my-machine:~$ strace -e trace=connect querybts > --proxy=http://172.16.0.66:8080/ -b reportbug I don't see the error you report, with Reportbug version “6.6.6”. The connection succeeds and the ‘querybts’ command continues successfully. > Does that help? Do you need something more? Do you still see the reported failure in the Reportbug from current Sid? On 22-Jul-2013, Olaf Zaplinski wrote: > when reportbug asks for a proxy server and I enter the apt.conf proxy > setting > http://user:p...@proxyhost.example.com:8080 > then internet access still fails. Does this still occur in the latest Reportbug from Sid? On 09-Jan-2015, Andrew Gallagher wrote: > This bug is still present in testing. With which version did you experience this? Do you still see the reported failure in Reportbug from current Sid? On 02-Apr-2016, Lasse Makholm wrote: > This is a problem in Jessie (8.2) using reportbug 6.6.3 Thank you. Do you still see the reported failure in Reportbug 6.6.6 (or the latest from Sid when you read this)? -- \ “Religions have contrived to make it impossible to disagree | `\ with them critically, without being rude.” —Daniel Dennett, | _o__) _The Four Horsemen_, 2008-05-20 | Ben Finneysignature.asc Description: PGP signature
Bug#717563: Still present in reportbug/6.6.3
This is a problem in Jessie (8.2) using reportbug 6.6.3 http_proxy "" in .reportbugrc does not work. reportbug --http_proxy does not work. env http_proxy=... reportbug does not work. env HTTP_PROXY=... reportbug does work, however. So yeah, still pretty broken. -- /Lasse
Bug#717563: proxy setting still not working
This bug is still present in testing. I can confirm that proxy operation also fails when using the --http_proxy and --proxy command line options. -- Andrew Gallagher Internetworking and Security Engineer, Ward Solutions Ltd. Unit 2054 Castle Drive, Citywest, Dublin 24 +353 87 1200174 The information in this email and any attachments contain confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail, the attachments or any part thereof. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. Unless expressly stated, this email is not intended to create any contractual relationship. If this email is not sent in the course of the senders employment or fulfilment of his/her duties to Ward Solutions, Ward Solutions accepts no liability whatsoever for the content of this message or any attachment(s). Ward Solutions Ltd. Registered in Republic of Ireland at 2054 Castle Drive, CityWest Business Campus, Dublin 24 Reg. No. 316165. signature.asc Description: OpenPGP digital signature
Bug#717563: reportbug: web access thru proxy not available
Dear Sandro, On Mon, Jul 22, 2013 at 01:54:28PM +0200, Sandro Tosi wrote: On Mon, Jul 22, 2013 at 1:35 PM, Olaf Zaplinski o...@zaplinski.de wrote: then internet access still fails. whta part of the internet access fails? doing what operation? fetching updated versions? bugs? you can run reportbug from the terminal and report the transcript. reportbug and querybts fail for me, too (w/ normal http-proxy settings). Running querybts with strace results in: nicolas@my-machine:~$ strace -e trace=connect querybts --proxy=http://172.16.0.66:8080/ -b reportbug --- SIGCHLD (Child exited) @ 0 (0) --- connect(7, {sa_family=AF_FILE, path=@/tmp/.X11-unix/X0}, 20) = 0 Querying Debian BTS for reports on reportbug... connect(3, {sa_family=AF_FILE, path=/var/run/nscd/socket}, 110) = -1 ENOENT (No such file or directory) connect(3, {sa_family=AF_FILE, path=/var/run/nscd/socket}, 110) = -1 ENOENT (No such file or directory) connect(3, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr(172.16.0.66)}, 16) = 0 syscall_307(0x3, 0x7fff5b9d0220, 0x2, 0x4000, 0, 0x3, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930, 0x27b67930) = 0x2 connect(3, {sa_family=AF_INET, sin_port=htons(80), sin_addr=inet_addr(206.12.19.140)}, 16) = 0 connect(3, {sa_family=AF_UNSPEC, sa_data=\0\0\0\0\0\0\0\0\0\0\0\0\0\0}, 16) = 0 connect(3, {sa_family=AF_INET, sin_port=htons(80), sin_addr=inet_addr(140.211.166.26)}, 16) = 0 connect(3, {sa_family=AF_INET6, sin6_port=htons(80), inet_pton(AF_INET6, 2607:f8f0:610:4000:6564:a62:ce0c:138c, sin6_addr), sin6_flowinfo=0, sin6_scope_id=0}, 28) = -1 ENETUNREACH (Network is unreachable) connect(3, {sa_family=AF_INET, sin_port=htons(80), sin_addr=inet_addr(206.12.19.140)}, 16^C unfinished ... I have no clue, what this 'syscall_307' means, but what I can see is that reportbug connects successfully the proxy (172.16.0.66:8080), but afterwards attempts to connect bugs.debian.org directly (which has to fail). Since reportbug builds on python-debianbts, I assume that the bug does not come from reportbug directly... Does that help? Do you need something more? Kind regards, Nicolas -- gpg public key: ID 0xACBC3B35, jabber: nico...@jabber.no -- frykten for herren er opphav til kunnskap -- pgpWfdgafl18B.pgp Description: PGP signature
Bug#717563: reportbug: web access thru proxy not available
Package: reportbug Version: 6.4.4 Severity: important Dear Maintainer, when reportbug asks for a proxy server and I enter the apt.conf proxy setting http://user:p...@proxyhost.example.com:8080 then internet access still fails. This is also true when I 1. set the correct environment variables http_proxy, https_proxy and ftp_proxy 2. do not enter proxy setting when reportbug asks for it. -- Package-specific info: ** Environment settings: VISUAL=vi INTERFACE=text ** /root/.reportbugrc: reportbug_version 6.4.4 mode standard ui text realname Olaf Zaplinski email o...@zaplinski.de no-check-uid http_proxy http://svc-cde-it-suse:start...@ddcrdtm200v1.corp.draeger.global:8080; no-cc header X-Debbugs-CC: o...@zaplinski.de smtphost reportbug.debian.org -- System Information: Debian Release: 7.1 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 3.2.0-4-amd64 (SMP w/1 CPU core) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages reportbug depends on: ii apt 0.9.7.9 ii python2.7.3-4 ii python-reportbug 6.4.4 reportbug recommends no packages. Versions of packages reportbug suggests: pn claws-mail none pn debconf-utilsnone pn debsums none pn dlocate none pn emacs22-bin-common | emacs23-bin-common none ii file 5.11-2 ii gnupg1.4.12-7 pn postfix | exim4 | mail-transport-agent none pn python-gtk2 none pn python-gtkspell none pn python-urwid none pn python-vte none pn xdg-utilsnone Versions of packages python-reportbug depends on: ii apt 0.9.7.9 ii python2.7.3-4 ii python-debian 0.1.21 ii python-debianbts 1.11 ii python-support1.0.15 python-reportbug suggests no packages. -- no debconf information -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#717563: reportbug: web access thru proxy not available
On Mon, Jul 22, 2013 at 1:35 PM, Olaf Zaplinski o...@zaplinski.de wrote: then internet access still fails. whta part of the internet access fails? doing what operation? fetching updated versions? bugs? you can run reportbug from the terminal and report the transcript. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org