I am working on tutorial Django app.
It is a very basic application, aimed at learning ‘sceleton’ structure of Django project.
The problem – I am not able to do any imports between files in app directory.
No imports between files like forms.py, views.py, models.py seem to work.
In particular, I am not able to call:
‘from models import ModelClass‘
in my forms.py file. I always get an error: ModuleNotFoundError: No module named … (name of file here, e.g. ‘models’).
‘from .models import ModelClass‘ – (with dot before ‘models’) doesn’t work either – same error. Also, I do have the usual ‘init’ file in the same directory.
Any ideas on how to import model class from models.py file into forms.py, both files in same directory?