LeeV
0
Q:

pathlib path of current file

import pathlib
pathlib.Path(__file__).parent.absolute()
1
from pathlib import Path

BASE_DIR = Path(__file__).resolve().parent.parent
TEMPLATES_DIR = BASE_DIR.joinpath('templates')
0

New to Communities?

Join the community