Let people paste in the auth redirect url#7805
Conversation
| "errors": { | ||
| "cloud_auth_required": "आपके संगठन को Roo Code Cloud प्रमाणीकरण की आवश्यकता है। कृपया जारी रखने के लिए साइन इन करें।", | ||
| "organization_mismatch": "आपको अपने संगठन के Roo Code Cloud खाते से प्रमाणित होना होगा।", | ||
| "manual_url_empty": "कृपया एक वैध callback URL दर्ज करें", |
There was a problem hiding this comment.
Typographical note: The new error messages (lines 196–200) do not end with a sentence-terminating punctuation (like the full stop '।') as other messages in the file do. Consider adding a terminating punctuation for consistency.
| "manual_url_empty": "कृपया एक वैध callback URL दर्ज करें", | |
| "manual_url_empty": "कृपया एक वैध callback URL दर्ज करें।", |
| "errors": { | ||
| "cloud_auth_required": "आपके संगठन को Roo Code Cloud प्रमाणीकरण की आवश्यकता है। कृपया जारी रखने के लिए साइन इन करें।", | ||
| "organization_mismatch": "आपको अपने संगठन के Roo Code Cloud खाते से प्रमाणित होना होगा।", | ||
| "manual_url_empty": "कृपया एक वैध callback URL दर्ज करें", |
There was a problem hiding this comment.
Lexical consistency: The error messages use two different terms for the URL. Lines 196–198 refer to it as "callback URL" whereas line 199 uses "मैनुअल URL". Consider using a consistent term across all messages.
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| value={manualUrl} | ||
| onChange={handleManualUrlChange} | ||
| onKeyDown={handleKeyDown} | ||
| placeholder="vscode://RooVeterinaryInc.roo-cline/auth/clerk/callback?state=..." |
There was a problem hiding this comment.
The placeholder URL contains 'RooVeterinaryInc.roo-cline', which looks inconsistent with the repository name 'Roo-Code' and owner 'RooCodeInc'. This might be a typo—please verify the correct URL.
| placeholder="vscode://RooVeterinaryInc.roo-cline/auth/clerk/callback?state=..." | |
| placeholder="vscode://RooCodeInc.roo-code/auth/clerk/callback?state=..." |
This comment was generated because it violated a code review rule: irule_VrRKWqywZ2YV2SOE.
There was a problem hiding this comment.
Thank you for this contribution! This PR adds a useful fallback mechanism for users experiencing issues with the automatic OAuth redirect flow when connecting to Roo Code Cloud from containers. The implementation is clean and follows existing patterns well.
Positive aspects:
- ✅ Proper integration with existing CloudService authentication flow
- ✅ Comprehensive internationalization support for all 18 languages
- ✅ Good UX with auto-detection when a valid URL is pasted
- ✅ Proper error handling with localized error messages
- ✅ Clean state management and UI flow
I've left some suggestions inline that could improve security and user experience, but overall this is a solid implementation that addresses a real user need.
|
|
||
| // Auto-trigger authentication when a complete URL is pasted (with slight delay to ensure full paste is processed) | ||
| setTimeout(() => { | ||
| if (url.trim() && url.includes("://") && url.includes("/auth/clerk/callback")) { |
There was a problem hiding this comment.
Security consideration: The current validation accepts any URL with "://" and "/auth/clerk/callback". Could we add stricter validation to ensure the URL is from a trusted domain? For example:
| if (url.trim() && url.includes("://") && url.includes("/auth/clerk/callback")) { | |
| if (url.trim() && url.startsWith("vscode://") && url.includes("/auth/clerk/callback")) { |
This would ensure only VSCode protocol URLs are accepted, reducing the risk of phishing attempts.
| value={manualUrl} | ||
| onChange={handleManualUrlChange} | ||
| onKeyDown={handleKeyDown} | ||
| placeholder="vscode://RooVeterinaryInc.roo-cline/auth/clerk/callback?state=..." |
There was a problem hiding this comment.
User guidance improvement: The placeholder shows a specific extension ID that might not match the user's actual installation. Consider making this more generic or dynamic:
| placeholder="vscode://RooVeterinaryInc.roo-cline/auth/clerk/callback?state=..." | |
| placeholder="vscode://[extension-id]/auth/clerk/callback?state=..." |
Or better yet, detect and use the actual extension ID if possible.
| <div className="text-xs text-vscode-descriptionForeground"> | ||
| {t("cloud:pasteCallbackUrl")} | ||
| </div> | ||
| <VSCodeTextField |
There was a problem hiding this comment.
UX improvement: Consider adding visual feedback when authentication is in progress after manual URL submission. You could disable the input field or show a loading spinner:
| <VSCodeTextField | |
| <VSCodeTextField | |
| value={manualUrl} | |
| onChange={handleManualUrlChange} | |
| onKeyDown={handleKeyDown} | |
| placeholder="vscode://RooVeterinaryInc.roo-cline/auth/clerk/callback?state=..." | |
| className="w-1/2" | |
| disabled={authInProgress} | |
| /> |
| setManualUrl(url) | ||
|
|
||
| // Auto-trigger authentication when a complete URL is pasted (with slight delay to ensure full paste is processed) | ||
| setTimeout(() => { |
There was a problem hiding this comment.
Is the 100ms delay necessary here? If it's for ensuring the full paste is processed, modern browsers should handle this synchronously. Consider removing the setTimeout unless there's a specific browser compatibility issue:
| setTimeout(() => { | |
| if (url.trim() && url.includes("://") && url.includes("/auth/clerk/callback")) { | |
| vscode.postMessage({ type: "rooCloudManualUrl", text: url.trim() }) | |
| } |
Co-authored-by: roomote[bot] <219738659+roomote[bot]@users.noreply.github.com>
Some people are having trouble connecting to cloud from a container. This allows them to paste in the redirect URL directly.


Important
Adds manual URL input for authentication in
webviewMessageHandler.tsandCloudView.tsx, with i18n support for multiple languages.webviewMessageHandler.tsandCloudView.tsx.CloudView.tsxfor manual URL entry.common.jsonfiles across multiple locales.This description was created by
for ab31a16. You can customize this summary. It will automatically update as commits are pushed.