Run through gpt_4v agent pipeline
This commit is contained in:
@@ -11,13 +11,9 @@ def execute_command():
|
||||
|
||||
# Execute the command without any safety checks.
|
||||
try:
|
||||
process = subprocess.Popen(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||
stdout, stderr = process.communicate()
|
||||
|
||||
subprocess.run(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||
return jsonify({
|
||||
'status': 'success',
|
||||
'output': stdout.decode(),
|
||||
'error': stderr.decode()
|
||||
})
|
||||
except Exception as e:
|
||||
return jsonify({
|
||||
|
||||
Reference in New Issue
Block a user