diff options
author | François Schmidts <francois.schmidts@gmail.com> | 2015-04-06 10:19:58 +0200 |
---|---|---|
committer | François Schmidts <francois.schmidts@gmail.com> | 2015-04-06 10:19:58 +0200 |
commit | f2463bc333cc207ffa9ab935b7edf59a9894720d (patch) | |
tree | ba7e4a0cfce8a910e5cd53f06d118390f9d12981 /pyaggr3g470r/controllers/feed.py | |
parent | implementing cache construction on crawler side (limiting useless pushes) (diff) | |
download | newspipe-f2463bc333cc207ffa9ab935b7edf59a9894720d.tar.gz newspipe-f2463bc333cc207ffa9ab935b7edf59a9894720d.tar.bz2 newspipe-f2463bc333cc207ffa9ab935b7edf59a9894720d.zip |
misc update
updating the way we maintain feed up to date in the database
fixing the counter
bumping the minimum error count
Diffstat (limited to 'pyaggr3g470r/controllers/feed.py')
-rw-r--r-- | pyaggr3g470r/controllers/feed.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/pyaggr3g470r/controllers/feed.py b/pyaggr3g470r/controllers/feed.py index ff496efc..b99a3a7f 100644 --- a/pyaggr3g470r/controllers/feed.py +++ b/pyaggr3g470r/controllers/feed.py @@ -5,14 +5,15 @@ from .abstract import AbstractController from pyaggr3g470r.models import Feed logger = logging.getLogger(__name__) -DEFAULT_MAX_ERROR = 3 +DEFAULT_MAX_ERROR = 6 DEFAULT_LIMIT = 5 class FeedController(AbstractController): _db_cls = Feed - def list_late(self, max_last, max_error=DEFAULT_MAX_ERROR, limit=DEFAULT_LIMIT): + def list_late(self, max_last, max_error=DEFAULT_MAX_ERROR, + limit=DEFAULT_LIMIT): return [feed for feed in self.read( error_count__lt=max_error, enabled=True, last_retrieved__lt=max_last) |