Django

Code

Ticket #1791 (closed: fixed)

Opened 2 years ago

Last modified 1 year ago

Application dependencies should be documented

Reported by: anonymous Assigned to: adrian
Milestone: Component: Documentation
Version: SVN Keywords:
Cc: Triage Stage: Accepted
Has patch: 0 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

svn At revision 2864.

MIDDLEWARE_CLASSES = (

"django.middleware.common.CommonMiddleware?", "django.contrib.sessions.middleware.SessionMiddleware?", "django.contrib.auth.middleware.AuthenticationMiddleware?", "django.middleware.doc.XViewMiddleware", 'django.contrib.flatpages.middleware.FlatpageFallbackMiddleware?',

)

INSTALLED_APPS = (

'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions',

# 'django.contrib.sites',

'django.contrib.admin', 'django.contrib.flatpages', 'mydjangoproject.customers',

)

error: ~/mydjangoproject$ python manage.py syncdb Error: None couldn't be installed, because there were errors in your model: flatpages.flatpage: 'sites' has m2m relation with uninstalled model Site

if I uncomment django.contrib.sites everything works

Attachments

Change History

05/07/06 05:25:35 changed by Esaj

  • status changed from new to closed.
  • resolution set to invalid.

That's because flatpages depends on sites.

05/07/06 11:57:31 changed by eugene@lazutkin.com

  • status changed from closed to reopened.
  • resolution deleted.
  • type changed from defect to enhancement.
  • component changed from Core framework to Documentation.
  • summary changed from django.contrib.flatpages does not install if django.contrib.sites is not installed to Application dependencies should be documented.

Application dependencies should be documented.

One more frequently occured dependency chain: django.contrib.admin depends on django.contrib.auth, and django.contrib.contenttypes. Attempts to run an app without them brings following errors (?):

Validating models...
admin.logentry: 'user' has relation with uninstalled model User
admin.logentry: 'content_type' has relation with uninstalled model ContentType
2 errors found.

I don't think this is an error per se, but it should be documented to reduce a confusion. For starters these error messages don't say anything about what additional applications are required.

02/01/07 17:16:42 changed by Michael Radziej <mir@noris.de>

  • stage changed from Unreviewed to Accepted.

06/07/07 12:50:53 changed by jacob

  • status changed from reopened to closed.
  • resolution set to fixed.

(In [5432]) Fixed #1791 - documented dependancies of contrib packages.


Add/Change #1791 (Application dependencies should be documented)




Change Properties
Action