#20309 closed Uncategorized (fixed)

File admin.py needs to be created first

Reported by: Katya <internum.odium@…> Owned by: nobody
Component: Documentation Version: 1.5
Severity: Normal Keywords:
Cc: bmispelon@… Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

https://docs.djangoproject.com/en/1.5/intro/tutorial02/#make-the-poll-app-modifiable-in-the-admin

Just one thing to do: we need to tell the admin that Poll objects have an admin interface. To do this, open the polls/admin.py file, and edit it to look like this:

At that point the file admin.py doesn't exist yet. I'd suggest adding a note saying that the file needs to be created first.

Change History (6)

comment:1 Changed 23 months ago by bmispelon

  • Cc bmispelon@… added
  • Easy pickings set
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted
  • Version changed from 1.4 to 1.5

I believe you are correct.

Note however that this only applies to 1.5 since admin.py is created automatically with the new app template (this was added in commit 3f1c7b70537330435e2ec2fca9550f7b7fa4372e).

Thanks for your report.

comment:2 Changed 23 months ago by aaugustin

  • Resolution set to invalid
  • Status changed from new to closed

You're following the tutorial for the development version (future 1.6) while using Django 1.5.

Please follow the tutorial for the version of Django you're using.

comment:3 Changed 23 months ago by aaugustin

  • Resolution invalid deleted
  • Status changed from closed to new

Oops, I didn't notice that the link pointed to the 1.5 docs. Sorry. Thank you bmispelon.

comment:4 Changed 23 months ago by bmispelon

For reference, this issue was introduced by commit 6e3b80239e9a066ac2e9d10212196acbc2e6d35c.

comment:5 Changed 22 months ago by aaugustin

#20345 and #20334 were duplicates.

comment:6 Changed 22 months ago by Claude Paroz <claude@…>

  • Resolution set to fixed
  • Status changed from new to closed

In 4f10b35a2e4012512ae57cadd19f34ec8d4979a1:

[1.5.x] Fixed #20309 -- admin.py is not automatically created in Django 1.5

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