Skip to content

JSON decode error deleting an organization when its id is missing from a request. #18665

Open
@gshif

Description

@gshif

Response error json object should always return error code and error message in case of the error.
When organization id (required) is missing from delete organization request then response.json() is returning JSONDecodeError

Repro:

  • Delete request:
     base_url=http://localhost:9999
     path=/api/v2/orgs/
     auth=None
     headers={'Authorization': 'Token Ndm22KCx8Te05YD3UsoA2_HOQeagonlRM6zOWureORyGTEpKkcYpbWiR9BZvvCm8_Pp4FTyZLJCntKzdgJ1aqg=='}
     timeout=None
     verify=False
    

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions