<commit_before><?php
$config = null;
$clientConfig = null;
/* @var $clientConfig KalturaConfiguration */

require_once __DIR__ . '/init.php';

$kmcUrl = $clientConfig->serviceUrl . 'kmc';
$kmcHtmlContent = file_get_contents($kmcUrl);
if(!$kmcHtmlContent)
{
	echo "Fetching URL [$kmcUrl] failed\n";
	exit(-1);
}

$swfPaths = array(
	'/flash/kmc/login/' . $config['kmc']['login_version'] . '/login.swf',
	'/flash/kmc/' . $config['kmc']['version'] . '/kmc.swf',
);

foreach($swfPaths as $swfPath)
{
	$url = $clientConfig->serviceUrl . $swfPath;
	$ch = curl_init($url);
	curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
	curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
	curl_setopt($ch, CURLOPT_HEADER, true);
	curl_setopt($ch, CURLOPT_NOBODY, true);
	curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
	curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
	$content = curl_exec($ch);
	$code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
	if($code != 200)
	{
		echo "Fetching URL [$url] failed with HTTP error code [$code]\n";<commit_msg>Update get_kmc_swfs.php<commit_after><?php
$config = null;
$clientConfig = null;
/* @var $clientConfig KalturaConfiguration */

require_once __DIR__ . '/init.php';

$kmcUrl = $clientConfig->serviceUrl . 'kmc';
stream_wrapper_restore('http');
stream_wrapper_restore('https');
$kmcHtmlContent = file_get_contents($kmcUrl);
stream_wrapper_unregister('http');
stream_wrapper_unregister('https');
if(!$kmcHtmlContent)
{
	echo "Fetching URL [$kmcUrl] failed\n";
	exit(-1);
}

$swfPaths = array(
	'/flash/kmc/login/' . $config['kmc']['login_version'] . '/login.swf',
	'/flash/kmc/' . $config['kmc']['version'] . '/kmc.swf',
);

foreach($swfPaths as $swfPath)
{
	$url = $clientConfig->serviceUrl . $swfPath;
	$ch = curl_init($url);
	curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
	curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
	curl_setopt($ch, CURLOPT_HEADER, true);
	curl_setopt($ch, CURLOPT_NOBODY, true);
	curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
	curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
	$content = curl_exec($ch);
	$code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
	if($code != 200)
	{
		echo "Fetching URL [$url] failed with HTTP error code [$code]\n";
{'fraction_non_alphanumeric': 0.18102658111824016, 'fraction_numerical': 0.00458295142071494, 'mean_word_length': 6.301003344481606, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, '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': '7374821', 'n_tokens_mistral': 904, 'n_tokens_neox': 851, 'n_words': 152}