Python
파이썬 jinja2.exceptions.TemplateNotFound 오류 해결
Jann
2022. 1. 13. 21:54
728x90
파이썬 jinja2.exceptions.TemplateNotFound 오류 해결
TemplateNotFound(template)
rendering-templates 로 html파일을 불러오는 app.py 실행하려고 하니 TemplateNotFound(template) 오류가 나서 해결 방법을 찾아보았다.
rendering-templates 설명 링크 참조
https://flask.palletsprojects.com/en/0.12.x/quickstart/#rendering-templates
Quickstart — Flask Documentation (0.12.x)
For web applications it’s crucial to react to the data a client sends to the server. In Flask this information is provided by the global request object. If you have some experience with Python you might be wondering how that object can be global and how
flask.palletsprojects.com
app.py 파일 상위로 이동하기
폴더 구조에 따라서 templates 폴더 안에 있어도 html 파일을 인식하지 못하는 경우가 생길 수 있는 듯 하여 app.py 파일 위치를 상위로 이동했다.
TemplateNotFound(template) 해결 후 rendering-templates 구동
728x90