Opened 7 weeks ago

Closed 7 weeks ago

#35633 closed Bug (invalid)

i found a bug in the documentation version 4.2 in Writing your first Django app, part 5

Reported by: amirreza Owned by:
Component: Uncategorized Version: 4.2
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

in the section "Create a test to expose the bug" of the tutorial 5 i write the exact code in my test.py file but when i runing the "python manage.py test polls" command in the next section i get this error:
RuntimeError: Model class mehr_paj.polls.models.Question doesn't declare an explicit app_label and isn't in an application in INSTALLED_APPS.

i figure out if chnage this line of test code "from .models import Question" to this "from polls.models import Question" the problem is solved and test code running with out the problem

Change History (1)

comment:1 by Natalia Bidart, 7 weeks ago

Resolution: invalid
Status: newclosed

Hello amirreza, thank you for taking the time to create this report.

I'm afraid that you may have a different local setup than the one described in the tutorial if you are getting the shown error. Because of that, this report seems better suited to be a support request. The best place to get answers to your issue is using any of the user support channels from this link.

Since the goal of this issue tracker is to track issues about Django itself, and your issue seems, at first, to be located in your custom code, I'll be closing this ticket as invalid following the ticket triaging process.

Note: See TracTickets for help on using tickets.
Back to Top