aim icon indicating copy to clipboard operation
aim copied to clipboard

Img load failure when AIM_UI_BASE_PATH is changed

Open ptaejoon opened this issue 2 years ago • 2 comments

🐛 Bug

https://github.com/aimhubio/aim/blob/main/aim/web/configs.py#L8 Changing AIM_UI_BASE_PATH causes failure on loading imgs. loading imgs below : /static-files/static/media/experiments.d7187189.svg /static-files/static/media/runs.eaf7976b.svg returned 404 error

To reproduce

  1. aim up after set AIM_UI_BASE_PATH to another name (ex. aim up --base-path="1234")
  2. visit web-ui (ex. visit /1234)
  3. check web-console (there will be error-msgs with 404)

Expected behavior

There should be no failure on loading imgs

Environment

  • Aim Version : 3.5
  • Python version : 3.8
  • pip version
  • OS (e.g., Linux) : Mac
  • Any other relevant information

Additional context

This is when base-url is changed 스크린샷 2022-02-15 오후 5 29 59

This is when base-url is set to default 스크린샷 2022-02-15 오후 5 32 31

this issue came from below: https://aimstack.slack.com/archives/C02V1DJV2BH/p1644914072221839

ptaejoon avatar Feb 15 '22 08:02 ptaejoon

Thanks @ptaejoon for raising the issue! @Hamik25 could you please share additional context regarding this issue? Lets also explore possible approaches to fix.

alberttorosyan avatar Feb 15 '22 10:02 alberttorosyan

The issue is related with import SVG files from CSS files during loading SVG files our CSS loader doesn't know about the base path and the base path is not included in GET request URL for these SVG files at the same time static server return 404 because it knows about the base path and serves only request under the base path.

Hamik25 avatar Feb 17 '22 09:02 Hamik25

Closing this issue as the Home page was redesigned.

roubkar avatar Mar 14 '23 09:03 roubkar