Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

execute_python_file throws opaque error if docker is not installed #2006

Closed
2 tasks done
Nickonomic opened this issue Apr 16, 2023 · 7 comments · Fixed by #2231
Closed
2 tasks done

execute_python_file throws opaque error if docker is not installed #2006

Nickonomic opened this issue Apr 16, 2023 · 7 comments · Fixed by #2231
Labels
bug Something isn't working

Comments

@Nickonomic
Copy link

Nickonomic commented Apr 16, 2023

⚠️ Search for existing issues first ⚠️

  • I have searched the existing issues, and there is no existing issue for my problem

GPT-3 or GPT-4

  • I am using Auto-GPT with GPT-3 (GPT-3.5)

Steps to reproduce 🕹

CRITICISM: I need to ensure that the command is working properly before attempting to locate and fix the issue with the trading strategies file.
NEXT ACTION: COMMAND = execute_python_file ARGUMENTS = {'file': 'hello_world.py'}
Executing file 'hello_world.py' in workspace 'E:\auto\Auto-GPT\auto_gpt_workspace'
SYSTEM: Command execute_python_file returned: Error: Error while fetching server API version: (2, 'CreateFile', 'The system cannot find the file specified.')
The JSON object is valid.

Current behavior 😯

No response

Expected behavior 🤔

The only way I managed to make execute file work was to get rid of docker stuff and re-write it using subprocess.

Your prompt 📝

# Paste your prompt here
@Nickonomic Nickonomic changed the title Python files execution doesn't work (actually, never did). Python files execution doesn't work (actually, it never did). Apr 16, 2023
@E-Labs-io
Copy link

Yea mine hasn't been able to execute and python ether. Haven't really looked into it though

@nponeccop nponeccop added the bug Something isn't working label Apr 16, 2023
@Wladastic
Copy link
Contributor

You need to have Docker Desktop running for that to work.

@robnraz
Copy link

robnraz commented Apr 17, 2023

Have the same issue but the bot normally issues a search command for the filename specified, finds the file (in the working directory), and can then execute the file.

It seems a search must be performed first before execution of the file can be done

It has happened this way for me several times.

@GerardCB
Copy link

I could only execute these files if I asked AutoGPT to run the 'python hello_world.py' command using the command line.
If we need to have Docker Desktop installed, this should be added to some requirements or only allow the bot to use the execute python files command if the user has installed Docker Desktop.

@E-Labs-io
Copy link

I have Docker desktop running, but when Auto-GPT trys to execute a command we get

NEXT ACTION: COMMAND = execute_python_file ARGUMENTS = {'file': 'authenticate_notion.py'}
Executing file 'authenticate_notion.py' in workspace '/Users/tuck/Documents/E-Labs/AI/Build Tests/Auto-GPT-master(16:04 02)/auto_gpt_workspace'
SYSTEM: Command execute_python_file returned: Error: File 'authenticate_notion.py' does not exist.

The file does exists, just isn't visible it seems to auto-gpt

@Stunspot
Copy link

The issue is that someone rewrote the execute_python_file command to assume it was in a docker container. An app expecting to be in a docker container that isn't throws a file not found error. Was going nuts from this. Just now had ChatGPT rip out the docker crap for me. Here's my execute_code.py file:

execute_code - execute_python_file fixed.py.txt

@Pwuts Pwuts changed the title Python files execution doesn't work (actually, it never did). execute_python_file throws opaque error if docker is not installed Apr 17, 2023
@Pwuts Pwuts moved this to 📋 Backlog in AutoGPT development kanban Apr 17, 2023
@Pwuts Pwuts moved this from 📋 Backlog to 🏗 In progress in AutoGPT development kanban Apr 18, 2023
@iva-nova-e-katerina
Copy link

This bug is annoying me for a week

@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in AutoGPT development kanban Apr 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

8 participants