Compare commits
3 Commits
fix/dev-st
...
fix/dev-wh
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
800475cf36
|
||
| 36eb0f1dd2 | |||
|
|
f950e3cd5e
|
@@ -4,6 +4,13 @@ DEBUG = True
|
|||||||
|
|
||||||
INTERNAL_IPS = ["127.0.0.1"]
|
INTERNAL_IPS = ["127.0.0.1"]
|
||||||
|
|
||||||
|
# In dev, drop WhiteNoise from middleware and use plain static file storage.
|
||||||
|
# WhiteNoise serves from STATIC_ROOT which is empty without collectstatic,
|
||||||
|
# so it intercepts every /static/ request and returns nothing.
|
||||||
|
# Django's runserver handles static files natively when DEBUG=True.
|
||||||
|
MIDDLEWARE = [m for m in MIDDLEWARE if m != "whitenoise.middleware.WhiteNoiseMiddleware"]
|
||||||
|
STATICFILES_STORAGE = "django.contrib.staticfiles.storage.StaticFilesStorage"
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import debug_toolbar # noqa: F401
|
import debug_toolbar # noqa: F401
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user