Replit doesn't inspect Django models properly and underlines in red their attributes and the objects default manager

Problem description

Replit doesn’t inspect Django models properly and underlines ModelName.objects in red. It also underlines in red any attributes of the model.

Expected behavior

Replit should inspect the models properly and not give fake errors. ModelName.objects and model_name_instance.attribute should not be underlined in red.

Actual behavior

Replit underlines ModelName.objects and model_name_instance.attribute in red.

Steps to reproduce

from django.db import models
class Item(models.Model):
    text = models.TextField(default="")

from django.test import TestCase
from lists.models import Item
class ItemModelTest(TestCase):
    def test_red_underlined(self):
        first_item = Item()
        first_item.text = "The first (ever) item"
        items = Item.objects.all()

There’s no need to run the code, Just observe the red underlining of the last two lines in the Replit UI.


LibreWolf (Firefox fork) 124.0.1-1, but also on the desktop app


Debian GNU/Linux 12 (bookworm)

Device if mobile



free tier