Skip to content

Incorrect type. Expected pk value, received OrderedDict when updating a relationship #111

@schtibe

Description

@schtibe

I get this error:

{'errors': [{'detail': 'Incorrect type. Expected pk value, received '
                   'OrderedDict.',
         'source': {'pointer': '/data/attributes/title'},
         'status': '400'}]}

since commit d654c75 when I run my unit test. The data I send is

    data = {
        "data": {
            "type": "customers",
            "id":   self.lukeId,
            "relationships": {
                "title": {
                    "data": { "type": "titles", "id": "2" }
                }
            }
        }
    }

What is that change for / is my data wrong?

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