Last active
January 13, 2025 18:56
-
-
Save prappo/894fb83f6ffcce95138167c4fdaa3113 to your computer and use it in GitHub Desktop.
Enable WordPress debugging and map debug.log file for wp-env
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"plugins": ["."], | |
"config": { | |
"WP_DEBUG": true, | |
"WP_DEBUG_LOG": true, | |
"SCRIPT_DEBUG": true, | |
"WP_DEBUG_DISPLAY": true, | |
"WP_PHP_BINARY": "php" | |
}, | |
"mappings": { | |
"wp-content/debug.log": "./debug.log" | |
} | |
} |
I had the same issue
Hi @greenworld, I use another way to fix it
"config": {
"WP_DEBUG": true,
"WP_DEBUG_DISPLAY": true,
"SCRIPT_DEBUG": false,
"WP_DEBUG_LOG": "/var/www/html/wp-content/plugins/[plugin-slug]/debug.log"
}
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you for a useful config snippet
Mapping is not working properly for me (directory
./debug.log
is created instead of file) to fix need to remove folder and create locally file./debug.log
with appropriate permissions