Opened 14 years ago

Closed 14 years ago

#14081 closed (duplicate)

Tutorial 3, when 'decoupling', leaves apparently redundant code

Reported by: nickd Owned by: nobody
Component: Documentation Version: 1.2
Severity: Keywords: Tutorial
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

at the end of tutorial 3: http://docs.djangoproject.com/en/dev/intro/tutorial03/#decoupling-the-urlconfs

It talks about 'decoupling' the poll-app from the base site. After moving the URLconf to the app, it leaves in the code:

urlpatterns = patterns('mysite.polls.views'

This still leaves it coupled to the base site installation (and every app you use would need to be tailored to this). Changing this to use just an app-relative reference i.e.

urlpatterns = patterns('polls.views',

appears to work fine, and achieves the decoupling from the base project. Either this is deliberate, and unexplained, or unintentional.

Change History (1)

comment:1 by Łukasz Rekucki, 14 years ago

Resolution: duplicate
Status: newclosed

Yet another duplicate of #3941.

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