Skip to content

Session is Busy Error Message #760

Closed

Description

@captjt

While working in a long session, I get an error that says "Error: Session session_id is busy", but my chat is not "working..." and I can still run /compact on the session. I assume there is a mechanism that isn't quite updating that the session is actually unlocked now. Here are some logs and a screenshot that might be useful. This is on a Mac, but if there are any other things that might help reproduce this please let me know -- I can add more details.

Image
INFO  2025-07-08T14:44:33 +0ms service=session sessionID=ses_815a2734cfferqJAknKIO6uGQ6 unlocking
INFO  2025-07-08T14:44:33 +0ms service=bus type=session.idle publishing
INFO  2025-07-08T14:44:33 +0ms service=server duration=20443 response
INFO  2025-07-08T14:44:41 +7942ms service=server method=GET path=/find/file request
INFO  2025-07-08T14:44:41 +33ms service=server duration=32 response
INFO  2025-07-08T14:44:41 +179ms service=server method=GET path=/find/file request
INFO  2025-07-08T14:44:41 +12ms service=server duration=12 response
INFO  2025-07-08T14:44:41 +5ms service=server method=GET path=/find/file request
INFO  2025-07-08T14:44:41 +17ms service=server duration=16 response
INFO  2025-07-08T14:44:42 +104ms service=server method=GET path=/find/file request
INFO  2025-07-08T14:44:42 +10ms service=server duration=10 response
INFO  2025-07-08T14:44:42 +50ms service=server method=GET path=/find/file request
INFO  2025-07-08T14:44:42 +10ms service=server duration=9 response
INFO  2025-07-08T14:44:42 +51ms service=server method=GET path=/find/file request
INFO  2025-07-08T14:44:42 +8ms service=server duration=8 response
INFO  2025-07-08T14:44:42 +197ms service=server method=GET path=/find/file request
INFO  2025-07-08T14:44:42 +11ms service=server duration=11 response
INFO  2025-07-08T14:44:42 +35ms service=server method=GET path=/find/file request
INFO  2025-07-08T14:44:42 +10ms service=server duration=9 response
INFO  2025-07-08T14:44:44 +1654ms service=server method=POST path=/session/ses_815a2734cfferqJAknKIO6uGQ6/message request
INFO  2025-07-08T14:44:44 +0ms service=session sessionID=ses_815a2734cfferqJAknKIO6uGQ6 locking
INFO  2025-07-08T14:44:44 +0ms service=session session=ses_815a2734cfferqJAknKIO6uGQ6 chatting
INFO  2025-07-08T14:44:44 +4ms service=session sessionID=ses_815a2734cfferqJAknKIO6uGQ6 locking
INFO  2025-07-08T14:44:44 +0ms service=session sessionID=ses_815a2734cfferqJAknKIO6uGQ6 unlocking
INFO  2025-07-08T14:44:44 +1ms service=bus type=session.idle publishing
INFO  2025-07-08T14:44:44 +0ms service=server duration=5 response
INFO  2025-07-08T14:44:58 +14312ms service=bus type=* unsubscribing
INFO  2025-07-08T14:44:58 +0ms service=server event disconnected
INFO  2025-07-08T14:44:58 +3ms service=app name=lsp shutdown
INFO  2025-07-08T14:44:58 +0ms service=lsp.client serverID=golang shutting down
INFO  2025-07-08T14:44:58 +0ms service=lsp.client serverID=golang shutdown
INFO  2025-07-08T14:44:58 +0ms service=app name=file.watcher shutdown
INFO  2025-07-08T14:44:58 +0ms service=app name=session shutdown

Activity

  1. MendyLanda commented on Jul 8, 2025

    @MendyLanda

    same

  2. self-assigned this
    on Jul 9, 2025
  3. simon-marcus commented on Jul 9, 2025

    @simon-marcus

    Same:

     failed to send message: POST                       
     "http://127.0.0.1:59808/session/ses_81edb10f7ffedc 
     vbJvp8MW4xrJ/message": 400 Bad Request             
     {"name":"UnknownError","data":{"message":"Error:   
     Session ses_81edb10f7ffedcvbJvp8MW4xrJ is busy"}}  
    

    No further messages are sending. I've restarted opencode, using v0.2.13

  4. adambuchweitz commented on Jul 9, 2025

    @adambuchweitz

    Yep, same here

  5. luqven commented on Jul 9, 2025

    @luqven

    Same here, sharing in case it's useful.

    • Long session
    • Still see the error after existing and starting opencode again
    Image
  6. reedbender commented on Jul 10, 2025

    @reedbender

    same error here, I've gotten this message during multiple sessions today. v0.2.6 ... generally pops up after long sessions, but it happens regardless of how long its been since my last message -- I'm not trying to ask questions while a response is being generated.

    Image
  7. reedbender commented on Jul 10, 2025

    @reedbender

    Generally resolved with /new , but session context is lost

  8. reedbender commented on Jul 10, 2025

    @reedbender

    I wonder if this has anything to do with this open issue...? Any chance the session isn't actually being released in some instances, leading to a memory leak?
    #804 (comment)

  9. almirsarajcic commented on Jul 10, 2025

    @almirsarajcic
    Contributor

    Got the same on 0.2.18, claude-opus-4-20250514.
    Noticed it in two sessions, both were long, certainly at more than 60% context.

  10. thdxr commented on Jul 10, 2025

    @thdxr
    Member

    fixed in v0.2.19

  11. almirsarajcic commented on Jul 10, 2025

    @almirsarajcic
    Contributor

    Unfortunately, I still see this when I'm trying to add a message to the queue.

    Btw., I can't interrupt it while it's working - that's why I even tried to queue up a message. But I get that "session is busy" message, and I have to wait for it to finish the work it's doing until I can continue prompting.

    I'm on version 0.2.20.

  12. markjaquith commented on Jul 11, 2025

    @markjaquith
    Contributor

    v0.2.27 — also can't queue a message while it's working (sonnet 3.7 via bedrock)

  13. almirsarajcic commented on Jul 17, 2025

    @almirsarajcic
    Contributor

    Should I create a new issue for this? I can't add a message to the queue.

    If there's no ability to queue messages (or an intent to support that feature), maybe we should be forced to interrupt the session before being able to type into the textarea.

    I'm on version 0.3.18, Claude Sonnet 4.

  14. adamdotdevin commented on Jul 17, 2025

    @adamdotdevin
    Member

    we're going to add queueing, just haven't gotten to it yet

  15. added a commit that references this issue on May 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions