maxkb/apps/knowledge/tasks/__init__.py
朱潮 dea3454011 修复Django应用启动时的导入错误
- 在knowledge/apps.py的ready()方法中注册Celery任务
- 移除ops/__init__.py中的直接导入,避免循环依赖
- 简化tasks/__init__.py,使用延迟导入
- 解决"Apps aren't loaded yet"错误

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-31 01:25:16 +08:00

5 lines
176 B
Python

# coding=utf-8
# Import tasks for Celery discovery
# Note: We use lazy imports to avoid Django app loading issues
# Tasks will be imported when needed by Celery's autodiscover