fix: Cannot find declaration to go to CLEAN_DAY_SETTING (#10157)

Co-authored-by: 刘江波 <liujiangbo1@xiaomi.com>
This commit is contained in:
jiangbo721 2024-11-01 17:25:31 +08:00 committed by Yeuoly
parent 007b561e32
commit d1c480a7d8
No known key found for this signature in database
GPG Key ID: A66E7E320FB19F61

View File

@ -14,7 +14,7 @@ from models.dataset import Embedding
@app.celery.task(queue="dataset")
def clean_embedding_cache_task():
click.echo(click.style("Start clean embedding cache.", fg="green"))
clean_days = int(dify_config.CLEAN_DAY_SETTING)
clean_days = int(dify_config.PLAN_SANDBOX_CLEAN_DAY_SETTING)
start_at = time.perf_counter()
thirty_days_ago = datetime.datetime.now() - datetime.timedelta(days=clean_days)
while True: