<commit_before># Used during module installation to prevent easy_install and python
# setup.py install/test from downloading

{ stdenv, python }:

stdenv.mkDerivation {
  name = "python-offline-distutils-${python.version}";

  buildInputs = [ python ];

  unpackPhase = "true";
  installPhase = ''
    dst="$out/lib/${python.libPrefix}"
    ensureDir $dst/distutils
    ln -s ${python}/lib/${python.libPrefix}/distutils/* $dst/distutils/
    cat <<EOF > $dst/distutils/distutils.cfg
[easy_install]
allow-hosts = None
EOF
  '';
}<commit_msg>fix offlineDistutils (#271), needs to be in a site-packages subdir<commit_after># Used during module installation to prevent easy_install and python
# setup.py install/test from downloading

{ stdenv, python }:

stdenv.mkDerivation {
  name = "python-offline-distutils-${python.version}";

  buildInputs = [ python ];

  unpackPhase = "true";
  installPhase = ''
    dst="$out/lib/${python.libPrefix}/site-packages"
    ensureDir $dst/distutils
    ln -s ${python}/lib/${python.libPrefix}/distutils/* $dst/distutils/
    cat <<EOF > $dst/distutils/distutils.cfg
[easy_install]
allow-hosts = None
EOF
  '';
}
{'fraction_non_alphanumeric': 0.14210985178727115, 'fraction_numerical': 0.0026155187445510027, 'mean_word_length': 4.147982062780269, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4042699', 'n_tokens_mistral': 385, 'n_tokens_neox': 373, 'n_words': 85}