how do "do not download" certain file #192
What is the problem or limitation you are having?hi, sorry for my bad English, Describe the solution you'd likeDescribe alternatives you've consideredAdditional contextNo response |
Answered by
rmartin16
May 1, 2023
Replies: 1 comment 1 reply
|
Yes; you can use For example: torrent = client.torrents_info(torrent_hashes="<torrent hash>")[0]
# show torrent files
print(torrent.files)
# get all file IDs for epub files
epub_file_ids = [file.id for file in torrent.files if file.name.endswith("epub")]
# set epub files to "do not download"
torrent.file_priority(file_ids=epub_file_ids, priority=0) |
1 reply
Answer selected by
rmartin16
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yes; you can use
torrents_file_priority().For example: