简体   繁体   中英

libtorrent, how download .torrent in Python

I need to use this library from Python, but I not found good documentation.

How can I dowload a torrent using this library, if I have a .torrent file?

Here are and example using magnet link, but I need one with .torrent file.

Thanks.

ses = lt.session() 

ses.listen_on(6881, 6891) 

info = lt.torrent_info('ubuntu.torrent')

h = ses.add_torrent({'ti': info, 'save_path': './'}

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM