-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
6.14.0
Description of problem:
When I use an API call to create an organization and I specify an existing, but incorrect content-type (or I don't specify any at all), the call returns 500 Internal Server Error.
Version-Release number of selected component (if applicable):
Reproduced on Sat 6.14 snap 9.0, 10.0, but not 8.0.
How reproducible:
Deterministic
Steps to Reproduce:
1. # curl -uadmin:changeme -H 'Content-Type: application/json' -X POST https://$(hostname)/api/organizations -d '{"organization": {"name": "test1"}}'
{"select_all_types":[],"description":null,"created_at":"2023-08-03 10:51:04 UTC"
[...]
2. # curl -uadmin:changeme -H 'Content-Type: text/html' -X POST https://$(hostname)/api/organizations -d '{"organization": {"name": "test2"}}'
{
"error":
}
3. # curl -uadmin:changeme -H 'Content-Type: text/html' -X POST https://$(hostname)/api/locations -d '{"location": {"name": "test3"}}'
{
"error":
}
Actual results:
For correct content-type, the organization is created. For incorrect type on a location endpoint, a location is not created and the error is handled correctly. For incorrect type on an organization endpoint, ISE happens.
Expected results:
The same behavior as for locaiton.
Additional info:
Traceback attached.