galaxy icon indicating copy to clipboard operation
galaxy copied to clipboard

Trailing slashes on galaxy_url_prefix are no longer stripped/collapsed after upgrade to starlette 0.35.1

Open natefoo opened this issue 2 years ago • 0 comments

Describe the bug After the starlette upgrade in 0c0da9c821e81ee3e077b70c52c7bf180036333f, trailing slashes in galaxy_url_prefix are no longer stripped/collapsed/ignored as they were before. As a result, if set to /prefix/, the URL must also contain the trailing slash, e.g. http://localhost:8080/prefix//api/version or you get a 404.

Galaxy Version and/or server at which you observed the bug Galaxy Version: 24.0 dev Commit: 9c3a02037fef6680594efedea5f4cbf96a30b6fb

To Reproduce Steps to reproduce the behavior:

  1. Set galaxy_url_prefix: /prefix/ in galaxy.yml
  2. Start galaxy and curl http://localhost:8080/prefix/api/version (fails), then curl http://localhost:8080/prefix//api/version (succeeds)
  3. Downgrade to 24b90be3d8f71998055eeb91afc3a140c54e709b and pip install -r requirements.txt
  4. Start galaxy and repeat curls, both succeed.

Expected behavior Trailing slashes are not required to be part of the URL.

Screenshots N/A

Additional context This was initially caught by the tests on galaxyproject/gravity#116

natefoo avatar Feb 06 '24 18:02 natefoo