Skip to content

feat: add has_connection, listen and receive_queue to websocket_manager#3330

Merged
dni merged 1 commit into
devfrom
feat/wsmanager
Sep 2, 2025
Merged

feat: add has_connection, listen and receive_queue to websocket_manager#3330
dni merged 1 commit into
devfrom
feat/wsmanager

Conversation

@dni
Copy link
Copy Markdown
Member

@dni dni commented Aug 22, 2025

  • change signature to id - data
  • add has_connection
  • add get_connections
  • add receive

@dni dni changed the title feat: add has_connection and receive to websocket_manager feat: add has_connection, listen and receive queue to websocket_manager Aug 22, 2025
@codecov
Copy link
Copy Markdown

codecov Bot commented Aug 22, 2025

Codecov Report

❌ Patch coverage is 89.79592% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 57.37%. Comparing base (95b9dab) to head (5534aa9).
⚠️ Report is 3 commits behind head on dev.

Files with missing lines Patch % Lines
lnbits/core/services/websockets.py 92.30% 3 Missing ⚠️
lnbits/core/views/websocket_api.py 71.42% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev    #3330      +/-   ##
==========================================
+ Coverage   57.34%   57.37%   +0.03%     
==========================================
  Files         113      113              
  Lines       14323    14345      +22     
==========================================
+ Hits         8214     8231      +17     
- Misses       6109     6114       +5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

dni added a commit to lnbits/bitcoinswitch_extension that referenced this pull request Aug 22, 2025
depends on lnbits/lnbits#3330

- remove check server websocket in frontend
dni added a commit to lnbits/bitcoinswitch_extension that referenced this pull request Aug 22, 2025
depends on lnbits/lnbits#3330

- remove check server websocket in frontend

todo
dni added a commit to lnbits/bitcoinswitch_extension that referenced this pull request Aug 22, 2025
depends on lnbits/lnbits#3330

- remove check server websocket in frontend

todo
- change signature to id - data
- add has_connection
- add get_connections
- add receive
dni added a commit to lnbits/bitcoinswitch_extension that referenced this pull request Aug 23, 2025
depends on lnbits/lnbits#3330

- remove check server websocket in frontend

todo
dni added a commit to lnbits/bitcoinswitch_extension that referenced this pull request Aug 23, 2025
depends on lnbits/lnbits#3330

- remove check server websocket in frontend

todo
@dni dni requested review from arcbtc and talvasconcelos August 23, 2025 11:29
@motorina0
Copy link
Copy Markdown
Collaborator

why is this required?

@motorina0 motorina0 self-requested a review September 1, 2025 06:34
@dni
Copy link
Copy Markdown
Member Author

dni commented Sep 2, 2025

@dni
Copy link
Copy Markdown
Member Author

dni commented Sep 2, 2025

its a nice feature to have the ability to check if anyone is listening to the websocket.

Comment thread lnbits/core/services/notifications.py
Comment thread lnbits/core/services/websockets.py
Copy link
Copy Markdown
Collaborator

@motorina0 motorina0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dni dni changed the title feat: add has_connection, listen and receive queue to websocket_manager feat: add has_connection, listen and receive_queue to websocket_manager Sep 2, 2025
@dni dni merged commit 5021570 into dev Sep 2, 2025
85 of 86 checks passed
@dni dni deleted the feat/wsmanager branch September 2, 2025 08:02
dni added a commit to lnbits/bitcoinswitch_extension that referenced this pull request Sep 3, 2025
depends on lnbits/lnbits#3330

- remove check server websocket in frontend

todo
dni added a commit to lnbits/bitcoinswitch_extension that referenced this pull request Sep 3, 2025
* feat: dont create invoices when no websocket is active
depends on lnbits/lnbits#3330
- remove check server websocket in frontend
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants