ChatGPT
ChatGPT copied to clipboard
[Feature] Proxy support
Feature description
Add a support to set a proxy server
Motivation
If you try to enter a website from other country, it shows that I don't have access to the website
Alternatives
Use a VPN
Additional context
No response
This project is built on tauri, which does not support proxy, so this functionality is not possible.
will nofwl get proxy support or its also made on tauri?
The WindowBuilder (https://docs.rs/tauri/latest/tauri/window/struct.WindowBuilder.html) has/will have a additional_browser_args() method
(https://docs.rs/wry/latest/x86_64-pc-windows-msvc/wry/webview/trait.WebViewBuilderExtWindows.html#tymethod.with_additional_browser_args)
may be , you can use it. i don't know rust , so I don't know how to use it
if can use, add --proxy-server=127.0.0.1:7890
the webview2 can use proxy
如果通过api密钥登录,其实可以解决这个问题,当遇到访问1小时限制,访问解决,IP限制的情况时。可以通过自己api密钥去直接访问ChatGPT。
不幸的是,我的帐户没有任何积分,我不能用我的卡来支付它,所以它应该是一个网络应用程序
The WindowBuilder (https://docs.rs/tauri/latest/tauri/window/struct.WindowBuilder.html) has/will have a additional_browser_args() method
(https://docs.rs/wry/latest/x86_64-pc-windows-msvc/wry/webview/trait.WebViewBuilderExtWindows.html#tymethod.with_additional_browser_args)
may be , you can use it.
i don't know rust , so I don't know how to use it
if can use, add
--proxy-server=127.0.0.1:7890
the webview2 can use proxy
When I'm gonna get home, I'll try this
change file at
C:\Users\xxx\.cargo\registry\src\github.com-1ecc6299db9ec823\wry-0.24.1\src\webview\webview2\mod.rs
130 line
"--disable-features=msWebOOUI,msPdfOOUI,msSmartScreenProtection --proxy-server=127.0.0.1:7890".to_string()
build, you can use proxy
change default port 7890
with open("ChatGPT.exe", "rb+") as f:
data = f.read()
data = data.replace(b"127.0.0.1:7890", b"127.0.0.1:1080")
f.seek(0)
f.write(data)
f.truncate()
change file at
C:\Users\xxx\.cargo\registry\src\github.com-1ecc6299db9ec823\wry-0.24.1\src\webview\webview2\mod.rs
130 line"--disable-features=msWebOOUI,msPdfOOUI,msSmartScreenProtection --proxy-server=127.0.0.1:7890".to_string()
build, you can use proxy
change default port 7890
with open("ChatGPT.exe", "rb+") as f: data = f.read() data = data.replace(b"127.0.0.1:7890", b"127.0.0.1:1080") f.seek(0) f.write(data) f.truncate()
It is recommended to submit a PR. This method works.
The WindowBuilder (https://docs.rs/tauri/latest/tauri/window/struct.WindowBuilder.html) has/will have a additional_browser_args() method
(https://docs.rs/wry/latest/x86_64-pc-windows-msvc/wry/webview/trait.WebViewBuilderExtWindows.html#tymethod.with_additional_browser_args)
may be , you can use it.
i don't know rust , so I don't know how to use it
if can use, add
--proxy-server=127.0.0.1:7890
the webview2 can use proxyWhen I'm gonna get home, I'll try this
Does this works?
--proxy-server=127.0.0.1:7890
The latest version of Tauri supports setting proxies, and if dependencies can be updated, users can choose to configure proxies themselves.
The latest version of Tauri supports setting proxies, and if dependencies can be updated, users can choose to configure proxies themselves.
I couldn't find any information about it. I updated the packages, what's next?
The latest version of Tauri supports setting proxies, and if dependencies can be updated, users can choose to configure proxies themselves.
I couldn't find any information about it. I updated the packages, what's next?
You can refer to this commit https://github.com/tauri-apps/tauri/commit/3dc38b150ea8c59c8ba67fd586f921016928f47c First of all, the version of Tauri should be 2.0 instead of 1.0. If you have upgraded, you can then set the startup command line and configure a proxy.
https://github.com/lencx/ChatGPT/blob/main/src-tauri/src/app/setup.rs#L70
I created a topic in the Discord chat about this feature, but I couldn't solve it myself. I'm waiting for Mac OS support here.
The latest version of Tauri supports setting proxies, and if dependencies can be updated, users can choose to configure proxies themselves.
I couldn't find any information about it. I updated the packages, what's next?
You can refer to this commit tauri-apps/tauri@3dc38b1 First of all, the version of Tauri should be 2.0 instead of 1.0. If you have upgraded, you can then set the startup command line and configure a proxy.
https://github.com/lencx/ChatGPT/blob/main/src-tauri/src/app/setup.rs#L70
Seems that latest v1.3.0 has merged the commit: https://github.com/tauri-apps/tauri/releases/tag/tauri-v1.3.0
You can refer to this commit tauri-apps/tauri@3dc38b1 First of all, the version of Tauri should be 2.0 instead of 1.0. If you have upgraded, you can then set the startup command line and configure a proxy.
Waiting for MacOS.
Is this issue been solved or not?
Is this issue been solved or not? No
this feature still unsupported, uninstalled!