Properly use the downloaded torrent file in the qBittorrent plugin (except on magnet links).#1397
Properly use the downloaded torrent file in the qBittorrent plugin (except on magnet links).#1397cvium merged 4 commits intoFlexget:developfrom dsemi:develop
Conversation
|
I'm gonna test this later today |
| with open(filepath, 'rb') as f: | ||
| multipart_data['torrents'] = f | ||
| self.session.post(self.url + '/command/upload', files=multipart_data) | ||
| log.debug('Added task to qBittorrent') |
There was a problem hiding this comment.
You don't add a task, you add entries. The debug message is pointless as it provides no information.
|
I took the liberty of re-inserting the template you deleted. Please fill it with the proper information. It's there to help us. |
|
Made the changes. |
There was a problem hiding this comment.
You should negate the expression if you want to call it is_magnet.
|
@dsemi I assume you've tested it? |
| log.info('Test mode.') | ||
| log.info('Would add torrent to qBittorrent with:') | ||
| if not is_magnet: | ||
| log.info(' File: %s', entry.get('file')) |
There was a problem hiding this comment.
We don't use empty space prefixes / indentations in log messages.
There was a problem hiding this comment.
Not entirely true. It's used in other places for indentation.
|
Looks pretty good |
|
@cvium Yes @paranoidi Removed the spaces. |
|
For what it's worth, tested in master and seem to work well. |
|
No problem :) |
Motivation for changes:
Make qbittorrent more like the other client plugins.
Detailed changes:
Allow qBittorrent plugin to properly handle input torrent files and magnet links.
Also merge change to set 'label' as 'category' since qBittorrent decided to change the API and the original PR looks abandoned.
Addressed issues: