Skip to content

Conversation

@adrianlyjak
Copy link
Contributor

@adrianlyjak adrianlyjak commented Sep 30, 2025

Add a consumer lock to the /events API handler to ensure reliable event consumption for a single connection, multiple connections are rejected until the first hangs up.

@cursor
Copy link

cursor bot commented Sep 30, 2025

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@coveralls
Copy link

coveralls commented Sep 30, 2025

Pull Request Test Coverage Report for Build 18150157826

Details

  • 35 of 37 (94.59%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.008%) to 90.236%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/workflows/server/server.py 35 37 94.59%
Totals Coverage Status
Change from base Build 18149922980: -0.008%
Covered Lines: 1608
Relevant Lines: 1782

💛 - Coveralls

@adrianlyjak adrianlyjak force-pushed the cursor/add-consumer-lock-to-events-api-ba01 branch from 0f92195 to 151ba51 Compare October 1, 2025 03:10
Co-authored-by: adrian <adrian@runllama.ai>
@adrianlyjak adrianlyjak force-pushed the cursor/add-consumer-lock-to-events-api-ba01 branch from 151ba51 to 5a4f4de Compare October 1, 2025 03:15
@adrianlyjak adrianlyjak marked this pull request as ready for review October 1, 2025 11:40
@zhaotai
Copy link
Contributor

zhaotai commented Oct 1, 2025

Not sure in general if it's a good idea because there could be potential cases where users switch to different client or listen to same events from different clients.

Even though we want to limit only one session at the same time. We probably need to implement a mechanism to switch instead of reject.

But as a workaround, it's fine for now

@adrianlyjak adrianlyjak added the bug Something isn't working label Oct 1, 2025
@adrianlyjak adrianlyjak merged commit 686293f into main Oct 1, 2025
6 checks passed
@adrianlyjak adrianlyjak deleted the cursor/add-consumer-lock-to-events-api-ba01 branch October 1, 2025 20:25
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

Successfully merging this pull request may close these issues.

6 participants