OpenHands icon indicating copy to clipboard operation
OpenHands copied to clipboard

BedrockException - AWS region not set

Open cocobeach opened this issue 1 year ago • 5 comments

Describe the bug

Error when giving prompt top the AI for the first time:

Error condensing thoughts: BedrockException - AWS region not set: set AWS_REGION_NAME or AWS_REGION env variable or in .env file

Setup and configuration

Current version:

dcaf51b

My config.toml and environment vars (be sure to redact API keys):

WORKSPACE_DIR="./workspace"
LLM_BASE_URL="http://0.0.0.0:4000/"
LLM_MODEL="ollama/mixtral"
LLM_EMBEDDING_MODEL="ollama/mixtral"
ANTHROPIC_API_KEY="xxxxxxxxxxxxxxxxxxxxxxxxxxxx"

My model and agent (you can see these settings in the UI):

  • Model: mistral.mixtral-8x7b-instruct-v0:1
  • Agent:MonologueAgent

Commands I ran to install and run OpenDevin: make start-frontend Starting frontend...

litellm --model ollama/mixtral

uvicorn opendevin.server.listen:app --port 3000

Steps to Reproduce:

  1. Start Open Devin
  2. input a prompt:

Screenshot from 2024-04-05 08-46-14

Logs, error messages, and screenshots:

Additional Context

/OpenDevin/agenthub/monologue_agent/utils/monologue.py", line 36, in condense raise RuntimeError(f"Error condensing thoughts: {e}") RuntimeError: Error condensing thoughts: BedrockException - AWS region not set: set AWS_REGION_NAME or AWS_REGION env variable or in .env file

OBSERVATION: Error condensing thoughts: BedrockException - AWS region not set: set AWS_REGION_NAME or AWS_REGION env variable or in .env file Exited before finishing

cocobeach avatar Apr 05 '24 07:04 cocobeach

Point being I don;t want amazon, I didn't setup amazon, why is it giving me this exception?

thanks for the great job btw

cocobeach avatar Apr 05 '24 07:04 cocobeach

Screenshot from 2024-04-05 09-05-45 Same with claude

cocobeach avatar Apr 05 '24 08:04 cocobeach

What is the output of your logs located at OpenDevin/logs? I don't see anything in the code to ask this so I wonder if something else. Also, I see you ran the make start-frontend but did you also run make start-backend?

risingsunomi avatar Apr 05 '24 09:04 risingsunomi

We have not use aws in backend. I guess the problem may result from ollama/mixtral . Not sure if anyone have experience on ollama/mixtral can reply.

yufansong avatar Apr 05 '24 20:04 yufansong

Trying different models and get the same result, none of ollama models installed on my machine is working. All returns the message: "Oops. Something went wrong: BedrockException - AWS region not set: set AWS_REGION_NAME or AWS_REGION env variable or in .env file".

Joseph-L-O avatar Apr 05 '24 20:04 Joseph-L-O

I had the same issue, this solved it for me: https://github.com/OpenDevin/OpenDevin/issues/619#issuecomment-2041526238

liontariai avatar Apr 07 '24 16:04 liontariai

This should be solved as of https://github.com/OpenDevin/OpenDevin/pull/863

If not let us know!

rbren avatar Apr 07 '24 22:04 rbren