Skip to content

Patching a field on a model with a ManyToManyField removes the related objects #2829

@pyeekwr

Description

@pyeekwr

I am currently on drf 3.0

I am running into an issue where when I am trying to PATCH a field on a model with a ManyToManyField, the model serializer produces a deserialization where the related many to many relation gets removed, even though the field payload does not include the many to many field. Is this intended behavior? or am I configuring this incorrectly?

Test case

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions