避免因密集request被禁止連線 - 加入暫停時間

import time

print('第一次request')
r = requests.post(url, headers=request_headers, data=form_data)
print(r.status_code)

time.sleep(3)

print('第二次request')
r = requests.post(url, headers=request_headers, data=form_data)
print(r.status_code)

results matching ""

    No results matching ""