Skip to content

Commit

Permalink
[BUGFIX] Redirect slash when defining ARGILLA_BASE_URL (#5796)
Browse files Browse the repository at this point in the history
# Description
<!-- Please include a summary of the changes and the related issue.
Please also include relevant motivation and context. List any
dependencies that are required for this change. -->

Closes #5792

**Type of change**
<!-- Please delete options that are not relevant. Remember to title the
PR according to the type of change -->

- Bug fix (non-breaking change which fixes an issue)

**How Has This Been Tested**
<!-- Please add some reference about how your feature has been tested.
-->

**Checklist**
<!-- Please go over the list and make sure you've taken everything into
account -->

- I added relevant documentation
- I followed the style guidelines of this project
- I did a self-review of my code
- I made corresponding changes to the documentation
- I confirm My changes generate no new warnings
- I have added tests that prove my fix is effective or that my feature
works
- I have added relevant notes to the CHANGELOG.md file (See
https://keepachangelog.com/)
  • Loading branch information
frascuchon authored Jan 28, 2025
1 parent 8e29938 commit 105888a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion argilla-server/src/argilla_server/_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ def create_server_app() -> FastAPI:
# This if-else clause is needed to simplify the test dependency setup. Otherwise, we cannot override dependencies
# easily. We can review this once we have separate fastapi application for the api and the webapp.
if settings.base_url and settings.base_url != "/":
_app = FastAPI(docs_url=None, redoc_url=None, openapi_url=None, redirect_slashes=False)
_app = FastAPI(docs_url=None, redoc_url=None, openapi_url=None, redirect_slashes=True)
_app.mount(settings.base_url, app)
return _app
else:
Expand Down

0 comments on commit 105888a

Please sign in to comment.