小编Edw*_*ric的帖子

使用 python 发送 post 请求最快的方法是什么?

我尝试了普通的“请求”模块,但它真的很慢,有没有更快的方法来发送 POST 请求?

import requests 
from time import time 
t = time() 
requests.post("https://httpbin.org/post") 
print(time() - t)  # 0.884 s
Run Code Online (Sandbox Code Playgroud)

对于 GET 请求也是如此:

requests.get("https://example.com/") 
print(time() - t)  # 0.604 s
Run Code Online (Sandbox Code Playgroud)

python post http python-requests

0
推荐指数
1
解决办法
5484
查看次数

标签 统计

http ×1

post ×1

python ×1

python-requests ×1