djk2 / django-admin-shell

Django/Python shell for django admin site.
MIT License
77 stars 11 forks source link

Missing bootstrap.min.css.map #8

Closed MourguesBenjamin closed 10 months ago

MourguesBenjamin commented 1 year ago

Hello,

Using whitenoise to serve my static file, it seems I can't launch my server because of a missing static file, here is the traceback:

https://github.com/djk2/django-admin-shell/blob/ed65289e1173fd1af4ef102b4740d0d010cf6a48/django_admin_shell/static/django_admin_shell/css/bootstrap3.min.css#L6

 2023-09-18 13:20:30,142 INFO spawned: 'run-app' with pid 80
 Hotpatching App Insight instrumentation key
 + echo 'Hotpatching App Insight instrumentation key'
 + basedir=/home/fbox/uc7/frontend
 + sed -i -e 's|APP_INSIGHT_CONNECTION_STRING_PLACEHOLDER||g' /home/fbox/uc7/frontend/static/index-c88f43b4.js
 + '[' '!' -z 1 ']'
 + rm -rf static-files/admin static-files/debug_toolbar static-files/django_admin_shell static-files/django_extensions static-files/fonts static-files/images static-files/import_export static-files/index-695e406c.css static-files/index-c88f43b4.js static-files/index.html static-files/mptt static-files/north-oil-5d6244e7.png static-files/north-oil.png static-files/poppins-all-400-normal-c68e1edb.woff static-files/poppins-all-600-normal-952d2591.woff static-files/poppins-devanagari-400-normal-478b3ab7.woff2 static-files/poppins-devanagari-600-normal-d036ece3.woff2 static-files/poppins-latin-400-normal-7d93459d.woff2 static-files/poppins-latin-600-normal-f4e80d9d.woff2 static-files/poppins-latin-ext-400-normal-cb8bdeab.woff2 static-files/poppins-latin-ext-600-normal-9c15f7b0.woff2 static-files/rest_framework static-files/static static-files/styles static-files/user-guide.pdf
 + python manage.py collectstatic --noinput --settings=uc7.settings.development
 System check identified some issues:

 WARNINGS:
 ?: (staticfiles.W004) The directory '/home/fbox/uc7/static-files/static' in the STATICFILES_DIRS setting does not exist.
 Post-processing 'django_admin_shell/css/bootstrap3.min.css' failed!

 Traceback (most recent call last):
   File "/home/fbox/uc7/manage.py", line 27, in <module>
     main()
   File "/home/fbox/uc7/manage.py", line 23, in main
     execute_from_command_line(sys.argv)
   File "/home/fbox/env/lib/python3.10/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
     utility.execute()
   File "/home/fbox/env/lib/python3.10/site-packages/django/core/management/__init__.py", line 440, in execute
     self.fetch_command(subcommand).run_from_argv(self.argv)
   File "/home/fbox/env/lib/python3.10/site-packages/django/core/management/base.py", line 402, in run_from_argv
     self.execute(*args, **cmd_options)
   File "/home/fbox/env/lib/python3.10/site-packages/django/core/management/base.py", line 448, in execute
     output = self.handle(*args, **options)
   File "/home/fbox/env/lib/python3.10/site-packages/django/contrib/staticfiles/management/commands/collectstatic.py", line 209, in handle
     collected = self.collect()
   File "/home/fbox/env/lib/python3.10/site-packages/django/contrib/staticfiles/management/commands/collectstatic.py", line 154, in collect
     raise processed
 whitenoise.storage.MissingFileError: The file 'django_admin_shell/css/bootstrap.min.css.map' could not be found with <whitenoise.storage.CompressedManifestStaticFilesStorage object at 0x7fef24aedff0>.

 The CSS file 'django_admin_shell/css/bootstrap3.min.css' references a file which could not be found:
   django_admin_shell/css/bootstrap.min.css.map

 Please check the URL references in this CSS file, particularly any
 relative paths which might be pointing to the wrong location.
MourguesBenjamin commented 1 year ago

Removing this line

https://github.com/djk2/django-admin-shell/blob/ed65289e1173fd1af4ef102b4740d0d010cf6a48/django_admin_shell/static/django_admin_shell/css/bootstrap3.min.css#L6

Fixed the issue for me.

djk2 commented 10 months ago

New version v2.0.1 contains bootstrap.min.css.map