問題描述
如何使用 IDM 自動下載? (How can I automate downloads using IDM?)
我想使用 selenium python 自動下載,而 selenium python 又帶有 IDM 的鏈接。但是,問題是我無法使用 IDM 下載。
參考解法
方法 1:
Thisis not good practice in selenium automation
Whilst it is possible to start a download by clicking a link with a browser under Selenium’s control, the API does not expose download progress, making it less than ideal for testing downloaded files. This is because downloading files is not considered an important aspect of emulating user interaction with the web platform. Instead, find the link using Selenium (and any required cookies) and pass it to a HTTP request library like libcurl.
Please refer seleniumhq site
(by 007 AZx、Justin Lambert)