summarylogtreecommitdiffstats
path: root/fix-pytest-asyncio-usage.patch
blob: c43a6cc5ef036fdc3b2b6fc30b8ffbe298c7e5d3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
diff --unified --recursive --text --new-file anthropic-sdk-python-0.21.3.orig/tests/conftest.py anthropic-sdk-python-0.21.3/tests/conftest.py
--- anthropic-sdk-python-0.21.3.orig/tests/conftest.py	2024-03-23 18:35:29.207121356 +0100
+++ anthropic-sdk-python-0.21.3/tests/conftest.py	2024-03-23 18:36:54.607407733 +0100
@@ -1,7 +1,6 @@
 from __future__ import annotations
 
 import os
-import asyncio
 import logging
 from typing import TYPE_CHECKING, Iterator, AsyncIterator
 
@@ -16,14 +15,6 @@
 
 logging.getLogger("anthropic").setLevel(logging.DEBUG)
 
-
-@pytest.fixture(scope="session")
-def event_loop() -> Iterator[asyncio.AbstractEventLoop]:
-    loop = asyncio.new_event_loop()
-    yield loop
-    loop.close()
-
-
 base_url = os.environ.get("TEST_API_BASE_URL", "http://127.0.0.1:4010")
 
 api_key = "my-anthropic-api-key"