Skip to content

Commit

Permalink
fix(runner): Eliminate the exception during shutdown
Browse files Browse the repository at this point in the history
Signed-off-by: Frost Ming <[email protected]>
  • Loading branch information
frostming committed May 4, 2023
1 parent 1e07ade commit ede36c3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/bentoml/_internal/marshal/dispatcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ async def train_optimizer(
info.enqueue_time = now
self._loop.create_task(self.outbound_call(inputs_info))
except asyncio.CancelledError:
return
raise
except Exception as e: # pylint: disable=broad-except
logger.error(traceback.format_exc(), exc_info=e)

Expand Down
4 changes: 2 additions & 2 deletions tests/e2e/bento_server_http/tests/test_serve.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def test_http_server(bentoml_home: str):

server.stop()

timeout = 60
timeout = 10
start_time = time.time()
while time.time() - start_time < timeout:
retcode = server.process.poll()
Expand Down Expand Up @@ -48,7 +48,7 @@ def test_http_server_ctx(bentoml_home: str):

assert res == {"more_test": "and more json"}

timeout = 60
timeout = 10
start_time = time.time()
while time.time() - start_time < timeout:
retcode = server.process.poll()
Expand Down

0 comments on commit ede36c3

Please sign in to comment.