Skip to content

Release#146

Merged
sk-keeper merged 37 commits intomasterfrom
release
Feb 27, 2026
Merged

Release#146
sk-keeper merged 37 commits intomasterfrom
release

Conversation

@sk-keeper
Copy link
Collaborator

No description provided.

ukumar-ks and others added 30 commits November 12, 2025 21:32
* Fix asyncio event loop cleanup with SSO auth

Previously, when applications using SSO authentication exited, the
asyncio event loop was closed while background tasks were still
running, resulting in:
- ERROR: Task was destroyed but it is pending
- RuntimeError: Event loop is closed

This issue occurred specifically with SSO authentication flows that
use push notifications, but not with password-only authentication.

This fix ensures proper cleanup by:
1. Cancelling all pending tasks before stopping the event loop
2. Giving tasks time (0.3s) to handle CancelledError gracefully
3. Waiting for the event loop thread to finish before closing

This prevents "Task was destroyed but it is pending" errors when
shutting down applications that use SSO with push notifications.

* Revert "Fix asyncio event loop cleanup with SSO auth"

This reverts commit 8364e1c.

* Close login websocket after authentication

During SSO authentication flows, a push notification websocket
(LoginPushNotifications) is created to handle 2FA, device approval,
and SSO data key requests.

This websocket was never closed after successful login, causing
it to remain active until application shutdown. This resulted in
asyncio errors about pending tasks being destroyed.

Fix: Close login.push_notifications in _on_logged_in() immediately
after authentication completes and before any post-login setup.
@socket-security
Copy link

socket-security bot commented Feb 27, 2026

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addedemail-validator@​2.3.0100100100100100

View full report

@sk-keeper sk-keeper merged commit fbb6122 into master Feb 27, 2026
7 checks passed
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.

4 participants