cheshire-cat-ai / core

Production ready AI agent framework
https://cheshirecat.ai
GNU General Public License v3.0
2.28k stars 305 forks source link

Fix trailing slashes generating infinite redirect. #817

Closed ggiallo28 closed 4 months ago

ggiallo28 commented 4 months ago

Description

Fix trailing slashes generating infinite redirect. Update FastAPI groups and public static page assets references.

Related to issue #(issue)

Type of change

Checklist:

pieroit commented 4 months ago

Thanks @ggiallo28 !!

@nicola-corbellini @zAlweNy26 do you thik the client libs will break by fixing these trailing slashes?

nicola-corbellini commented 4 months ago

no idea, we can test it in the develop branch maybe

zAlweNy26 commented 4 months ago

To be sure I will probably update the TS client, anyway it should not break anything

ggiallo28 commented 4 months ago

I ran the tests and they seem to have passed.

One thing I am experiencing right now is that the admin client returns "not found" on the plugin page if you are already there and refresh the page, while it works correctly when you go on the plugins using navigation.

zAlweNy26 commented 4 months ago

Did you try removing the trailing slash in the code where we mount the admin?

pieroit commented 4 months ago

Please PR branching off from develop! Otherwise a lot of unwanted commits end up in the PR