Создал приложение news.
#urls.py
from django.urls import path,include
from django.conf.urls import url
from django.views.generic import ListView,DetailView
from news.models import Articles
urlpatterns = [
path(r'/^$',ListView.as_view(queryset=Articles.objects.all().order_by("-date")[:20],template_name="news/posts.html" ) ),
]
#models.py
from django.db import models
class Articles(models.Model):
title=models.CharField(max_length=120)
post=models.TextField()
date=models.DateTimeField()
def __str__(self):
return self.title
В командной строке ввожу python manage.py migrate и выдает ошибку ModuleNotFoundError: No module named 'news '