fix execute

This commit is contained in:
Junlin Liu
2023-06-18 11:44:35 +00:00
parent 4b093cb29b
commit e58bfff8bb

View File

@@ -143,10 +143,11 @@ def execute_entrypoint(ai, dbs):
print() print()
print(command) print(command)
print() print()
print('If yes, press enter. If no, type "no"') print('If yes, type "yes". If no, press enter.')
print() print()
if input() == "no": if input().lower() != "yes":
print("Ok, not executing the code.") print("Ok, not executing the code.")
return []
print("Executing the code...") print("Executing the code...")
print() print()
subprocess.run("bash run.sh", shell=True, cwd=dbs.workspace.path) subprocess.run("bash run.sh", shell=True, cwd=dbs.workspace.path)