Skip to content

Nested Object POST Request Uninformative Error Messages  #8077

@WillJeynes

Description

@WillJeynes

API Platform version(s) affected: 3.0.10

Description
When trying to create an object with a one to many relationship by nesting child objects in an array getting error message 'Nested documents for attribute "attributes" are not allowed. Use IRIs instead.'. The cause of this error is not having a remove attributes function, which is never called and this actual problem is not hinted at in the error.

How to reproduce
Make a one to many relationship in doctrine and remove the removeWhatever function in the parent class. Set up a group for a post request. Try to add an element.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions