Skip to content

Commit 25f7891

Browse files
authored
Merge pull request #186 from plotly/andrew/flags
Add single-process to flags
2 parents d71b5a2 + dd5ab73 commit 25f7891

File tree

4 files changed

+10
-3
lines changed

4 files changed

+10
-3
lines changed

choreographer/browser_async.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,8 +179,9 @@ async def _close(self) -> None:
179179
return
180180
except ChannelClosedError:
181181
_logger.debug("Can send browser.close on close channel")
182-
183182
await asyncio.to_thread(self._channel.close)
183+
if await self._is_closed(wait=2):
184+
return
184185

185186
if await self._is_closed():
186187
_logger.debug("Browser is closed after closing channel")

choreographer/utils/_kill.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@
33
import platform
44
import subprocess
55

6+
import logistro
7+
8+
_logger = logistro.getLogger(__name__)
9+
610

711
def kill(process: subprocess.Popen[bytes]) -> None:
812
if platform.system() == "Windows":
@@ -13,5 +17,7 @@ def kill(process: subprocess.Popen[bytes]) -> None:
1317
)
1418
else:
1519
process.terminate()
20+
_logger.info("Called terminate")
1621
if process.poll() is None:
22+
_logger.info("Calling kill")
1723
process.kill()

choreographer/utils/_tmpfile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ def extra_clean() -> None:
193193
_logger.info(f"Extra manual clean executing {i}.")
194194
self._delete_manually(quiet=True)
195195
i += 1
196-
time.sleep(2)
196+
time.sleep(10)
197197
if self.path.exists():
198198
self._delete_manually(quiet=False)
199199

tests/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ async def wrapped_test_fn(*args, **kwargs):
8989

9090
def pytest_configure():
9191
# change this by command line TODO
92-
pytest.default_timeout = 20
92+
pytest.default_timeout = 60
9393

9494

9595
# pytest shuts down its capture before logging/threads finish

0 commit comments

Comments
 (0)