Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add proxy support for the editor #55747

Merged
merged 1 commit into from
Dec 16, 2021
Merged

Conversation

timothyqiu
Copy link
Member

Follow-up of #47257.

  • Adds proxy support for HTTPRequest.
  • Adds network/http_proxy/{host,port} editor settings.
    • Labeled as "HTTP Proxy" and it's meant to be used for both HTTP and HTTPS requests. This is the same convention as seen in Android Studio's proxy settings.
  • Makes Asset Library and Export Template Manager setup proxy according to the editor settings.

The proxy has to be set manually in Editor Settings. It would be a separate PR trying to figure out default proxy from environment variables on different platforms 馃槣

Fixes #6100.

* Adds proxy support for `HTTPRequest`.
* Adds `network/http_proxy/{host,port}` editor settings.
    * Labeled as "HTTP Proxy" and it will be used for both HTTP and
      HTTPS requests. This is the same convention as seen in Android
      Studio's proxy settings.
* Makes Asset Library and Export Template Manager use proxy according to
  the editor settings.
@timothyqiu timothyqiu added this to the 4.0 milestone Dec 9, 2021
@timothyqiu timothyqiu requested review from a team as code owners December 9, 2021 04:02
@timothyqiu timothyqiu added topic:assetlib cherrypick:3.x Considered for cherry-picking into a future 3.x release labels Dec 9, 2021
@timothyqiu
Copy link
Member Author

I can do a separate 3.x PR for these two proxy PRs after this one is merged. Adding the cherrypick: 3.x tag just as a reminder 馃槃

@akien-mga akien-mga requested a review from a team December 9, 2021 09:19
@Calinou
Copy link
Member

Calinou commented Dec 9, 2021

The proxy has to be set manually in Editor Settings. It would be a separate PR trying to figure out default proxy from environment variables on different platforms stuck_out_tongue_winking_eye

On desktop platforms, I believe the HTTP_PROXY and HTTPS_PROXY environment variables are de facto standards nowadays. You will likely have to check for both uppercase and lowercase variants though, since environment variable names are case-sensitive on macOS and Linux. (It seems that a lot of software configures https_proxy as lowercase.)

@timothyqiu
Copy link
Member Author

timothyqiu commented Dec 9, 2021

Yeah, these environment variables are definitely the way to go. Meanwhile, on Windows and macOS, desktop applications tend to honor the system proxy settings which have to be queried via API, I think.

p.s. Personally, I use the lower cased https_proxy a lot since it's easier to type 馃ぃ

@mhilbrunner
Copy link
Member

mhilbrunner commented Dec 16, 2021

This is a straighforward change after the proxy PR. Looks good, and thanks for working on this!
I'll let @Faless merge.

@Faless Faless merged commit 75ed3d7 into godotengine:master Dec 16, 2021
@Faless
Copy link
Collaborator

Faless commented Dec 16, 2021

Thanks!

@almusx
Copy link

almusx commented Apr 21, 2023

Authenticated proxy doesnt work.

@Calinou
Copy link
Member

Calinou commented Apr 21, 2023

Authenticated proxy doesnt work.

Please open a new issue for this, while detailing your OS and proxy configuration (which authentication method does it use?).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Asset Library not working behind proxy (also applies to HTTPClient and HTTPRequest)
5 participants