Code

Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#14793 closed (fixed)

staticfiles documentation example overwrites urlpatterns

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

Description

The example of manually adding the static file development view to urlpatterns incorrectly overwrites urlpatterns. It should have "urlpatterns += ..." rather than an "urlpatterns = ..."

Currently it is the first example at:
http://docs.djangoproject.com/en/dev/ref/contrib/staticfiles/#staticfiles-development-view

Attachments (1)

14793.diff (495 bytes) - added by gg 3 years ago.
patch adding the '+'

Download all attachments as: .zip

Change History (4)

comment:1 Changed 3 years ago by gg

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Summary changed from staticfiles documentation overwrites urlpatterns to staticfiles documentation example overwrites urlpatterns

Changed 3 years ago by gg

patch adding the '+'

comment:2 Changed 3 years ago by Honza_Kral

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

(In [14729]) Fixed #14793 -- staticfiles documentation example overwrites urlpatterns. Thanks gg!

comment:3 Changed 3 years ago by jacob

  • milestone 1.3 deleted

Milestone 1.3 deleted

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.