mediacms-io / mediacms

MediaCMS is a modern, fully featured open source video and media CMS, written in Python/Django and React, featuring a REST API.
https://mediacms.io
GNU Affero General Public License v3.0
2.86k stars 532 forks source link

Error when viewing video details after rebuilding the static frontend folder to the static web folder #1045

Open harryitc opened 3 months ago

harryitc commented 3 months ago

Describe the issue

When I first clone the project and run it using the .yaml file docker-compose-dev.yaml, everything works fine. However, a problem occurs when I use the command npm run build. After build success, I go to the domain http://localhost:80/view?m={mediaID}, and it doesn't work when I click on some media in the list.

To Reproduce

Steps to reproduce the issue: (i followed by Develop_docs.md )

  1. Run docker-compose -f docker-compose-dev.yaml up
  2. In the frontend folder, runnpm run build (or docker-compose -f docker-compose-dev.yaml exec frontend npm run dist)
  3. Copy the contents of frontend/dist/static/ to the static/ folder in the root: cp -r frontend/dist/static/* static/
  4. Restart the web service: docker-compose -f docker-compose-dev.yaml restart web
  5. Go to http//localhost/user/{username} and choose a random media item in the "My Media" tab.
  6. Observe the error below

Screenshots

image image

Environment

khaphan-github commented 3 months ago

Me too! I can't view the detailed error to troubleshoot it.

ycmin95 commented 1 month ago

I encountered a similar problem, and my solution was to install the dependencies that are consistent with the package-lock.json file.