updated readme and added ignored data
This commit is contained in:
parent
ad85494c1f
commit
fb55c54f01
@ -37,11 +37,15 @@ Config.json
|
||||
"password": "admin",
|
||||
"loglevel": "INFO",
|
||||
"logpath": "./qc.log",
|
||||
"protected_tag": "ipt",
|
||||
"non_protected_tag": "public",
|
||||
"age": 2419200,
|
||||
"use_pushover": true,
|
||||
"minimum_age": 432000,
|
||||
"use_pushover": false,
|
||||
"use_log": true,
|
||||
"po_key": "",
|
||||
"po_token": ""
|
||||
"po_token": "",
|
||||
"delete_torrents": false
|
||||
}
|
||||
```
|
||||
|
||||
|
@ -49,6 +49,7 @@ class Qbt:
|
||||
self.tracker_list = []
|
||||
self.up_tor_counter = 0
|
||||
self.preme_tor_counter = 0
|
||||
self.ignored_counter = 0
|
||||
self.torrent_hash_delete_list = []
|
||||
if self.use_log:
|
||||
self.tl.debug(self.tracker_whitelist)
|
||||
|
2
qlist.py
2
qlist.py
@ -14,10 +14,12 @@ def buildtorlist(self):
|
||||
continue
|
||||
if torrent['category'] in self.cat_whitelist.values():
|
||||
self.tl.info(f'Ignored torrent:["{torrent["name"][0:20]}..."]')
|
||||
self.ignored_counter += 1
|
||||
continue
|
||||
if torrent['tracker'] == '':
|
||||
if self.use_log:
|
||||
self.tl.warning(f'Torrent doesn\'t have a tracker ["{torrent["name"][0:20]}..."] [{torrent["tracker"]}]hash: {torrent["hash"]}')
|
||||
self.ignored_counter += 1
|
||||
continue
|
||||
if torrent['tracker'].split('/')[2] in self.tracker_whitelist.values():
|
||||
if self.use_log:
|
||||
|
@ -20,10 +20,11 @@ def tornotifysummary(self):
|
||||
"""Main notification method when the app is used in an automated fashion"""
|
||||
self.poc.send_message(f" Total: {self.total_torrents}\n\
|
||||
Premature: {self.preme_tor_counter}\n\
|
||||
Ignored: {self.ignored_counter}\n\
|
||||
Protected: {self.c[self.tracker_protected_tag]}\n\
|
||||
Non-protected: {self.c[self.tracker_non_protected_tag]}\n\
|
||||
Marked for deletion: {len(self.torrent_hash_delete_list)}\n\
|
||||
Orphaned: {self.up_tor_counter}", title="--- qbit-maid summary ---")
|
||||
Orphaned: {self.up_tor_counter}\n\
|
||||
Marked for deletion: {len(self.torrent_hash_delete_list)}", title="--- qbit-maid summary ---")
|
||||
|
||||
def printprocessor(self):
|
||||
"""Print summary of torrents"""
|
||||
@ -32,6 +33,7 @@ def printprocessor(self):
|
||||
self.c[item["tags"]] += 1
|
||||
self.tl.info(f'Total: {self.total_torrents}')
|
||||
self.tl.info(f'Premature: {self.preme_tor_counter}')
|
||||
self.tl.info(f'Ignored: {self.ignored_counter}')
|
||||
self.tl.info(f'Protected: {self.c[self.tracker_protected_tag]}')
|
||||
self.tl.info(f'Non-protected: {self.c[self.tracker_non_protected_tag]}')
|
||||
self.tl.info(f'Orphaned: {self.up_tor_counter}')
|
||||
|
Loading…
x
Reference in New Issue
Block a user