diff --git a/README.md b/README.md index 4afe113..5c50cb3 100644 --- a/README.md +++ b/README.md @@ -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 } ``` diff --git a/qbit-maid.py b/qbit-maid.py index 08bcdc2..beb4fc5 100644 --- a/qbit-maid.py +++ b/qbit-maid.py @@ -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) diff --git a/qlist.py b/qlist.py index ba4c7c9..7b3f3f5 100644 --- a/qlist.py +++ b/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: diff --git a/qlogging.py b/qlogging.py index f2a8e1b..72380b9 100644 --- a/qlogging.py +++ b/qlogging.py @@ -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}')