diff options
| author | Liguros - Gitlab CI/CD [develop] <gitlab@liguros.net> | 2021-07-28 13:45:00 +0000 |
|---|---|---|
| committer | Liguros - Gitlab CI/CD [develop] <gitlab@liguros.net> | 2021-07-28 13:45:00 +0000 |
| commit | 101b72453363cc3926ff5be738d873c77e90403b (patch) | |
| tree | cc66a9458e329f6124a92ec098a44f189c6238a4 /dev-python/requests | |
| parent | 1c657c4fe9e9483b204d3790241fd9ac307f4055 (diff) | |
| download | baldeagleos-repo-101b72453363cc3926ff5be738d873c77e90403b.tar.gz baldeagleos-repo-101b72453363cc3926ff5be738d873c77e90403b.tar.xz baldeagleos-repo-101b72453363cc3926ff5be738d873c77e90403b.zip | |
Adding metadata
Diffstat (limited to 'dev-python/requests')
| -rw-r--r-- | dev-python/requests/files/requests-2.26.0-test.patch | 30 | ||||
| -rw-r--r-- | dev-python/requests/requests-2.26.0.ebuild | 4 |
2 files changed, 34 insertions, 0 deletions
diff --git a/dev-python/requests/files/requests-2.26.0-test.patch b/dev-python/requests/files/requests-2.26.0-test.patch new file mode 100644 index 000000000000..6bbf78871713 --- /dev/null +++ b/dev-python/requests/files/requests-2.26.0-test.patch @@ -0,0 +1,30 @@ +From 6552e5374c335d62ba960a74b5b978897c823376 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org> +Date: Wed, 28 Jul 2021 10:33:22 +0200 +Subject: [PATCH] Fix creating non-listening sockets in tests on some platforms + +Fix the listen() invocation for the test server not to pass a backlog +value of zero. The value of zero means no backlog which effectively +means that the socket can not accept any connections. This does not +matter for the majority of platforms since the value is only advisory +and the platform tends to go with a bigger backlog anyway. However, +a few platforms (e.g. alpha or riscv Linux) do take the value literally, +and therefore the tests fail since they are unable to connect to +the server. Let Python use a 'default reasonable value' instead. +--- + tests/testserver/server.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/testserver/server.py b/tests/testserver/server.py +index 132221f7c4..92dcb6cb1a 100644 +--- a/tests/testserver/server.py ++++ b/tests/testserver/server.py +@@ -78,7 +78,7 @@ def run(self): + def _create_socket_and_bind(self): + sock = socket.socket() + sock.bind((self.host, self.port)) +- sock.listen(0) ++ sock.listen() + return sock + + def _close_server_sock_ignore_errors(self): diff --git a/dev-python/requests/requests-2.26.0.ebuild b/dev-python/requests/requests-2.26.0.ebuild index 0824b177c739..7b8c77fb28fa 100644 --- a/dev-python/requests/requests-2.26.0.ebuild +++ b/dev-python/requests/requests-2.26.0.ebuild @@ -36,6 +36,10 @@ BDEPEND=" distutils_enable_tests pytest +PATCHES=( + "${FILESDIR}"/${P}-test.patch +) + python_test() { local deselect=( # Internet |
