Code

Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#13876 closed (fixed)

Documentation duplicates

Reported by: pakal <chambon.pascal@…> Owned by: zerok
Component: Documentation Version: 1.2
Severity: Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description (last modified by Alex)

In documentation page "the Django admin site" : a section is written twice in a row, the one starting with :
"If the string given is a method of the model, ModelAdmin or a callable, Django will HTML-escape the output by default. If you'd rather not escape the output of the method, give the method an allow_tags attribute whose value is True."

Besides, in request-response doc , two different sections deal with setting/reading request headers, maybe they should be merged :

"""
Here's a full example model:

You can add and delete headers using dictionary syntax:

>>> response = HttpResponse()
>>> response['X-DJANGO'] = "It's the best."
>>> del response['X-PHP']
>>> response['X-DJANGO']
"It's the best."

Note that del doesn't raise KeyError if the header doesn't exist.

[....]

Setting headers

To set a header in your response, just treat it like a dictionary:
"""

Cheers,
Pascal

Attachments (2)

13876.diff (1.5 KB) - added by zerok 4 years ago.
13876.2.diff (1.6 KB) - added by timo 4 years ago.
more concise wording, correct position of versionadded tag

Download all attachments as: .zip

Change History (10)

comment:1 Changed 4 years ago by Alex

  • Description modified (diff)
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

Added formatting.

comment:2 Changed 4 years ago by zerok

  • Has patch set
  • Triage Stage changed from Unreviewed to Accepted

While the first issue I can't reproduce (the paragraphs started with the same phrases but then went in totally different directions), +1 on the second issue. I attached a patch for that based on 1.2.X

Changed 4 years ago by zerok

comment:3 Changed 4 years ago by zerok

  • Owner changed from nobody to zerok

comment:4 Changed 4 years ago by pakal <chambon.pascal@…>

Indeed I can't find issue 1 again, either it's been fixed since then or I just got confused.

comment:5 Changed 4 years ago by thejaswi_puthraya

  • Component changed from Uncategorized to Documentation

Changed 4 years ago by timo

more concise wording, correct position of versionadded tag

comment:6 Changed 4 years ago by timo

  • Triage Stage changed from Accepted to Ready for checkin

comment:7 Changed 4 years ago by jezdez

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

(In [13966]) Fixed #13876 -- Fixed duplication in docs. Thanks, zerok and timo.

comment:8 Changed 4 years ago by jezdez

(In [13972]) [1.2.X] Fixed #13876 -- Fixed duplication in docs. Thanks, zerok and timo.

Backport from trunk (r13966).

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.