<commit_before># xpyBuild - eXtensible Python-based Build System
#
# This module holds definitions that are used throughout the build system, and 
# typically all names from this module will be imported. 
#
# Copyright (c) 2013 - 2017 Software AG, Darmstadt, Germany and/or its licensors
#
#   Licensed under the Apache License, Version 2.0 (the "License");
#   you may not use this file except in compliance with the License.
#   You may obtain a copy of the License at
#
#       http://www.apache.org/licenses/LICENSE-2.0
#
#   Unless required by applicable law or agreed to in writing, software
#   distributed under the License is distributed on an "AS IS" BASIS,
#   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#   See the License for the specific language governing permissions and
#   limitations under the License.
#
# $Id: buildcommon.py 301527 2017-02-06 15:31:43Z matj $
#

import traceback, os, sys, locale, inspect


import platform

import logging
# do NOT define a 'log' variable here or targets will use it by mistake

from utils.flatten import flatten
from utils.fileutils import parsePropertiesFile

try:
	with open(os.path.join(os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))), "release.properties")) as f:
		_RELEASE_PROPERTIES=parsePropertiesFile(f)

	_XPYBUILD_VERSION = [value for (key, value, line) in _RELEASE_PROPERTIES if key == "VERSION"][0]
except:
	raise
	_XPYBUILD_VERSION = "<unknown>"



def include(file):<commit_msg>move logic for getting xpybuild version number into a function to avoid polluting the toplevel namespace of every module that imports buildcommon (which is all of them)<commit_after># xpyBuild - eXtensible Python-based Build System
#
# This module holds definitions that are used throughout the build system, and 
# typically all names from this module will be imported. 
#
# Copyright (c) 2013 - 2017 Software AG, Darmstadt, Germany and/or its licensors
#
#   Licensed under the Apache License, Version 2.0 (the "License");
#   you may not use this file except in compliance with the License.
#   You may obtain a copy of the License at
#
#       http://www.apache.org/licenses/LICENSE-2.0
#
#   Unless required by applicable law or agreed to in writing, software
#   distributed under the License is distributed on an "AS IS" BASIS,
#   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#   See the License for the specific language governing permissions and
#   limitations under the License.
#
# $Id: buildcommon.py 301527 2017-02-06 15:31:43Z matj $
#

import traceback, os, sys, locale, inspect


import platform

import logging
# do NOT define a 'log' variable here or targets will use it by mistake

from utils.flatten import flatten
from utils.fileutils import parsePropertiesFile

def __getXpybuildVersion():

	try:
		with open(os.path.join(os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))), "release.properties")) as f:
			_RELEASE_PROPERTIES=parsePropertiesFile(f)
	
		return [value for (key, value, line) in _RELEASE_PROPERTIES if key == "VERSION"][0]
	except Exception:
		raise
		return "<unknown>"
_XPYBUILD_VERSION = __getXpybuildVersion()



def include(file):
{'fraction_non_alphanumeric': 0.07990089811087024, 'fraction_numerical': 0.020439764633013318, 'mean_word_length': 4.47457627118644, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '2075262', 'n_tokens_mistral': 982, 'n_tokens_neox': 921, 'n_words': 386}