From 7b10a928e0c1f0fd73b44e4e8d939fdfb55e06f8 Mon Sep 17 00:00:00 2001 From: Eetu Purontaus Date: Tue, 1 Sep 2026 14:53:36 +0300 Subject: [PATCH] Clarify that only required=True conflicts with default --- docs/api-guide/fields.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/api-guide/fields.md b/docs/api-guide/fields.md index 8f88cef361..7bbc0b2fc7 100644 --- a/docs/api-guide/fields.md +++ b/docs/api-guide/fields.md @@ -63,7 +63,7 @@ For example: When serializing the instance, default will be used if the object attribute or dictionary key is not present in the instance. -Note that setting a `default` value implies that the field is not required. Including both the `default` and `required` keyword arguments is invalid and will raise an error. +Note that setting a `default` value implies that the field is not required. Combining `default` with `required=True` is invalid and will raise an error. An explicit `required=False` alongside `default` is allowed, but redundant. ### `allow_null`