void-packages/srcpkgs/python3-trio/patches/fix-for-attrs-24.1.0.patch

25 lines
898 B
Diff
Raw Normal View History

2024-08-05 19:43:21 +02:00
Cherry picked from: https://github.com/python-trio/trio/pull/3058
From 0152c3efcffe7d9b77b2a765e6992c6685b63499 Mon Sep 17 00:00:00 2001
From: A5rocks <git@helvetica.moe>
Date: Mon, 5 Aug 2024 21:29:33 +0900
Subject: [PATCH 2/5] Fix deprecation warning from attrs
---
src/trio/_threads.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/trio/_threads.py b/src/trio/_threads.py
index a04b73729..0f0e58500 100644
--- a/src/trio/_threads.py
+++ b/src/trio/_threads.py
@@ -139,7 +139,7 @@ def current_default_thread_limiter() -> CapacityLimiter:
# system; see https://github.com/python-trio/trio/issues/182
# But for now we just need an object to stand in for the thread, so we can
# keep track of who's holding the CapacityLimiter's token.
-@attrs.frozen(eq=False, hash=False, slots=False)
+@attrs.frozen(eq=False, slots=False)
class ThreadPlaceholder:
name: str