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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE REQUEST] A few different proxy additions. #37

Open
GenerelSchwerz opened this issue Dec 10, 2020 · 1 comment
Open

[FEATURE REQUEST] A few different proxy additions. #37

GenerelSchwerz opened this issue Dec 10, 2020 · 1 comment

Comments

@GenerelSchwerz
Copy link

  1. If a webhook returns an error such as a 429 error, there should be a way to iterate through the supplied dict of proxies.

  2. As far as I'm aware, setting the proxies for a webhook object does not persist through a While or For-loop if it is nested. As such, proxies (to my albeit mediocre coding skills) can't be changed per n messages sent.

  3. The proxies used by the webhook should be an attribute of the webhook so debugging for proxy usage is easier.

@GrandMoff100
Copy link
Contributor

  1. Could you iterate through the webhook.proxies attribute of a given webhook that you call .execute() on?

  2. The workaround is a little hacky, but you could modify the .proxies attribute of the webhook object in the for/while loop, given that the webhook object persists, a.k.a. initializing it before entering the loop.

  3. As for you third point, the proxies are available with webhook.proxies, that's where the DiscordWebhook class stores them the proxies to use, until and after executed.

Does this help? And if not, do you have any subsequent questions?

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

No branches or pull requests

2 participants