Commit Graph

1898 Commits

Author SHA1 Message Date
Tom Atkins 3b869b09d0 Fixed #21847 -- Clarified where ContactForm was defined 2014-01-23 13:48:09 -05:00
Andrew Godwin b8c8241945 Add docs about converting from South 2014-01-23 11:45:25 +00:00
Baptiste Mispelon 05d36dc06e Always use parentheses when documenting a method with no arguments. 2014-01-22 22:26:10 +01:00
Baptiste Mispelon 79e1d6ebd7 Don't show `self` in the list of arguments of a method.
This is consistent with Python's official documentation
and it's a sphinx recommendation too[1].

[1] http://sphinx-doc.org/markup/desc.html#dir-method

Refs #21855.
2014-01-22 22:17:32 +01:00
Tim Graham 5f9790072d Fixed #20834 -- Described how caching of user permissions works.
Thanks Giggaflop and Jennifer Casavantes.
2014-01-22 13:08:51 -05:00
Tim Graham 6f06c749b7 Fixed #21726 -- Clarified that password should not be included in REQUIRED_FIELDS.
Thanks russellm for the report.
2014-01-22 10:17:44 -05:00
Russell Keith-Magee d818e0c9b2 Fixed #16905 -- Added extensible checks (nee validation) framework
This is the result of Christopher Medrela's 2013 Summer of Code project.

Thanks also to Preston Holmes, Tim Graham, Anssi Kääriäinen, Florian
Apolloner, and Alex Gaynor for review notes along the way.

Also: Fixes #8579, fixes #3055, fixes #19844.
2014-01-20 10:45:21 +08:00
Andrew Godwin 6bbb820014 Fixed #21290: Documented migration serializing and improved error 2014-01-19 19:27:30 +00:00
Tim Graham 5c7ac7494a Fixed #18907 -- Correct docs regard population of model backrefs.
Thanks simonpercivall for the report and Aymeric for the patch.
2014-01-19 09:35:59 -05:00
Tim Graham b87c59b04b Removed some unnecessary __exact operators in filters. 2014-01-17 18:12:45 -05:00
Tim Graham dd98ccd482 Fixed #16785 -- Documented some of the design decisions of the cache framework.
Thanks jamesp for the draft patch.
2014-01-16 21:13:08 -05:00
Claude Paroz 2a31d00933 Fixed #21740 -- Stopped using mutable default arguments in test client
Thanks Denver Coneybeare for the report and initial patch, and
Atala for another patch.
2014-01-16 17:44:20 +01:00
Tim Graham a6e3fb80b0 Fixed #21343 -- Noted many-to-many restrictions with intermediate model.
Thanks EvilDMP for the report.
2014-01-16 08:38:40 -05:00
Tim Graham d35f2bfd5b Fixed #21727 -- Added some links to help clarify topics/auth/default.txt
Thanks daGrevis for the suggestion.
2014-01-16 07:16:09 -05:00
Tim Graham 9e5033b302 Fixed #21747 -- Added {% elif %} to template topics guide.
Thanks gcc for the suggestion.
2014-01-16 07:07:53 -05:00
Unai Zalakain 9eb16031ca Fixed #12571 -- Attached originating WSGIRequest to test client responses.
Originating WSGIRequests are now attached to the ``wsgi_request`` attribute of
the ``HttpResponse`` returned by the testing client.

Thanks rvdrijst for the suggestion.
2014-01-09 18:50:03 -05:00
Claude Paroz c717ebbfec Fixed #21730 -- Removed superfluous db_index in custom auth docs
Thanks rafalp for the report.
2014-01-04 16:11:21 +01:00
Tim Graham 4d27d311f6 Fixed a sentence in the session security docs; thanks claudep. 2014-01-03 12:02:58 -05:00
Frank Tobia 6dd8631617 Fixed typos. Changed grammar.
Minor typos. Some grammar changes.
2014-01-02 14:22:52 -05:00
Tim Graham 4d8d76e7a8 Fixed #21484 -- Documented that SQL logging does not include "framework level" queries. 2013-12-31 13:02:01 -05:00
Claude Paroz b8e3373f45 Fixed #21714 -- Moved logging configuration to global setup()
Thanks Aymeric Augustin for the report and the review.
2013-12-31 18:35:00 +01:00
Aymeric Augustin 1d23d766ab Renamed AppConfig.setup to ready.
Thanks Jannis and Marc for the feedback.

Fixed #21717.
2013-12-31 18:04:54 +01:00
Tim Graham 69f0249d7b Fixed #19395 -- Added a simple example logging config.
Thanks ken.nelson at maclaren.com.
2013-12-31 10:20:44 -05:00
Tim Graham 9953e98e6a Fixed #21701 -- Improved testing doc titles and added testing/tools.txt.
Thanks cjerdonek for the suggestion.
2013-12-31 08:14:09 -05:00
Tim Graham 270f7e2167 Fixed #21708 -- Added some headings to separate unrelated topics.
Thanks ashley at ashleymills.com for the suggestion.
2013-12-30 17:55:12 -05:00
Aymeric Augustin c31d7c4813 Updated advice on connecting signals at startup. 2013-12-30 22:11:17 +01:00
Aymeric Augustin 99649ddcb2 Assumed Python 3 throughout docs/intro.
Various small fixes while I was proof-reading.
2013-12-30 19:09:45 +01:00
Tim Graham 81a5e35c8d Fixed doc indentation in previous commit. 2013-12-28 11:33:24 -05:00
ijl 71a03e01aa Fixed #20346 -- Made cache middleware vary on the full URL.
Previously, only the URL path was included in the cache key.

Thanks jamey for the suggestion.
2013-12-28 11:20:18 -05:00
Aymeric Augustin c81fae6b95 Used app_label instead of appname.
The last component of the dotted path to the application module is
consistently referenced as the application "label". For instance it's
AppConfig.label. appname could be confused with AppConfig.name, which is
the full dotted path.
2013-12-28 09:53:02 +01:00
Tim Graham 85270ef3f5 Fixed #21650 -- Corrected bad advice for plural translation.
Thanks nedbatchelder and claudep.
2013-12-27 10:02:22 -05:00
Tim Graham 025ec2e7fe Fixed #21582 -- Corrected URL namespace example.
Thanks oubiga for the report.
2013-12-26 20:04:28 -05:00
Tim Graham d8d83777eb Fixed #21629 -- Added instructions for loading MySQL time zone definitions.
Thanks Aymeric for the suggestion.
2013-12-26 15:50:33 -05:00
Aymeric Augustin 5241763c81 Added modify_settings to alter settings containing lists of values. 2013-12-23 21:37:43 +01:00
Tim Graham 23d9f517dc Fixed #21585 -- Updated some links to 3rd party database projects.
Thanks graeme.perrow at sap.com for the original report.
2013-12-18 18:48:21 -05:00
Tianyi Wang b62031441b Fixed #21625 -- incorrect documentation for DiscoverRunner.build_suite 2013-12-18 14:12:04 +01:00
Baptiste Mispelon e904d421d0 Added internal link to i18n documentation. 2013-12-15 01:50:54 +01:00
Alasdair Nicol 1fa681ee11 Fixed #21539 -- Added example of modelformset_factory's form argument 2013-12-14 16:35:14 -05:00
Marti Raudsepp 75ec1fdf16 Clarifed table rewrites in migration docs.
Small nitpicks. All column-related ALTER TABLE commands take an
exclusive table lock in PostgreSQL. The difference is that adding a
column without default doesn't cause a table rewrite, so the lock is
held only for a short time.

The time taken is more accurately proportional to table size, not row
count.
2013-12-14 12:34:45 -05:00
Chris Jerdonek d599b590eb Fixed #21614 -- improved docs on configuring email for development. 2013-12-14 11:20:38 -05:00
johannes-gehrs f685f94c98 Fixed #21580 -- Clarified why render() does not return a TemplateResponse object. 2013-12-13 18:56:18 -05:00
Christian Schmitt 744aac6dac Fixed #21560 -- missing 'slug' field in example code
I updated the documentation, that the modelform now includes the 'slug' field.
2013-12-09 22:54:11 +01:00
Claude Paroz 626bdf648a Updated a bunch of hyperlinks in documentation 2013-12-08 18:40:09 +01:00
Frank Wiles 164df40501 Fixing manager documentation inaccuracy 2013-12-04 18:03:28 -06:00
Ramiro Morales abb04f1f3f Added link to localized formatting doc from main index. 2013-12-04 10:26:03 -03:00
Tim Graham f3e7ab366c Removed gender-based pronouns per [c0a2daad78]. 2013-11-30 08:37:15 -05:00
Claude Paroz 50a8ab7cd1 Enabled makemessages to support several translation directories
Thanks Rémy Hubscher, Ramiro Morales, Unai Zalakain and
Tim Graham for the reviews.
Also fixes #16084.
2013-11-30 11:00:23 +01:00
Tim Graham df6760f12c Added a warning regarding risks in serving user uploaded media.
Thanks Preston Holmes for the draft text.
2013-11-27 16:35:25 -05:00
Andrew Godwin 0c46ca83e8 Merge pull request #1985 from raphaa/21499
Fixed #21499 -- Migrations won't work if field signature changes
2013-11-26 12:33:52 -08:00
Alex Gaynor 4e07d93325 Fixed some unnescesarily gendered language in the docs 2013-11-24 21:05:59 -06:00
Simon Charette eb38257e51 Fixed #21391 -- Allow model signals to lazily reference their senders. 2013-11-24 17:51:22 -05:00
Raphael Jasjukaitis 455e2896b1 Fixed #21499 -- Added a paragraph to the docs. 2013-11-24 15:26:45 +01:00
Curtis Maloney ffc37e2343 Fixed #21012 -- New API to access cache backends.
Thanks Curtis Malony and Florian Apolloner.

Squashed commit of the following:

commit 3380495e93
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Sat Nov 23 14:18:07 2013 +0100

    Looked up the template_fragments cache at runtime.

commit 905a74f52b
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Sat Nov 23 14:19:48 2013 +0100

    Removed all uses of create_cache.

    Refactored the cache tests significantly.

    Made it safe to override the CACHES setting.

commit 35e289fe92
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Sat Nov 23 12:23:57 2013 +0100

    Removed create_cache function.

commit 8e274f747a
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Sat Nov 23 12:04:52 2013 +0100

    Updated docs to describe a simplified cache backend API.

commit ee7eb0f73e
Author: Curtis Maloney <curtis@tinbrain.net>
Date:   Sat Oct 19 09:49:24 2013 +1100

    Fixed #21012 -- Thread-local caches, like databases.
2013-11-23 15:06:59 +01:00
Loic Bistuer 033b26173b Improved docs for ModelFormSet.clean(). 2013-11-22 19:48:54 -05:00
mlissner c456ea4ec8 Noted that localmem is the default cache. 2013-11-22 19:39:25 -05:00
Tim Graham f0fc1690b4 Removed unused import in docs/topics/http/sessions.txt 2013-11-22 15:28:22 -05:00
Aymeric Augustin 9f8810ac51 Fixed #21487 -- Session cannot store tzinfo instances anymore.
Thanks filipp for the report.

Forward-port of 1eddca0a from stable/1.6.x.
2013-11-22 15:34:37 +01:00
Loic Bistuer 27f04e79b1 Fixed #21479 -- Favor 'migrate' over 'syncdb' in the docs. 2013-11-21 15:12:39 +01:00
Baptiste Mispelon ebfa508fa3 Added more examples to the get_object_or_404 documentation. 2013-11-19 19:23:44 +01:00
Unai Zalakain 4fdd51b732 Fixed #15179 -- middlewares not applied for test client login()
Requests made with django.test.Client.login() and logout() respect
defaults defined in django.test.Client instantiation and are processed
through middleware.

Thanks to Loic for the reviews.
2013-11-19 09:04:20 +02:00
Tim Graham 9348fc5628 Fixed typo in topics/http/sessions.txt. 2013-11-18 19:10:58 -05:00
Tim Graham d011714002 Fixed #21440 -- Typo #2 in topics/http/shortcuts.txt
Thanks alasdair.
2013-11-15 10:21:58 -05:00
Tim Graham 3ccc0253f2 Fixed #21425 -- Made order in which loggers are introduced consistent.
Thanks oubiga for the suggestion.
2013-11-15 08:39:40 -05:00
Tim Graham 6e9e6ca071 Fixed #21440 -- Typo in topics/http/shortcuts.txt
Thanks olof.bjarnason at gmail.com for the report.
2013-11-15 07:09:46 -05:00
Bernardo Pires 8bc350b385 Fixed #21372 -- Corrected docs regarding translating LANGUAGES.
Corrected LANGUAGES documentation on how to translate language
names. Now using django.utils.translation.ugettext_lazy instead
of a dummy gettext() function.

Thanks to Salvatore for the report.
2013-11-09 23:56:53 +01:00
Cody Scott a8e84521c4 Noted that .clear() will delete intermediary models 2013-11-08 19:24:31 -05:00
Tom Scholl cab72a439b Fixed docs for EmailMessage extra_headers attribute
The EmailMessage documentation describes the initialization parameters
and states they 'can be set at any time prior to calling the send()
method.'. However, the 'headers' parameter's corresponding attribute is
called 'extra_headers'.
2013-11-08 18:38:45 -05:00
Claude Paroz b780d03d62 Removed obsolete locale restriction admonition
Refs #14461. Thanks Ramiro Morales for pointing this.
2013-11-08 16:47:19 +01:00
Bouke Haarsma 7a7c789d5a Fixed #5849 -- Strip whitespace from blocktrans
Add the trimmed option to the blocktrans tag to trim any newlines and
whitespace from its content.

This allows the developer to indent the blocktrans tag without adding
new lines and whitespace to the msgid in the PO file.

Thanks to mpessas for the initial patch and Dmitri Fedortchenko for the
report.
2013-11-08 00:52:17 +02:00
Anssi Kääriäinen 30203a0dea Merge pull request #1850 from unaizalakain/ticket_13725
Fixed #13725 -- take url scheme into account in assertRedirects

Thanks to Loic for review.
2013-11-07 14:30:04 -08:00
Unai Zalakain 9c5f6cd565 Fixed #13725 -- take url scheme into account in assertRedirects
Scheme is handled correctly when making comparisons between two URLs. If
there isn't any scheme specified in the location where we are redirected to,
the original request's scheme is used. If present, the scheme in
``expected_url`` is the one used to make the comparations to.
2013-11-07 19:06:32 +01:00
Sylvain Bellemare 3935b0f263 Removed no longer relevant word 2013-11-07 09:31:44 -05:00
Jaap Roes 7be638390e Fixed #20536 -- rewrite of the file based cache backend
* Safer for use in multiprocess environments
 * Better random culling
 * Cache files use less disk space
 * Safer delete behavior

Also fixed #15806, fixed #15825.
2013-11-07 16:12:15 +02:00
Claude Paroz 88b9d4ff3a Fixed #21373 -- Typo fixed in i18n docs
Thanks rpq at winscores.com for the report.
2013-11-02 19:13:29 +01:00
Unai Zalakain 99b681e227 Fixed #21341 -- Eased https requests with the test client
All request methods of ``django.test.client.Client`` receive a ``secure``
argument that defaults to ``False`` indicating whether or not to make the
request through https.
Thanks Aymeric Augustin for the review.
2013-11-02 19:03:13 +01:00
Tim Graham 090315f5df Fixed spelling ("dependant" -> "dependent")
Dependent means reliant on.
A dependant is a person like a child or spouse.

Thanks Andrew Wilcox for the report.
2013-11-01 21:29:39 -04:00
Sylvain Bellemare c7dabe49dd Fixed typo -- "a" user, not "an" user 2013-11-01 15:15:36 +01:00
Tim Graham 51e6575472 Fixed #21294 -- Clarified the logout next_page argument.
Thanks wim at go2people.nl for the report.
2013-10-30 09:25:21 -04:00
Antoine Catton e9a356a695 Documented the limitation on sep argument to Signer
Co-Authored-By: Gavin Wahl <gwahl@fusionbox.com>
2013-10-30 08:26:33 -04:00
Tim Graham cc2049cdd7 Fixed #21325 -- Added missing argument to permission_required decorator. 2013-10-25 17:36:07 -04:00
Tim Graham 43cfc652d2 Fixed doc typo in previous commit. 2013-10-24 21:25:51 -04:00
SusanTan 4e0a2fe59c Fixed #21271 -- Added timeout parameter to SMTP EmailBackend.
Thanks Tobias McNulty and Tim Graham for discussions and code review.
Thanks Andre Cruz the suggestion and initial patch.
2013-10-24 20:38:00 -04:00
Curtis Maloney 8688f03eef Fixed #20945 -- Allowed cache tag to use a specific cache. 2013-10-23 19:27:08 -04:00
Tim Graham 9704c49d59 Fixed #21304 -- Typo in docs/topics/testing/advanced.txt
Thanks joao at silvaneves.org for the report.
2013-10-22 12:05:26 -04:00
Florian Hahn 5240b83462 Fixed #17027 -- Added support for the power operator in F expressions.
Thanks dan at dlo.me for the initial patch.

- Added __pow__ and __rpow__ to ExpressionNode
- Added oracle and mysql specific power expressions
- Added used-defined power function for sqlite
2013-10-22 10:29:57 -04:00
Bouke Haarsma 0d0f4f020a Fixed #5789 -- Changed LocaleMiddleware session variable to '_language'.
The old 'django_language' variable will still be read from in order
to migrate users. The backwards-compatability shim will be removed in
Django 1.8.

Thanks to jdunck for the report and stugots for the initial patch.
2013-10-22 09:24:42 -04:00
Tim Graham 28b70425af Added docs for the hasher's iteration count changes. 2013-10-21 20:32:02 +02:00
Tim Graham a3372f67cb Added a warning regarding session security and subdomains. 2013-10-18 09:42:45 -04:00
Tianyi Wang 944a2bb7c1 Improvement on InlineFormSet doc, refs #21006 2013-10-15 14:51:45 +01:00
Tianyi Wang 9bfe66164e Fixed #21006 -- Added example code for overriding methods on an InlineFormSet.
Thanks treysta at gmail.com for the suggestion.
2013-10-15 07:34:29 -04:00
Marc Tamlyn ce823d3710 Merge pull request #1382 from loic/ticket19617
Fixed #19617 -- Refactored form metaclasses to support more inheritance scenarios.
2013-10-15 04:22:34 -07:00
Sorcha Bowler 018e2c055a Fixed #21223 -- Added form.id_for_label to topic guide.
Thanks ebertti at yahoo.com.br for the suggestion.
2013-10-14 18:41:22 -04:00
Loic Bistuer b16dd1fe01 Fixed #8620 -- Updated the Form metaclass to support excluding fields by shadowing them. 2013-10-14 22:42:33 +07:00
Loic Bistuer ac5ec7b8bc Fixed #19617 -- Refactored Form metaclasses to support more inheritance scenarios.
Thanks apollo13, funkybob and mjtamlyn for the reviews.
2013-10-14 21:59:30 +07:00
Loic Bistuer 54cd930baf Clarfied the ModelForm docs with respect to generated vs. declared fields.
The ModelForm docs suggested that fields defined declaratively override
default fields generated from the form Meta.

This is conceptually wrong, especially with inheritance in mind. Meta is
usually defined on the topmost ModelForm subclass, while fields can come
from anywhere in the MRO, especially base classes; therefore we suggested
that something defined in a base class override something from a subclass.

This patch rephrases the docs around the idea that Meta is used to generate
*missing* fields.

Refs #8620, #19617.

Thanks @mjtamlyn and @timgraham for the review.
2013-10-14 10:54:22 -04:00
Bouke Haarsma 8fc63087f6 Fixed #21264 -- Incorrect RST usage in docs 2013-10-14 08:14:27 -04:00
Claude Paroz 1e8eadc94e Fixed #15888 -- Made tablename argument of createcachetable optional
Thanks Aymeric Augustin for the report and the documentation and
Tim Graham for the review.
2013-10-14 13:24:40 +02:00
Aymeric Augustin 570d9c2678 Fixed #19560 -- Identified field in warning for naive datetime.
Thanks gcc for the report and vajrasky for the patch.
2013-10-13 11:54:11 +02:00
Tim Graham dd839a2dfd Fixed #15582 -- Documented how TransactionTestCase.multi_db affects fixtures.
Thanks slinkp for the suggestion.
2013-10-11 20:11:49 -04:00
Cody Scott 8bfc7cc64c Minor edits to docs/topics/db/queries.txt. 2013-10-11 15:34:11 -04:00
Tai Lee e527c0b6d8 Fixed #13252 -- Added ability to serialize with natural primary keys.
Added ``--natural-foreign`` and ``--natural-primary`` options and
deprecated the ``--natural`` option to the ``dumpdata`` management
command.

Added ``use_natural_foreign_keys`` and ``use_natural_primary_keys``
arguments and deprecated the ``use_natural_keys`` argument to
``django.core.serializers.Serializer.serialize()``.

Thanks SmileyChris for the suggestion.
2013-10-11 12:52:57 -04:00
Cody Scott 695bc0d191 Small improvements to docs/topics/db/models.txt 2013-10-10 20:56:11 -04:00
Tim Graham 1dae4ac177 Whitespace cleanup.
* Removed trailing whitespace.
* Added newline to EOF if missing.
* Removed blank lines at EOF.
* Removed some stray tabs.
2013-10-10 16:49:20 -04:00
Claude Paroz 1b9c72fc4f Fixed grammar/typos in auth customization docs 2013-10-09 16:21:19 +02:00
Dan Loewenherz 43f213e475 Fix grammatical errors in email documentation 2013-10-08 09:21:45 -05:00
Russell Keith-Magee ddb53856b6 Fixed #21164 -- Added documentation for issue with test users.
The package renaming restores the older package names (which were also the
documented package names). This doesn't affect test discovery because the
module in question doesn't contain any tests.

Thanks to Carl for the design discussion.
2013-10-08 10:32:56 +08:00
Ramiro Morales 67f5dffbec Re-added link to SQLite notes from DB section of install doc. 2013-10-07 07:40:41 -03:00
Tim Graham 75bb6ba966 Fixed #10913 -- Documented how related_name affects QuerySet filtering
Thanks neithere for the suggestion.
2013-10-02 12:12:53 -04:00
Baptiste Mispelon e1b7723817 Changed the doc to use gender-neutral pronouns when possible. 2013-10-02 16:41:04 +02:00
Tim Graham 00a0d3de02 Clarified session replay attack differences with cookie backend. 2013-10-02 10:15:18 -04:00
Aymeric Augustin 728548e483 Fixed #21134 -- Prevented queries in broken transactions.
Squashed commit of the following:

commit 63ddb271a44df389b2c302e421fc17b7f0529755
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Sun Sep 29 22:51:00 2013 +0200

    Clarified interactions between atomic and exceptions.

commit 2899ec299228217c876ba3aa4024e523a41c8504
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Sun Sep 22 22:45:32 2013 +0200

    Fixed TransactionManagementError in tests.

    Previous commit introduced an additional check to prevent running
    queries in transactions that will be rolled back, which triggered a few
    failures in the tests. In practice using transaction.atomic instead of
    the low-level savepoint APIs was enough to fix the problems.

commit 4a639b059ea80aeb78f7f160a7d4b9f609b9c238
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Sep 24 22:24:17 2013 +0200

    Allowed nesting constraint_checks_disabled inside atomic.

    Since MySQL handles transactions loosely, this isn't a problem.

commit 2a4ab1cb6e83391ff7e25d08479e230ca564bfef
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Sat Sep 21 18:43:12 2013 +0200

    Prevented running queries in transactions that will be rolled back.

    This avoids a counter-intuitive behavior in an edge case on databases
    with non-atomic transaction semantics.

    It prevents using savepoint_rollback() inside an atomic block without
    calling set_rollback(False) first, which is backwards-incompatible in
    tests.

    Refs #21134.

commit 8e3db393853c7ac64a445b66e57f3620a3fde7b0
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Sun Sep 22 22:14:17 2013 +0200

    Replaced manual savepoints by atomic blocks.

    This ensures the rollback flag is handled consistently in internal APIs.
2013-09-30 09:42:27 +02:00
Michael Manfre 99c87f1410 Fixed #17671 - Cursors are now context managers. 2013-09-25 21:47:26 +03:00
Loic Bistuer 04a2a6b0f9 Fixed #3871 -- Custom managers when traversing reverse relations. 2013-09-25 21:15:59 +03:00
Tim Graham 77f6b468e5 Fixed #21137 -- Corrected ULRconf include example.
Thanks marfire for the report.
2013-09-24 09:41:12 -04:00
Tim Graham 45969bdeb5 Removed implication that six is part of Python stdlib. 2013-09-23 18:30:05 -04:00
Daley Chetwynd a53caf28bf Fixed #20830 -- Clarified that Django uses a customized version of six.
Thanks glarrain for the suggestion.
2013-09-23 11:03:50 -04:00
Åke Forslund 6a30075eaa Fixed #21140 -- Added 'Using cached sessions' to the performance guide.
Thanks EvilDMP for the suggestion.
2013-09-23 10:50:19 -04:00
Ramiro Morales ce0c5c38ea A few doc additions for changes from d228c1192e. 2013-09-22 13:46:16 -03:00
Ramiro Morales 9dc45efeba Reference Meta.index_together in DB performance guide. 2013-09-22 11:11:02 -03:00
Michael DiBernardo 222460a994 Fixed #21137 -- Documented best practice for URLconfs with repeated pattern prefixes. 2013-09-21 18:17:21 -04:00
Aymeric Augustin 11187386f4 Addressed inaccuracies in performance docs
* Move the discussion of CachedStaticFilesStorage to the section about
  HTTP. It's really about client-side caching. It doesn't fit with the
  caching utilities from django.utils.functional.

* Tone down the warning against Pypy as per Alex' feedback. It's a valid
  choice for advanced users who are comfortable using a non-standard
  stack.

* Generally reworded the 'Using different versions of available software'
  section.

* Some other minor adjustments to the document.
2013-09-21 16:41:26 +01:00
evildmp dc8f95b639 Fixed #20877 -- added a performance optimization guide 2013-09-20 23:21:49 +01:00
Aymeric Augustin 4db2752e28 Clarified why one must not catch database errors inside atomic. 2013-09-20 21:56:35 +02:00
Markus Amalthea Magnuson 2c5c422d34 Added missing "in" in sentence. 2013-09-19 13:26:01 -04:00
yokomizor df27803a55 Fixed #9532 -- Added min_num and validate_min on formsets.
Thanks gsf for the suggestion.
2013-09-19 13:11:49 -04:00
Tim Graham d1c9802811 Fixed #21116 -- Made usage of manage.py in docs more consistent.
Thanks daniel.quattro at gmail.com for the report.
2013-09-18 10:35:41 -04:00
Berker Peksag 2f0566fa61 Fixed #4278 -- Added a dirs parameter to a few functions to override TEMPLATE_DIRS.
* django.template.loader.get_template()
* django.template.loader.select_template()
* django.shortcuts.render()
* django.shortcuts.render_to_response()

Thanks amcnabb for the suggestion.
2013-09-18 07:37:08 -04:00
Ramiro Morales 9d12f68a53 Reworded a paragraph in the logging docs. 2013-09-16 17:49:46 -03:00
Tim Graham 18ffdb1772 Fixed #17627 -- Renamed util.py files to utils.py
Thanks PaulM for the suggestion and Luke Granger-Brown and
Wiktor Kołodziej for the initial patch.
2013-09-16 12:52:05 -04:00
Tim Graham da843e7dba Fixed #20887 -- Added a warning to GzipMiddleware in light of BREACH.
Thanks EvilDMP for the report and Russell Keith-Magee
for the draft text.
2013-09-11 08:17:15 -04:00
Kevin Christopher Henry 5eca021d48 Documentation -- Improved description of cache arguments
- Fixed some grammar and formatting mistakes
- Added the type and default for CULL_FREQUENCY
- Made the note on culling the entire cache more precise. (It's actually
  slower on the filesystem backend.)
2013-09-11 07:42:49 -04:00
Juan Catalano 4840fd9cbc Fixed #20919 -- Extended assertRedirects to be able to avoid fetching redirect's response.
Thanks mjtamlyn for the suggestion.
2013-09-10 12:22:55 -04:00
Tim Graham 4ba373840a Fixed #16534 -- Improved ability to customize DiscoverRunner
Added DiscoverRunner.test_suite and .test_runner attributes.

Thanks tomchristie for the suggestion and jcd for the patch.
2013-09-10 09:49:39 -04:00
Kevin Christopher Henry 9d700322b3 Fixed #19885 -- cleaned up the django.test namespace
* override_settings may now be imported from django.test
* removed Approximate from django.test
* updated documentation for things importable from django.test

Thanks akaariai for the suggestion.
2013-09-09 16:03:13 -04:00
e0ne cbf08c6b0c Fixed #16895 -- Warned about cost of QuerySet ordering
Thanks outofculture at gmail.com for the suggestion.
2013-09-09 09:47:18 -04:00
Tim Graham e4b012feeb Fixed #21068 -- Added some docs for DiscoverRunner
Thanks jcd.
2013-09-07 16:10:07 -04:00
Tim Graham 0c295a7718 Fixed a link in topics/testing/overview.txt 2013-09-06 17:41:12 -04:00
Tim Graham db3de52807 Fixed #20646 -- Clarified the use of AbstractBaseUser.REQUIRED_FIELDS
Thanks craigbruce.
2013-09-06 16:01:29 -04:00
evildmp 79cc66692a Consolidated documentation for F() and Q() 2013-09-06 12:57:25 -05:00
Eric Boersma 4d13cc56de Fixed #21035 -- Changed docs to treat the acronym SQL phonetically.
The documentation and comments now all use 'an' to
refer to the word SQL and not 'a'.
2013-09-05 20:14:58 -04:00
Aymeric Augustin 6a6428a36f Took advantage of django.utils.six.moves.urllib.*. 2013-09-05 14:39:23 -05:00
CHI Cheng ed9cd4fd8b Fixed #21000 -- Made cached_db session backend respect SESSION_CACHE_ALIAS 2013-09-05 10:47:58 -04:00
Loic Bistuer b7af44d474 Removed "makemigrations --force" from docs since it doesn't actually exist. 2013-09-05 02:33:05 +07:00
Tim Graham 3baf1d1042 Fixed #21002 -- Documented JSON session serialization requires string keys
Thanks jeroen.pulles at redslider.net for the report.
2013-09-03 07:48:03 -04:00
Aymeric Augustin 365c3e8b73 Replaced "not PY3" by "PY2", new in six 1.4.0. 2013-09-02 12:11:02 +02:00
Ramiro Morales e909ceae9b Made django.test.testcases not depend on staticfiles contrib app.
Do this by introducing a django.contrib.staticfiles.testing.StaticLiveServerCase
unittest TestCase subclass.

Fixes #20739.
2013-08-31 11:02:32 -03:00
Loic Bistuer 9885f07757 Made the doc about translating string literals in templates more prominent. 2013-08-31 07:59:53 -04:00
Tim Graham be48c6c199 Fixed #20997 -- Added SessionStore note to docs.
Thanks jsdalton.
2013-08-29 14:15:58 -04:00
Phaneendra Chiruvella 2fbf949760 Minor spelling correction in ModelForms docs 2013-08-28 16:05:46 +05:30
Krzysztof Jurewicz 095643e691 Fixed #20981 -- Noted the default value of disable_existing_loggers. 2013-08-27 10:25:26 -04:00
Tim Graham c9a69cdb93 Fixed #20976 -- Fixed labels in migration docs.
Thanks chrismedrela for the report.
2013-08-27 08:05:13 -04:00
Jan Böcker 5fd2c979cb Fixed typo in docs/topics/conditional-view-processing.txt 2013-08-26 11:19:40 +02:00
Andrew Godwin 5569b0b92f Merge remote-tracking branch 'core/master' into schema-alteration
Conflicts:
	django/db/backends/oracle/base.py
	django/db/backends/postgresql_psycopg2/base.py
	django/db/models/signals.py
	tests/queries/tests.py
2013-08-23 12:36:53 +01:00
Ramiro Morales 57c82f909b Typos introduced in 297f5af222. 2013-08-22 21:25:35 -03:00
Tim Graham b0ce6fe656 Fixed #20922 -- Allowed customizing the serializer used by contrib.sessions
Added settings.SESSION_SERIALIZER which is the import path of a serializer
to use for sessions.

Thanks apollo13, carljm, shaib, akaariai, charettes, and dstufft for reviews.
2013-08-22 13:58:26 -04:00
Kevin Christopher Henry 2e926b041c Documentation -- Clarified use of 'view' in test client introduction. 2013-08-22 09:37:03 -04:00
Ramiro Morales 297f5af222 Made description of LANGUAGE_CODE setting more clear. 2013-08-22 08:27:04 -03:00
Ramiro Morales 01223840f3 Fixed #18967 -- Don't base64-encode message/rfc822 attachments.
Thanks Michael Farrell for the report and his work on the fix.
2013-08-21 22:32:04 +01:00
Ramiro Morales f9d1d5dc13 Fixed #18967 -- Don't base64-encode message/rfc822 attachments.
Thanks Michael Farrell for the report and his work on the fix.
2013-08-20 22:17:26 -03:00
Andrew Godwin b6a957f0ba Merge remote-tracking branch 'core/master' into schema-alteration
Conflicts:
	docs/ref/django-admin.txt
2013-08-19 18:30:48 +01:00
Tim Graham 7b69c3e775 Removed versionadded/changed annotations for 1.5 2013-08-19 09:09:41 -04:00
Tim Graham 29255fcb4f Fixed some ReST errors regarding backticks 2013-08-15 07:14:10 -04:00
Mel Collins 6bdb3b1135 Fixed #13518 -- Added FILE_UPLOAD_DIRECTORY_PERMISSIONS setting
This setting does for new directories what FILE_UPLOAD_PERMISSIONS
does for new files.

Thanks jacob@ for the suggestion.
2013-08-12 07:15:59 -04:00
Tim Graham ab680725bf Fixed #20890 -- Added missing import in class-based view docs.
Thanks André Augusto.
2013-08-10 18:08:05 -04:00
Andrew Godwin 7970d97a70 Docs tweaks (thanks timgraham) 2013-08-10 20:00:12 +01:00
ersran9 00d23a13eb Fixed #20828 -- Allowed @permission_required to take a list of permissions
Thanks Giggaflop for the suggestion.
2013-08-10 10:10:18 -04:00
Andrew Godwin de64c4d6e9 Merge remote-tracking branch 'core/master' into schema-alteration
Conflicts:
	django/core/management/commands/flush.py
	django/core/management/commands/syncdb.py
	django/db/models/loading.py
	docs/internals/deprecation.txt
	docs/ref/django-admin.txt
	docs/releases/1.7.txt
2013-08-09 14:17:30 +01:00
Leandro Regueiro 709cd2c4b7 Added section labels in cache docs 2013-08-06 11:56:01 -04:00
Dominic Rodger c33d1ca1d9 Fixed #20852 - Fixed incorrectly generated left quotes in docs.
Sphinx generates left single quotes for apostrophes after
code markup, when right single quotes are required. The
easiest way to fix this is just by inserting the unicode
character for a right single quote.

Instances of the problem were found by looking for
">&#8216;" in the generated HTML.
2013-08-06 07:13:17 -04:00
Justin Michalicek 6d88d47be6 Fixed #20832 -- Enabled HTML password reset email
Added optional html_email_template_name parameter to password_reset view
and PasswordResetForm.
2013-08-05 09:47:28 -04:00
Tim Graham 26c4bd38ac Fixed #20862 -- Updated startproject MIDDLEWARE_CLASSES in docs.
Thanks Keryn Knight.
2013-08-05 08:14:27 -04:00
Justin Michalicek 61ecb5f48a Fixed #20855 -- Added documentation of current_app and extra_context params to django.contrib.auth views
refs #5298 and refs #8342
2013-08-04 08:04:12 -04:00
Alasdair Nicol a0c58113b9 Added missing request argument to example in URL dispatcher docs 2013-08-03 20:42:02 +01:00
Tim Graham 31ee120787 Fixed #20667 - Removed discussion of DEBUG from tutorial.
Forward-port of 3493f18d78 from master.
2013-08-01 18:07:59 -04:00
Tim Graham a1889397a9 Fixed #12103 -- Added AuthenticationForm.confirm_login_allowed to allow customizing the logic policy.
Thanks ejucovy and lasko for work on the patch.
2013-07-31 13:54:05 -04:00
Tim Graham d4dd55e78c Doc tweaks for html_message parameter to send_mail(); refs #20817 2013-07-30 08:06:49 -04:00
Andrew Godwin fddc5957c5 Implement allow_migrate for migration operations 2013-07-30 12:34:31 +01:00
Andrew Godwin 12e9804d16 Rename allow_syncdb to allow_migrate 2013-07-30 12:08:59 +01:00
Andrew Godwin 68e0a169c4 Rename pre_ and post_syncdb to *_migrate, with aliases from old names 2013-07-30 11:52:52 +01:00
Justin Michalicek ac09558760 Fixed #20817 -- Added html_message parameter to django.core.mail.send_mail() 2013-07-29 09:53:47 -04:00
minusf 70c080fcdb Misc doc cleanups. 2013-07-29 06:57:33 -04:00
Jannis Leidel 33e6cf5ec3 Fixed #20774 -- Mention the new django-localflavor app as a replacement for the contrib app. 2013-07-29 10:54:53 +02:00
Tim Graham 0b35a2cce3 Fixed ReST typo in topics/class-based-views/mixins.txt 2013-07-28 14:09:29 -04:00
Julien Phalip 47c755327b Fixed a number of minor misspellings. 2013-07-27 18:46:03 -07:00
Andrew Godwin 88e1e6f9f3 A bit more documentation 2013-07-26 16:28:09 +01:00
Loic Bistuer 31fadc1202 Fixed #20625 -- Chainable Manager/QuerySet methods.
Additionally this patch solves the orthogonal problem that specialized
`QuerySet` like `ValuesQuerySet` didn't inherit from the current `QuerySet`
type. This wasn't an issue until now because we didn't officially support
custom `QuerySet` but it became necessary with the introduction of this new
feature.

Thanks aaugustin, akaariai, carljm, charettes, mjtamlyn, shaib and timgraham
for the reviews.
2013-07-26 12:41:27 +03:00
Andrew Godwin f8297f6323 More migration docs, and conversion of all easy syncdb references 2013-07-25 16:19:36 +01:00
Andrew Godwin 06103c8ef5 Small start to migrations documentation 2013-07-25 14:45:38 +01:00
Tim Graham bd0dcc6c89 Fixed #20766 -- Deprecated FastCGI support. 2013-07-24 13:41:45 -04:00
Tim Graham 65e03a424e Fixed #10284 -- ModelFormSet.save(commit=False) no longer deletes objects
Thanks laureline.guerin@ and Wedg.
2013-07-23 16:21:23 -04:00
Claude Paroz 6d52844b9b Fixed #18551 -- Enabled skipIfDBFeature/skipUnlessDBFeature to decorate a class
Thanks Tim Graham for the review and improved patch.
2013-07-19 20:30:14 +02:00
Tim Graham e1c737b62f Merge pull request #1374 from seocam/fix_i18n_docs
LocaleMiddleware isn't default anymore (corrected docs)
2013-07-19 03:35:46 -07:00
Tim Graham 997e305d24 Merge pull request #1375 from Matt-Stevens/master
Fixed Croatia's country code in `localflavor` docs
2013-07-19 02:30:27 -07:00
Tim Graham 4669986228 Merge pull request #1378 from loic/docs
Fixed #20772 -- Fixed minor typo in form media docs.
2013-07-19 02:19:24 -07:00
Loic Bistuer aa41eb9b8b Fixed #20772 -- Fixed minor typo in form media docs. 2013-07-19 15:48:38 +07:00
Matt Deacalion Stevens 97e5398629 Fix Croatia's country code in `localflavor` docs
Croatia's country code is 'HR', not 'CR'.
2013-07-19 09:01:13 +01:00
Sergio Oliveira cf6c754629 LocaleMiddleware isn't default anymore
Changed in @23229061fcb836ecca2195cc75f91e331279a5d1
2013-07-18 21:15:30 -03:00
Tim Graham dce8945ea6 Fixed #20762 -- Clarified that add_fieldsets is not a standard ModelAdmin attribute. 2013-07-18 12:41:01 -04:00
Loic Bistuer fba6c2ede7 Reworked docs for ModelForm validation. 2013-07-16 19:20:53 -04:00
David Binetti 51b50c47c7 Fixes grammatical error in auth docs
Changes "An error will be raise if you try..." to "An error will be raised if you try..."
2013-07-13 20:28:04 -07:00
Claude Paroz 64099e30e8 Removed obsolete sentence in queries docs 2013-07-13 21:08:44 +02:00
Joeri Bekker 66f3d57b79 Fixed #19031 -- Added a warning when using override_settings with 'DATABASES' 2013-07-12 07:10:18 -04:00
Claude Paroz 59ebe39812 Fixed #17471 -- Added smtplib.SMTP_SSL connection option for SMTP backend
Thanks dj.facebook at gmail.com for the report and initial patch
and Areski Belaid and senko for improvements.
2013-07-11 22:00:08 +02:00
Tim Graham 684a606a4e Fixed #20730 -- Fixed "Programmatically creating permissions" error.
Thanks glarrain for the report.
2013-07-11 11:06:34 -04:00
Benjamin Kagia b0953dc913 Fixed #13721 -- Added UploadedFile.content_type_extra.
Thanks Waldemar Kornewald and mvschaik for work on the patch.
2013-07-11 09:11:59 -04:00
SusanTan ef3fddf26e Fixed #18261 -- Clarified 'project root directory' 2013-07-09 07:11:41 -04:00
James Bennett c0f03175ce Fixed #19695 -- Retitle "Form Media" to "Form Assets". 2013-07-08 13:59:54 -04:00
Tim Graham 660c30ed95 Fixed #16965 -- Clarified Formset can_delete docs.
Thanks gregcorey@ for the suggestion.
2013-07-08 12:08:30 -04:00
Tim Graham 181f63c22d Fixed #12346 -- Added a note on how to validate InlineFormSets.
Thanks johnsmith for the suggestion.
2013-07-08 08:29:28 -04:00
Claude Paroz 7442eb1a24 Fixed #20224 -- Update docs examples which mention __unicode__
Thanks Marc Tamlyn and Tim Graham for the review.
2013-07-05 19:27:07 +02:00
Tim Graham da5069f68f Fixed #20134 -- Correct list of fields that UserManager requires.
Thanks semenov and pegler.
2013-07-04 10:19:00 -04:00
Tim Graham 231e31c690 Fixed #20690 -- Mentioned LOCALE_PATHS earlier in translation docs.
Thanks rene@ for the suggestion.
2013-07-04 05:44:22 -04:00
SusanTan 067e0424ce Fixed #20609 -- Documented how to use request.user with RequestFactory
Thanks michel@ for the suggestion.
2013-07-03 11:05:03 -04:00
Tomáš Ehrlich c5bc98d7e1 Fixed #20687 -- Added documentation for django.core.signing API.
Thanks Baptiste Mispelon for the suggestion.
2013-07-03 10:36:21 -04:00
Ben Firshman 8160e6341d Fix "semicolon" in docs 2013-07-02 17:52:54 +01:00
Aymeric Augustin 6c66a41c3d Relied on NullHandler from the logging stdlib module. 2013-07-01 23:16:25 +02:00
Aymeric Augustin 72c65fea41 Deprecated django.utils.dictconfig.
The module still exists for whoever uses it in its current state, but it
isn't imported by Django anywhere.
2013-07-01 22:50:58 +02:00
Aymeric Augustin cfcf4b3605 Stopped using django.utils.unittest in the test suite.
Refs #20680.
2013-07-01 14:29:33 +02:00
Aymeric Augustin 7f264e02f4 Fixed #20680 -- Deprecated django.utils.unittest.
Refs #19204.
2013-07-01 14:29:33 +02:00
Baptiste Mispelon 88de53d4a8 Fixed #20659 -- Fixed PublisherDetail in CBV topic documentation.
Thanks to tudor.prodan, susan, and Tim Graham for the report and reviews.
2013-07-01 14:05:49 +02:00
Aymeric Augustin a763915a03 Bumped minimum Python version requirement to 2.7 in Django 1.7. 2013-07-01 12:01:59 +02:00
Aymeric Augustin 3fd8eb1a27 Stopped branding Python 3 support as experimental.
Forward-port of 0de21a6 from stable/1.6.x.
2013-07-01 11:52:37 +02:00
Ramiro Morales c196564132 Removed custom profile model functionality as per deprecation TL. 2013-06-28 21:48:16 -03:00
Shai Berger d097417025 Support 'pyformat' style parameters in raw queries, Refs #10070
Add support for Oracle, fix an issue with the repr of RawQuerySet,
add tests and documentations. Also added a 'supports_paramstyle_pyformat'
database feature, True by default, False for SQLite.

Thanks Donald Stufft for review of documentation.
2013-06-28 06:59:10 +03:00
Aymeric Augustin c1284c3d3c Fixed #20571 -- Added an API to control connection.needs_rollback.
This is useful:
- to force a rollback on the exit of an atomic block without having to
  raise and catch an exception;
- to prevent a rollback after handling an exception manually.
2013-06-27 22:19:54 +02:00
Andrew Godwin e26b589b8c Fixed #20590: Documented new test case ordering 2013-06-27 14:02:00 +01:00
Tim Graham 1184d07789 Fixed #14881 -- Modified password reset to work with a non-integer UserModel.pk.
uid is now base64 encoded in password reset URLs/views. A backwards compatible
password_reset_confirm view/URL will allow password reset links generated before
this change to continue to work. This view will be removed in Django 1.7.

Thanks jonash for the initial patch and claudep for the review.
2013-06-26 13:11:47 -04:00
Loic Bistuer c6862d57c1 Fixed #20658 -- Fixed bad reST formatting and missing parentheses in the docs for CBV mixins
Thanks to Keryn Knight for the report.
2013-06-26 14:07:52 +02:00
Tim Graham e161e4ff11 Clarified get_list_or_404 docs, refs #14150. 2013-06-24 07:00:53 -04:00
Baptiste Mispelon cd000dacc7 Fixed #20643 -- Fixed implementation of JSONResponseMixin in CBV docs
Thanks to Michal Sládek for the report and initial patch,
and to loic84 for the review.
2013-06-24 11:55:43 +02:00
Simon Meers 6466a0837b Corrected minor typos in FileUploadHandler.receive_data_chunk docs. 2013-06-24 13:59:03 +10:00
Baptiste Mispelon bd9fbd1497 Fixed errors and inconsistencies in CBV topic documentation.
The code examples should now work correctly.
The `get_context_data` method in the examples was changed when
necessary to adopt a singular style (get context with super(...),
add the extra keys to the dict then return it).

Thanks to Remco Wendt for the initial report and to Tim Graham
for the review.
2013-06-23 00:18:23 +02:00
Baptiste Mispelon b53ed5ac55 Fixed #20612 -- Fixed incorrect wording in CBV documentation
Thanks to ndokos for the report.
2013-06-21 17:50:43 +02:00
Baptiste Mispelon b0b506b933 Fixed broken reference in documentation. 2013-06-19 10:37:24 +02:00
Erik Romijn 2c4fe761a0 Fixed #20593 -- Allow blank passwords in check_password() and set_password() 2013-06-18 13:32:54 -04:00
Baptiste Mispelon 1b7634a0d0 Fixed #20464 -- Added a `total_error_count` method on formsets.
Thanks to frog32 for the report and to Tim Graham for the review.
2013-06-16 15:49:30 -04:00
Tim Graham a1122e14a6 Fixed #20604 - Fixed file example in docs.
Thanks Chris Lasher for the report.
2013-06-14 21:28:17 -04:00
Loic Bistuer 9e50833e22 Fixed #20000 -- Allowed ModelForm meta overrides for label, help_text and error_messages 2013-06-13 15:06:25 -04:00
Danilo Bargen cd7d7452bc Fixed order of base classes in CBV mixin docs 2013-06-13 14:59:13 +02:00
Aymeric Augustin 55cbd65985 Fixed #20579 -- Improved TransactionTestCase.available_apps.
Also moved its documentation to the 'advanced' section. It doesn't
belong to the 'overview'. Same for TransactionTestCase.reset_sequences.

When available_apps is set, after a TransactionTestCase, the database
is now totally empty. post_syncdb is fired at the beginning of the next
TransactionTestCase.

Refs #20483.
2013-06-12 20:01:41 +02:00
Wilfred Hughes b79aa796d8 FormSet.forms is an iterable, so just iterate over it 2013-06-11 16:05:19 +01:00
Tim Graham 9ff5f100dd Fixed #20578 - Typo in BaseFormSet module name 2013-06-10 14:36:40 -04:00
Gabe Jackson 584bd14dcf Fixed #18134 -- BoundField.label_tag now includes the form's label_suffix
There was an inconsistency between how the label_tag for forms were
generated depending on which method was used: as_p, as_ul and as_table
contained code to append the label_suffix where as label_tag called on a
form field directly did NOT append the label_suffix. The code for
appending the label_suffix has been moved in to the label_tag code of
the field and the HTML generation code for as_p, as_ul and as_table now
calls this code as well.

This is a backwards incompatible change because users who have added the
label_suffix manually in their templates may now get double label_suffix
characters in their forms.
2013-06-10 14:23:15 -04:00
Aymeric Augustin 4daf570b98 Added TransactionTestCase.available_apps.
This can be used to make Django's test suite significantly faster by
reducing the number of models for which content types and permissions
must be created and tables must be flushed in each non-transactional
test.

It's documented for Django contributors and committers but it's branded
as a private API to preserve our freedom to change it in the future.

Most of the credit goes to Anssi. He got the idea and did the research.

Fixed #20483.
2013-06-10 11:24:10 +02:00
Tim Graham 4e94c84e50 Fixed #19875 - Added warnings regarding DEBUG=False and empty ALLOWED_HOSTS 2013-06-09 15:05:15 -04:00
Kenny Rachuonyo 4bd6e5e895 Update media.txt
Fixed typo: froms -> forms
2013-06-09 08:23:48 +03:00
Jacob Kaplan-Moss 357d62d9f2 Explained that timezone.now() always returns times in UTC.
The docs were ambiguous about the time zone for now(), leading people to
assume that it would be the current time zone rather that UTC.
2013-06-06 11:05:33 -05:00
Tim Graham bb863faecd Proofed the 1.6 release notes 2013-06-05 12:55:58 -04:00
Tim Graham a35ed20241 Fixed #18924 -- Made test.Client.logout send user_logged_out signal.
Thanks awsum for the suggestion and Pavel Ponomarev and
Florian Hahn for the patch.
2013-06-04 12:39:09 -04:00
Tim Graham f315693304 Fixed #20543 - Typo in db model fields docs.
Thanks i.amber.jain@ for the report.
2013-06-01 05:48:38 -04:00
Tim Graham f10e9af227 Fixed #20166 - Corrected TEST_DEPENDENCIES example in testing docs.
Thanks czambran.
2013-05-31 08:18:29 -04:00
Claude Paroz 3d883e8bd9 Merge pull request #1232 from fusionbox/normalize_email
Fixed #20531 -- Don't hard-code class names when calling static methods
2013-05-31 00:56:56 -07:00
Ramiro Morales ac90aee55c Tweak caching decorators/utility functions xrefs. 2013-05-30 20:38:44 -03:00
Gavin Wahl 01ae881bb4 Don't hard-code class names when calling static methods
normalize_email should be called on the instance, not the class. This
has the same effect normally but is more helpful to subclassers. When
methods are called directly on the class, subclasses can't override
them.
2013-05-29 16:11:26 -06:00
Tim Graham 1fdc3d256d Fixed #20523 - Incorrect form field for FilePathField.
Thanks sane4ka.sh@ for the report.
2013-05-28 11:54:53 -04:00
Tim Graham 8365d76da0 Fixed #20513 - Expanded docs on QuerySet caching.
Thanks seddonym.
2013-05-28 08:41:13 -04:00
Tim Graham d194714c0a Fixed #11603 - Added django.test.SimpleTestCase.assertFormsetError
Thank-you Martin Green for the patch.
2013-05-27 12:25:35 -04:00
yishaibeeri f077f89198 Patch for ticket #20506 - documentation type 2013-05-27 11:14:38 +03:00
Preston Holmes d228c1192e Fixed #19866 -- Added security logger and return 400 for SuspiciousOperation.
SuspiciousOperations have been differentiated into subclasses, and
are now logged to a 'django.security.*' logger. SuspiciousOperations
that reach django.core.handlers.base.BaseHandler will now return a 400
instead of a 500.

Thanks to tiwoc for the report, and Carl Meyer and Donald Stufft
for review.
2013-05-25 16:27:34 -07:00
Tim Graham dffdca1109 Fixed #20316 - Clarified transaction behavior of TestCase.
Thanks uberj@ for the report and lolek09 for the patch.
2013-05-23 10:57:44 -04:00
Panagiotis H.M. Issaris 6845dc7e8f Fixed comments for translators example in the i18n documentation
The documentation regarding adding a comment for translators was confusing
as the example contained mismatching tags.
2013-05-23 10:19:10 +02:00
Tim Graham 2fd61285d1 Fixed #20471 - Typos in topics/forms/formsets.txt 2013-05-20 13:56:19 -04:00
Ryan Kaskel 4280217f31 Fixed #20403 -- Ignore forms marked for deletion when validating max_num. 2013-05-20 12:13:21 -04:00
Aymeric Augustin 6633eeb886 Changed API to disable ATOMIC_REQUESTS per view.
A decorator is easier to apply to CBVs. Backwards compatibility isn't an
issue here, except for people running on a recent clone of master.

Fixed a few minor problems in the transactions docs while I was there.
2013-05-19 19:53:16 +02:00
Tim Graham 41bea033b7 Fixed #20183 - Clarified docs assumption that certain objects exist in database.
Thanks Tomasz Jaskowski for the patch.
2013-05-19 11:31:27 -04:00
leandrafinger 08b501e7d3 add missing imports to the examples in the 'Forms' 2013-05-19 13:31:45 +02:00
Silvan Spross 1d543949d7 Add missing imports and models to the examples in internationalization and localization documentation 2013-05-19 13:30:01 +02:00
Tim Graham cc62cbed76 Fixed some line wrapping, refs #20233 2013-05-19 06:51:55 -04:00
Aymeric Augustin 753edfa4b5 Fixed a rest mistake I introduced in d5ce2ff. 2013-05-19 12:14:44 +02:00
Marc Tamlyn d9c01da1f8 Improve cookie based session backend docs.
Note the don't require sessions to be in installed apps.
2013-05-19 11:24:35 +02:00
Andrew Godwin cf56536ac7 Merge pull request #1145 from postrational/ticket_20233
Fixed #20233 - Full custom user model example isn't really full
2013-05-19 02:00:50 -07:00
postrational 0b3a6ead88 refs #20233 - Full custom user model example isn't really full
Addition and fix for custom user model example documentation.

https://code.djangoproject.com/ticket/20233
2013-05-19 10:48:30 +02:00
Marc Tamlyn 33c361ef9d Merge pull request #1129 from frog32/master
Add needed Imports to the Documentation
2013-05-19 01:37:25 -07:00
Ramiro Morales 0a50311063 Fixed #20004 -- Moved non DB-related assertions to SimpleTestCase.
Thanks zalew for the suggestion and work on a patch.

Also updated, tweaked and fixed testing documentation.
2013-05-18 19:04:34 -03:00
Silvan Spross cd72c55d86 Add missing imports and models to the examples in the view layer documentation 2013-05-18 18:39:11 +02:00
Marc Egli e4591debd1 Add missing imports and models to the examples in the the model layer documentation 2013-05-18 18:38:52 +02:00
Łukasz Langa bd97f7d0cb Fixed #15201: Marked CACHE_MIDDLEWARE_ANONYMOUS_ONLY as deprecated 2013-05-18 17:38:32 +02:00
Tim Graham 96cabba808 Fixed #20335 - Documented the {% language %} template tag.
Thanks bmispelon for the suggestion and djangsters for the patch.
2013-05-18 11:20:02 -04:00
Erik Romijn d5ce2ff5e4 Fixed #20444 -- Cookie-based sessions does not include a remote code execution-warning 2013-05-18 16:53:13 +02:00
Jacob Burch 89955cc35f Fixed #9595 -- Allow non-expiring cache timeouts.
Also, streamline the use of 0 and None between cache backends.
2013-05-18 15:39:42 +02:00
Erik Romijn 756b81dbd1 Fixed #13546 -- Easier handling of localize field options in ModelForm 2013-05-18 14:13:00 +02:00
Marc Tamlyn 9666874ee1 Tidy up some of the transaction documentation. 2013-05-17 18:40:50 +02:00
Florian Apolloner 10e397e263 Fixed #20426 -- Added some extra info to the auth forms.
Thanks to Joel Hansson for the suggestion and Curtis Maloney for the initial
patch.
2013-05-17 16:14:23 +02:00
Stefan hr Berder 746d3166d6 small typo, example pk=27 but description pk=24 2013-05-16 15:21:18 +08:00
Aymeric Augustin c8dcee9a42 Improved the timezone middleware example slightly.
This change avoids having the timezone leak from a request to the next.
2013-05-15 16:43:39 +02:00
Tim Graham 84d8b247d2 Fixed #20165 - Updated testing example to use django.test.TestCase.
Thanks Lorin Hochstein.
2013-05-15 06:48:17 -04:00
Donald Stufft 8f0a4665d6 Recommend using the bcrypt library instead of py-bcrypt
* py-bcrypt has not been updated in some time
* py-bcrypt does not support Python3
* py3k-bcrypt, a port of py-bcrypt to python3 is not compatible
  with Django
* bcrypt is supported on all versions of Python that Django
  supports
2013-05-13 23:49:00 -04:00
Tim Graham 1708c8afb6 Merge pull request #1053 from makto/patch-1
Fixed #20394 - Clarified argument of get_user in docs
2013-05-13 11:02:30 -07:00
Tim Graham 897e4eab65 Fixed #20398 - Added language selection code to example in documentation
Thanks ggbaker for the suggestion and Simeon Visser for the patch.
2013-05-13 13:43:28 -04:00
Ramiro Morales 956973ca6c Updated test failure example. 2013-05-12 17:29:34 -03:00
zhongqi 1172bef998 Update customizing.txt
The origin statement "which could be ... or whatever" **misguides** many newbies like me.

In fact, the ``login`` function in ``contrib.auth`` stores ``user.pk`` in session, then ``get_user`` function in ``contrib.auth`` gets ``user.pk`` in session and then passes it to your custom ``get_user`` as ``user_id``.

Which means, ``user_id`` prarameter in your custom ``get_user`` has to be the primary key of ``User`` object, too.
2013-05-11 15:53:54 +08:00
Carl Meyer 9012833af8 Fixed #17365, #17366, #18727 -- Switched to discovery test runner.
Thanks to Preston Timmons for the bulk of the work on the patch, especially
updating Django's own test suite to comply with the requirements of the new
runner. Thanks also to Jannis Leidel and Mahdi Yusuf for earlier work on the
patch and the discovery runner.

Refs #11077, #17032, and #18670.
2013-05-10 23:08:45 -04:00
Aymeric Augustin bdd285723f Fixed #20385 -- Typo in files docs. 2013-05-10 13:23:57 +02:00
Luke Plant f026a519ae Fixed #19733 - deprecated ModelForms without 'fields' or 'exclude', and added '__all__' shortcut
This also updates all dependent functionality, including modelform_factory
 and modelformset_factory, and the generic views `ModelFormMixin`,
 `CreateView` and `UpdateView` which gain a new `fields` attribute.
2013-05-09 16:44:36 +01:00
Carl Meyer d89b421352 Python 2.5 is not relevant to master. 2013-05-07 17:05:37 -06:00
Mike Fogel 1ad83145df Remove outdated ForeignKey manager documentation. 2013-05-07 10:06:15 -04:00
Tim Graham bc02a963db Fixed #20177 - Corrected docs for django.test.utils.setup_test_environment.
Thanks vlad.london.uk@ for the report.
2013-05-06 13:55:02 -04:00
Tim Graham e886808994 Fixed #20274 - Added some clarifying section headings in the test docs. 2013-05-06 13:45:24 -04:00
Christopher Allen-Poole a96bff179a Found a mistake in SQL documentation 2013-05-05 11:01:45 -04:00
Ana Krivokapic cee96b87c0 Fix two typos in database transactions docs 2013-04-30 18:38:59 +02:00
Aymeric Augustin 1267d2d9bc Fixed #20330 -- Normalized spelling of "web server".
Thanks Baptiste Mispelon for the report.
2013-04-29 19:40:43 +02:00
Thomas Thurman b47b0211f5 Corrected "it's" to "its" when used possessively.
Fixed #20327.
2013-04-29 17:21:37 +02:00
Baptiste Mispelon 73c26f0c95 Fixed #20270 -- Fixed error in AjaxResponseMixin documentation 2013-04-22 20:00:50 +02:00
Juan Catalano 78c842a323 Adapted uses of versionchanged/versionadded to the new form.
Refs #20104.
2013-04-20 17:18:35 +02:00
Aymeric Augustin bfe25de429 Explained the pattern for special methods compatibility. 2013-04-19 09:53:50 +02:00
Tim Graham 9f7b277d2e Fixed #20285 - Added missing commas in translation docs.
Thanks cody.j.b.scott@
2013-04-18 13:44:20 -04:00
Claude Paroz 58b3a974fc Fixed #20266 -- Updated view example in CBV introduction
Thanks jim at hellolocals.com for the report.
2013-04-16 08:59:55 +02:00
Simon Charette 1de63cccb1 Fixed #20263 -- Corrected wording in the formset documentation.
Thanks to feraudyh at yahoo.com for the report.
2013-04-15 12:19:17 -04:00
Tim Graham c852d45681 Fixed #20204 - Consistent usage of url() in URL dispatcher documentation
Thanks Baptiste Mispelon for the patch and dave.lampton@ for the suggestion.
2013-04-10 20:38:25 -04:00
Baptiste Mispelon 2c27300f34 Fix #20195: wrong reference in session settings documentation. 2013-04-04 18:12:12 +02:00
Tim Graham 4a1d425cfe Fixed #8649 - Documented a caveat about dynamically adjusting formsets. 2013-03-31 04:34:28 -04:00
Tim Graham c119d0f152 Fixed #20168 - Generalized a PostgreSQL specific database query in the docs.
Thanks Russ for the suggestion.
2013-03-31 03:40:44 -04:00
Tim Graham 6c730da1f6 Fixed #19897 - Updated static files howto.
Thanks Jan Murre, Reinout van Rees and Wim Feijen,
plus Remco Wendt for reviewing.
2013-03-29 19:15:19 -04:00
Nimesh Ghelani 485c024567 Fixed #20150 -- Fixed an error in manager doc example 2013-03-30 01:01:56 +05:30
Simon Charette 6293eaa062 Fixed #20159 -- Mispelled attribute in multi-db documentation example.
Thanks to sane4ka.sh at gmail for the report!
2013-03-29 14:16:30 -04:00
Donald Stufft f2a0be6151 Fix a missing " character in the password documentation 2013-03-26 15:26:20 -04:00
Donald Stufft 25f2acfed0 Fixed #20138 -- Added BCryptSHA256PasswordHasher
BCryptSHA256PasswordHasher pre-hashes the users password using
SHA256 to prevent the 72 byte truncation inherient in the BCrypt
algorithm.
2013-03-26 13:26:57 -04:00
Ramiro Morales ccf8d81113 Fixed docs reST warning. 2013-03-25 21:56:52 -03:00
Aymeric Augustin ae417dd4d5 Added release notes for 4b31a6a9.
Thanks Florian for reporting this omission.
2013-03-24 13:13:19 +01:00
Claude Paroz f670cce9f5 Fixed #20119 -- Fixed typo in auth docs
Thanks vinyll for the report.
2013-03-23 20:00:18 +01:00
Claude Paroz 76aecfbc4b Fixed #9055 -- Standardized behaviour of parameter escaping in db cursors
Previously, depending on the database backend or the cursor type,
you'd need to double the percent signs in the query before passing
it to cursor.execute. Now cursor.execute consistently need percent
doubling whenever params argument is not None (placeholder substitution
will happen).
Thanks Thomas Güttler for the report and Walter Doekes for his work
on the patch.
2013-03-23 17:11:10 +01:00
Tim Graham 93cffc3b37 Added missing markup to docs. 2013-03-22 13:50:07 -04:00
Tim Graham f7795e968d Fixed #17935 - Clarified intro of topics/files.txt.
Thanks guettli for the suggestion.
2013-03-22 06:01:51 -04:00
Andrew Gorcester f9ab543720 Fixed #20084 -- Provided option to validate formset max_num on server.
This is provided as a new "validate_max" formset_factory option defaulting to
False, since the non-validating behavior of max_num is longstanding, and there
is certainly code relying on it. (In fact, even the Django admin relies on it
for the case where there are more existing inlines than the given max_num). It
may be that at some point we want to deprecate validate_max=False and
eventually remove the option, but this commit takes no steps in that direction.

This also fixes the DoS-prevention absolute_max enforcement so that it causes a
form validation error rather than an IndexError, and ensures that absolute_max
is always 1000 more than max_num, to prevent surprising changes in behavior
with max_num close to absolute_max.

Lastly, this commit fixes the previous inconsistency between a regular formset
and a model formset in the precedence of max_num and initial data. Previously
in a regular formset, if the provided initial data was longer than max_num, it
was truncated; in a model formset, all initial forms would be displayed
regardless of max_num. Now regular formsets are the same as model formsets; all
initial forms are displayed, even if more than max_num. (But if validate_max is
True, submitting these forms will result in a "too many forms" validation
error!) This combination of behaviors was chosen to keep the max_num validation
simple and consistent, and avoid silent data loss due to truncation of initial
data.

Thanks to Preston for discussion of the design choices.
2013-03-21 01:27:24 -07:00
Claude Paroz a9ee0e2970 Fixed #20096 -- Added link to the Greek localflavor app 2013-03-20 17:08:08 +01:00
Aymeric Augustin 6197935152 Fixed #19968 -- Dropped support for PostgreSQL < 8.4. 2013-03-18 21:16:29 +01:00
Aymeric Augustin f3a6d74db9 Minor docs fix for e11ccc76. 2013-03-17 22:43:49 +01:00
Aymeric Augustin e11ccc76d3 Updated bundled version of six. 2013-03-17 10:44:28 +01:00
Aymeric Augustin f8c7c8f27b Merge pull request #901 from giamfreeg/master
Fixed an erroneous import in example code of docs (class-based-views/intro).
2013-03-15 06:23:21 -07:00
Aymeric Augustin 3f2befc931 Deprecated django.views.defaults.shortcut. 2013-03-14 20:30:23 +01:00
Claude Paroz 50eb70b08f Fixed #20032 -- Documented how to simulate the absence of a setting
Thanks Ram Rachum for the report.
2013-03-13 23:14:26 +01:00
Pablo Sanfilippo bd68f701b1 Fixed an erroneous import in example code. 2013-03-13 14:16:27 -03:00
Aymeric Augustin 5d8342f321 Proof-read and adjusted the transactions docs. 2013-03-13 15:17:41 +01:00
Aymeric Augustin 83a416f5e7 Made atomic usable when autocommit is off.
Thanks Anssi for haggling until I implemented this.

This change alleviates the need for atomic_if_autocommit. When
autocommit is disabled for a database, atomic will simply create and
release savepoints, and not commit anything. This honors the contract of
not doing any transaction management.

This change also makes the hack to allow using atomic within the legacy
transaction management redundant.

None of the above will work with SQLite, because of a flaw in the design
of the sqlite3 library. This is a known limitation that cannot be lifted
without unacceptable side effects eg. triggering arbitrary commits.
2013-03-13 15:17:40 +01:00
Aymeric Augustin e654180ce2 Improved the API of set_autocommit. 2013-03-11 15:10:58 +01:00
Aymeric Augustin 4dbd1b2dd8 Used commit_on_success_unless_managed to make ORM operations atomic. 2013-03-11 15:05:05 +01:00
Aymeric Augustin 107d9b1d97 Added an option to disable the creation of savepoints in atomic. 2013-03-11 15:05:04 +01:00
Aymeric Augustin 189fb4e294 Added a note about long-running processes.
There isn't much else to say, really.
2013-03-11 15:05:04 +01:00
Aymeric Augustin 17cf29920b Added an explanation of transactions and grouped low-level APIs. 2013-03-11 15:05:02 +01:00
Aymeric Augustin ffe41591e7 Updated the documentation for savepoints.
Apparently django.db.transaction used to be an object.
2013-03-11 15:04:10 +01:00
Aymeric Augustin ac37ed21b3 Deprecated TransactionMiddleware and TRANSACTIONS_MANAGED.
Replaced them with per-database options, for proper multi-db support.

Also toned down the recommendation to tie transactions to HTTP requests.
Thanks Jeremy for sharing his experience.
2013-03-11 15:04:05 +01:00
Aymeric Augustin 7c46c8d5f2 Added some assertions to enforce the atomicity of atomic. 2013-03-11 14:48:55 +01:00
Aymeric Augustin d7bc4fbc94 Implemented an 'atomic' decorator and context manager.
Currently it only works in autocommit mode.

Based on @xact by Christophe Pettus.
2013-03-11 14:48:55 +01:00
Aymeric Augustin 4b31a6a9e6 Added support for savepoints in SQLite.
Technically speaking they aren't usable yet.
2013-03-11 14:48:55 +01:00
Aymeric Augustin 5e27debc5c Enabled database-level autocommit for all backends.
This is mostly a documentation change.

It has the same backwards-incompatibility consequences as those
described for PostgreSQL in a previous commit.
2013-03-11 14:48:54 +01:00
Aymeric Augustin f515619494 Added an API to control database-level autocommit. 2013-03-11 14:48:53 +01:00
Loic Bistuer 6983a1a540 Fixed #15363 -- Renamed and normalized to `get_queryset` the methods that return a QuerySet. 2013-03-08 10:11:45 -05:00
Claude Paroz 4cccb85e29 Fixed #19997 -- Added custom EMPTY_VALUES to form fields
Thanks Loic Bistuer for the report and the patch.
2013-03-07 15:22:03 +01:00
Michael Manfre bb998c9fec Update link to django-mssql project 2013-03-06 12:12:42 -05:00
Tobias Carlander df7668a9e4 Fix Typo explicitly. Fixes #19971 2013-03-03 22:34:10 +04:00
Aymeric Augustin 97afc49bb0 Removed unnecessary imports. 2013-03-03 16:07:38 +01:00
Tim Graham fe5d9fe5fe Fixed #19962 - Added a note about SESSION_EXPIRE_AT_BROWSER_CLOSE and browsers that persist sessions.
Thanks David Sanders.
2013-03-02 10:11:23 -05:00
Tim Graham d009ffe436 Fixed #19937 - Typo in class-based views intro. 2013-02-28 08:25:14 -05:00
Tim Graham 226a9fb2ea Merge pull request #858 from intgr/py3kdoc-fix
Fixed a typo in Python 3 porting guide.
2013-02-27 13:16:55 -08:00
Claude Paroz b0ba21db07 Fixed #19926 -- Fixed a link to code example in queries docs
Thanks Randy Salvo for the report.
2013-02-27 21:30:54 +01:00
Tim Graham 2108941677 Fixed #16807 - Added a class-based views intro.
Thanks Preston Holmes for the text.
2013-02-27 07:13:55 -05:00
Marti Raudsepp fba6df19b5 [py3] str.decode does not exist; str.encode was intended 2013-02-26 23:28:47 +02:00
Tim Graham 9ce1b6191b Fixed #19922 - Typo in translation docs.
Thanks amoebob for the report.
2013-02-26 15:12:28 -05:00
Aymeric Augustin 0836670c5c Fixed #6195 -- Documented caching options for javascript_catalog. 2013-02-25 22:29:38 +01:00
Ben Konrath d546259647 Fixed #19394 --Added note about auth forms and custom user models. 2013-02-24 07:55:38 -08:00
Zbigniew Siciarz 0a8402eb05 Test case and docs for custom context data in feeds
Thanks Paul Winkler for the initial patch. (Ref #18112).
2013-02-24 08:33:20 -06:00
Florian Apolloner 4506ae0497 Merge pull request #717 from slurms/ticket_19746
Fixed #19746 -- Allow deserialization of pk-less data
2013-02-24 06:31:14 -08:00
Tomek Paczkowski 99edbe0e27 Fixed #19253 -- Extracted template cache key building logic
Introduced a public function
django.core.cache.utils.make_template_fragment_key
Thanks @chrismedrela for fruitful cooperation.
2013-02-24 14:32:45 +01:00
Aymeric Augustin b6aede3268 Merge pull request #815 from zerok/tickets/11971
Fixed #11971 -- Documented the serialization formats
2013-02-24 02:18:32 -08:00
Horst Gutmann 5612f54bd5 Added more details about the various serialization formats. 2013-02-24 10:58:03 +01:00
Tim Graham cf890c110e Added an example of "default" database dictionary left blank; refs #19775.
Thanks wsmith323 for the patch.
2013-02-23 16:01:43 -05:00
Tim Graham 24a2bcbcdd Fixed #19402 - Clarified purpose of CustomUser.REQUIRED_FIELDS
Thanks pydanny for the report and ptone for the patch.
2013-02-23 15:42:56 -05:00
Tim Graham 4c05fdb467 Fixed #19579 - Documented that "providing_args" is purely documentational. 2013-02-23 15:33:43 -05:00
Tim Graham 31bcb102b2 Fixed #19775 - Clarified requirements of the "default" database.
Thanks monkut for the report and wsmith323 for the patch.
2013-02-23 15:21:35 -05:00
Horst Gutmann 2f4a4703e1 Fixed #19758 -- Avoided leaking email existence through the password reset form. 2013-02-23 14:31:21 +01:00
Claude Paroz 7ec2a21be1 Fixed #19686 -- Added HTML5 number input type
Thanks Simon Charette for his help on the patch. Refs #16630.
2013-02-23 10:18:08 +01:00
Preston Holmes 649118961c Fixed #19868 -- Clarified purpose of custom user example 2013-02-20 15:32:35 -08:00
Tim Graham bd006e00e4 Merge pull request #737 from hrbonz/docs_CBV_generic_views_typo
Fixed typo in docs/topics/class-based-views/generic-display.txt
2013-02-19 13:30:28 -08:00
Aymeric Augustin 35c991aa06 Added a default limit to the maximum number of forms in a formset.
This is a security fix. Disclosure and advisory coming shortly.
2013-02-19 11:23:30 -07:00
Carl Meyer d51fb74360 Added a new required ALLOWED_HOSTS setting for HTTP host header validation.
This is a security fix; disclosure and advisory coming shortly.
2013-02-19 11:23:29 -07:00
Tim Graham 00031b73bd Updated a couple admonitions to use the warning directive. 2013-02-19 11:31:41 -05:00
Stefan "hr" Berder 22d5e4b4af Update docs/topics/class-based-views/generic-display.txt
simple typo in "Making friendly template contexts"
2013-02-19 16:01:06 +08:00
Tim Graham 64d0f89ab1 Fixed #19717 - Removed mentions of "root QuerySet" in docs.
Thanks julien.aubert.mail@ for the report and James Pic for the patch.
2013-02-18 09:35:22 -05:00
Alex Hunley 976dc07baf Removed a misleading examples from documentations ala ticket #19719 2013-02-16 14:30:55 -05:00
Russell Keith-Magee 91c26eadc9 Refs #14881 -- Document that User models need to have an integer primary key.
Thanks to Kaloian Minkov for the reminder about this undocumented requirement.
2013-02-16 10:21:05 +08:00
Russell Keith-Magee f5e4a699ca Fixed #19822 -- Added validation for uniqueness on USERNAME_FIELD on custom User models.
Thanks to Claude Peroz for the draft patch.
2013-02-15 09:00:55 +08:00
Claude Paroz 668d0b8d49 Fixed #19823 -- Fixed memcached code example in cache docs 2013-02-14 11:23:52 +01:00
Aymeric Augustin c4841b3de4 Merge pull request #719 from JonLoy/ticket_19808
Fixed #19808 -- Typo in example
2013-02-12 06:24:22 -08:00
JonLoy 74003ca36b Fixed #19808 Capitalization error in example text 2013-02-12 09:14:19 -05:00
Ramiro Morales 0560bfb705 Mention backward relationships in aggregate docs.
Thanks Anssi and Marc Tamlyn for reviewing.

Fixes #19803.
2013-02-12 09:36:29 -03:00
Nick Sandford 278dad5b41 Fixed #19746 -- Allow deserialization of pk-less data 2013-02-12 17:10:42 +08:00
Ramiro Morales 112c6e987d Typo in i18n docs. 2013-02-07 19:57:26 -03:00
Tim Graham 43efefae69 Fixed #19756 - Corrected a ManyToMany example and added some links and markup. 2013-02-07 06:12:25 -05:00
Tim Graham afa3e16334 Fixed #19743 - Documented some limitations of contrib.auth.
Thanks Aymeric for the suggestion.
2013-02-06 08:24:38 -05:00
Simon Charette ea425ebcb2 Fixed a documentation warning introduced by 3f1c7b7 2013-02-06 01:07:42 -05:00
Aymeric Augustin 3f1c7b7053 Simplified default project template.
Squashed commit of:

commit 508ec9144b35c50794708225b496bde1eb5e60aa
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 22:50:55 2013 +0100

    Tweaked default settings file.

    * Explained why BASE_DIR exists.
    * Added a link to the database configuration options, and put it in its
      own section.
    * Moved sensitive settings that must be changed for production at the
      top.

commit 6515fd2f1aa73a86dc8dbd2ccf512ddb6b140d57
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 14:35:21 2013 +0100

    Documented the simplified app & project templates in the changelog.

commit 2c5b576c2ea91d84273a019b3d0b3b8b4da72f23
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 13:59:27 2013 +0100

    Minor fixes in tutorials 5 and 6.

commit 55a51531be8104f21b3cca3f6bf70b0a7139a041
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 13:51:11 2013 +0100

    Updated tutorial 2 for the new project template.

commit 29ddae87bdaecff12dd31b16b000c01efbde9e20
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 11:58:54 2013 +0100

    Updated tutorial 1 for the new project template.

commit 0ecb9f6e2514cfd26a678a280d471433375101a3
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 11:29:13 2013 +0100

    Adjusted the default URLconf detection to account for the admin.

    It's now enabled by default.

commit 5fb4da0d3d09dac28dd94e3fde92b9d4335c0565
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 10:36:55 2013 +0100

    Added security warnings for the most sensitive settings.

commit 718d84bd8ac4a42fb4b28ec93965de32680f091e
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 23:24:06 2013 +0100

    Used an absolute path for the SQLite database.

    This ensures the settings file works regardless of which directory
    django-admin.py / manage.py is invoked from.

    BASE_DIR got a +1 from a BDFL and another core dev. It doesn't involve
    the concept of a "Django project"; it's just a convenient way to express
    relative paths within the source code repository for non-Python files.

    Thanks Jacob Kaplan-Moss for the suggestion.

commit 1b559b4bcda622e10909b68fe5cab90db6727dd9
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 23:22:40 2013 +0100

    Removed STATIC_ROOT from the default settings template.

    It isn't necessary in development, and it confuses beginners to no end.

    Thanks Carl Meyer for the suggestion.

commit a55f141a500bb7c9a1bc259bbe1954c13b199671
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 23:21:43 2013 +0100

    Removed MEDIA_ROOT/URL from default settings template.

    Many sites will never deal with user-uploaded files, and MEDIA_ROOT is
    complicated to explain.

    Thanks Carl Meyer for the suggestion.

commit 44bf2f2441420fd9429ee9fe1f7207f92dd87e70
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 22:22:09 2013 +0100

    Removed logging config.

    This configuration is applied regardless of the value of LOGGING;
    duplicating it in LOGGING is confusing.

commit eac747e848eaed65fd5f6f254f0a7559d856f88f
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 22:05:31 2013 +0100

    Enabled the locale middleware by default.

    USE_I18N is True by default, and doesn't work well without
    LocaleMiddleware.

commit d806c62b2d00826dc2688c84b092627b8d571cab
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 22:03:16 2013 +0100

    Enabled clickjacking protection by default.

commit 99152c30e6a15003f0b6737dc78e87adf462aacb
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 22:01:48 2013 +0100

    Reorganized settings in logical sections, and trimmed comments.

commit d37ffdfcb24b7e0ec7cc113d07190f65fb12fb8a
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 16:54:11 2013 +0100

    Avoided misleading TEMPLATE_DEBUG = DEBUG.

    According to the docs TEMPLATE_DEBUG works only when DEBUG = True.

commit 15d9478d3a9850e85841e7cf09cf83050371c6bf
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 16:46:25 2013 +0100

    Removed STATICFILES_FINDERS/TEMPLATE_LOADERS from default settings file.

    Only developers with special needs ever need to change these settings.

commit 574da0eb5bfb4570883756914b4dbd7e20e1f61e
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 16:45:01 2013 +0100

    Removed STATICFILES/TEMPLATES_DIRS from default settings file.

    The current best practice is to put static files and templates in
    applications, for easier testing and deployment.

commit 8cb18dbe56629aa1be74718a07e7cc66b4f9c9f0
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 16:24:16 2013 +0100

    Removed settings related to email reporting from default settings file.

    While handy for small scale projects, it isn't exactly a best practice.

commit 8ecbfcb3638058f0c49922540f874a7d802d864f
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 18:54:43 2013 +0100

    Documented how to enable the sites framework.

commit 23fc91a6fa67d91ddd9d71b1c3e0dc26bdad9841
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 16:28:59 2013 +0100

    Disabled the sites framework by default.

    RequestSite does the job for single-domain websites.

commit c4d82eb8afc0eb8568bf9c4d12644272415e3960
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Tue Jan 29 00:08:33 2013 +0100

    Added a default admin.py to the application template.

    Thanks Ryan D Hiebert for the suggestion.

commit 4071dc771e5c44b1c5ebb9beecefb164ae465e22
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 10:59:49 2013 +0100

    Enabled the admin by default.

    Everyone uses the admin.

commit c807a31f8d89e7e7fd97380e3023f7983a8b6fcb
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 10:57:05 2013 +0100

    Removed admindocs from default project template.

commit 09e4ce0e652a97da1a9e285046a91c8ad7a9189c
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 16:32:52 2013 +0100

    Added links to the settings documentation.

commit 5b8f5eaef364eb790fcde6f9e86f7d266074cca8
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 11:06:54 2013 +0100

    Used a significant example for URLconf includes.

commit 908e91d6fcee2a3cb51ca26ecdf12a6a24e69ef8
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 16:22:31 2013 +0100

    Moved code comments about WSGI to docs, and rewrote said docs.

commit 50417e51996146f891d08ca8b74dcc736a581932
Author: Aymeric Augustin <aymeric.augustin@m4x.org>
Date:   Mon Jan 28 15:51:50 2013 +0100

    Normalized the default application template.

    Removed the default test that 1 + 1 = 2, because it's been committed
    way too many times, in too many projects.

    Added an import of `render` for views, because the first view will
    often be:

    def home(request):
        return render(request, "mysite/home.html")
2013-02-04 13:21:36 +01:00
Tim Graham 2c173ff3b4 Fixed a typo in docs/topics/auth/customizing.txt 2013-02-03 13:23:16 -05:00
Julien Phalip 293f7a2114 Fixed #17797 -- Enabled support for PATCH requests in the dummy test client. Thanks to pfarmer for the suggestion and initial patch. 2013-02-02 18:22:40 -08:00
Tim Graham fdaaa24171 Fixed #19700 - Added documentation for BoundField.field.
Thanks Tiberiu Ana for the report and patch.
2013-02-02 08:34:42 -05:00
Tim Graham bdb5f28714 Merge pull request #682 from LucianU/master
Fixed #19690 - Removed unused import in doc examples
2013-02-01 16:18:05 -08:00
Ramiro Morales 7947c9e3a6 Deprecated undocumented warnings manipulation testing tools. 2013-01-31 14:57:45 -03:00
Aymeric Augustin 89cb771be7 Fixed #19692 -- Completed deprecation of mimetype in favor of content_type.
Thanks Tim for the report and initial patch.
2013-01-31 13:54:40 +01:00
Aymeric Augustin 3f1a0c0040 Fixed #19160 -- Made lazy plural translations usable.
Many thanks to Alexey Boriskin, Claude Paroz and Julien Phalip.
2013-01-30 20:28:16 +01:00
Ramiro Morales 47ddd6a408 Fixed #19552 -- Enhanced makemessages handling of ``{# #}``-style template comments.
They are simply ignored now. This allows for a more correct behavior when
they are placed before translatable constructs on the same line.

Previously, the latter were wrongly ignored because the former were
preserved when converting template code to the internal Python-syntax
form later fed to xgettext but Python has no ``/* ... */``-style
comments.

Also, special comments directed to translators are now only taken in
account when they are located at the end of a line. e.g.::

  {# Translators: ignored #}{% trans "Literal A" %}{# Translators: valid, associated with "Literal B" below #}
  {% trans "Literal B" %}

Behavior of ``{% comment %}...{% endcomment %}``tags remains unchanged.

Thanks juneih at redpill-linpro dot com for the report and Claude for
his work on the issue.
2013-01-29 19:13:23 -03:00
Tim Graham ee26797cff Fixed typos in docs and comments 2013-01-29 10:55:55 -07:00