ontoportal-lirmm / ontologies_api

Hypermedia API for ontologies
http://data.agroportal.lirmm.fr/
Other
2 stars 7 forks source link

Fix: remove duplicated agents root #85

Closed Bilelkihal closed 1 month ago

Bilelkihal commented 2 months ago

Related issue: https://github.com/agroportal/project-management/issues/471

Related GOO PR: https://github.com/ontoportal-lirmm/goo/pull/62

Bilelkihal commented 2 months ago

I tested also the UI with ontologies_api_ruby_client and it's doing calls using the lowercase /agents, see the screenshot below image

Bilelkihal commented 2 months ago

@syphax-bouazzouni You can merge it

Bilelkihal commented 2 months ago

Yes deploy it, so I can debug it in ontologies_api_ruby_client

syphax-bouazzouni commented 2 months ago

I tested also the UI with ontologies_api_ruby_client and it's doing calls using the lowercase /agents, see the screenshot below image

@Bilelkihal here try the call to find one Agent.

I deployed this branch in stage, so that can do you tests

image
syphax-bouazzouni commented 2 months ago

The unique issue that I found with removing the Agents endpoint is not in the UI but in the API if you go to https://data.stageportal.lirmm.fr/agents endpoint and click on one of the IDs, it will return a not found page. Example: https://data.stageportal.lirmm.fr/Agents/565540a0-3018-013c-5eb5-5254007cab39

image
Bilelkihal commented 2 months ago

The problem is not only in the object Agent, but also for the AgentIdentifier for example and I believe some more others and the problem was here in GOO project the method uuid_uri_generator, we need to downcase the modelname before passing it to the URI:

image

I'll create a PR in GOO project for this

Bilelkihal commented 2 months ago

Done ✅