NO_PROXY is unfortunately not standardized many applications and libs do support whitespace- and comma-separated env var value. Unfortunately, due to PR 236204 one cannot use commas. Therefore, I have created a PR upstream, after a long-running discussion they rejected my PR for no profound reason. To still solve this problem on FreeBSD providing my patch to downstream. withouth the patch: ======= $ echo $NO_PROXY localhost .siemens.net .siemens.com .siemens.de osipovmi@deblndw011x:~/var/Projekte/lda-docgen/latex-system/templates (master =) $ .gitlab-ci/validate-templates.py -S backend-dev -J 8 LaTeXSample/1 2022-12-05 11:26:16,099 [MainThread] INFO validate-templates.py: Validating template 'LaTeXSample/1' ... Traceback (most recent call last): File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 700, in urlopen self._prepare_proxy(conn) File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 996, in _prepare_proxy conn.connect() File "/usr/local/lib/python3.7/site-packages/urllib3/connection.py", line 369, in connect self._tunnel() File "/usr/local/lib/python3.7/http/client.py", line 931, in _tunnel message.strip())) OSError: Tunnel connection failed: 502 Bad Gateway During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/local/lib/python3.7/site-packages/requests/adapters.py", line 499, in send timeout=timeout, File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 788, in urlopen method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2] File "/usr/local/lib/python3.7/site-packages/urllib3/util/retry.py", line 592, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='....ad001.siemens.net', port=443): Max retries exceeded with url: /backend-dev/api/documents (Caused by ProxyError('Cannot connect to proxy.', OSError('Tunnel connection failed: 502 Bad Gateway'))) ======= With the patch all works.
References: * https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=236204 * https://github.com/psf/requests/pull/5465
Created attachment 238536 [details] Git-formatted patch
Adding to have koobs@'s opinion.
I'm not going to commit this. Please make it accepted by upstream.
(In reply to Po-Chuan Hsieh from comment #4) I tried (https://github.com/psf/requests/pull/5465), they closed the PR w/o reasonable explanation and even locked the discussion. What should I do? This is a serious problem for users behind a proxy.
I can try, of course, create a new PR...
The alternative is that Bug 236204 is addressed in 13 and 14. The merge window for 12 has been missed. That would be fine for me also. WDYT?