From da1d7b909447ea63bf98a3c0c622946669af921e Mon Sep 17 00:00:00 2001 From: femto Date: Fri, 7 Feb 2025 18:22:58 +0800 Subject: [PATCH] add self.logger = logger for e2b_executor (#537) --- src/smolagents/e2b_executor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/smolagents/e2b_executor.py b/src/smolagents/e2b_executor.py index 6c0919b..ca899ee 100644 --- a/src/smolagents/e2b_executor.py +++ b/src/smolagents/e2b_executor.py @@ -38,6 +38,7 @@ except ModuleNotFoundError: class E2BExecutor: def __init__(self, additional_imports: List[str], tools: List[Tool], logger): + self.logger = logger try: from e2b_code_interpreter import Sandbox except ModuleNotFoundError: @@ -58,7 +59,6 @@ class E2BExecutor: # timeout=300 # ) # print("Installation of agents package finished.") - self.logger = logger additional_imports = additional_imports + ["smolagents"] if len(additional_imports) > 0: execution = self.sbx.commands.run("pip install " + " ".join(additional_imports))