Created attachment 10895 [details] Suggested patch The hostname for objects in the kelvin api is case sensitive The function "unscheme_and_unquote" in "kelvin-api/ucsschool/kelvin/routers/user.py" is used to normalize urls identifying school objects. The function does not normalize the case of the domain name. This results in exceptions from the "url_to_name" function in "kelvin-api/ucsschool/kelvin/urls.py" if the calculated url and given url differ in case, even if they refer to the same object. The attached patch normalizes the domainname case. Some notes: I think it would be nice if we rename the "unscheme_and_unquote" function to something like "normalize_url". I was expecting that unscheme meant that the scheme will be completely removed, instead it is changed to http. The "NoObject" exception from "url_to_name" should also include the calculated url ("calc_url"). That would have made debugging, a lot easier.
There is already an issue and a MR to fix this problem: * https://git.knut.univention.de/univention/components/ucsschool-kelvin-rest-api/-/issues/105 * https://git.knut.univention.de/univention/components/ucsschool-kelvin-rest-api/-/merge_requests/92
The fix has been published with Kelvin version 1.9.0.