Skip to content

Commit 9a27445

Browse files
committed
Remove leave_alive from changestream
1 parent 55aaee3 commit 9a27445

File tree

2 files changed

+0
-4
lines changed

2 files changed

+0
-4
lines changed

pymongo/asynchronous/change_stream.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,8 +258,6 @@ async def _run_aggregation_cmd(
258258

259259
async def _create_cursor(self) -> AsyncCommandCursor: # type: ignore[type-arg]
260260
async with self._client._tmp_session(self._session) as s:
261-
if s:
262-
s.leave_alive = True
263261
return await self._run_aggregation_cmd(session=s)
264262

265263
async def _resume(self) -> None:

pymongo/synchronous/change_stream.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -256,8 +256,6 @@ def _run_aggregation_cmd(self, session: Optional[ClientSession]) -> CommandCurso
256256

257257
def _create_cursor(self) -> CommandCursor: # type: ignore[type-arg]
258258
with self._client._tmp_session(self._session) as s:
259-
if s:
260-
s.leave_alive = True
261259
return self._run_aggregation_cmd(session=s)
262260

263261
def _resume(self) -> None:

0 commit comments

Comments
 (0)