Enable using of configured http proxy for media #1298
No reviewers
Labels
No labels
accessibility
bug
discussion
documentation
enhancement
feature parity
good first issue
help wanted
question
rss
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
PAS/nitter!1298
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "digletthat/proxy-for-media"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Currently, configured http proxy (
Config.proxy,Config.proxy_auth) is only used for API calls. Media (twimg.com) is always downloaded directly. This PR adds usage of proxy for media too.This PR adds some code duplication: both
http_poolandroutes/mediamodules now havesetHttpProxymethod andproxyvar. Maybe I should refactor this a bit and make single global var and setter somewhere, but I'm not sure where to put it.Also, maybe there should be separate proxy settings for API and media in config?
This is my first code edits in nim language.
Does this allow to toggle on or off in the preferences?
No. I don't think it should be configurable by user. It's related to http proxy that is used for outgoing http requests, so it's part of nitter server configuration.
Now that I think again about this PR, I didn't fully understand it well.
It's not about activating or deactivating the media proxy in nitter. But the http proxy when used in nitter. Sorry.
I'm not sure I agree with this change. The purpose of the proxy is circumvent IP bans, and avoid IP-based detection. API requests are low bandwidth, media certainly isn't, and most proxies are either slow, expensive, or both. If you add a separate
mediaProxyor something, then it makes sense, but having a proxy configured should not mean all media requests flow through it without a way to turn that off.View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.