Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

http.client.HTTPConnection.request vs. urllib.request.Request

urllib.request and http.client are both python standard libraries. The docs for the relevant method from the former is here and the latter, here (am using 3.5)

Does anyone know why they have 2 methods within the standard libraries which appear to do the same thing, or what the difference between them is?

Reason for asking, is that I am working on merging some classes with the goal of sending a POST request of content-type multipart/form-data using Python standard libraries only. There is a question about that here with a link to code with a class which does it.

like image 213
cardamom Avatar asked Oct 15 '25 02:10

cardamom


1 Answers

see: Python urllib vs httplib?

like image 51
booleys1012 Avatar answered Oct 17 '25 17:10

booleys1012



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!