potiuk commented on a change in pull request #17797: URL: https://github.com/apache/airflow/pull/17797#discussion_r694367348
########## File path: tests/task/task_runner/test_standard_task_runner.py ########## @@ -228,6 +225,8 @@ def test_on_kill(self): for process in processes: assert not psutil.pid_exists(process.pid), f"{process} is still alive" + session.close() Review comment: Maybe simply: ``` from contextlib import closing with closing(new Session()) as session: .... ``` That would avoid creating an explicit context manager. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@airflow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org