mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Create http package. #2883.
This commit is contained in:
parent
744c2cd325
commit
2442015af2
50 changed files with 930 additions and 1203 deletions
|
@ -11,7 +11,7 @@ import os
|
|||
import socket
|
||||
import platform
|
||||
import configparser
|
||||
import httplib
|
||||
import http.client
|
||||
import base64
|
||||
import urlparse
|
||||
|
||||
|
@ -151,9 +151,9 @@ class upload(PyPIRCCommand):
|
|||
urlparse.urlparse(self.repository)
|
||||
assert not params and not query and not fragments
|
||||
if schema == 'http':
|
||||
http = httplib.HTTPConnection(netloc)
|
||||
http = http.client.HTTPConnection(netloc)
|
||||
elif schema == 'https':
|
||||
http = httplib.HTTPSConnection(netloc)
|
||||
http = http.client.HTTPSConnection(netloc)
|
||||
else:
|
||||
raise AssertionError("unsupported schema "+schema)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue