<commit_before>min_version = v"3.0"

try
    @pyimport yt
    yt_version = convert(VersionNumber, yt.__version__)
    if yt_version < min_version
        println("Your version of yt is not up to date. You need at least version $min_version")
    end
catch import_err
    println("yt is not installed with the Python that is in the current path.")
end<commit_msg>More iterations on throwing build errors<commit_after>import PyCall: @pyimport

min_version = v"3.0"

try
    @pyimport yt
catch
    throw(ErrorException("Cannot import import yt! Is it installed in the current Python?"))
end

@pyimport yt
yt_version = convert(VersionNumber, yt.__version__)
if yt_version < min_version
    err_msg = ("Your version of yt is not up to date. " *
               "You need at least version $min_version, " *
               "but your current version is $yt_version.")
    throw(ErrorException(err_msg))
end
{'fraction_non_alphanumeric': 0.07803790412486064, 'fraction_numerical': 0.004459308807134894, 'mean_word_length': 3.5583756345177666, 'pattern_counts': {'":': 0, '<': 5, '<?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': '4350071', 'n_tokens_mistral': 274, 'n_tokens_neox': 269, 'n_words': 100}