gpt-engineer icon indicating copy to clipboard operation
gpt-engineer copied to clipboard

Unable to run app.py after gpt-engineer creates it

Open promptDeveloper opened this issue 2 years ago • 8 comments

I am getting the following error message when I try to run the app.py file gpt-engineer wrote, but I am having trouble running it. Screen Shot 2023-06-19 at 5 50 34 PM Also, I wasn't able to run the pip install --user -r requirements.txt command because I got the following error message. Could these have been reason for python app.py not running? Screen Shot 2023-06-19 at 5 49 10 PM

promptDeveloper avatar Jun 19 '23 22:06 promptDeveloper

try this

go to the folder you want the files to be. 

git clone https://github.com/AntonOsika/gpt-engineer.git

cd {your_project_folder}/gpt-engineer
pip install gpt-engineer
pip install -e .

export OPENAI_API_KEY=[your api key]

cp -r projects/example/ projects/my-new-project
Fill in the main_prompt file in your new folder

Make sure you are in {your_project_folder}/gpt-engineer folder
Run: gpt-engineer projects/my-new-project

Check the generated files in projects/my-new-project/workspace

juarezjl avatar Jun 19 '23 23:06 juarezjl

Scratch that again... now I'm getting an ImportError, as shown below. What can I do to fix this? Screen Shot 2023-06-19 at 6 45 04 PM

ghost avatar Jun 19 '23 23:06 ghost

by any chance you are trying to run a game example using pygame ina vbox env ? Otherwise you are missing some dependecies need it to run your app.py (pygame)

juarezjl avatar Jun 19 '23 23:06 juarezjl

no i'm trying to run the simple GUI that I hope gpt-engineer made for me that allows users to slow/speed up songs and add bass to them. What other dependencies should I have then? Here is the following error I'm running into as well Screen Shot 2023-06-19 at 6 54 33 PM

ghost avatar Jun 19 '23 23:06 ghost

I'm also not sure if I'm in a vbox env, what env should I be in?

ghost avatar Jun 19 '23 23:06 ghost

So there is a subdirectory called 'venv' under which my workspace directory is under. Also the error I am currently facing is this one, any thoughts? Screen Shot 2023-06-19 at 7 05 18 PM

ghost avatar Jun 20 '23 00:06 ghost

again you are missing dependecies for your app.py is not gpt-engineer. here is a post that might help https://github.com/jiaaro/pydub/issues/348 or you can try this based on your error :

pip install ffmpeg-downloader
ffdl install --add-path

juarezjl avatar Jun 20 '23 00:06 juarezjl

i wrote the two above commands you gave me, should I have written my own path where you listed add-path (would that be the path that app.py is in?). They both installed, and here is the error I am currently facing even after restarting my terminal Screen Shot 2023-06-19 at 7 17 29 PM

ghost avatar Jun 20 '23 00:06 ghost

Should work now

AntonOsika avatar Jul 08 '23 15:07 AntonOsika