libdev 0.89__tar.gz → 0.90__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {libdev-0.89 → libdev-0.90}/PKG-INFO +1 -1
- {libdev-0.89 → libdev-0.90}/libdev/__init__.py +1 -1
- {libdev-0.89 → libdev-0.90}/libdev/req.py +9 -1
- {libdev-0.89 → libdev-0.90}/libdev/s3.py +1 -1
- {libdev-0.89 → libdev-0.90}/libdev.egg-info/PKG-INFO +1 -1
- {libdev-0.89 → libdev-0.90}/LICENSE +0 -0
- {libdev-0.89 → libdev-0.90}/README.md +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/cfg.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/check.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/codes.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/crypt.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/dev.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/doc.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/fin.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/gen.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/img.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/lang.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/log.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/num.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev/time.py +0 -0
- {libdev-0.89 → libdev-0.90}/libdev.egg-info/SOURCES.txt +0 -0
- {libdev-0.89 → libdev-0.90}/libdev.egg-info/dependency_links.txt +0 -0
- {libdev-0.89 → libdev-0.90}/libdev.egg-info/requires.txt +0 -0
- {libdev-0.89 → libdev-0.90}/libdev.egg-info/top_level.txt +0 -0
- {libdev-0.89 → libdev-0.90}/setup.cfg +0 -0
- {libdev-0.89 → libdev-0.90}/setup.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_cfg.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_check.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_codes.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_crypt.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_dev.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_doc.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_gen.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_img.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_lang.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_log.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_num.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_req.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_s3.py +0 -0
- {libdev-0.89 → libdev-0.90}/tests/test_time.py +0 -0
|
@@ -8,6 +8,7 @@ import aiohttp
|
|
|
8
8
|
async def fetch(
|
|
9
9
|
url,
|
|
10
10
|
payload=None,
|
|
11
|
+
files=None,
|
|
11
12
|
type_req="post",
|
|
12
13
|
type_data="json",
|
|
13
14
|
headers=None,
|
|
@@ -35,8 +36,15 @@ async def fetch(
|
|
|
35
36
|
if payload is None:
|
|
36
37
|
payload = {}
|
|
37
38
|
|
|
39
|
+
if files is not None:
|
|
40
|
+
form = aiohttp.FormData()
|
|
41
|
+
for name, fdata in files.items():
|
|
42
|
+
form.add_field(name, fdata)
|
|
43
|
+
payload = form
|
|
44
|
+
type_data = "data"
|
|
45
|
+
|
|
38
46
|
async with aiohttp.ClientSession(
|
|
39
|
-
timeout=
|
|
47
|
+
timeout=aiohttp.ClientTimeout(total=timeout),
|
|
40
48
|
) as session:
|
|
41
49
|
if type_req == "post":
|
|
42
50
|
req = session.post
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|