fix: added Cursor OAuth provider and fixed authentication flow race conditions
- Added Cursor OAuth provider support to CLI authentication flow. - Fixed race conditions in OAuth callback handling and session picker cleanup. - Improved JWT token parsing and error handling across OAuth providers. - Replaced Bun.sleep() with abortable sleep for proper cancellation support. - Enhanced process execution with concurrent stream reading and better timeout handling. - Added cache cleanup mechanism for auth storage with 5-minute intervals.
This commit is contained in:
@@ -28,8 +28,11 @@ export async function selectSession(sessions: SessionInfo[]): Promise<string | n
|
||||
}
|
||||
},
|
||||
() => {
|
||||
ui.stop();
|
||||
process.exit(0);
|
||||
if (!resolved) {
|
||||
resolved = true;
|
||||
ui.stop();
|
||||
process.exit(0);
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user