gbv / jskos-proxy

HTTP proxy to serve JSKOS objects
https://uri.gbv.de/terminology/
MIT License
3 stars 2 forks source link

External uri's not working for single records #24

Closed StiftungAusNachlass closed 1 year ago

StiftungAusNachlass commented 1 year ago

If the URI is an external URI, then the application does not resolve it.

Example: https://uri.gbv.de/terminology/?uri=https://obersuperdatensatz23.gbv.de

That is: https://api.dante.gbv.de/data?uri=https%3A%2F%2Fobersuperdatensatz23.gbv.de&properties=*&cache=0

nichtich commented 1 year ago

This is a nasty edge case. It's not because the URI is external but because https://obersuperdatensatz23.gbv.de is normalized to URL https://obersuperdatensatz23.gbv.de/ by Node URL.

StiftungAusNachlass commented 1 year ago

Waah, sounds ugly. But https://obersuperdatensatz23.gbv.de is a valid URI. The URL parameter is usually encoded. Above is only in standard form. Why is Node normalizing an encoded url here? It should actually go into the parameter without any manipulation.

Ok - does not matter. There will never be a URI ending with just the tld. I changed to https://uri.gbv.de/terminology/?uri=https://obersuperdatensatz23.gbv.de/123 and that works..