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

twisted 22 / removal of several old functions #579

Open
jbleyel opened this issue May 17, 2022 · 5 comments
Open

twisted 22 / removal of several old functions #579

jbleyel opened this issue May 17, 2022 · 5 comments

Comments

@jbleyel
Copy link
Contributor

jbleyel commented May 17, 2022

https://github.com/twisted/twisted/releases/tag/twisted-22.1.0rc1
->

Deprecations and Removals

twisted.web.client.getPage, twisted.web.client.downladPage, and the associated implementation classes (HTTPPageGetter, HTTPPageDownloader, HTTPClientFactory, HTTPDownloader) have been removed because they do not segregate cookies by domain. They were deprecated in Twisted 16.7.0 in favor of twisted.web.client.Agent. GHSA-92x2-jw7w-xvvx. (#10295)

@jbleyel
Copy link
Contributor Author

jbleyel commented May 17, 2022

We have several options for twisted.web.client.getPage and twisted.web.client.downladPage

  • urllib.request
  • requests
  • treq
  • twisted Agent

I'm not sure what's the best case.

PRO/CONS are welcome.

@TwolDE2
Copy link
Contributor

TwolDE2 commented May 17, 2022

Personally hate twisted as its a pain to debug. E2m3u2bouquet was changed to requests and works fine…there are a couple of other modules that use requests (if I could remember which!)
Have you checked which plugins use twisted getpage etc?

@TwolDE2
Copy link
Contributor

TwolDE2 commented May 17, 2022

XLMTV-import is one, so this is an issue

@jbleyel
Copy link
Contributor Author

jbleyel commented May 20, 2022

requests or urllib is blocking the UI and twisted getPage is using a background thread.

That's why i prefer treq as a replacement.

@TwolDE2
Copy link
Contributor

TwolDE2 commented May 20, 2022

treq looks good, and based around requests api.

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