Added restart script and fixed dockerfile and run to match docs
This commit is contained in:
@@ -1,8 +1,9 @@
|
||||
from collections import defaultdict
|
||||
from datetime import datetime, timezone
|
||||
from enum import Enum, auto
|
||||
from sys import exit
|
||||
from threading import Lock
|
||||
from typing import Callable, Dict, List, Optional
|
||||
from collections import defaultdict
|
||||
|
||||
from .base_agent import BaseAgent
|
||||
from .command import Command
|
||||
@@ -160,7 +161,9 @@ class WebAgent(BaseAgent):
|
||||
if isinstance(parse_result, Command):
|
||||
result = parse_result.execute(self._working_memory)
|
||||
self._command_result = result
|
||||
if not result.should_stop:
|
||||
if result.should_stop:
|
||||
exit(42)
|
||||
else:
|
||||
self._working_memory.update()
|
||||
else:
|
||||
parse_result.update()
|
||||
|
||||
Reference in New Issue
Block a user