Ignore Missing Files

This commit is contained in:
Juhn-Vitus Saß
2025-04-06 22:24:15 +02:00
parent 95f2a82532
commit f264d10cb8

View File

@@ -142,8 +142,11 @@ STATIC_URL = '/static/'
STATIC_ROOT = BASE_DIR / "staticfiles" STATIC_ROOT = BASE_DIR / "staticfiles"
STATICFILES_DIRS = [BASE_DIR / 'static'] STATICFILES_DIRS = [BASE_DIR / 'static']
# Exclude development CSS files from collectstatic # WhiteNoise configuration
STATICFILES_IGNORE_PATTERNS = ['t-input.css'] STATICFILES_STORAGE = 'whitenoise.storage.CompressedStaticFilesStorage'
WHITENOISE_SKIP_COMPRESS_EXTENSIONS = ['css', 'js']
# Return 404 instead of 500 for missing files
WHITENOISE_MISSING_FILE_ERRNO = None
# Default primary key field type # Default primary key field type
# https://docs.djangoproject.com/en/5.1/ref/settings/#default-auto-field # https://docs.djangoproject.com/en/5.1/ref/settings/#default-auto-field