Fixed #20819 -- Return 404 instead of 500 error when ``staticfiles`` view is used in production.
Merge pull request #1416 from thirstydigital/tickets/20819-staticfiles-serve-404

Fixed #20819 -- Return 404 instead of 500 error when ``staticfiles`` vie...
Added a test for AdminSite.app_index_template; refs #8498.
Fixed #20779 -- Documented AdminSite.app_index_template; refs #8498.

Thanks CollinAnderson for the report.
Fixed some ReST errors; refs #20819.
Fixed #20793 -- Added Last-Modified header to sitemaps.
Fixed #20348 -- Consistently handle Promise objects in model fields.

All Promise objects were passed to force_text() deep in ORM query code.
Not only does this make it difficult or impossible for developers to
prevent or alter this behaviour, but it is also wrong for non-text
fields.

This commit changes `Field.get_prep_value()` from a no-op to one that
resolved Promise objects. All subclasses now call super() method first
to ensure that they have a real value to work with.
Added field.attname to Options.name_map

The change also removed allow_explicit_fk from sql/query.py.
Fixed #11521 -- usage of field.attname in .update()

Fixed already by previous patch, only test added.
Fixed #15624 -- Made sure aggregations are present in SELECT
Added a bugfix in docutils 0.11 -- docs will now build properly.
Fixed #20826 -- Moved Manager.raw() and Manager._insert() to the QuerySet class.
Fixed #19987 -- Disabled host validation when DEBUG=True.

The documentation promises that host validation is disabled when
DEBUG=True, that all hostnames are accepted. Domains not compliant with
RFC 1034/1035 were however being validated, this validation has now been
removed when DEBUG=True.

Additionally, when DEBUG=False a more detailed SuspiciousOperation
exception message is provided when host validation fails because the
hostname is not RFC 1034/1035 compliant.
Fixed #12103 -- Added AuthenticationForm.confirm_login_allowed to allow customizing the logic policy.

Thanks ejucovy and lasko for work on the patch.
Fixed #20649 -- Allowed blank field display to be defined in the initial list of choices.
Removed unused model option "admin"
Fixed #20667 - Removed discussion of DEBUG from tutorial.

Forward-port of 3493f18d78 from master.
Fixed #17519 -- Fixed missing SQL constraints to proxy models.

Thanks thibaultj for the report, jenh for the patch,
and charettes for the tests.
Fixed #18777 -- Localized form fields with as_text/as_hidden

Thanks croldan for the report.
Fixed #20838 -- Fixed Geodjango spatialrefsys test failure with postgis-2.0.3