<commit_before>set_error_handler( function( $errno, $errstr, $errfile, $errline, $errcontext ) {
	$err = "Error: $errstr";
	if ( $errfile ) {
		$err .= " in $errfile";
		if ( $errline ) {
			$err .= ", line $errline";
		}
	}
	$err .= ".\n";
	die( $err );
}, E_WARNING | E_NOTICE | E_USER_WARNING | E_USER_NOTICE );<commit_msg>Make warnings_as_errors role throw exceptions<commit_after>set_error_handler( function( $errno, $errstr, $errfile, $errline, $errcontext ) {
	throw new ErrorException( $errstr, $errno, E_ERROR, $errfile, $errline );
}, E_WARNING | E_NOTICE | E_USER_WARNING | E_USER_NOTICE );


{'fraction_non_alphanumeric': 0.16749585406301823, 'fraction_numerical': 0.0, 'mean_word_length': 4.921568627450981, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3833371', 'n_tokens_mistral': 236, 'n_tokens_neox': 229, 'n_words': 51}