summaryrefslogtreecommitdiff
path: root/dev-python/parso
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-08-26 00:09:36 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-08-26 00:09:36 +0100
commitb1c81de4fadbd00897700a7321f03b390d952b2e (patch)
treee6cc812351d4f105c110cfc363ebb497e996f47a /dev-python/parso
parent7c59acba5699c9c58090a7a738669669a7307023 (diff)
gentoo resync : 26.08.2021
Diffstat (limited to 'dev-python/parso')
-rw-r--r--dev-python/parso/Manifest3
-rw-r--r--dev-python/parso/files/parso-0.7.1-flaky-test.patch37
-rw-r--r--dev-python/parso/parso-0.7.1-r1.ebuild7
3 files changed, 45 insertions, 2 deletions
diff --git a/dev-python/parso/Manifest b/dev-python/parso/Manifest
index 17b9bc99a326..18ce9b6e2c12 100644
--- a/dev-python/parso/Manifest
+++ b/dev-python/parso/Manifest
@@ -1,8 +1,9 @@
+AUX parso-0.7.1-flaky-test.patch 1307 BLAKE2B 63af3a1a0f0d31aba82de3bf9e00001257a794e8e4da752a780d44be83421ca28600c400d9f1ad4bb491c0ed94bdcf61e430880d7305378246be2a16db8ba4f7 SHA512 2101a4cc01e90cc4ce37aa1386bea2be8334834bbe0ee54540bf5645e11ebcaf8395dd8b1fdd308cc1a124ec4f1fe623f7fdd35abc3b82aaf3d9c120becdc961
AUX parso-0.8.2-flaky-test.patch 947 BLAKE2B b6ece3214328f3121e4de8217395ac108678a37a97bea943e900e13cf44fdbeccf70f2b3bf8dda70df6cf06feb73a55f2bd2d75236898e4cf45c8b22f46b93fb SHA512 b7c5ac93d2f44a897b8d9eb59c470c82b2013f4e3ebf35e81254294f9961e8916a6d590d61ed1d8f3841e50c47cc7902e13d1e28826869afa9168e44e85a98e0
AUX parso-0.8.2-py310-2.patch 2145 BLAKE2B f0b403c9b9ca5370b1c2ffd52d0a22d995bff03242526a4a649cd58392380c3e38cad4b251b20580b5c22ab859f4829d8ef6ad9c5faaaae3a02b39526d3d585a SHA512 6761d95f4ae0c9a8042abc3fcb42848f323337920306974802f008614c75c7c313aa9a666dd24cfe7e01c7d01f06cbd8e2d370fbc89cc08fdd8b87bcea0aec61
AUX parso-0.8.2-py310.patch 1128 BLAKE2B f052039f8aef2913cef406c97d55e1afdcd76e46d2a64e2e2f1fd2ac1b7571950ca816213b155602f7b974d01996876a4a7bb0b92f49161d9b29e4ec98950918 SHA512 5aaff0ca295195674006f1435863ff59eac121189c938ef44428eba929a2d76daea9fffb51feebcc75502dbdfb5df7ead18d62c4ee98cb53c35129b81c562810
DIST parso-0.7.1.tar.gz 399842 BLAKE2B 1e47c1dd6846d01aa5820d7cedc3eafcf12ea0d4a2e95fa3f54429633b1c12dc39a4abe237fa46eb629408006777bd1f512cf878025b55119568ac19729b8c19 SHA512 318969a7a941c4a0948e58643b07b6f5c446ea166b3a8e44a556f0677ec9a36d7dc8c6d37ca7bce3f8276ee3d7144e22fbaaeac90c738fb90f7e94a0cf8abf7d
DIST parso-0.8.2.tar.gz 394419 BLAKE2B f4e86ae55140adc9bbfdd34a8044e7fdfbf9d318a6385ac5feedc07127061943c2d690581af144f158846e3bf6f82124046c7e625369a4055ab92a54f9210c49 SHA512 a90810ad89301d804d215392ed77593b015f13bc7ef8512302a8893b314a9e74c15e2aaa77157c8595a134d3481e8115f306f9628835271478837ec6f19e645f
-EBUILD parso-0.7.1-r1.ebuild 869 BLAKE2B 0b906c4aa9d6fd0e31eedb932560f741085380e9ab2d91188e1eca5be7bc082ace6097cd5b85a91e2c6864cc65f1cef16e03207ccd911f6f77d4b17409f9bfc2 SHA512 1fcf6676478daf62f12bbf9bb8ddfb49fd0a267637de678059693fbaac0dd07f05238782e5e0a48ad0645bef27e46c2383492bfc7f829b1fac450b0df3831959
+EBUILD parso-0.7.1-r1.ebuild 962 BLAKE2B aa2ffca7196799bc053be25fc8683e63344e4f690d0d8825d74264988d5fc7e943be088332dcc7a9ec25cafb0a4f04bdd9505c24d1c43c4ce9172235b34873d4 SHA512 be6eaf76d268fee8f0cab25d04b271d18944468cf96c70afbbb8038a4215c8163b6e13869f6854591ef1000f9dfe95b469dd79f0cac5c4bd03b65f4c248d5ab2
EBUILD parso-0.8.2.ebuild 922 BLAKE2B 30e7445875016d94268188ecb5f654c8daac9a473bf218190317c8cd15b1f45654ce94e3cfd5e2360b0de5c6ac0a02f6eb4cb786749f45c2d1e83c0a2a38031f SHA512 08a707da0f0e3a69f0c84cf8391f025f911c9a560a2da38d283f721e8053bc8289741837bef1c2e3408f6c6e2d5a7b4c3725608956fc9cdc6ac9595f5c19ddf5
MISC metadata.xml 402 BLAKE2B 3dbbdbbd15ec82aa4f38d92f52f4342a14b209edff3aa09b5dc1866784533e21f8c5d75146e3b9b535c01bb4dd36cd259abb2deb959382866242d99fb5d8fad3 SHA512 61cca7520333f595582f3e52602afa09d685d8072a211c4b8a2930fccbd98645c8c69ef7f687a25c05e2e2dc7ddda2fee16b7666cc2854b0b5ac6e23a95bac42
diff --git a/dev-python/parso/files/parso-0.7.1-flaky-test.patch b/dev-python/parso/files/parso-0.7.1-flaky-test.patch
new file mode 100644
index 000000000000..609918f31bb5
--- /dev/null
+++ b/dev-python/parso/files/parso-0.7.1-flaky-test.patch
@@ -0,0 +1,37 @@
+From 2799a7a3c2cf87fdc2d0c19a0890acea425091ce Mon Sep 17 00:00:00 2001
+From: Ivan Babrou <github@ivan.computer>
+Date: Tue, 23 Feb 2021 22:27:05 -0800
+Subject: [PATCH] Fix flaky test_cache_last_used_update
+
+Sometimes time moves slowly and strict comparison is not enough:
+
+```
+> assert now < node_cache_item.last_used < time.time()
+E assert 1614147958.869299 < 1614147958.869299
+E + where 1614147958.869299 = <parso.cache._NodeCacheItem object at 0x10456fe80>.last_used
+E + and 1614147958.869299 = <built-in function time>()
+E + where <built-in function time> = time.time
+
+test/test_cache.py:149: AssertionError
+```
+
+In particular, macOS timings can be a bit coarse.
+
+The test failure is from Apple Silicon M1.
+---
+ test/test_cache.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/test/test_cache.py b/test/test_cache.py
+index bfdbaf5..f4291c2 100644
+--- a/test/test_cache.py
++++ b/test/test_cache.py
+@@ -146,7 +146,7 @@ def test_cache_last_used_update(diff_cache, use_file_io):
+ parse('somecode2', cache=True, path=p, diff_cache=diff_cache)
+
+ node_cache_item = next(iter(parser_cache.values()))[p]
+- assert now < node_cache_item.last_used < time.time()
++ assert now <= node_cache_item.last_used <= time.time()
+
+
+ @skip_pypy
diff --git a/dev-python/parso/parso-0.7.1-r1.ebuild b/dev-python/parso/parso-0.7.1-r1.ebuild
index b4f7c8a1858e..74e95da16baf 100644
--- a/dev-python/parso/parso-0.7.1-r1.ebuild
+++ b/dev-python/parso/parso-0.7.1-r1.ebuild
@@ -13,11 +13,16 @@ SRC_URI="https://github.com/davidhalter/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.
LICENSE="MIT"
SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ppc ppc64 ~riscv sparc x86"
+KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ppc64 ~riscv sparc x86"
distutils_enable_sphinx docs
distutils_enable_tests pytest
+PATCHES=(
+ "${FILESDIR}"/${P}-flaky-test.patch
+ "${FILESDIR}"/${PN}-0.8.2-flaky-test.patch
+)
+
python_test() {
local deselect=()
[[ ${EPYTHON} == python3.10 ]] && deselect+=(