Hello,
I started rebuilding my old plugin "User related debugmodus" for use in Moodle 3.5.
This plugin is simple but very useful if you only need a debugging mode for specific users. This is often required in production environments where debug mode can not easily be globally enabled.
You can get this plugin from the plugin database: https://moodle.org/plugins/view.php?id=462
Best regards
Andreas