mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-12-09 08:15:27 +01:00
classifier cache timeout
This commit is contained in:
parent
ffe96c8fff
commit
7702f5012b
1 changed files with 2 additions and 1 deletions
|
|
@ -39,7 +39,8 @@ def load_classifier():
|
|||
classifier = DocumentClassifier()
|
||||
try:
|
||||
classifier.load()
|
||||
cache.set("paperless-classifier", classifier, version=version)
|
||||
cache.set("paperless-classifier", classifier,
|
||||
version=version, timeout=86400)
|
||||
except (EOFError, IncompatibleClassifierVersionError) as e:
|
||||
# there's something wrong with the model file.
|
||||
logger.error(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue