Skip to content

Commit 4a49502

Browse files
authored
Merge pull request #910 from similato87/python-3.8-support
Update Type Hinting from tuple to Tuple
2 parents 39f7b2a + db29cbe commit 4a49502

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

gpt_engineer/core/base_execution_env.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from abc import ABC, abstractmethod
22
from subprocess import Popen
3-
from typing import Optional
3+
from typing import Optional, Tuple
44

55
from gpt_engineer.core.files_dict import FilesDict
66

@@ -20,7 +20,7 @@ class BaseExecutionEnv(ABC):
2020
"""
2121

2222
@abstractmethod
23-
def run(self, command: str, timeout: Optional[int] = None) -> tuple[str, str, int]:
23+
def run(self, command: str, timeout: Optional[int] = None) -> Tuple[str, str, int]:
2424
"""
2525
Runs a command in the execution environment.
2626
"""

gpt_engineer/core/default/disk_execution_env.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import time
33

44
from pathlib import Path
5-
from typing import Optional, Union
5+
from typing import Optional, Tuple, Union
66

77
from gpt_engineer.core.base_execution_env import BaseExecutionEnv
88
from gpt_engineer.core.default.file_store import FileStore
@@ -41,7 +41,7 @@ def popen(self, command: str) -> subprocess.Popen:
4141
)
4242
return p
4343

44-
def run(self, command: str, timeout: Optional[int] = None) -> tuple[str, str, int]:
44+
def run(self, command: str, timeout: Optional[int] = None) -> Tuple[str, str, int]:
4545
start = time.time()
4646
print("\n--- Start of run ---")
4747
# while running, also print the stdout and stderr

0 commit comments

Comments
 (0)