1
0
mirror of https://github.com/django/django.git synced 2024-12-28 20:16:19 +00:00
Commit Graph

573 Commits

Author SHA1 Message Date
sage
2d8dcba03a Fixed #31829 -- Used JSONField __contains lookup on key transforms. 2020-07-28 13:10:12 +02:00
Mariusz Felisiak
ba691933ce
Fixed #31836 -- Dropped support for JSONField __contains and __contained_by lookups on SQLite.
The current implementation works only for basic examples without
supporting nested structures and doesn't follow "the general principle
that the contained object must match the containing object as to
structure and data contents, possibly after discarding some
non-matching array elements or object key/value pairs from the
containing object".
2020-07-28 13:06:52 +02:00
Mariusz Felisiak
02447fb133
Fixed #31835 -- Dropped support for JSONField __contains lookup on Oracle.
The current implementation works only for basic examples without
supporting nested structures and doesn't follow "the general principle
that the contained object must match the containing object as to
structure and data contents, possibly after discarding some
non-matching array elements or object key/value pairs from the
containing object".
2020-07-28 11:54:01 +02:00
Adam Johnson
5ef6f62634 Refs #31502 -- Made minor edits to Model._state docs. 2020-07-16 20:50:53 +02:00
Adam Johnson
e906ff6fca Fixed #30457 -- Added TestCase.captureOnCommitCallbacks(). 2020-07-13 11:56:46 +02:00
MansurAliKoroglu
d88952142b Adjusted multi-db example to avoid confusion with DATABASES keys. 2020-07-03 12:41:00 +02:00
David Smith
dbdc192ca3 Preferred usage of among/while to amongst/whilst. 2020-06-03 21:02:48 +02:00
David Smith
06c8565a46
Updated link to Celery. 2020-06-02 14:37:16 +02:00
Nikita Sobolev
682b295c6c
Made small improvement to docs/topics/db/multi-db.txt. 2020-06-01 10:20:00 +02:00
Jon Dufresne
494ba27b5f
Changed some doc links to use intersphinx. 2020-05-29 21:09:57 +02:00
Carlton Gibson
5af17babb0
Fixed #31591 -- Clarified "reverse" lookup name in making queries docs. 2020-05-19 20:27:05 +02:00
Nick Pope
a9337b4add Used :pep: role in various docs. 2020-05-13 09:14:04 +02:00
sage
6789ded0a6 Fixed #12990, Refs #27694 -- Added JSONField model field.
Thanks to Adam Johnson, Carlton Gibson, Mariusz Felisiak, and Raphael
Michel for mentoring this Google Summer of Code 2019 project and
everyone else who helped with the patch.

Special thanks to Mads Jensen, Nick Pope, and Simon Charette for
extensive reviews.

Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2020-05-08 07:23:31 +02:00
Adam Johnson
d17b380653 Refs #30573 -- Rephrased "Of Course" and "Obvious(ly)" in documentation and comments. 2020-05-04 12:10:47 +02:00
Greg Kaleka
5d2f5dd4cc Doc'd Meta inheritance from abstract parents. 2020-05-01 07:48:50 +02:00
Hasan Ramezani
33f7739108 Fixed #31356 -- Changed IRC links to the Freenode webchat. 2020-04-29 20:08:36 +02:00
Simon Charette
fa5e7e46d8 Fixed #31423 -- Clarified nested atomic() example. 2020-04-04 20:39:33 +02:00
Hannes Ljungberg
f3da09df0f Fixed #31396 -- Added binary XOR operator to F expressions. 2020-03-25 10:16:30 +01:00
Philipp Bosch
f75af5b67b Corrected outdated sentence in One-to-one relationships docs. 2020-03-17 10:49:37 +01:00
Adam Radwon
a2f554249e
Fixed #27865 -- Adjusted docs example to avoid confusion with models.BaseManager. 2020-03-10 09:14:30 +01:00
Shrikrishna Singh
370628673b
Fixed #31350 -- Fixed typo in docs/topics/db/optimization.txt. 2020-03-09 07:54:25 +01:00
Carlton Gibson
08a6215d33 Fixed #31342 -- Clarified docs about using base managers for related objects. 2020-03-06 11:08:08 +01:00
Matheus Cunha Motta
0352a44dd6 Fixed #31303 -- Removed outdated note about symmetrical intermediate table for self-referential ManyToManyField.
Follow up to 87b1ad6e73.
2020-02-24 08:26:29 +01:00
Jon Dufresne
958977f662 Fixed #31212 -- Updated psycopg links to HTTPS and new location. 2020-01-29 06:25:40 +01:00
Mariusz Felisiak
d202846ced
Refs #29998 -- Corrected auto-created OneToOneField parent_link in MTI docs. 2020-01-15 15:07:07 +01:00
Adam Johnson
2ea3fb3e63 Removed "Don't do that" from docs and error messages.
It's slightly aggressive and doesn't explain itself.
2020-01-06 13:50:43 +01:00
Jon Dufresne
5e00bd1f77 Removed unnecessary code-block directives in various docs. 2019-12-23 14:47:13 +01:00
Sergey Fedoseev
abc51d44af Used 🎫 role in all tickets links. 2019-11-26 14:02:24 +01:00
Caio Ariede
608e06023e Fixed #27164 -- Fixed an example of using routers in multiple databases docs.
Make sure that AuthRouter includes ContentType in the same database.
2019-11-20 11:43:14 +01:00
Simon Charette
11e327a3ff Fixed #30988 -- Deprecated the InvalidQuery exception.
It was barely documented without pointers at its defining location and
was abused to prevent misuse of the QuerySet field deferring feature.
2019-11-18 14:06:51 +01:00
David Foster
6a04e69e68 Fixed #30828 -- Added how to remove/insert many-to-many relations in bulk to the database optimization docs. 2019-11-12 12:44:41 +01:00
René Fleschenberg
367634f976 Replaced 'n_' prefix with 'number_of_' in docs/topics/db/queries.txt. 2019-11-07 09:22:13 +01:00
Mariusz Felisiak
e5cacb1f47 Refs #30947 -- Changed tuples to lists in model Meta options examples in docs.
Follow up to 97d3321e89.
2019-11-04 10:20:30 -08:00
Mariusz Felisiak
a370dbd954
Corrected error message in Many-to-many relationships docs. 2019-10-30 16:17:20 +01:00
Simon Charette
35396a7f24 Refs #26207 -- Removed obsolete note about slow constructing a model with deferred fields.
This is not true since 7f51876 removed the necessity of creating
proxy model classes at runtime for each deferred field sets.
2019-10-14 12:51:07 +02:00
Mariusz Felisiak
0ddb4ebf7b Refs #14357 -- Made Meta.ordering not affect GROUP BY queries.
Per deprecation timeline.
2019-09-10 12:01:00 +02:00
Mariusz Felisiak
416c584cab Removed versionadded/changed annotations for 2.2. 2019-09-10 12:01:00 +02:00
Tobias Kunze
4a954cfd11 Fixed #30573 -- Rephrased documentation to avoid words that minimise the involved difficulty.
This patch does not remove all occurrences of the words in question.
Rather, I went through all of the occurrences of the words listed
below, and judged if they a) suggested the reader had some kind of
knowledge/experience, and b) if they added anything of value (including
tone of voice, etc). I left most of the words alone. I looked at the
following words:

- simply/simple
- easy/easier/easiest
- obvious
- just
- merely
- straightforward
- ridiculous

Thanks to Carlton Gibson for guidance on how to approach this issue, and
to Tim Bell for providing the idea. But the enormous lion's share of
thanks go to Adam Johnson for his patient and helpful review.
2019-09-06 13:27:46 +02:00
Shai Berger
72ebe85a26 Fixed #27910 -- Added enumeration helpers for use in Field.choices.
These classes can serve as a base class for user enums, supporting
translatable human-readable names, or names automatically inferred
from the enum member name.

Additional properties make it easy to access the list of names, values
and display labels.

Thanks to the following for ideas and reviews:

Carlton Gibson, Fran Hrženjak, Ian Foote, Mariusz Felisiak, Shai Berger.

Co-authored-by: Shai Berger <shai@platonix.com>
Co-authored-by: Nick Pope <nick.pope@flightdataservices.com>
Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2019-09-04 14:42:49 +02:00
Dan Swain
cece802dbb Corrected typo in search docs. (#11673) 2019-08-20 10:37:48 +02:00
daniel a rios
68aeb90160 Fixed #30656 -- Added QuerySet.bulk_update() to the database optimization docs. 2019-07-29 09:52:29 +02:00
daniel a rios
fe33fdc049 Refs #30656 -- Reorganized bulk methods in the database optimization docs. 2019-07-29 09:52:29 +02:00
Meysam
833878411c Fixed typo in docs/topics/db/models.txt. 2019-06-24 09:04:33 +02:00
Caio Ariede
5248abe9b0 Fixed #30505 -- Doc'd how changes in the order of Field.choices affect migrations. 2019-06-04 14:11:41 +02:00
Mariusz Felisiak
b6c4766f53
Refs #29548 -- Updated docs for MariaDB support. 2019-05-27 19:59:49 +02:00
Akshesh
888fdf182e Fixed #30419 -- Favored Meta.indexes over Meta.index_together in optimization docs. 2019-05-22 07:34:54 +02:00
Jon Dufresne
e86cc14bd3 Changed docs to link to Python's description of iterable. 2019-05-17 17:27:19 +02:00
Jon Dufresne
97d3321e89 Changed tuple choices to list in docs. 2019-05-15 14:31:42 +02:00
Przemysław Suliga
af5ec222cc Used time.monotonic() instead of time.time() where applicable.
time.monotonic() available from Python 3.3:

- Nicely communicates a narrow intent of "get a local system monotonic
  clock time" instead of possible "get a not necessarily accurate Unix
  time stamp because it needs to be communicated to outside of this
  process/machine" when time.time() is used.
  
- Its result isn't affected by the system clock updates.

There are two classes of time.time() uses changed to time.monotonic()
by this change:

- measuring time taken to run some code.

- setting and checking a "close_at" threshold for for persistent db
  connections (django/db/backends/base/base.py).
2019-05-08 18:34:22 +02:00
Daniel Musketa
6fd9c9daa6 Fixed #30365 -- Fixed syntax highlighting in SQL examples.
Sphinx interprets some "%[a-z]" in SQL statements as a
"Literal.String.Interpol" which leads to incorrect highlighting.
2019-04-23 12:37:50 +02:00