Skip to content

Commit e8648ae

Browse files
committed
nit
1 parent aeb07d1 commit e8648ae

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

playwright/_impl/_wait_helper.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -45,11 +45,9 @@ def _wait_for_event_info_before(self, wait_id: str, event: str) -> None:
4545
},
4646
)
4747

48-
async def _wait_for_event_info_after(
49-
self, wait_id: str, error: Exception = None
50-
) -> None:
48+
def _wait_for_event_info_after(self, wait_id: str, error: Exception = None) -> None:
5149
try:
52-
await self._channel.send(
50+
self._channel.send_no_reply(
5351
"waitForEventInfo",
5452
{
5553
"info": {
@@ -97,15 +95,13 @@ def _fulfill(self, result: Any) -> None:
9795
self._cleanup()
9896
if not self._result.done():
9997
self._result.set_result(result)
100-
self._loop.create_task(self._wait_for_event_info_after(self._wait_id))
98+
self._wait_for_event_info_after(self._wait_id)
10199

102100
def _reject(self, exception: Exception) -> None:
103101
self._cleanup()
104102
if not self._result.done():
105103
self._result.set_exception(exception)
106-
self._loop.create_task(
107104
self._wait_for_event_info_after(self._wait_id, exception)
108-
)
109105

110106
def wait_for_event(
111107
self,

0 commit comments

Comments
 (0)