* [gentoo-commits] repo/gentoo:master commit in: dev-python/psutil/files/, dev-python/psutil/
@ 2019-11-27 12:24 Michał Górny
0 siblings, 0 replies; 6+ messages in thread
From: Michał Górny @ 2019-11-27 12:24 UTC (permalink / raw
To: gentoo-commits
commit: 050802355807c7485e3c2d9bdee6b47c121810c6
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Wed Nov 27 12:24:07 2019 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Wed Nov 27 12:24:43 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=05080235
dev-python/psutil: Bump to 5.6.7
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/psutil/Manifest | 1 +
dev-python/psutil/files/psutil-5.6.7-tests.patch | 96 ++++++++++++++++++++++++
dev-python/psutil/psutil-5.6.7.ebuild | 41 ++++++++++
3 files changed, 138 insertions(+)
diff --git a/dev-python/psutil/Manifest b/dev-python/psutil/Manifest
index 9564a9ab596..acbbd55f013 100644
--- a/dev-python/psutil/Manifest
+++ b/dev-python/psutil/Manifest
@@ -6,3 +6,4 @@ DIST psutil-5.5.0.tar.gz 425058 BLAKE2B 0a13149b060d1a99faa600470fdbd592ee520b24
DIST psutil-5.6.0.tar.gz 426596 BLAKE2B 803cb09262575a7193ecc9cf9bfbbf721e10ef4adc25672f6747111306d1803c1422c9894636421653eaae11c241100f58837c80173ab473bb9dc39da2580aed SHA512 01daf80698954a53a9e987afad6c7aefad502c76b5f34601728c3864c924ca52099f139242e508fd4c72378cbe436c9870eca7a33c112fb8dead0be501aaf2aa
DIST psutil-5.6.1.tar.gz 427472 BLAKE2B ef49aef2a2584efe24816641dc7eec65cc8d2f202bad398dde65e11434684e1454f9f5b213697e94378603e21d67954012f814b74ceaefd272aa7efebfd617fe SHA512 0800c7cb62f1643594ef410a9f4295a48684f39ab772a27bd8ebae8484d9eaa1c7d5b1064dd63bb2252364180062e7db2e46aa4013ba8bd427827287a520f581
DIST psutil-5.6.5.tar.gz 447489 BLAKE2B 9301d1580bded927b4b117facf82a3c6be9b43cb648f0f52b841dc2c59cbcc58b5a5c3e0ea7cee30a546e1ea1c00fc0e03b3b49fa69209bbfd3c873e18510859 SHA512 037b1501b686b7101be4180c8698b09d20d4260962a88f0c437ff558d91c405f56eae186c9d55c1893c612c4534093ab26e6943f0ed56db69e343c5c0317be1b
+DIST psutil-5.6.7.tar.gz 448321 BLAKE2B 4e47fb7def5a0eed162686d4e90dd122bd380eca50c3294cd89ed154e27f71972dbc2b3b481456d5022107a1adad2a637e8f233002d429463232c38a04a957c7 SHA512 74eb488b91764941e38214f07bca00e3c837167ad543bfd9ae3b83d665e2be1bb5341eca4aff9282ad50d321568a679e1ffa2ee72ad7b4965cda92b7c80b2503
diff --git a/dev-python/psutil/files/psutil-5.6.7-tests.patch b/dev-python/psutil/files/psutil-5.6.7-tests.patch
new file mode 100644
index 00000000000..3e6ec254c19
--- /dev/null
+++ b/dev-python/psutil/files/psutil-5.6.7-tests.patch
@@ -0,0 +1,96 @@
+diff -dupr a/psutil/_pslinux.py b/psutil/_pslinux.py
+--- a/psutil/_pslinux.py 2019-11-21 17:23:01.000000000 +0100
++++ b/psutil/_pslinux.py 2019-11-27 12:56:11.491875281 +0100
+@@ -1108,7 +1108,7 @@ def disk_io_counters(perdisk=False):
+ fields = f.read().strip().split()
+ name = os.path.basename(root)
+ (reads, reads_merged, rbytes, rtime, writes, writes_merged,
+- wbytes, wtime, _, busy_time, _) = map(int, fields)
++ wbytes, wtime, _, busy_time, _) = map(int, fields[:11])
+ yield (name, reads, writes, rbytes, wbytes, rtime,
+ wtime, reads_merged, writes_merged, busy_time)
+
+diff -dupr a/psutil/tests/test_contracts.py b/psutil/tests/test_contracts.py
+--- a/psutil/tests/test_contracts.py 2019-06-20 08:10:28.000000000 +0200
++++ b/psutil/tests/test_contracts.py 2019-11-27 12:56:11.492875227 +0100
+@@ -174,6 +174,7 @@ class TestAvailability(unittest.TestCase
+
+ class TestDeprecations(unittest.TestCase):
+
++ @unittest.skip("broken with newer deps")
+ def test_memory_info_ex(self):
+ with warnings.catch_warnings(record=True) as ws:
+ psutil.Process().memory_info_ex()
+diff -dupr a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py
+--- a/psutil/tests/test_linux.py 2019-11-21 17:23:25.000000000 +0100
++++ b/psutil/tests/test_linux.py 2019-11-27 13:18:19.715499797 +0100
+@@ -17,6 +17,7 @@ import re
+ import shutil
+ import socket
+ import struct
++import sys
+ import tempfile
+ import textwrap
+ import time
+@@ -380,6 +381,8 @@ class TestSystemVirtualMemory(unittest.T
+ ret = psutil.virtual_memory()
+ assert m.called
+ self.assertEqual(ret.available, 2057400 * 1024 + 4818144 * 1024)
++ if sys.version_info < (3,):
++ return
+ w = ws[0]
+ self.assertIn(
+ "inactive memory stats couldn't be determined", str(w.message))
+@@ -410,6 +413,8 @@ class TestSystemVirtualMemory(unittest.T
+ ret = psutil.virtual_memory()
+ self.assertEqual(
+ ret.available, 2057400 * 1024 + 4818144 * 1024)
++ if sys.version_info < (3,):
++ return
+ w = ws[0]
+ self.assertIn(
+ "inactive memory stats couldn't be determined",
+@@ -878,7 +883,7 @@ class TestLoadAvg(unittest.TestCase):
+ # =====================================================================
+
+
+-@unittest.skipIf(not LINUX, "LINUX only")
++@unittest.skip('very fragile, broken with new ipaddress')
+ class TestSystemNetIfAddrs(unittest.TestCase):
+
+ def test_ips(self):
+@@ -1363,6 +1368,7 @@ class TestMisc(unittest.TestCase):
+ psutil.PROCFS_PATH = "/proc"
+ os.rmdir(tdir)
+
++ @unittest.skip('fails on Gentoo')
+ def test_issue_687(self):
+ # In case of thread ID:
+ # - pid_exists() is supposed to return False
+@@ -2090,6 +2096,7 @@ class TestProcessAgainstStatus(unittest.
+ value = self.read_status_file("nonvoluntary_ctxt_switches:")
+ self.assertEqual(self.proc.num_ctx_switches().involuntary, value)
+
++ @unittest.skip('fails on Gentoo')
+ def test_cpu_affinity(self):
+ value = self.read_status_file("Cpus_allowed_list:")
+ if '-' in str(value):
+diff -dupr a/psutil/tests/test_process.py b/psutil/tests/test_process.py
+--- a/psutil/tests/test_process.py 2019-11-22 12:37:20.000000000 +0100
++++ b/psutil/tests/test_process.py 2019-11-27 13:07:36.966525513 +0100
+@@ -351,6 +351,7 @@ class TestProcess(unittest.TestCase):
+ self.assertGreaterEqual(io2[i], 0)
+ self.assertGreaterEqual(io2[i], 0)
+
++ @unittest.skip('fails if builder is ioniced already')
+ @unittest.skipIf(not HAS_IONICE, "not supported")
+ @unittest.skipIf(not LINUX, "linux only")
+ def test_ionice_linux(self):
+@@ -1486,6 +1487,7 @@ class TestProcess(unittest.TestCase):
+ d2 = clean_dict(os.environ.copy())
+ self.assertEqual(d1, d2)
+
++ @unittest.skip("broken by Gentoo sandbox magic")
+ @unittest.skipIf(not HAS_ENVIRON, "not supported")
+ @unittest.skipIf(not POSIX, "POSIX only")
+ def test_weird_environ(self):
diff --git a/dev-python/psutil/psutil-5.6.7.ebuild b/dev-python/psutil/psutil-5.6.7.ebuild
new file mode 100644
index 00000000000..58e6fc6d35f
--- /dev/null
+++ b/dev-python/psutil/psutil-5.6.7.ebuild
@@ -0,0 +1,41 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+PYTHON_COMPAT=( python{2_7,3_{5,6,7,8}} pypy{,3} )
+
+inherit distutils-r1
+
+DESCRIPTION="Retrieve information on running processes and system utilization"
+HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+DEPEND="
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ test? (
+ dev-python/mock[${PYTHON_USEDEP}]
+ dev-python/ipaddress[${PYTHON_USEDEP}]
+ )
+"
+
+PATCHES=(
+ "${FILESDIR}/psutil-5.6.7-tests.patch"
+)
+
+python_test() {
+ if [[ ${EPYTHON} == pypy* ]]; then
+ ewarn "Not running tests on ${EPYTHON} since they are broken"
+ return 0
+ fi
+
+ # since we are running in an environment a bit similar to CI,
+ # let's skip the tests that are disable for CI
+ TRAVIS=1 APPVEYOR=1 "${EPYTHON}" psutil/tests/__main__.py ||
+ die "tests failed with ${EPYTHON}"
+}
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/psutil/files/, dev-python/psutil/
@ 2020-02-19 7:00 Michał Górny
0 siblings, 0 replies; 6+ messages in thread
From: Michał Górny @ 2020-02-19 7:00 UTC (permalink / raw
To: gentoo-commits
commit: 1e0a44950d6cdf988976b777fde7ad1043088016
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Wed Feb 19 06:53:43 2020 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Wed Feb 19 06:53:43 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1e0a4495
dev-python/psutil: Remove old
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/psutil/Manifest | 4 --
dev-python/psutil/files/psutil-5.6.5-tests.patch | 90 ------------------------
dev-python/psutil/psutil-5.4.8.ebuild | 32 ---------
dev-python/psutil/psutil-5.5.0.ebuild | 32 ---------
dev-python/psutil/psutil-5.6.0.ebuild | 31 --------
dev-python/psutil/psutil-5.6.5.ebuild | 42 -----------
6 files changed, 231 deletions(-)
diff --git a/dev-python/psutil/Manifest b/dev-python/psutil/Manifest
index bbf5dadec5e..50a5c6357b2 100644
--- a/dev-python/psutil/Manifest
+++ b/dev-python/psutil/Manifest
@@ -1,6 +1,2 @@
-DIST psutil-5.4.8.tar.gz 422742 BLAKE2B 13c4b9b412704728c4b192032a6be78756b03a37cd6f425a81a83d0aca4ce155ebf24a1f62b75e66433f21e8bd3f2fa3c7bbb5ec2686c6dc951b89e97ebfa688 SHA512 5691e7e7ecd827aff2755a85c4c1be3a23beec3a1dbff079547991dcfffa8e075cff7fb6983e1f6fa287e2216e3b1466618730afaf114a0ee209d7b70d7b0c6a
-DIST psutil-5.5.0.tar.gz 425058 BLAKE2B 0a13149b060d1a99faa600470fdbd592ee520b247f916313bef428feaa652bc4e9152f09ceeea5378769d4cdcd9876ccdc96dc4378d74136bcbcadf4a9266b90 SHA512 e614d41162087e236779738b50ec9e83403082f20492e152605fe80da23a11a4bd667db82a234f00815f68139d53b19368c2118ab27d52144341c2250091c570
-DIST psutil-5.6.0.tar.gz 426596 BLAKE2B 803cb09262575a7193ecc9cf9bfbbf721e10ef4adc25672f6747111306d1803c1422c9894636421653eaae11c241100f58837c80173ab473bb9dc39da2580aed SHA512 01daf80698954a53a9e987afad6c7aefad502c76b5f34601728c3864c924ca52099f139242e508fd4c72378cbe436c9870eca7a33c112fb8dead0be501aaf2aa
-DIST psutil-5.6.5.tar.gz 447489 BLAKE2B 9301d1580bded927b4b117facf82a3c6be9b43cb648f0f52b841dc2c59cbcc58b5a5c3e0ea7cee30a546e1ea1c00fc0e03b3b49fa69209bbfd3c873e18510859 SHA512 037b1501b686b7101be4180c8698b09d20d4260962a88f0c437ff558d91c405f56eae186c9d55c1893c612c4534093ab26e6943f0ed56db69e343c5c0317be1b
DIST psutil-5.6.7.tar.gz 448321 BLAKE2B 4e47fb7def5a0eed162686d4e90dd122bd380eca50c3294cd89ed154e27f71972dbc2b3b481456d5022107a1adad2a637e8f233002d429463232c38a04a957c7 SHA512 74eb488b91764941e38214f07bca00e3c837167ad543bfd9ae3b83d665e2be1bb5341eca4aff9282ad50d321568a679e1ffa2ee72ad7b4965cda92b7c80b2503
DIST psutil-5.7.0.tar.gz 449628 BLAKE2B 3bd07a0a2f95a539910fa1cef92e72d168c3ee7a495c0defd3fad307d96448d81182b7ccc5e4388d6726495a18df26b076e27b3cbf57096a5c3c8326c00f2dea SHA512 8cee64ab396dae79866e961aeabdb9a4174e1339bcd5c0a35f23fee97ca2a61c0cb08f7152d7e0db90c387400c5c6fb3da2dd2124ce9bf97dfffe6f3b4967981
diff --git a/dev-python/psutil/files/psutil-5.6.5-tests.patch b/dev-python/psutil/files/psutil-5.6.5-tests.patch
deleted file mode 100644
index ab06ffd069b..00000000000
--- a/dev-python/psutil/files/psutil-5.6.5-tests.patch
+++ /dev/null
@@ -1,90 +0,0 @@
-diff --git a/psutil/_pslinux.py b/psutil/_pslinux.py
-index 80fbf8bf..13c195b8 100644
---- a/psutil/_pslinux.py
-+++ b/psutil/_pslinux.py
-@@ -1108,7 +1108,7 @@ def disk_io_counters(perdisk=False):
- fields = f.read().strip().split()
- name = os.path.basename(root)
- (reads, reads_merged, rbytes, rtime, writes, writes_merged,
-- wbytes, wtime, _, busy_time, _) = map(int, fields)
-+ wbytes, wtime, _, busy_time, _) = map(int, fields[:11])
- yield (name, reads, writes, rbytes, wbytes, rtime,
- wtime, reads_merged, writes_merged, busy_time)
-
-diff --git a/psutil/tests/test_contracts.py b/psutil/tests/test_contracts.py
-index cb4a2b96..1ff7f6ca 100755
---- a/psutil/tests/test_contracts.py
-+++ b/psutil/tests/test_contracts.py
-@@ -174,6 +174,7 @@ class TestAvailability(unittest.TestCase):
-
- class TestDeprecations(unittest.TestCase):
-
-+ @unittest.skip("broken with newer deps")
- def test_memory_info_ex(self):
- with warnings.catch_warnings(record=True) as ws:
- psutil.Process().memory_info_ex()
-diff --git a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py
-index ccde735d..db7183af 100755
---- a/psutil/tests/test_linux.py
-+++ b/psutil/tests/test_linux.py
-@@ -380,9 +380,10 @@ class TestSystemVirtualMemory(unittest.TestCase):
- ret = psutil.virtual_memory()
- assert m.called
- self.assertEqual(ret.available, 2057400 * 1024 + 4818144 * 1024)
-- w = ws[0]
-- self.assertIn(
-- "inactive memory stats couldn't be determined", str(w.message))
-+ # i have no idea what they are trying to do here
-+ #w = ws[0]
-+ #self.assertIn(
-+ # "inactive memory stats couldn't be determined", str(w.message))
-
- def test_avail_old_missing_zoneinfo(self):
- # Remove /proc/zoneinfo file. Make sure fallback is used
-@@ -410,10 +411,12 @@ class TestSystemVirtualMemory(unittest.TestCase):
- ret = psutil.virtual_memory()
- self.assertEqual(
- ret.available, 2057400 * 1024 + 4818144 * 1024)
-- w = ws[0]
-- self.assertIn(
-- "inactive memory stats couldn't be determined",
-- str(w.message))
-+
-+ # i have no idea what they are trying to do here
-+ #w = ws[0]
-+ #self.assertIn(
-+ # "inactive memory stats couldn't be determined",
-+ # str(w.message))
-
- def test_virtual_memory_mocked(self):
- # Emulate /proc/meminfo because neither vmstat nor free return slab.
-@@ -878,7 +881,7 @@ class TestLoadAvg(unittest.TestCase):
- # =====================================================================
-
-
--@unittest.skipIf(not LINUX, "LINUX only")
-+@unittest.skipIf(not LINUX or True, "Not working with latest ipaddress")
- class TestSystemNetIfAddrs(unittest.TestCase):
-
- def test_ips(self):
-diff --git a/psutil/tests/test_process.py b/psutil/tests/test_process.py
-index 24a29b5a..9d9d36d2 100755
---- a/psutil/tests/test_process.py
-+++ b/psutil/tests/test_process.py
-@@ -950,7 +950,7 @@ class TestProcess(unittest.TestCase):
-
- for combo in combos:
- p.cpu_affinity(combo)
-- self.assertEqual(p.cpu_affinity(), combo)
-+ self.assertEqual(set(p.cpu_affinity()), set(combo))
-
- # TODO: #595
- @unittest.skipIf(BSD, "broken on BSD")
-@@ -1486,6 +1486,7 @@ class TestProcess(unittest.TestCase):
- d2 = clean_dict(os.environ.copy())
- self.assertEqual(d1, d2)
-
-+ @unittest.skipIf(TRAVIS, "broken under sandbox, using TRAVIS for Gentoo")
- @unittest.skipIf(not HAS_ENVIRON, "not supported")
- @unittest.skipIf(not POSIX, "POSIX only")
- def test_weird_environ(self):
diff --git a/dev-python/psutil/psutil-5.4.8.ebuild b/dev-python/psutil/psutil-5.4.8.ebuild
deleted file mode 100644
index 02ce4a8970a..00000000000
--- a/dev-python/psutil/psutil-5.4.8.ebuild
+++ /dev/null
@@ -1,32 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python2_7 python3_{6,7} pypy3 )
-
-inherit distutils-r1
-
-DESCRIPTION="Retrieve information on running processes and system utilization"
-HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-IUSE="test"
-
-DEPEND="
- dev-python/setuptools[${PYTHON_USEDEP}]
- test? (
- dev-python/mock[${PYTHON_USEDEP}]
- dev-python/ipaddress[${PYTHON_USEDEP}]
- )
-"
-
-# Many tests fail, even on a regular tox run on a upstream clone
-RESTRICT="test"
-
-python_test() {
- ${PYTHON} psutil/tests/__main__.py || die
-}
diff --git a/dev-python/psutil/psutil-5.5.0.ebuild b/dev-python/psutil/psutil-5.5.0.ebuild
deleted file mode 100644
index 98afea2f806..00000000000
--- a/dev-python/psutil/psutil-5.5.0.ebuild
+++ /dev/null
@@ -1,32 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python2_7 python3_{6,7} pypy3 )
-
-inherit distutils-r1
-
-DESCRIPTION="Retrieve information on running processes and system utilization"
-HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ia64 ppc ppc64 s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-IUSE="test"
-
-DEPEND="
- dev-python/setuptools[${PYTHON_USEDEP}]
- test? (
- dev-python/mock[${PYTHON_USEDEP}]
- dev-python/ipaddress[${PYTHON_USEDEP}]
- )
-"
-
-# Many tests fail, even on a regular tox run on a upstream clone
-RESTRICT="test"
-
-python_test() {
- ${PYTHON} psutil/tests/__main__.py || die
-}
diff --git a/dev-python/psutil/psutil-5.6.0.ebuild b/dev-python/psutil/psutil-5.6.0.ebuild
deleted file mode 100644
index 205a8af9975..00000000000
--- a/dev-python/psutil/psutil-5.6.0.ebuild
+++ /dev/null
@@ -1,31 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-PYTHON_COMPAT=( python2_7 python3_{6,7} pypy3 )
-
-inherit distutils-r1
-
-DESCRIPTION="Retrieve information on running processes and system utilization"
-HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ppc ppc64 s390 ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-IUSE="test"
-
-DEPEND="
- dev-python/setuptools[${PYTHON_USEDEP}]
- test? (
- dev-python/mock[${PYTHON_USEDEP}]
- dev-python/ipaddress[${PYTHON_USEDEP}]
- )
-"
-
-# Many tests fail, even on a regular tox run on a upstream clone
-RESTRICT="test"
-
-python_test() {
- ${PYTHON} psutil/tests/__main__.py || die
-}
diff --git a/dev-python/psutil/psutil-5.6.5.ebuild b/dev-python/psutil/psutil-5.6.5.ebuild
deleted file mode 100644
index c33d3e6edda..00000000000
--- a/dev-python/psutil/psutil-5.6.5.ebuild
+++ /dev/null
@@ -1,42 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-PYTHON_COMPAT=( python{2_7,3_{6,7,8}} pypy3 )
-
-inherit distutils-r1
-
-DESCRIPTION="Retrieve information on running processes and system utilization"
-HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-IUSE="test"
-
-DEPEND="
- dev-python/setuptools[${PYTHON_USEDEP}]
- test? (
- dev-python/mock[${PYTHON_USEDEP}]
- dev-python/ipaddress[${PYTHON_USEDEP}]
- )
-"
-
-RESTRICT="!test? ( test )"
-
-PATCHES=(
- "${FILESDIR}/psutil-5.6.5-tests.patch"
-)
-
-python_test() {
- if [[ ${EPYTHON} == pypy* ]]; then
- ewarn "Not running tests on ${EPYTHON} since they are broken"
- return 0
- fi
-
- # since we are running in an environment a bit similar to CI,
- # let's skip the tests that are disable for CI
- TRAVIS=1 APPVEYOR=1 PYTHONPATH="${BUILD_DIR}/lib" ${PYTHON} psutil/tests/__main__.py || \
- die "tests failed with ${EPYTHON}"
-}
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/psutil/files/, dev-python/psutil/
@ 2020-02-19 7:00 Michał Górny
0 siblings, 0 replies; 6+ messages in thread
From: Michał Górny @ 2020-02-19 7:00 UTC (permalink / raw
To: gentoo-commits
commit: d20080f1b85093237d41e6ef9576412dbcc8575f
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Wed Feb 19 06:37:42 2020 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Wed Feb 19 06:37:42 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d20080f1
dev-python/psutil: Bump to 5.7.0
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/psutil/Manifest | 1 +
dev-python/psutil/files/psutil-5.7.0-tests.patch | 113 +++++++++++++++++++++++
dev-python/psutil/psutil-5.7.0.ebuild | 49 ++++++++++
3 files changed, 163 insertions(+)
diff --git a/dev-python/psutil/Manifest b/dev-python/psutil/Manifest
index b4f19d028a8..bbf5dadec5e 100644
--- a/dev-python/psutil/Manifest
+++ b/dev-python/psutil/Manifest
@@ -3,3 +3,4 @@ DIST psutil-5.5.0.tar.gz 425058 BLAKE2B 0a13149b060d1a99faa600470fdbd592ee520b24
DIST psutil-5.6.0.tar.gz 426596 BLAKE2B 803cb09262575a7193ecc9cf9bfbbf721e10ef4adc25672f6747111306d1803c1422c9894636421653eaae11c241100f58837c80173ab473bb9dc39da2580aed SHA512 01daf80698954a53a9e987afad6c7aefad502c76b5f34601728c3864c924ca52099f139242e508fd4c72378cbe436c9870eca7a33c112fb8dead0be501aaf2aa
DIST psutil-5.6.5.tar.gz 447489 BLAKE2B 9301d1580bded927b4b117facf82a3c6be9b43cb648f0f52b841dc2c59cbcc58b5a5c3e0ea7cee30a546e1ea1c00fc0e03b3b49fa69209bbfd3c873e18510859 SHA512 037b1501b686b7101be4180c8698b09d20d4260962a88f0c437ff558d91c405f56eae186c9d55c1893c612c4534093ab26e6943f0ed56db69e343c5c0317be1b
DIST psutil-5.6.7.tar.gz 448321 BLAKE2B 4e47fb7def5a0eed162686d4e90dd122bd380eca50c3294cd89ed154e27f71972dbc2b3b481456d5022107a1adad2a637e8f233002d429463232c38a04a957c7 SHA512 74eb488b91764941e38214f07bca00e3c837167ad543bfd9ae3b83d665e2be1bb5341eca4aff9282ad50d321568a679e1ffa2ee72ad7b4965cda92b7c80b2503
+DIST psutil-5.7.0.tar.gz 449628 BLAKE2B 3bd07a0a2f95a539910fa1cef92e72d168c3ee7a495c0defd3fad307d96448d81182b7ccc5e4388d6726495a18df26b076e27b3cbf57096a5c3c8326c00f2dea SHA512 8cee64ab396dae79866e961aeabdb9a4174e1339bcd5c0a35f23fee97ca2a61c0cb08f7152d7e0db90c387400c5c6fb3da2dd2124ce9bf97dfffe6f3b4967981
diff --git a/dev-python/psutil/files/psutil-5.7.0-tests.patch b/dev-python/psutil/files/psutil-5.7.0-tests.patch
new file mode 100644
index 00000000000..2def4979faf
--- /dev/null
+++ b/dev-python/psutil/files/psutil-5.7.0-tests.patch
@@ -0,0 +1,113 @@
+From e910d08976e00bc12b5a516daa9e6a6d42d48354 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
+Date: Wed, 19 Feb 2020 07:27:32 +0100
+Subject: [PATCH] Skip broken tests on Gentoo
+
+---
+ psutil/tests/test_linux.py | 8 ++++++++
+ psutil/tests/test_posix.py | 1 +
+ psutil/tests/test_process.py | 2 ++
+ psutil/tests/test_system.py | 1 +
+ 4 files changed, 12 insertions(+)
+
+diff --git a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py
+index e51f8bd5..48527ccb 100755
+--- a/psutil/tests/test_linux.py
++++ b/psutil/tests/test_linux.py
+@@ -17,6 +17,7 @@ import re
+ import shutil
+ import socket
+ import struct
++import sys
+ import tempfile
+ import textwrap
+ import time
+@@ -381,6 +382,8 @@ class TestSystemVirtualMemory(unittest.TestCase):
+ ret = psutil.virtual_memory()
+ assert m.called
+ self.assertEqual(ret.available, 2057400 * 1024 + 4818144 * 1024)
++ if sys.version_info < (3,):
++ return
+ w = ws[0]
+ self.assertIn(
+ "inactive memory stats couldn't be determined", str(w.message))
+@@ -411,6 +414,8 @@ class TestSystemVirtualMemory(unittest.TestCase):
+ ret = psutil.virtual_memory()
+ self.assertEqual(
+ ret.available, 2057400 * 1024 + 4818144 * 1024)
++ if sys.version_info < (3,):
++ return
+ w = ws[0]
+ self.assertIn(
+ "inactive memory stats couldn't be determined",
+@@ -882,6 +887,7 @@ class TestLoadAvg(unittest.TestCase):
+ @unittest.skipIf(not LINUX, "LINUX only")
+ class TestSystemNetIfAddrs(unittest.TestCase):
+
++ @unittest.skip("broken on Gentoo")
+ def test_ips(self):
+ for name, addrs in psutil.net_if_addrs().items():
+ for addr in addrs:
+@@ -1364,6 +1370,7 @@ class TestMisc(unittest.TestCase):
+ psutil.PROCFS_PATH = "/proc"
+ os.rmdir(tdir)
+
++ @unittest.skip("broken on Gentoo")
+ def test_issue_687(self):
+ # In case of thread ID:
+ # - pid_exists() is supposed to return False
+@@ -2073,6 +2080,7 @@ class TestProcessAgainstStatus(unittest.TestCase):
+ value = self.read_status_file("nonvoluntary_ctxt_switches:")
+ self.assertEqual(self.proc.num_ctx_switches().involuntary, value)
+
++ @unittest.skip("broken on Gentoo")
+ def test_cpu_affinity(self):
+ value = self.read_status_file("Cpus_allowed_list:")
+ if '-' in str(value):
+diff --git a/psutil/tests/test_posix.py b/psutil/tests/test_posix.py
+index a96b310f..70199203 100755
+--- a/psutil/tests/test_posix.py
++++ b/psutil/tests/test_posix.py
+@@ -364,6 +364,7 @@ class TestSystemAPIs(unittest.TestCase):
+ "couldn't find %s nic in 'ifconfig -a' output\n%s" % (
+ nic, output))
+
++ @unittest.skip("broken on Gentoo")
+ @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI")
+ @retry_on_failure()
+ def test_users(self):
+diff --git a/psutil/tests/test_process.py b/psutil/tests/test_process.py
+index 987bdf38..cb04f3ef 100755
+--- a/psutil/tests/test_process.py
++++ b/psutil/tests/test_process.py
+@@ -350,6 +350,7 @@ class TestProcess(unittest.TestCase):
+ self.assertGreaterEqual(io2[i], 0)
+ self.assertGreaterEqual(io2[i], 0)
+
++ @unittest.skip("fails if builder is ioniced already")
+ @unittest.skipIf(not HAS_IONICE, "not supported")
+ @unittest.skipIf(not LINUX, "linux only")
+ def test_ionice_linux(self):
+@@ -1495,6 +1496,7 @@ class TestProcess(unittest.TestCase):
+ d2 = clean_dict(os.environ.copy())
+ self.assertEqual(d1, d2)
+
++ @unittest.skip("broken by sandbox")
+ @unittest.skipIf(not HAS_ENVIRON, "not supported")
+ @unittest.skipIf(not POSIX, "POSIX only")
+ def test_weird_environ(self):
+diff --git a/psutil/tests/test_system.py b/psutil/tests/test_system.py
+index 3834209f..b07b5883 100755
+--- a/psutil/tests/test_system.py
++++ b/psutil/tests/test_system.py
+@@ -215,6 +215,7 @@ class TestMiscAPIs(unittest.TestCase):
+ self.assertGreater(bt, 0)
+ self.assertLess(bt, time.time())
+
++ @unittest.skip("broken on Gentoo")
+ @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI")
+ def test_users(self):
+ users = psutil.users()
+--
+2.25.1
+
diff --git a/dev-python/psutil/psutil-5.7.0.ebuild b/dev-python/psutil/psutil-5.7.0.ebuild
new file mode 100644
index 00000000000..7940191f1b9
--- /dev/null
+++ b/dev-python/psutil/psutil-5.7.0.ebuild
@@ -0,0 +1,49 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+PYTHON_COMPAT=( python{2_7,3_{6,7,8}} pypy3 )
+
+inherit distutils-r1
+
+DESCRIPTION="Retrieve information on running processes and system utilization"
+HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+DEPEND="
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ test? (
+ $(python_gen_cond_dep '
+ dev-python/mock[${PYTHON_USEDEP}]
+ dev-python/ipaddress[${PYTHON_USEDEP}]
+ ' -2)
+ )
+"
+
+PATCHES=(
+ "${FILESDIR}/psutil-5.7.0-tests.patch"
+)
+
+python_test() {
+ if [[ ${EPYTHON} == pypy* ]]; then
+ ewarn "Not running tests on ${EPYTHON} since they are broken"
+ return 0
+ fi
+
+ # since we are running in an environment a bit similar to CI,
+ # let's skip the tests that are disable for CI
+ TRAVIS=1 APPVEYOR=1 "${EPYTHON}" psutil/tests/runner.py ||
+ die "tests failed with ${EPYTHON}"
+}
+
+python_compile() {
+ # force -j1 to avoid .o linking race conditions
+ local MAKEOPTS=-j1
+ distutils-r1_python_compile
+}
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/psutil/files/, dev-python/psutil/
@ 2022-02-22 9:38 Michał Górny
0 siblings, 0 replies; 6+ messages in thread
From: Michał Górny @ 2022-02-22 9:38 UTC (permalink / raw
To: gentoo-commits
commit: 78d7db39b5de8a185ff9785513ca745e69d835fe
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Tue Feb 22 09:26:11 2022 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Tue Feb 22 09:38:24 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=78d7db39
dev-python/psutil: Bump to 5.9.0
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/psutil/Manifest | 1 +
dev-python/psutil/files/psutil-5.9.0-tests.patch | 188 +++++++++++++++++++++++
dev-python/psutil/psutil-5.9.0.ebuild | 45 ++++++
3 files changed, 234 insertions(+)
diff --git a/dev-python/psutil/Manifest b/dev-python/psutil/Manifest
index 5990e841b32f..a8eb6c71de71 100644
--- a/dev-python/psutil/Manifest
+++ b/dev-python/psutil/Manifest
@@ -1 +1,2 @@
DIST psutil-5.7.3.tar.gz 465556 BLAKE2B 6a9f31fcba571f381c1f4c904a9ff65659d13ed64e91df478aa7df4dabb87a35c4fbd9c0491a3d10b9eaf0fdcc8f2407fcf7144e729043eda605dfe6e6f93844 SHA512 8fcff56dd4e4c1b877c09023721e6f562424f7f84ae5304d518976a1e7f21dd026772f1abfc063bdd0857a375bc869f42febde090dc0b65918d1ebf44e3ad71d
+DIST psutil-5.9.0.tar.gz 478322 BLAKE2B 763c8ae14ae546bed64a360047d2ce38783e9e7e939160f751c4ccc94b8e023aaa4cdca426f584e05dae8b1326333660e216d7cb3edd820e24a931dddfa5160f SHA512 b521cfce51e90fdf87ba19bf8069877e3210aede92c17460ea0b00324a36e133168e4bff550462d07ab6d93c597c6560d68954340031ff43168d54a8e5d4c4e7
diff --git a/dev-python/psutil/files/psutil-5.9.0-tests.patch b/dev-python/psutil/files/psutil-5.9.0-tests.patch
new file mode 100644
index 000000000000..56a5e1168733
--- /dev/null
+++ b/dev-python/psutil/files/psutil-5.9.0-tests.patch
@@ -0,0 +1,188 @@
+diff --git a/psutil/tests/__init__.py b/psutil/tests/__init__.py
+index 21bb3e61..6c45c9e0 100644
+--- a/psutil/tests/__init__.py
++++ b/psutil/tests/__init__.py
+@@ -88,6 +88,7 @@ __all__ = [
+ "HAS_IONICE", "HAS_MEMORY_MAPS", "HAS_PROC_CPU_NUM", "HAS_RLIMIT",
+ "HAS_SENSORS_BATTERY", "HAS_BATTERY", "HAS_SENSORS_FANS",
+ "HAS_SENSORS_TEMPERATURES", "HAS_MEMORY_FULL_INFO",
++ "GENTOO_TESTING",
+ # subprocesses
+ 'pyrun', 'terminate', 'reap_children', 'spawn_testproc', 'spawn_zombie',
+ 'spawn_children_pair',
+@@ -128,6 +129,7 @@ PYPY = '__pypy__' in sys.builtin_module_names
+ APPVEYOR = 'APPVEYOR' in os.environ
+ GITHUB_ACTIONS = 'GITHUB_ACTIONS' in os.environ or 'CIBUILDWHEEL' in os.environ
+ CI_TESTING = APPVEYOR or GITHUB_ACTIONS
++GENTOO_TESTING = "GENTOO_TESTING" in os.environ
+ # are we a 64 bit process?
+ IS_64BIT = sys.maxsize > 2 ** 32
+
+diff --git a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py
+index 20e28d29..ce5d10a0 100755
+--- a/psutil/tests/test_linux.py
++++ b/psutil/tests/test_linux.py
+@@ -28,6 +28,7 @@ from psutil._compat import PY3
+ from psutil._compat import FileNotFoundError
+ from psutil._compat import basestring
+ from psutil._compat import u
++from psutil.tests import GENTOO_TESTING
+ from psutil.tests import GITHUB_ACTIONS
+ from psutil.tests import GLOBAL_TIMEOUT
+ from psutil.tests import HAS_BATTERY
+@@ -929,6 +930,7 @@ class TestLoadAvg(PsutilTestCase):
+ @unittest.skipIf(not LINUX, "LINUX only")
+ class TestSystemNetIfAddrs(PsutilTestCase):
+
++ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
+ def test_ips(self):
+ for name, addrs in psutil.net_if_addrs().items():
+ for addr in addrs:
+@@ -1491,6 +1493,7 @@ class TestMisc(PsutilTestCase):
+ psutil.PROCFS_PATH = "/proc"
+
+ @retry_on_failure()
++ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
+ def test_issue_687(self):
+ # In case of thread ID:
+ # - pid_exists() is supposed to return False
+@@ -1596,6 +1599,8 @@ class TestSensorsBattery(PsutilTestCase):
+ self.assertEqual(psutil.sensors_battery().power_plugged, False)
+ assert m.called
+
++ @unittest.skipIf(GENTOO_TESTING,
++ "mocking doesn't work with non-BAT0 battery")
+ def test_emulate_power_undetermined(self):
+ # Pretend we can't know whether the AC power cable not
+ # connected (assert fallback to False).
+@@ -1614,6 +1619,8 @@ class TestSensorsBattery(PsutilTestCase):
+ self.assertIsNone(psutil.sensors_battery().power_plugged)
+ assert m.called
+
++ @unittest.skipIf(GENTOO_TESTING,
++ "mocking doesn't work with non-BAT0 battery")
+ def test_emulate_energy_full_0(self):
+ # Emulate a case where energy_full files returns 0.
+ with mock_open_content(
+@@ -1621,6 +1628,8 @@ class TestSensorsBattery(PsutilTestCase):
+ self.assertEqual(psutil.sensors_battery().percent, 0)
+ assert m.called
+
++ @unittest.skipIf(GENTOO_TESTING,
++ "mocking doesn't work with non-BAT0 battery")
+ def test_emulate_energy_full_not_avail(self):
+ # Emulate a case where energy_full file does not exist.
+ # Expected fallback on /capacity.
+@@ -1634,6 +1643,8 @@ class TestSensorsBattery(PsutilTestCase):
+ "/sys/class/power_supply/BAT0/capacity", b"88"):
+ self.assertEqual(psutil.sensors_battery().percent, 88)
+
++ @unittest.skipIf(GENTOO_TESTING,
++ "mocking doesn't work with non-BAT0 battery")
+ def test_emulate_no_power(self):
+ # Emulate a case where /AC0/online file nor /BAT0/status exist.
+ with mock_open_exception(
+@@ -2220,6 +2231,7 @@ class TestProcessAgainstStatus(PsutilTestCase):
+ value = self.read_status_file("nonvoluntary_ctxt_switches:")
+ self.assertEqual(self.proc.num_ctx_switches().involuntary, value)
+
++ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
+ def test_cpu_affinity(self):
+ value = self.read_status_file("Cpus_allowed_list:")
+ if '-' in str(value):
+diff --git a/psutil/tests/test_misc.py b/psutil/tests/test_misc.py
+index d946eb62..a53de565 100755
+--- a/psutil/tests/test_misc.py
++++ b/psutil/tests/test_misc.py
+@@ -32,6 +32,7 @@ from psutil._compat import PY3
+ from psutil._compat import redirect_stderr
+ from psutil.tests import APPVEYOR
+ from psutil.tests import CI_TESTING
++from psutil.tests import GENTOO_TESTING
+ from psutil.tests import HAS_BATTERY
+ from psutil.tests import HAS_MEMORY_MAPS
+ from psutil.tests import HAS_NET_IO_COUNTERS
+@@ -401,6 +402,7 @@ class TestMisc(PsutilTestCase):
+ reload_module(psutil)
+ self.assertIn("version conflict", str(cm.exception).lower())
+
++ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
+ def test_debug(self):
+ if PY3:
+ from io import StringIO
+diff --git a/psutil/tests/test_posix.py b/psutil/tests/test_posix.py
+index 31b81926..7eb9bac5 100755
+--- a/psutil/tests/test_posix.py
++++ b/psutil/tests/test_posix.py
+@@ -23,6 +23,7 @@ from psutil import OPENBSD
+ from psutil import POSIX
+ from psutil import SUNOS
+ from psutil.tests import CI_TESTING
++from psutil.tests import GENTOO_TESTING
+ from psutil.tests import HAS_NET_IO_COUNTERS
+ from psutil.tests import PYTHON_EXE
+ from psutil.tests import PsutilTestCase
+@@ -326,6 +327,7 @@ class TestSystemAPIs(PsutilTestCase):
+ "couldn't find %s nic in 'ifconfig -a' output\n%s" % (
+ nic, output))
+
++ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
+ @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI")
+ @retry_on_failure()
+ def test_users(self):
+diff --git a/psutil/tests/test_process.py b/psutil/tests/test_process.py
+index c9059e33..0050c42a 100755
+--- a/psutil/tests/test_process.py
++++ b/psutil/tests/test_process.py
+@@ -38,6 +38,7 @@ from psutil._compat import long
+ from psutil._compat import super
+ from psutil.tests import APPVEYOR
+ from psutil.tests import CI_TESTING
++from psutil.tests import GENTOO_TESTING
+ from psutil.tests import GITHUB_ACTIONS
+ from psutil.tests import GLOBAL_TIMEOUT
+ from psutil.tests import HAS_CPU_AFFINITY
+@@ -292,6 +293,7 @@ class TestProcess(PsutilTestCase):
+ time.strftime("%Y %m %d %H:%M:%S", time.localtime(p.create_time()))
+
+ @unittest.skipIf(not POSIX, 'POSIX only')
++ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
+ def test_terminal(self):
+ terminal = psutil.Process().terminal()
+ if terminal is not None:
+@@ -341,6 +343,7 @@ class TestProcess(PsutilTestCase):
+ self.assertGreaterEqual(io2[i], 0)
+ self.assertGreaterEqual(io2[i], 0)
+
++ @unittest.skipIf(GENTOO_TESTING, "fails if builder is ioniced already")
+ @unittest.skipIf(not HAS_IONICE, "not supported")
+ @unittest.skipIf(not LINUX, "linux only")
+ def test_ionice_linux(self):
+@@ -1406,6 +1409,7 @@ class TestProcess(PsutilTestCase):
+ if not OSX and GITHUB_ACTIONS:
+ self.assertEqual(d1, d2)
+
++ @unittest.skipIf(GENTOO_TESTING, "broken by Gentoo sandbox")
+ @unittest.skipIf(not HAS_ENVIRON, "not supported")
+ @unittest.skipIf(not POSIX, "POSIX only")
+ def test_weird_environ(self):
+diff --git a/psutil/tests/test_system.py b/psutil/tests/test_system.py
+index db2cb348..b1faa154 100755
+--- a/psutil/tests/test_system.py
++++ b/psutil/tests/test_system.py
+@@ -33,6 +33,7 @@ from psutil._compat import long
+ from psutil.tests import ASCII_FS
+ from psutil.tests import CI_TESTING
+ from psutil.tests import DEVNULL
++from psutil.tests import GENTOO_TESTING
+ from psutil.tests import GITHUB_ACTIONS
+ from psutil.tests import GLOBAL_TIMEOUT
+ from psutil.tests import HAS_BATTERY
+@@ -199,6 +200,7 @@ class TestMiscAPIs(PsutilTestCase):
+ self.assertGreater(bt, 0)
+ self.assertLess(bt, time.time())
+
++ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
+ @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI")
+ def test_users(self):
+ users = psutil.users()
diff --git a/dev-python/psutil/psutil-5.9.0.ebuild b/dev-python/psutil/psutil-5.9.0.ebuild
new file mode 100644
index 000000000000..00a12bc0d760
--- /dev/null
+++ b/dev-python/psutil/psutil-5.9.0.ebuild
@@ -0,0 +1,45 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( python3_{8..10} pypy3 )
+
+inherit distutils-r1
+
+DESCRIPTION="Retrieve information on running processes and system utilization"
+HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+PATCHES=(
+ "${FILESDIR}"/psutil-5.9.0-tests.patch
+)
+
+python_test() {
+ if [[ ${EPYTHON} == pypy* ]]; then
+ ewarn "Not running tests on ${EPYTHON} since they are broken"
+ return 0
+ fi
+
+ # since we are running in an environment a bit similar to CI,
+ # let's skip the tests that are disable for CI
+ local -x TRAVIS=1
+ local -x APPVEYOR=1
+ local -x GITHUB_ACTIONS=1
+ local -x GENTOO_TESTING=1
+ "${EPYTHON}" psutil/tests/runner.py ||
+ die "tests failed with ${EPYTHON}"
+}
+
+python_compile() {
+ # force -j1 to avoid .o linking race conditions
+ local MAKEOPTS=-j1
+ distutils-r1_python_compile
+}
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/psutil/files/, dev-python/psutil/
@ 2022-05-11 16:43 Michał Górny
0 siblings, 0 replies; 6+ messages in thread
From: Michał Górny @ 2022-05-11 16:43 UTC (permalink / raw
To: gentoo-commits
commit: 1a22d0a9c57689f96eef49fed4adc7de636573e5
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Wed May 11 15:46:53 2022 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Wed May 11 16:43:34 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1a22d0a9
dev-python/psutil: Remove old
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/psutil/Manifest | 1 -
dev-python/psutil/files/psutil-5.7.2-tests.patch | 112 -----------------------
dev-python/psutil/psutil-5.7.3.ebuild | 39 --------
3 files changed, 152 deletions(-)
diff --git a/dev-python/psutil/Manifest b/dev-python/psutil/Manifest
index a8eb6c71de71..558b4186bfca 100644
--- a/dev-python/psutil/Manifest
+++ b/dev-python/psutil/Manifest
@@ -1,2 +1 @@
-DIST psutil-5.7.3.tar.gz 465556 BLAKE2B 6a9f31fcba571f381c1f4c904a9ff65659d13ed64e91df478aa7df4dabb87a35c4fbd9c0491a3d10b9eaf0fdcc8f2407fcf7144e729043eda605dfe6e6f93844 SHA512 8fcff56dd4e4c1b877c09023721e6f562424f7f84ae5304d518976a1e7f21dd026772f1abfc063bdd0857a375bc869f42febde090dc0b65918d1ebf44e3ad71d
DIST psutil-5.9.0.tar.gz 478322 BLAKE2B 763c8ae14ae546bed64a360047d2ce38783e9e7e939160f751c4ccc94b8e023aaa4cdca426f584e05dae8b1326333660e216d7cb3edd820e24a931dddfa5160f SHA512 b521cfce51e90fdf87ba19bf8069877e3210aede92c17460ea0b00324a36e133168e4bff550462d07ab6d93c597c6560d68954340031ff43168d54a8e5d4c4e7
diff --git a/dev-python/psutil/files/psutil-5.7.2-tests.patch b/dev-python/psutil/files/psutil-5.7.2-tests.patch
deleted file mode 100644
index 3faaedad6661..000000000000
--- a/dev-python/psutil/files/psutil-5.7.2-tests.patch
+++ /dev/null
@@ -1,112 +0,0 @@
-From e910d08976e00bc12b5a516daa9e6a6d42d48354 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
-Date: Wed, 19 Feb 2020 07:27:32 +0100
-Subject: [PATCH] Skip broken tests on Gentoo
-
----
- psutil/tests/test_linux.py | 8 ++++++++
- psutil/tests/test_posix.py | 1 +
- psutil/tests/test_process.py | 2 ++
- psutil/tests/test_system.py | 1 +
- 4 files changed, 12 insertions(+)
-
-diff --git a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py
-index e51f8bd5..48527ccb 100755
---- a/psutil/tests/test_linux.py
-+++ b/psutil/tests/test_linux.py
-@@ -17,5 +17,6 @@ import re
- import shutil
- import socket
- import struct
-+import sys
- import textwrap
- import time
-@@ -381,6 +382,8 @@ class TestSystemVirtualMemory(unittest.TestCase):
- ret = psutil.virtual_memory()
- assert m.called
- self.assertEqual(ret.available, 2057400 * 1024 + 4818144 * 1024)
-+ if sys.version_info < (3,):
-+ return
- w = ws[0]
- self.assertIn(
- "inactive memory stats couldn't be determined", str(w.message))
-@@ -411,6 +414,8 @@ class TestSystemVirtualMemory(unittest.TestCase):
- ret = psutil.virtual_memory()
- self.assertEqual(
- ret.available, 2057400 * 1024 + 4818144 * 1024)
-+ if sys.version_info < (3,):
-+ return
- w = ws[0]
- self.assertIn(
- "inactive memory stats couldn't be determined",
-@@ -882,6 +887,7 @@ class TestLoadAvg(unittest.TestCase):
- @unittest.skipIf(not LINUX, "LINUX only")
- class TestSystemNetIfAddrs(unittest.TestCase):
-
-+ @unittest.skip("broken on Gentoo")
- def test_ips(self):
- for name, addrs in psutil.net_if_addrs().items():
- for addr in addrs:
-@@ -1364,7 +1370,8 @@ class TestMisc(unittest.TestCase):
- psutil.PROCFS_PATH = "/proc"
- os.rmdir(tdir)
-
- @retry_on_failure()
-+ @unittest.skip("broken on Gentoo")
- def test_issue_687(self):
- # In case of thread ID:
- # - pid_exists() is supposed to return False
-@@ -2073,6 +2080,7 @@ class TestProcessAgainstStatus(unittest.TestCase):
- value = self.read_status_file("nonvoluntary_ctxt_switches:")
- self.assertEqual(self.proc.num_ctx_switches().involuntary, value)
-
-+ @unittest.skip("broken on Gentoo")
- def test_cpu_affinity(self):
- value = self.read_status_file("Cpus_allowed_list:")
- if '-' in str(value):
-diff --git a/psutil/tests/test_posix.py b/psutil/tests/test_posix.py
-index a96b310f..70199203 100755
---- a/psutil/tests/test_posix.py
-+++ b/psutil/tests/test_posix.py
-@@ -364,6 +364,7 @@ class TestSystemAPIs(unittest.TestCase):
- "couldn't find %s nic in 'ifconfig -a' output\n%s" % (
- nic, output))
-
-+ @unittest.skip("broken on Gentoo")
- @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI")
- @retry_on_failure()
- def test_users(self):
-diff --git a/psutil/tests/test_process.py b/psutil/tests/test_process.py
-index 987bdf38..cb04f3ef 100755
---- a/psutil/tests/test_process.py
-+++ b/psutil/tests/test_process.py
-@@ -350,6 +350,7 @@ class TestProcess(unittest.TestCase):
- self.assertGreaterEqual(io2[i], 0)
- self.assertGreaterEqual(io2[i], 0)
-
-+ @unittest.skip("fails if builder is ioniced already")
- @unittest.skipIf(not HAS_IONICE, "not supported")
- @unittest.skipIf(not LINUX, "linux only")
- def test_ionice_linux(self):
-@@ -1495,6 +1496,7 @@ class TestProcess(unittest.TestCase):
- d2 = clean_dict(os.environ.copy())
- self.assertEqual(d1, d2)
-
-+ @unittest.skip("broken by sandbox")
- @unittest.skipIf(not HAS_ENVIRON, "not supported")
- @unittest.skipIf(not POSIX, "POSIX only")
- def test_weird_environ(self):
-diff --git a/psutil/tests/test_system.py b/psutil/tests/test_system.py
-index 3834209f..b07b5883 100755
---- a/psutil/tests/test_system.py
-+++ b/psutil/tests/test_system.py
-@@ -215,6 +215,7 @@ class TestMiscAPIs(unittest.TestCase):
- self.assertGreater(bt, 0)
- self.assertLess(bt, time.time())
-
-+ @unittest.skip("broken on Gentoo")
- @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI")
- def test_users(self):
- users = psutil.users()
---
-2.25.1
diff --git a/dev-python/psutil/psutil-5.7.3.ebuild b/dev-python/psutil/psutil-5.7.3.ebuild
deleted file mode 100644
index ddf8240254b4..000000000000
--- a/dev-python/psutil/psutil-5.7.3.ebuild
+++ /dev/null
@@ -1,39 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-PYTHON_COMPAT=( python3_{7..10} pypy3 )
-
-inherit distutils-r1
-
-DESCRIPTION="Retrieve information on running processes and system utilization"
-HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-IUSE="test"
-RESTRICT="!test? ( test )"
-
-PATCHES=(
- "${FILESDIR}/psutil-5.7.2-tests.patch"
-)
-
-python_test() {
- if [[ ${EPYTHON} == pypy* ]]; then
- ewarn "Not running tests on ${EPYTHON} since they are broken"
- return 0
- fi
-
- # since we are running in an environment a bit similar to CI,
- # let's skip the tests that are disable for CI
- TRAVIS=1 APPVEYOR=1 "${EPYTHON}" psutil/tests/runner.py ||
- die "tests failed with ${EPYTHON}"
-}
-
-python_compile() {
- # force -j1 to avoid .o linking race conditions
- local MAKEOPTS=-j1
- distutils-r1_python_compile
-}
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/psutil/files/, dev-python/psutil/
@ 2022-07-07 20:20 Michał Górny
0 siblings, 0 replies; 6+ messages in thread
From: Michał Górny @ 2022-07-07 20:20 UTC (permalink / raw
To: gentoo-commits
commit: f9083ba45948a338c45d8a807c270b414f51636a
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Thu Jul 7 20:20:25 2022 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Thu Jul 7 20:20:48 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f9083ba4
dev-python/psutil: Remove old
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/psutil/Manifest | 1 -
dev-python/psutil/files/psutil-5.9.0-tests.patch | 298 -----------------------
dev-python/psutil/psutil-5.9.0.ebuild | 40 ---
3 files changed, 339 deletions(-)
diff --git a/dev-python/psutil/Manifest b/dev-python/psutil/Manifest
index cbdc36c11b5e..fef27f7b5aff 100644
--- a/dev-python/psutil/Manifest
+++ b/dev-python/psutil/Manifest
@@ -1,3 +1,2 @@
-DIST psutil-5.9.0.tar.gz 478322 BLAKE2B 763c8ae14ae546bed64a360047d2ce38783e9e7e939160f751c4ccc94b8e023aaa4cdca426f584e05dae8b1326333660e216d7cb3edd820e24a931dddfa5160f SHA512 b521cfce51e90fdf87ba19bf8069877e3210aede92c17460ea0b00324a36e133168e4bff550462d07ab6d93c597c6560d68954340031ff43168d54a8e5d4c4e7
DIST psutil-5.9.1-tests-r2.patch.xz 3516 BLAKE2B 6a16d6f89fdeb06c7aa0d9d986eba84deae5f8d2bb829c2509744f954f9b274d8a70a00f94127f1880cea71f8d7e7b85097517f8516ee6ef14f17522ee9297b2 SHA512 b69efb32cd0229056ff9fbbde963f0f01f6bf1d0820f028527f464e38a9bd4211a55bd725cc8962a20608c12c28edb24b2063f5f58b53fdb6b001fe2f95da103
DIST psutil-5.9.1.tar.gz 479090 BLAKE2B 88f35a9134d942fa56b5fbc79753e82245c3bfdb1f640dbf3b56815b89d872517f9ee3a3945532ebd1a399c3307e160ac80394766c3b2cc7e3fb36ffdd555eef SHA512 1ddb119a10243d17d808417817ec8659d22447f12a4bbc0366c13f6587a4b0b59f4e74f6ac5d1e1a908bb5fd287be630466d32beabcb5008f6a19c24a1557c27
diff --git a/dev-python/psutil/files/psutil-5.9.0-tests.patch b/dev-python/psutil/files/psutil-5.9.0-tests.patch
deleted file mode 100644
index 6dcf6f240e41..000000000000
--- a/dev-python/psutil/files/psutil-5.9.0-tests.patch
+++ /dev/null
@@ -1,298 +0,0 @@
-diff --git a/psutil/tests/__init__.py b/psutil/tests/__init__.py
-index 21bb3e61..6c45c9e0 100644
---- a/psutil/tests/__init__.py
-+++ b/psutil/tests/__init__.py
-@@ -88,6 +88,7 @@ __all__ = [
- "HAS_IONICE", "HAS_MEMORY_MAPS", "HAS_PROC_CPU_NUM", "HAS_RLIMIT",
- "HAS_SENSORS_BATTERY", "HAS_BATTERY", "HAS_SENSORS_FANS",
- "HAS_SENSORS_TEMPERATURES", "HAS_MEMORY_FULL_INFO",
-+ "GENTOO_TESTING",
- # subprocesses
- 'pyrun', 'terminate', 'reap_children', 'spawn_testproc', 'spawn_zombie',
- 'spawn_children_pair',
-@@ -128,6 +129,7 @@ PYPY = '__pypy__' in sys.builtin_module_names
- APPVEYOR = 'APPVEYOR' in os.environ
- GITHUB_ACTIONS = 'GITHUB_ACTIONS' in os.environ or 'CIBUILDWHEEL' in os.environ
- CI_TESTING = APPVEYOR or GITHUB_ACTIONS
-+GENTOO_TESTING = "GENTOO_TESTING" in os.environ
- # are we a 64 bit process?
- IS_64BIT = sys.maxsize > 2 ** 32
-
-diff --git a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py
-index 20e28d29..c21d0aec 100755
---- a/psutil/tests/test_linux.py
-+++ b/psutil/tests/test_linux.py
-@@ -14,6 +14,7 @@ import errno
- import glob
- import io
- import os
-+import platform
- import re
- import shutil
- import socket
-@@ -28,6 +29,7 @@ from psutil._compat import PY3
- from psutil._compat import FileNotFoundError
- from psutil._compat import basestring
- from psutil._compat import u
-+from psutil.tests import GENTOO_TESTING
- from psutil.tests import GITHUB_ACTIONS
- from psutil.tests import GLOBAL_TIMEOUT
- from psutil.tests import HAS_BATTERY
-@@ -688,6 +690,7 @@ class TestSystemCPUCountLogical(PsutilTestCase):
- num = len([x for x in out.split('\n') if not x.startswith('#')])
- self.assertEqual(psutil.cpu_count(logical=True), num)
-
-+ @unittest.skipIf(GENTOO_TESTING and platform.machine().startswith("sparc"), "broken on Gentoo/SPARC")
- def test_emulate_fallbacks(self):
- import psutil._pslinux
- original = psutil._pslinux.cpu_count_logical()
-@@ -735,6 +738,7 @@ class TestSystemCPUCountCores(PsutilTestCase):
- core_ids.add(fields[1])
- self.assertEqual(psutil.cpu_count(logical=False), len(core_ids))
-
-+ @unittest.skipIf(GENTOO_TESTING and platform.machine().startswith("sparc"), "broken on Gentoo/SPARC")
- def test_method_2(self):
- meth_1 = psutil._pslinux.cpu_count_cores()
- with mock.patch('glob.glob', return_value=[]) as m:
-@@ -755,6 +759,7 @@ class TestSystemCPUCountCores(PsutilTestCase):
- class TestSystemCPUFrequency(PsutilTestCase):
-
- @unittest.skipIf(not HAS_CPU_FREQ, "not supported")
-+ @unittest.skipIf(GENTOO_TESTING and platform.machine().startswith("sparc"), "broken on Gentoo/SPARC")
- def test_emulate_use_second_file(self):
- # https://github.com/giampaolo/psutil/issues/981
- def path_exists_mock(path):
-@@ -769,6 +774,7 @@ class TestSystemCPUFrequency(PsutilTestCase):
- assert psutil.cpu_freq()
-
- @unittest.skipIf(not HAS_CPU_FREQ, "not supported")
-+ @unittest.skipIf(GENTOO_TESTING and platform.machine().startswith("sparc"), "broken on Gentoo/SPARC")
- def test_emulate_use_cpuinfo(self):
- # Emulate a case where /sys/devices/system/cpu/cpufreq* does not
- # exist and /proc/cpuinfo is used instead.
-@@ -896,11 +902,13 @@ class TestSystemCPUFrequency(PsutilTestCase):
- @unittest.skipIf(not LINUX, "LINUX only")
- class TestSystemCPUStats(PsutilTestCase):
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_ctx_switches(self):
- vmstat_value = vmstat("context switches")
- psutil_value = psutil.cpu_stats().ctx_switches
- self.assertAlmostEqual(vmstat_value, psutil_value, delta=500)
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_interrupts(self):
- vmstat_value = vmstat("interrupts")
- psutil_value = psutil.cpu_stats().interrupts
-@@ -929,6 +937,7 @@ class TestLoadAvg(PsutilTestCase):
- @unittest.skipIf(not LINUX, "LINUX only")
- class TestSystemNetIfAddrs(PsutilTestCase):
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_ips(self):
- for name, addrs in psutil.net_if_addrs().items():
- for addr in addrs:
-@@ -1316,6 +1325,7 @@ class TestRootFsDeviceFinder(PsutilTestCase):
- findmnt_value = sh("findmnt -o SOURCE -rn /")
- self.assertEqual(psutil_value, findmnt_value)
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_disk_partitions_mocked(self):
- with mock.patch(
- 'psutil._pslinux.cext.disk_partitions',
-@@ -1491,6 +1501,7 @@ class TestMisc(PsutilTestCase):
- psutil.PROCFS_PATH = "/proc"
-
- @retry_on_failure()
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_issue_687(self):
- # In case of thread ID:
- # - pid_exists() is supposed to return False
-@@ -1596,6 +1607,8 @@ class TestSensorsBattery(PsutilTestCase):
- self.assertEqual(psutil.sensors_battery().power_plugged, False)
- assert m.called
-
-+ @unittest.skipIf(GENTOO_TESTING,
-+ "mocking doesn't work with non-BAT0 battery")
- def test_emulate_power_undetermined(self):
- # Pretend we can't know whether the AC power cable not
- # connected (assert fallback to False).
-@@ -1614,6 +1627,8 @@ class TestSensorsBattery(PsutilTestCase):
- self.assertIsNone(psutil.sensors_battery().power_plugged)
- assert m.called
-
-+ @unittest.skipIf(GENTOO_TESTING,
-+ "mocking doesn't work with non-BAT0 battery")
- def test_emulate_energy_full_0(self):
- # Emulate a case where energy_full files returns 0.
- with mock_open_content(
-@@ -1621,6 +1636,8 @@ class TestSensorsBattery(PsutilTestCase):
- self.assertEqual(psutil.sensors_battery().percent, 0)
- assert m.called
-
-+ @unittest.skipIf(GENTOO_TESTING,
-+ "mocking doesn't work with non-BAT0 battery")
- def test_emulate_energy_full_not_avail(self):
- # Emulate a case where energy_full file does not exist.
- # Expected fallback on /capacity.
-@@ -1634,6 +1651,8 @@ class TestSensorsBattery(PsutilTestCase):
- "/sys/class/power_supply/BAT0/capacity", b"88"):
- self.assertEqual(psutil.sensors_battery().percent, 88)
-
-+ @unittest.skipIf(GENTOO_TESTING,
-+ "mocking doesn't work with non-BAT0 battery")
- def test_emulate_no_power(self):
- # Emulate a case where /AC0/online file nor /BAT0/status exist.
- with mock_open_exception(
-@@ -2220,6 +2239,7 @@ class TestProcessAgainstStatus(PsutilTestCase):
- value = self.read_status_file("nonvoluntary_ctxt_switches:")
- self.assertEqual(self.proc.num_ctx_switches().involuntary, value)
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_cpu_affinity(self):
- value = self.read_status_file("Cpus_allowed_list:")
- if '-' in str(value):
-diff --git a/psutil/tests/test_misc.py b/psutil/tests/test_misc.py
-index d946eb62..a53de565 100755
---- a/psutil/tests/test_misc.py
-+++ b/psutil/tests/test_misc.py
-@@ -32,6 +32,7 @@ from psutil._compat import PY3
- from psutil._compat import redirect_stderr
- from psutil.tests import APPVEYOR
- from psutil.tests import CI_TESTING
-+from psutil.tests import GENTOO_TESTING
- from psutil.tests import HAS_BATTERY
- from psutil.tests import HAS_MEMORY_MAPS
- from psutil.tests import HAS_NET_IO_COUNTERS
-@@ -401,6 +402,7 @@ class TestMisc(PsutilTestCase):
- reload_module(psutil)
- self.assertIn("version conflict", str(cm.exception).lower())
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_debug(self):
- if PY3:
- from io import StringIO
-diff --git a/psutil/tests/test_posix.py b/psutil/tests/test_posix.py
-index 31b81926..53b17953 100755
---- a/psutil/tests/test_posix.py
-+++ b/psutil/tests/test_posix.py
-@@ -23,6 +23,7 @@ from psutil import OPENBSD
- from psutil import POSIX
- from psutil import SUNOS
- from psutil.tests import CI_TESTING
-+from psutil.tests import GENTOO_TESTING
- from psutil.tests import HAS_NET_IO_COUNTERS
- from psutil.tests import PYTHON_EXE
- from psutil.tests import PsutilTestCase
-@@ -193,6 +194,7 @@ class TestProcess(PsutilTestCase):
- vsz_psutil = psutil.Process(self.pid).memory_info()[1] / 1024
- self.assertEqual(vsz_ps, vsz_psutil)
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_name(self):
- name_ps = ps_name(self.pid)
- # remove path if there is any, from the command
-@@ -271,6 +273,7 @@ class TestProcess(PsutilTestCase):
- adjusted_ps_pathname = ps_pathname[:len(ps_pathname)]
- self.assertEqual(ps_pathname, adjusted_ps_pathname)
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_cmdline(self):
- ps_cmdline = ps_args(self.pid)
- psutil_cmdline = " ".join(psutil.Process(self.pid).cmdline())
-@@ -326,6 +329,7 @@ class TestSystemAPIs(PsutilTestCase):
- "couldn't find %s nic in 'ifconfig -a' output\n%s" % (
- nic, output))
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI")
- @retry_on_failure()
- def test_users(self):
-diff --git a/psutil/tests/test_process.py b/psutil/tests/test_process.py
-index c9059e33..0050c42a 100755
---- a/psutil/tests/test_process.py
-+++ b/psutil/tests/test_process.py
-@@ -38,6 +38,7 @@ from psutil._compat import long
- from psutil._compat import super
- from psutil.tests import APPVEYOR
- from psutil.tests import CI_TESTING
-+from psutil.tests import GENTOO_TESTING
- from psutil.tests import GITHUB_ACTIONS
- from psutil.tests import GLOBAL_TIMEOUT
- from psutil.tests import HAS_CPU_AFFINITY
-@@ -292,6 +293,7 @@ class TestProcess(PsutilTestCase):
- time.strftime("%Y %m %d %H:%M:%S", time.localtime(p.create_time()))
-
- @unittest.skipIf(not POSIX, 'POSIX only')
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_terminal(self):
- terminal = psutil.Process().terminal()
- if terminal is not None:
-@@ -341,6 +343,7 @@ class TestProcess(PsutilTestCase):
- self.assertGreaterEqual(io2[i], 0)
- self.assertGreaterEqual(io2[i], 0)
-
-+ @unittest.skipIf(GENTOO_TESTING, "fails if builder is ioniced already")
- @unittest.skipIf(not HAS_IONICE, "not supported")
- @unittest.skipIf(not LINUX, "linux only")
- def test_ionice_linux(self):
-@@ -1406,6 +1409,7 @@ class TestProcess(PsutilTestCase):
- if not OSX and GITHUB_ACTIONS:
- self.assertEqual(d1, d2)
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken by Gentoo sandbox")
- @unittest.skipIf(not HAS_ENVIRON, "not supported")
- @unittest.skipIf(not POSIX, "POSIX only")
- def test_weird_environ(self):
-diff --git a/psutil/tests/test_system.py b/psutil/tests/test_system.py
-index db2cb348..d719c59e 100755
---- a/psutil/tests/test_system.py
-+++ b/psutil/tests/test_system.py
-@@ -10,6 +10,7 @@ import contextlib
- import datetime
- import errno
- import os
-+import platform
- import pprint
- import shutil
- import signal
-@@ -33,6 +34,7 @@ from psutil._compat import long
- from psutil.tests import ASCII_FS
- from psutil.tests import CI_TESTING
- from psutil.tests import DEVNULL
-+from psutil.tests import GENTOO_TESTING
- from psutil.tests import GITHUB_ACTIONS
- from psutil.tests import GLOBAL_TIMEOUT
- from psutil.tests import HAS_BATTERY
-@@ -199,6 +201,7 @@ class TestMiscAPIs(PsutilTestCase):
- self.assertGreater(bt, 0)
- self.assertLess(bt, time.time())
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI")
- def test_users(self):
- users = psutil.users()
-@@ -426,6 +429,7 @@ class TestCpuAPIs(PsutilTestCase):
- if difference >= 0.05:
- return
-
-+ @unittest.skipIf(GENTOO_TESTING, "flaky")
- def test_cpu_times_comparison(self):
- # Make sure the sum of all per cpu times is almost equal to
- # base "one cpu" times.
-@@ -512,6 +516,7 @@ class TestCpuAPIs(PsutilTestCase):
- self.assertGreater(value, 0)
-
- @unittest.skipIf(not HAS_CPU_FREQ, "not suported")
-+ @unittest.skipIf(GENTOO_TESTING and platform.machine().startswith("sparc"), "broken on Gentoo/SPARC")
- def test_cpu_freq(self):
- def check_ls(ls):
- for nt in ls:
-@@ -580,6 +585,7 @@ class TestDiskAPIs(PsutilTestCase):
- def test_disk_usage_bytes(self):
- psutil.disk_usage(b'.')
-
-+ @unittest.skipIf(GENTOO_TESTING, "broken in Gentoo test env")
- def test_disk_partitions(self):
- def check_ntuple(nt):
- self.assertIsInstance(nt.device, str)
diff --git a/dev-python/psutil/psutil-5.9.0.ebuild b/dev-python/psutil/psutil-5.9.0.ebuild
deleted file mode 100644
index ddb9962ebb08..000000000000
--- a/dev-python/psutil/psutil-5.9.0.ebuild
+++ /dev/null
@@ -1,40 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-DISTUTILS_USE_PEP517=setuptools
-PYTHON_COMPAT=( python3_{8..11} pypy3 )
-
-inherit distutils-r1
-
-DESCRIPTION="Retrieve information on running processes and system utilization"
-HOMEPAGE="https://github.com/giampaolo/psutil https://pypi.org/project/psutil/"
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-IUSE="test"
-RESTRICT="!test? ( test )"
-
-PATCHES=(
- "${FILESDIR}"/psutil-5.9.0-tests.patch
-)
-
-python_test() {
- # since we are running in an environment a bit similar to CI,
- # let's skip the tests that are disable for CI
- local -x TRAVIS=1
- local -x APPVEYOR=1
- local -x GITHUB_ACTIONS=1
- local -x GENTOO_TESTING=1
- "${EPYTHON}" psutil/tests/runner.py ||
- die "tests failed with ${EPYTHON}"
-}
-
-python_compile() {
- # force -j1 to avoid .o linking race conditions
- local MAKEOPTS=-j1
- distutils-r1_python_compile
-}
^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2022-07-07 20:20 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-11 16:43 [gentoo-commits] repo/gentoo:master commit in: dev-python/psutil/files/, dev-python/psutil/ Michał Górny
-- strict thread matches above, loose matches on Subject: below --
2022-07-07 20:20 Michał Górny
2022-02-22 9:38 Michał Górny
2020-02-19 7:00 Michał Górny
2020-02-19 7:00 Michał Górny
2019-11-27 12:24 Michał Górny
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox