Issue #2202887 by jonathan1055: For drupal_debug.txt use file_directory_temp() not 'temporary://'.