Skip to content

Commit

Permalink
test: Reduce sleep time
Browse files Browse the repository at this point in the history
  • Loading branch information
eddiebergman committed Aug 6, 2024
1 parent 812b84e commit 0c6c785
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
1 change: 1 addition & 0 deletions neps/runtime.py
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,7 @@ def run(self) -> None: # noqa: C901, PLR0915
except KeyboardInterrupt as e:
# This throws and we have stopped the worker at this point
self._emergency_cleanup(signum=signal.SIGINT, frame=None, rethrow=e)
return

evaluation_duration = evaluated_trial.metadata.evaluation_duration
assert evaluation_duration is not None
Expand Down
6 changes: 1 addition & 5 deletions tests/test_runtime/test_error_handling_strategies.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,11 +242,7 @@ def test_worker_reset_evaluating_to_pending_on_ctrl_c(
p = multiprocessing.Process(target=worker1.run)
p.start()

# Windows is exceptionally slow at starting processes
# due to it's spawn and the fact we import torch freshly in
# the worker... hence we give it 10 seconds to get there and
# only run this test in CI
time.sleep(10)
time.sleep(5)
assert p.pid is not None
assert p.is_alive()

Expand Down

0 comments on commit 0c6c785

Please sign in to comment.