WPIntell

Source evidence

SCRIPT_DEBUG (breaks wp-admin with caching/CDN)

Debug Log Manager – Conveniently Monitor and Inspect Errors · support · 2025-09-11T08:00:00+00:00

mixedsentiment
mediumseverity
0.85relevance
2replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

6 / 35 rows with source links

17.1% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

29 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
Christine resolved
Hello Wibowo, we love using Debug Log Manager for quick log handling. We’ve run into a reproducible issue in production: Issue When we enable error logging, the plugin also writes define(‘SCRIPT_DEBUG’, true); into wp-config.php. This makes WordPress load unminified development bundles in wp-admin (e.g., Rank Math). In our environment with caching/CDN (BunnyCDN + WP Fastest Cache; Perfmatters currently disabled) and stricter headers, those dev bundles become fragile (timing/chunk loading), leading to console errors like __webpack_require__ is not defined / module is not defined, and our cookie banner fails to initialize. Why this shows up in our setup Because of the caching/CDN layers, chunked dev assets loaded under SCRIPT_DEBUG = true are more sensitive. With SCRIPT_DEBUG = false, wp-admin is stable. Reproduction Enable logging in Debug Log Manager The plugin writes SCRIPT_DEBUG = true to wp-config.php Reload /wp-admin/ (e.g., Rank Math page) → admin assets break (errors above), cookie banner won’t load Workaround Manually restore SCRIPT_DEBUG to false → wp-admin is stable again. But the plugin may overwrite it the next time logging is toggled. Feature request Please add a way to enable WP_DEBUG / WP_DEBUG_LOG without touching SCRIPT_DEBUG. For example: a checkbox “Do not modify SCRIPT_DEBUG” (default off), or a filter/constant the site owner can set, e.g.: if (apply_filters(‘dlm_modify_script_debug’, true)) { // only change SCRIPT_DEBUG when true } // or honor a guard: if (defined(‘SCRIPT_DEBUG_LOCK’) && SCRIPT_DEBUG_LOCK) { /* do not change SCRIPT_DEBUG */ } We’re happy to provide headers/console screenshots or test a beta build. Thanks a lot! Christine The page I need help with: [ log in to see the link] @weddingstyle thanks for reporting this. I’ve just released v2.4.0 that adds an option at the bottom of the DLM dashboard to not modify SCRIPT_DEBUG when toggling error logging on/off. Please test. If you find DLM useful for your work, please consider writing a quick review for it at https://wordpress.org/plugins/debug-log-manager/#reviews . Thank you. WOWWWWW! That was fast! Thank you so much for your help!

Comments

2 shown
Bowo 2025-09-12T08:09:00+00:00

@weddingstyle thanks for reporting this. I’ve just released v2.4.0 that adds an option at the bottom of the DLM dashboard to not modify SCRIPT_DEBUG when toggling error logging on/off. Please test. If you find DLM useful for your work, please consider writing a quick review for it at https://wordpress.org/plugins/debug-log-manager/#reviews . Thank you.

Christine 2025-09-13T15:38:00+00:00

WOWWWWW! That was fast! Thank you so much for your help!