Skip to content

Agent gets stuck 'in-progress' #647

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

Open
anilaltuner opened this issue May 5, 2025 · 3 comments
Open

Agent gets stuck 'in-progress' #647

anilaltuner opened this issue May 5, 2025 · 3 comments
Labels
bug Something isn't working

Comments

@anilaltuner
Copy link

Please read this first

  • Have you read the docs?Agents SDK docs
    Yes
  • Have you searched for related issues? Others may have faced similar issues.
    Yes

Describe the bug

I have an orchestrator agent and two hand‑off agents.
Everything behaves correctly when I run the stack on my local machine, but after deploying the exact same containers to AWS EC2 (Docker), one of the hand‑off agents stops responding. From the traces it looks like the request to POST /v1/responses hangs indefinitely.

Image

Debug information

Item Value
Agents SDK version v0.0.12
Python version 3.11.x
Platform (local) macOS / Docker Desktop
Platform (prod) AWS EC2 t3.medium, Amazon Linux 2, Docker 24.0
OpenAI account / key Same key in both environments

Expected Behaviour

It's weird because one of the agent works well but other is stuck with same environment.

On the other hand, from local, it works well.

@anilaltuner anilaltuner added the bug Something isn't working label May 5, 2025
@pakrym-oai
Copy link
Contributor

pakrym-oai commented May 5, 2025

Does the agent end up hanging indefinitely? The underlying SDK has a 10m timeout. Do you ever hit that?

Can you try a client with much shorter timeout:

set_default_openai_client(
    AsyncOpenAI(
        http_client=DefaultAsyncHttpxClient(timeout=httpx.Timeout(timeout=20, connect=5.0))
    )
)

?

@anilaltuner
Copy link
Author

Yes it does, for example; my request from one day ago still says 'in progress' on tracing page.

Alright, I can try

@pakrym-oai
Copy link
Contributor

my request from one day ago still says 'in progress' on tracing page.

That might be a result of the outer tracing span never being terminated because the process got killed or some other reason. The fact that you see POST /v1... means that the request finished because we only send the request span information to the server after it's done.

Is it possible you're getting an error in the application that causes it to exit?

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
None yet
Development

No branches or pull requests

2 participants