Disable Jinja2 cache to fix hashing error
This commit is contained in:
parent
6b4a2fa31e
commit
d3c0dfbf5b
@ -21,7 +21,14 @@ from core.orchestrator import Orchestrator
|
||||
router = APIRouter()
|
||||
|
||||
# Templates - use string path for better compatibility
|
||||
templates = Jinja2Templates(directory=str(Path(__file__).parent / "templates"))
|
||||
# Disable cache to avoid hashing issues with Pydantic objects
|
||||
from jinja2 import Environment, FileSystemLoader
|
||||
template_env = Environment(
|
||||
loader=FileSystemLoader(str(Path(__file__).parent / "templates")),
|
||||
autoescape=True,
|
||||
cache_size=0, # Disable cache
|
||||
)
|
||||
templates = Jinja2Templates(env=template_env)
|
||||
|
||||
|
||||
def get_template_settings():
|
||||
|
||||
Loading…
Reference in New Issue
Block a user