We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Inaccurate exists_series reject message
The original issue was solved on forums: https://discuss.flexget.com/t/quality-upgrade-doesnt-working/3642 but I've been asked to add an issue here because of the _inaccurate error message_.
### Expected behaviour:
Download better quality
<!---
Please don't just say "it doesn't crash" or "it works". Explain what the expected result is.
--->

### Actual behaviour:
Rejecting by exists_series plugin because proper already exists (but there's no proper release)
 
#### Config:
```
  tv:
    series:
      settings:
        tvhd:
          quality: 720p+ !h265 !10bit
          propers: 15 hours
          upgrade: no
          specials: no
          special_ids: e00
          set:
            path: /TV/{{series_name}}/Season {{series_season}}
            include_subs: yes
      tvhd:    
        - Killjoys:
            upgrade: yes
    exists_series: 
      - /TV/{{series_name}}
```
  
#### Log:
```
2017-08-01 11:03 VERBOSE  task          RARBG           ACCEPTED: `Killjoys.S03E05.Attack.the.Rack.1080p.WEBRip.DDP5.1.x264-GRP` by series plugin because is an upgrade to existing quality
2017-08-01 11:03 VERBOSE  task          RARBG           REJECTED: `Killjoys.S03E05.Attack.the.Rack.1080p.WEBRip.DDP5.1.x264-GRP` by exists_series plugin because proper already exists

```

### Additional information:

- FlexGet version: 2.10.74
- Python version: 2.7.9
- Installation method: pip
- Using daemon (yes/no): yes
- OS and version: Ubuntu 15.04


<!---
In config and debug/crash logs, remember to redact any personal or sensitive information such as passwords, API keys, private URLs and so on.

Please verify that the following data is present before submitting your issue:

- Link to a paste service or paste above the relevant config (preferably full config, including templates if present). Please make sure the paste does not expire, if possible.
- Link to a paste service or paste above debug-level logs of the relevant task/s (use `flexget -L debug execute --tasks <Task_name>`).
- FlexGet version (use `flexget -V` to get it).
- Full Python version, for example `2.7.11` (use `python -V` to get it). Note that FlexGet is not supported for use with Python v3.0, 3.1, 3.2 or 3.6.
- Installation method (pip, git install, etc).
- Whether or not you're running FlexGet as a daemon.
- OS and version.
- Attach crash log if one was generated, in addition to the debug-level log. It can be found in the directory with your config file.
--->

Inaccurate exists_series reject message
The original issue was solved on forums: https://discuss.flexget.com/t/quality-upgrade-doesnt-working/3642 but I've been asked to add an issue here because of the _inaccurate error message_.
### Expected behaviour:
Download better quality
<!---
Please don't just say "it doesn't crash" or "it works". Explain what the expected result is.
--->

### Actual behaviour:
Rejecting by exists_series plugin because proper already exists (but there's no proper release)
 
#### Config:
```
  tv:
    series:
      settings:
        tvhd:
          quality: 720p+ !h265 !10bit
          propers: 15 hours
          upgrade: no
          specials: no
          special_ids: e00
          set:
            path: /TV/{{series_name}}/Season {{series_season}}
            include_subs: yes
      tvhd:    
        - Killjoys:
            upgrade: yes
    exists_series: 
      - /TV/{{series_name}}
```
  
#### Log:
```
2017-08-01 11:03 VERBOSE  task          RARBG           ACCEPTED: `Killjoys.S03E05.Attack.the.Rack.1080p.WEBRip.DDP5.1.x264-GRP` by series plugin because is an upgrade to existing quality
2017-08-01 11:03 VERBOSE  task          RARBG           REJECTED: `Killjoys.S03E05.Attack.the.Rack.1080p.WEBRip.DDP5.1.x264-GRP` by exists_series plugin because proper already exists

```

### Additional information:

- FlexGet version: 2.10.74
- Python version: 2.7.9
- Installation method: pip
- Using daemon (yes/no): yes
- OS and version: Ubuntu 15.04


<!---
In config and debug/crash logs, remember to redact any personal or sensitive information such as passwords, API keys, private URLs and so on.

Please verify that the following data is present before submitting your issue:

- Link to a paste service or paste above the relevant config (preferably full config, including templates if present). Please make sure the paste does not expire, if possible.
- Link to a paste service or paste above debug-level logs of the relevant task/s (use `flexget -L debug execute --tasks <Task_name>`).
- FlexGet version (use `flexget -V` to get it).
- Full Python version, for example `2.7.11` (use `python -V` to get it). Note that FlexGet is not supported for use with Python v3.0, 3.1, 3.2 or 3.6.
- Installation method (pip, git install, etc).
- Whether or not you're running FlexGet as a daemon.
- OS and version.
- Attach crash log if one was generated, in addition to the debug-level log. It can be found in the directory with your config file.
--->


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `flexget/plugins/filter/exists_series.py`
Content:
```
1 from __future__ import unicode_literals, division, absolute_import
2 from builtins import *  # noqa pylint: disable=unused-import, redefined-builtin
3 from past.builtins import basestring
4 
5 import logging
6 
7 from path import Path
8 
9 from flexget import plugin
10 from flexget.event import event
11 from flexget.config_schema import one_or_more
12 from flexget.utils.log import log_once
13 from flexget.utils.template import RenderError
14 from flexget.plugins.parsers import ParseWarning
15 from flexget.plugin import get_plugin_by_name
16 
17 log = logging.getLogger('exists_series')
18 
19 
20 class FilterExistsSeries(object):
21     """
22     Intelligent series aware exists rejecting.
23 
24     Example::
25 
26       exists_series: /storage/series/
27     """
28 
29     schema = {
30         'anyOf': [
31             one_or_more({'type': 'string', 'format': 'path'}),
32             {
33                 'type': 'object',
34                 'properties': {
35                     'path': one_or_more({'type': 'string', 'format': 'path'}),
36                     'allow_different_qualities': {'enum': ['better', True, False], 'default': False}
37                 },
38                 'required': ['path'],
39                 'additionalProperties': False
40             }
41         ]
42     }
43 
44     def prepare_config(self, config):
45         # if config is not a dict, assign value to 'path' key
46         if not isinstance(config, dict):
47             config = {'path': config}
48         # if only a single path is passed turn it into a 1 element list
49         if isinstance(config['path'], basestring):
50             config['path'] = [config['path']]
51         return config
52 
53     @plugin.priority(-1)
54     def on_task_filter(self, task, config):
55         if not task.accepted:
56             log.debug('Scanning not needed')
57             return
58         config = self.prepare_config(config)
59         accepted_series = {}
60         paths = set()
61         for entry in task.accepted:
62             if 'series_parser' in entry:
63                 if entry['series_parser'].valid:
64                     accepted_series.setdefault(entry['series_parser'].name, []).append(entry)
65                     for folder in config['path']:
66                         try:
67                             paths.add(entry.render(folder))
68                         except RenderError as e:
69                             log.error('Error rendering path `%s`: %s', folder, e)
70                 else:
71                     log.debug('entry %s series_parser invalid', entry['title'])
72         if not accepted_series:
73             log.warning('No accepted entries have series information. exists_series cannot filter them')
74             return
75 
76         # scan through
77         # For speed, only test accepted entries since our priority should be after everything is accepted.
78         for series in accepted_series:
79             # make new parser from parser in entry
80             series_parser = accepted_series[series][0]['series_parser']
81             for folder in paths:
82                 folder = Path(folder).expanduser()
83                 if not folder.isdir():
84                     log.warning('Directory %s does not exist', folder)
85                     continue
86 
87                 for filename in folder.walk(errors='ignore'):
88                     # run parser on filename data
89                     try:
90                         disk_parser = get_plugin_by_name('parsing').instance.parse_series(data=filename.name,
91                                                                                           name=series_parser.name)
92                     except ParseWarning as pw:
93                         disk_parser = pw.parsed
94                         log_once(pw.value, logger=log)
95                     if disk_parser.valid:
96                         log.debug('name %s is same series as %s', filename.name, series)
97                         log.debug('disk_parser.identifier = %s', disk_parser.identifier)
98                         log.debug('disk_parser.quality = %s', disk_parser.quality)
99                         log.debug('disk_parser.proper_count = %s', disk_parser.proper_count)
100 
101                         for entry in accepted_series[series]:
102                             log.debug('series_parser.identifier = %s', entry['series_parser'].identifier)
103                             if disk_parser.identifier != entry['series_parser'].identifier:
104                                 log.trace('wrong identifier')
105                                 continue
106                             log.debug('series_parser.quality = %s', entry['series_parser'].quality)
107                             if config.get('allow_different_qualities') == 'better':
108                                 if entry['series_parser'].quality > disk_parser.quality:
109                                     log.trace('better quality')
110                                     continue
111                             elif config.get('allow_different_qualities'):
112                                 if disk_parser.quality != entry['series_parser'].quality:
113                                     log.trace('wrong quality')
114                                     continue
115                             log.debug('entry parser.proper_count = %s', entry['series_parser'].proper_count)
116                             if disk_parser.proper_count >= entry['series_parser'].proper_count:
117                                 entry.reject('proper already exists')
118                                 continue
119                             else:
120                                 log.trace('new one is better proper, allowing')
121                                 continue
122 
123 
124 @event('plugin.register')
125 def register_plugin():
126     plugin.register(FilterExistsSeries, 'exists_series', interfaces=['task'], api_ver=2)
127
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/flexget/plugins/filter/exists_series.py b/flexget/plugins/filter/exists_series.py
--- a/flexget/plugins/filter/exists_series.py
+++ b/flexget/plugins/filter/exists_series.py
@@ -114,7 +114,7 @@
                                     continue
                             log.debug('entry parser.proper_count = %s', entry['series_parser'].proper_count)
                             if disk_parser.proper_count >= entry['series_parser'].proper_count:
-                                entry.reject('proper already exists')
+                                entry.reject('episode already exists')
                                 continue
                             else:
                                 log.trace('new one is better proper, allowing')

{"golden_diff": "diff --git a/flexget/plugins/filter/exists_series.py b/flexget/plugins/filter/exists_series.py\n--- a/flexget/plugins/filter/exists_series.py\n+++ b/flexget/plugins/filter/exists_series.py\n@@ -114,7 +114,7 @@\n                                     continue\n                             log.debug('entry parser.proper_count = %s', entry['series_parser'].proper_count)\n                             if disk_parser.proper_count >= entry['series_parser'].proper_count:\n-                                entry.reject('proper already exists')\n+                                entry.reject('episode already exists')\n                                 continue\n                             else:\n                                 log.trace('new one is better proper, allowing')\n", "issue": "Inaccurate exists_series reject message\nThe original issue was solved on forums: https://discuss.flexget.com/t/quality-upgrade-doesnt-working/3642 but I've been asked to add an issue here because of the _inaccurate error message_.\r\n### Expected behaviour:\r\nDownload better quality\r\n<!---\r\nPlease don't just say \"it doesn't crash\" or \"it works\". Explain what the expected result is.\r\n--->\r\n\r\n### Actual behaviour:\r\nRejecting by exists_series plugin because proper already exists (but there's no proper release)\r\n \r\n#### Config:\r\n```\r\n  tv:\r\n    series:\r\n      settings:\r\n        tvhd:\r\n          quality: 720p+ !h265 !10bit\r\n          propers: 15 hours\r\n          upgrade: no\r\n          specials: no\r\n          special_ids: e00\r\n          set:\r\n            path: /TV/{{series_name}}/Season {{series_season}}\r\n            include_subs: yes\r\n      tvhd:    \r\n        - Killjoys:\r\n            upgrade: yes\r\n    exists_series: \r\n      - /TV/{{series_name}}\r\n```\r\n  \r\n#### Log:\r\n```\r\n2017-08-01 11:03 VERBOSE  task          RARBG           ACCEPTED: `Killjoys.S03E05.Attack.the.Rack.1080p.WEBRip.DDP5.1.x264-GRP` by series plugin because is an upgrade to existing quality\r\n2017-08-01 11:03 VERBOSE  task          RARBG           REJECTED: `Killjoys.S03E05.Attack.the.Rack.1080p.WEBRip.DDP5.1.x264-GRP` by exists_series plugin because proper already exists\r\n\r\n```\r\n\r\n### Additional information:\r\n\r\n- FlexGet version: 2.10.74\r\n- Python version: 2.7.9\r\n- Installation method: pip\r\n- Using daemon (yes/no): yes\r\n- OS and version: Ubuntu 15.04\r\n\r\n\r\n<!---\r\nIn config and debug/crash logs, remember to redact any personal or sensitive information such as passwords, API keys, private URLs and so on.\r\n\r\nPlease verify that the following data is present before submitting your issue:\r\n\r\n- Link to a paste service or paste above the relevant config (preferably full config, including templates if present). Please make sure the paste does not expire, if possible.\r\n- Link to a paste service or paste above debug-level logs of the relevant task/s (use `flexget -L debug execute --tasks <Task_name>`).\r\n- FlexGet version (use `flexget -V` to get it).\r\n- Full Python version, for example `2.7.11` (use `python -V` to get it). Note that FlexGet is not supported for use with Python v3.0, 3.1, 3.2 or 3.6.\r\n- Installation method (pip, git install, etc).\r\n- Whether or not you're running FlexGet as a daemon.\r\n- OS and version.\r\n- Attach crash log if one was generated, in addition to the debug-level log. It can be found in the directory with your config file.\r\n--->\r\n\nInaccurate exists_series reject message\nThe original issue was solved on forums: https://discuss.flexget.com/t/quality-upgrade-doesnt-working/3642 but I've been asked to add an issue here because of the _inaccurate error message_.\r\n### Expected behaviour:\r\nDownload better quality\r\n<!---\r\nPlease don't just say \"it doesn't crash\" or \"it works\". Explain what the expected result is.\r\n--->\r\n\r\n### Actual behaviour:\r\nRejecting by exists_series plugin because proper already exists (but there's no proper release)\r\n \r\n#### Config:\r\n```\r\n  tv:\r\n    series:\r\n      settings:\r\n        tvhd:\r\n          quality: 720p+ !h265 !10bit\r\n          propers: 15 hours\r\n          upgrade: no\r\n          specials: no\r\n          special_ids: e00\r\n          set:\r\n            path: /TV/{{series_name}}/Season {{series_season}}\r\n            include_subs: yes\r\n      tvhd:    \r\n        - Killjoys:\r\n            upgrade: yes\r\n    exists_series: \r\n      - /TV/{{series_name}}\r\n```\r\n  \r\n#### Log:\r\n```\r\n2017-08-01 11:03 VERBOSE  task          RARBG           ACCEPTED: `Killjoys.S03E05.Attack.the.Rack.1080p.WEBRip.DDP5.1.x264-GRP` by series plugin because is an upgrade to existing quality\r\n2017-08-01 11:03 VERBOSE  task          RARBG           REJECTED: `Killjoys.S03E05.Attack.the.Rack.1080p.WEBRip.DDP5.1.x264-GRP` by exists_series plugin because proper already exists\r\n\r\n```\r\n\r\n### Additional information:\r\n\r\n- FlexGet version: 2.10.74\r\n- Python version: 2.7.9\r\n- Installation method: pip\r\n- Using daemon (yes/no): yes\r\n- OS and version: Ubuntu 15.04\r\n\r\n\r\n<!---\r\nIn config and debug/crash logs, remember to redact any personal or sensitive information such as passwords, API keys, private URLs and so on.\r\n\r\nPlease verify that the following data is present before submitting your issue:\r\n\r\n- Link to a paste service or paste above the relevant config (preferably full config, including templates if present). Please make sure the paste does not expire, if possible.\r\n- Link to a paste service or paste above debug-level logs of the relevant task/s (use `flexget -L debug execute --tasks <Task_name>`).\r\n- FlexGet version (use `flexget -V` to get it).\r\n- Full Python version, for example `2.7.11` (use `python -V` to get it). Note that FlexGet is not supported for use with Python v3.0, 3.1, 3.2 or 3.6.\r\n- Installation method (pip, git install, etc).\r\n- Whether or not you're running FlexGet as a daemon.\r\n- OS and version.\r\n- Attach crash log if one was generated, in addition to the debug-level log. It can be found in the directory with your config file.\r\n--->\r\n\n", "before_files": [{"content": "from __future__ import unicode_literals, division, absolute_import\nfrom builtins import *  # noqa pylint: disable=unused-import, redefined-builtin\nfrom past.builtins import basestring\n\nimport logging\n\nfrom path import Path\n\nfrom flexget import plugin\nfrom flexget.event import event\nfrom flexget.config_schema import one_or_more\nfrom flexget.utils.log import log_once\nfrom flexget.utils.template import RenderError\nfrom flexget.plugins.parsers import ParseWarning\nfrom flexget.plugin import get_plugin_by_name\n\nlog = logging.getLogger('exists_series')\n\n\nclass FilterExistsSeries(object):\n    \"\"\"\n    Intelligent series aware exists rejecting.\n\n    Example::\n\n      exists_series: /storage/series/\n    \"\"\"\n\n    schema = {\n        'anyOf': [\n            one_or_more({'type': 'string', 'format': 'path'}),\n            {\n                'type': 'object',\n                'properties': {\n                    'path': one_or_more({'type': 'string', 'format': 'path'}),\n                    'allow_different_qualities': {'enum': ['better', True, False], 'default': False}\n                },\n                'required': ['path'],\n                'additionalProperties': False\n            }\n        ]\n    }\n\n    def prepare_config(self, config):\n        # if config is not a dict, assign value to 'path' key\n        if not isinstance(config, dict):\n            config = {'path': config}\n        # if only a single path is passed turn it into a 1 element list\n        if isinstance(config['path'], basestring):\n            config['path'] = [config['path']]\n        return config\n\n    @plugin.priority(-1)\n    def on_task_filter(self, task, config):\n        if not task.accepted:\n            log.debug('Scanning not needed')\n            return\n        config = self.prepare_config(config)\n        accepted_series = {}\n        paths = set()\n        for entry in task.accepted:\n            if 'series_parser' in entry:\n                if entry['series_parser'].valid:\n                    accepted_series.setdefault(entry['series_parser'].name, []).append(entry)\n                    for folder in config['path']:\n                        try:\n                            paths.add(entry.render(folder))\n                        except RenderError as e:\n                            log.error('Error rendering path `%s`: %s', folder, e)\n                else:\n                    log.debug('entry %s series_parser invalid', entry['title'])\n        if not accepted_series:\n            log.warning('No accepted entries have series information. exists_series cannot filter them')\n            return\n\n        # scan through\n        # For speed, only test accepted entries since our priority should be after everything is accepted.\n        for series in accepted_series:\n            # make new parser from parser in entry\n            series_parser = accepted_series[series][0]['series_parser']\n            for folder in paths:\n                folder = Path(folder).expanduser()\n                if not folder.isdir():\n                    log.warning('Directory %s does not exist', folder)\n                    continue\n\n                for filename in folder.walk(errors='ignore'):\n                    # run parser on filename data\n                    try:\n                        disk_parser = get_plugin_by_name('parsing').instance.parse_series(data=filename.name,\n                                                                                          name=series_parser.name)\n                    except ParseWarning as pw:\n                        disk_parser = pw.parsed\n                        log_once(pw.value, logger=log)\n                    if disk_parser.valid:\n                        log.debug('name %s is same series as %s', filename.name, series)\n                        log.debug('disk_parser.identifier = %s', disk_parser.identifier)\n                        log.debug('disk_parser.quality = %s', disk_parser.quality)\n                        log.debug('disk_parser.proper_count = %s', disk_parser.proper_count)\n\n                        for entry in accepted_series[series]:\n                            log.debug('series_parser.identifier = %s', entry['series_parser'].identifier)\n                            if disk_parser.identifier != entry['series_parser'].identifier:\n                                log.trace('wrong identifier')\n                                continue\n                            log.debug('series_parser.quality = %s', entry['series_parser'].quality)\n                            if config.get('allow_different_qualities') == 'better':\n                                if entry['series_parser'].quality > disk_parser.quality:\n                                    log.trace('better quality')\n                                    continue\n                            elif config.get('allow_different_qualities'):\n                                if disk_parser.quality != entry['series_parser'].quality:\n                                    log.trace('wrong quality')\n                                    continue\n                            log.debug('entry parser.proper_count = %s', entry['series_parser'].proper_count)\n                            if disk_parser.proper_count >= entry['series_parser'].proper_count:\n                                entry.reject('proper already exists')\n                                continue\n                            else:\n                                log.trace('new one is better proper, allowing')\n                                continue\n\n\n@event('plugin.register')\ndef register_plugin():\n    plugin.register(FilterExistsSeries, 'exists_series', interfaces=['task'], api_ver=2)\n", "path": "flexget/plugins/filter/exists_series.py"}], "after_files": [{"content": "from __future__ import unicode_literals, division, absolute_import\nfrom builtins import *  # noqa pylint: disable=unused-import, redefined-builtin\nfrom past.builtins import basestring\n\nimport logging\n\nfrom path import Path\n\nfrom flexget import plugin\nfrom flexget.event import event\nfrom flexget.config_schema import one_or_more\nfrom flexget.utils.log import log_once\nfrom flexget.utils.template import RenderError\nfrom flexget.plugins.parsers import ParseWarning\nfrom flexget.plugin import get_plugin_by_name\n\nlog = logging.getLogger('exists_series')\n\n\nclass FilterExistsSeries(object):\n    \"\"\"\n    Intelligent series aware exists rejecting.\n\n    Example::\n\n      exists_series: /storage/series/\n    \"\"\"\n\n    schema = {\n        'anyOf': [\n            one_or_more({'type': 'string', 'format': 'path'}),\n            {\n                'type': 'object',\n                'properties': {\n                    'path': one_or_more({'type': 'string', 'format': 'path'}),\n                    'allow_different_qualities': {'enum': ['better', True, False], 'default': False}\n                },\n                'required': ['path'],\n                'additionalProperties': False\n            }\n        ]\n    }\n\n    def prepare_config(self, config):\n        # if config is not a dict, assign value to 'path' key\n        if not isinstance(config, dict):\n            config = {'path': config}\n        # if only a single path is passed turn it into a 1 element list\n        if isinstance(config['path'], basestring):\n            config['path'] = [config['path']]\n        return config\n\n    @plugin.priority(-1)\n    def on_task_filter(self, task, config):\n        if not task.accepted:\n            log.debug('Scanning not needed')\n            return\n        config = self.prepare_config(config)\n        accepted_series = {}\n        paths = set()\n        for entry in task.accepted:\n            if 'series_parser' in entry:\n                if entry['series_parser'].valid:\n                    accepted_series.setdefault(entry['series_parser'].name, []).append(entry)\n                    for folder in config['path']:\n                        try:\n                            paths.add(entry.render(folder))\n                        except RenderError as e:\n                            log.error('Error rendering path `%s`: %s', folder, e)\n                else:\n                    log.debug('entry %s series_parser invalid', entry['title'])\n        if not accepted_series:\n            log.warning('No accepted entries have series information. exists_series cannot filter them')\n            return\n\n        # scan through\n        # For speed, only test accepted entries since our priority should be after everything is accepted.\n        for series in accepted_series:\n            # make new parser from parser in entry\n            series_parser = accepted_series[series][0]['series_parser']\n            for folder in paths:\n                folder = Path(folder).expanduser()\n                if not folder.isdir():\n                    log.warning('Directory %s does not exist', folder)\n                    continue\n\n                for filename in folder.walk(errors='ignore'):\n                    # run parser on filename data\n                    try:\n                        disk_parser = get_plugin_by_name('parsing').instance.parse_series(data=filename.name,\n                                                                                          name=series_parser.name)\n                    except ParseWarning as pw:\n                        disk_parser = pw.parsed\n                        log_once(pw.value, logger=log)\n                    if disk_parser.valid:\n                        log.debug('name %s is same series as %s', filename.name, series)\n                        log.debug('disk_parser.identifier = %s', disk_parser.identifier)\n                        log.debug('disk_parser.quality = %s', disk_parser.quality)\n                        log.debug('disk_parser.proper_count = %s', disk_parser.proper_count)\n\n                        for entry in accepted_series[series]:\n                            log.debug('series_parser.identifier = %s', entry['series_parser'].identifier)\n                            if disk_parser.identifier != entry['series_parser'].identifier:\n                                log.trace('wrong identifier')\n                                continue\n                            log.debug('series_parser.quality = %s', entry['series_parser'].quality)\n                            if config.get('allow_different_qualities') == 'better':\n                                if entry['series_parser'].quality > disk_parser.quality:\n                                    log.trace('better quality')\n                                    continue\n                            elif config.get('allow_different_qualities'):\n                                if disk_parser.quality != entry['series_parser'].quality:\n                                    log.trace('wrong quality')\n                                    continue\n                            log.debug('entry parser.proper_count = %s', entry['series_parser'].proper_count)\n                            if disk_parser.proper_count >= entry['series_parser'].proper_count:\n                                entry.reject('episode already exists')\n                                continue\n                            else:\n                                log.trace('new one is better proper, allowing')\n                                continue\n\n\n@event('plugin.register')\ndef register_plugin():\n    plugin.register(FilterExistsSeries, 'exists_series', interfaces=['task'], api_ver=2)\n", "path": "flexget/plugins/filter/exists_series.py"}]}