Paul Okoli
Paul Okoli

Reputation: 101

whitenoise.storage.MissingFileError: The JS file 'drf-yasg\redoc\redoc.min.js' references a file which could not be found

I tried collecting static files on an API project I am working with Django/Django REST Framework and I got this error on my console. What could be the cause of the error?

raise processed whitenoise.storage.MissingFileError: The file 'drf-yasg/redoc/redoc.standalone.js.map' could not be found with <whitenoise.storage.CompressedManifestStaticFilesStorage object at 0x000002DEED19E050>.

The JS file 'drf-yasg\redoc\redoc.min.js' references a file which could not be found: drf-yasg/redoc/redoc.standalone.js.map

Please check the URL references in this JS file, particularly any relative paths which might be pointing to the wrong location. enter image description here

Upvotes: 2

Views: 1756

Answers (1)

Paul Okoli
Paul Okoli

Reputation: 101

I have figured out the cause of this error. I was working with Django==4.0, I had to downgrade it to Django==3.2.9 and the error disappeared.

Upvotes: 5

Related Questions