-
Notifications
You must be signed in to change notification settings - Fork 10
Fix Edge browser detection causing proxy.set to fail #54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
* update github action * minor change to System profile * Build(deps): Bump nanoid from 3.3.7 to 3.3.8 (bytevet#21) Bumps [nanoid](https://github.com/ai/nanoid) from 3.3.7 to 3.3.8. - [Release notes](https://github.com/ai/nanoid/releases) - [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md) - [Commits](ai/nanoid@3.3.7...3.3.8) --- updated-dependencies: - dependency-name: nanoid dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Avoid blocking 401 authentication request (bytevet#22) (bytevet#23) * fix 401 issue (bytevet#22) * enablle github action on develop branch * Support Firefox (bytevet#18) * Adapt firefox * support firefore auto publish * support firefox, and optimized UX * [i18n] Updates for file public/_locales/en/messages.json (bytevet#25) * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. * [i18n] Translate messages.json in zh_CN 100% reviewed source file: 'messages.json' on 'zh_CN'. * [i18n] Translate messages.json in zh_TW 100% reviewed source file: 'messages.json' on 'zh_TW'. * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. * update English i18n msg --------- Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> Co-authored-by: SYM01 <33443792+SYM01@users.noreply.github.com> * sentry integration (bytevet#29) * [WIP] support exporting * [WIP] support import/export settings (bytevet#7) * Support import/export profiles and close bytevet#7 (bytevet#30) * implemented an utility to export/import settings * optimized description * [i18n] Updates for file public/_locales/en/messages.json (bytevet#32) * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. * [i18n] Translate messages.json in zh_TW 100% reviewed source file: 'messages.json' on 'zh_TW'. * [i18n] Translate messages.json in zh_CN 100% reviewed source file: 'messages.json' on 'zh_CN'. --------- Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> * fix an import issue (bytevet#33) (bytevet#35) * optimized sentry release * Optimize Development Flow (bytevet#37) * [WIP] support chrome auto deploy * finalize Chrome auto deploy * npm audit fix * npm audit fix * UX improvement and close bytevet#28 (bytevet#38) * minor bug fixed * improve UX and close bytevet#28 * use the same CIDR validator as PAC script * [i18n] Updates for file public/_locales/en/messages.json (bytevet#40) * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. * [i18n] Translate messages.json in zh_TW 100% reviewed source file: 'messages.json' on 'zh_TW'. * [i18n] Translate messages.json in zh_CN 100% reviewed source file: 'messages.json' on 'zh_CN'. --------- Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> * Support Authentication in Auto Switch Profiles, fixing bytevet#34 (bytevet#45) * update deps * fix the auth issue in auto switch profiles * fix typo * Support Profile Detection for the Auto Profiles (bytevet#42) (bytevet#50) * [WIP] Reflect current profile when using auto profile (bytevet#42) * Show detected profile in the popup * simplify test cases --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com>
* update github action * minor change to System profile * Build(deps): Bump nanoid from 3.3.7 to 3.3.8 (bytevet#21) Bumps [nanoid](https://github.com/ai/nanoid) from 3.3.7 to 3.3.8. - [Release notes](https://github.com/ai/nanoid/releases) - [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md) - [Commits](ai/nanoid@3.3.7...3.3.8) --- updated-dependencies: - dependency-name: nanoid dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Avoid blocking 401 authentication request (bytevet#22) (bytevet#23) * fix 401 issue (bytevet#22) * enablle github action on develop branch * Support Firefox (bytevet#18) * Adapt firefox * support firefore auto publish * support firefox, and optimized UX * [i18n] Updates for file public/_locales/en/messages.json (bytevet#25) * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. * [i18n] Translate messages.json in zh_CN 100% reviewed source file: 'messages.json' on 'zh_CN'. * [i18n] Translate messages.json in zh_TW 100% reviewed source file: 'messages.json' on 'zh_TW'. * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. * update English i18n msg --------- Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> Co-authored-by: SYM01 <33443792+SYM01@users.noreply.github.com> * sentry integration (bytevet#29) * [WIP] support exporting * [WIP] support import/export settings (bytevet#7) * Support import/export profiles and close bytevet#7 (bytevet#30) * implemented an utility to export/import settings * optimized description * [i18n] Updates for file public/_locales/en/messages.json (bytevet#32) * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. * [i18n] Translate messages.json in zh_TW 100% reviewed source file: 'messages.json' on 'zh_TW'. * [i18n] Translate messages.json in zh_CN 100% reviewed source file: 'messages.json' on 'zh_CN'. --------- Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> * fix an import issue (bytevet#33) (bytevet#35) * optimized sentry release * Optimize Development Flow (bytevet#37) * [WIP] support chrome auto deploy * finalize Chrome auto deploy * npm audit fix * npm audit fix * UX improvement and close bytevet#28 (bytevet#38) * minor bug fixed * improve UX and close bytevet#28 * use the same CIDR validator as PAC script * [i18n] Updates for file public/_locales/en/messages.json (bytevet#40) * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. * [i18n] Translate messages.json in zh_TW 100% reviewed source file: 'messages.json' on 'zh_TW'. * [i18n] Translate messages.json in zh_CN 100% reviewed source file: 'messages.json' on 'zh_CN'. --------- Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> * Support Authentication in Auto Switch Profiles, fixing bytevet#34 (bytevet#45) * update deps * fix the auth issue in auto switch profiles * fix typo * Support Profile Detection for the Auto Profiles (bytevet#42) (bytevet#50) * [WIP] Reflect current profile when using auto profile (bytevet#42) * Show detected profile in the popup * simplify test cases * [i18n] Updates for file public/_locales/en/messages.json (bytevet#52) * [i18n] Translate messages.json in zh_TW 100% reviewed source file: 'messages.json' on 'zh_TW'. * [i18n] Translate messages.json in zh_CN 100% reviewed source file: 'messages.json' on 'zh_CN'. * [i18n] Translate messages.json in pt_BR 100% reviewed source file: 'messages.json' on 'pt_BR'. --------- Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com>
Replace generic proxy API detection with Firefox-specific runtime.getBrowserInfo method for more reliable browser identification.
Summary of ChangesHello @jimchan3301, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request addresses a critical bug where the Edge browser was misidentified as Firefox, leading to incorrect proxy configuration. The fix involves refining the browser detection mechanism to accurately distinguish Firefox from other Chromium-based browsers, thereby ensuring proper adapter selection and functionality for Edge users. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request correctly fixes a bug in browser detection where Edge was being misidentified as Firefox. The previous check for browser.proxy was too generic. The new approach, checking for the Firefox-specific API browser.runtime.getBrowserInfo, is a much more reliable way to detect Firefox and ensures that Chromium-based browsers like Edge correctly fall back to using the Chrome adapter. The change is well-implemented and robust.
|
Thank you @jimchan3301! The change is merged into develop instead. Will try to release a new version ASAP, after doing some tests. |
Root Cause
The detection logic checked
browser.proxyfirst, which exists in Edge but has Firefox-specific API behavior differences.Solution
Detect Firefox using
browser.runtime.getBrowserInfo(), a Firefox-specific API that doesn't exist in Chrome/Edge. This ensures Edge correctly uses the Chrome adapter.