Open maximedrn opened 1 year ago
Edit: this seems to be either an error with all POST requests on the project since the switch to FastAPI (I don't have a problem with version 0.4.0); or a problem with the "typing" of FastAPI as the "Pending" of the request suggests a failure in the function arguments.
Hello @maximedrn have you run it in production? Have you tried to manually punch in your API in the .env file? Are you asking it questions that need the serper key? Would you mind providing frontend end logs?
Looking forward to getting to the bottom of this !!!
Hi @jasangill1, thanks for your reply.
I ran it several times in production (master branch and versions 0.9.0 and 0.8.0), I used different browsers in normal and incognito mode. I've also used the /api/docs
interface and all POST requests don't work (remain pending).
The API key is present in both .env
files, I've also tried adding a second API key from the frontend.
I'm only requesting one of the 3 default tasks present in the frontend.
~Aren't the frontend logs the command prompt logs for ./next
?~
Hey thanks @maximedrn! The tools route is not behind an authentication wall so it will always return a result.
Because of this, this feels like maybe a db connection issue but again its hard to know for sure. Can you tell me about your precise setup. Are you running this on a VM, are you running this through docker, etc? Additionally, maybe we can schedule a call or something to walk through this and find the issue once and for all :)
I'm not running this on a VM or with Docker (don't wan't to enable Hyper-V and the Linux subsystem). Thus I'm using the manual setup. Here are all the commands I typed:
git clone https://github.com/reworkd/AgentGPT.git
cd AgentGPT
cd cli
npm install
npm run dev
Steps outside the prompt :
./next/.env
file with the above information../platform/.env
with the above information../reworkd_platform/settings.py
file with the above information..sh
files to ensure that the database ports are correct.First command prompt:
cd next
npm install
cd prisma
.\useSqlite.sh
cd ..
npx prisma db push
npm run dev
Second command prompt:
cd platform
python -m venv env
.\env\scripts\Activate.bat
pip install poetry
pip install charset-normalizer==2.0.12
poetry install
poetry run python -m reworkd_platform
I've tried all versions of AgentGPT, it doesn't work since version 0.7.0. Maybe since FastAPI has been added to the project something has gone wrong with the database during manual configuration.
I switched to Docker and the tool now works (after a few small modifications: https://github.com/reworkd/AgentGPT/issues/984) The manual version doesn't work, I think a little more documentation detailing the steps would be nice for such a well-developed project.
However, how do I get out of dev mode with Docker? I'd like to be able to access the connection with Google and Github. I haven't seen anything that explains how to do this, or at least I don't know what to change in the Docker files so that it runs npm run build && npm run start
instead of npm run dev
.
Hello @maximedrn Navigate to the ./next/dockerfile
there will be were you can edit the command you are looking for!! once in there edit the bottom line into this:
# Start the application in production mode CMD ["npm", "run", "build", "&&", "npm", "start"]
Please try it and let me know if it helps!
Please check that this issue hasn't been reported before.
Expected Behavior
AgentGPT should produce results from
/api/agent/start/
but does not. Everything else works: login with username, etc.Current behaviour
When deploying a task, AgentGPT starts to think but absolutely nothing happens. I can't pause the task (it loads indefinitely), I can only stop it.
Steps to reproduce
I'm running in development mode (Manual mode) with version 0.9.0-beta.
Operating system(s): Windows 11 (64-bit) and macOS. Python version: 3.9.13 Node.js version: 16.15.1 Model used: 3.5-turbo I tried with 2 different API keys that work on the online version of AgentGPT.
I'm using this script to run both the frontend and the backend (I don't think this will be a problem):
Here's the
.env
file I use for the./next/
and./platform/
folders:I also edited the lines 33, 34, 60 and 61 of the
./platform/reworkd_platform/settings.py
file:And here are the console outputs:
./next/
(everything seems ok there):./platform/
:The request to
/api/agent/start
remains "Pending" from the browser. Occasionally, the request is not even displayed on the./platform/
prompt, even though it has been sent. All communications with the database appear to be correct, at least for "GET /api/agent/tools HTTP/1.1" requests.Possible solution
I think it has something to do with the changes I've made because the basic settings prevent me from communicating with the database.
Which Operating Systems are you using?
Acknowledgements