<commit_before>{ stdenv, fetchFromGitHub, python2Packages, makeWrapper, chromaprint }:

let
  pypkgs = python2Packages;
  pname = "puddletag";

in pypkgs.buildPythonApplication rec {
  name = "${pname}-${version}";
  version = "1.2.0";

  src = fetchFromGitHub {
    owner = "keithgg";
    repo = pname;
    rev = "v${version}";
    sha256 = "1g6wa91awy17z5b704yi9kfynnvfm9lkrvpfvwccscr1h8s3qmiz";
  };

  sourceRoot = "${pname}-v${version}-src/source";

  disabled = pypkgs.isPy3k; # work to support python 3 has not begun

  outputs = [ "out" ];

  propagatedBuildInputs = [ chromaprint ] ++ (with pypkgs; [
    configobj
    mutagen
    pyparsing
    pyqt4
  ]);

  doCheck = false;   # there are no tests
  dontStrip = true;  # we are not generating any binaries

  installPhase = ''
    siteDir=$(toPythonPath $out)
    mkdir -p $siteDir
    PYTHONPATH=$PYTHONPATH:$siteDir
    ${pypkgs.python.interpreter} setup.py install --prefix $out<commit_msg>puddletag: get rid of pypkgs variable<commit_after>{ stdenv, fetchFromGitHub, python2Packages, makeWrapper, chromaprint }:

let
  pname = "puddletag";

in python2Packages.buildPythonApplication rec {
  name = "${pname}-${version}";
  version = "1.2.0";

  src = fetchFromGitHub {
    owner = "keithgg";
    repo = pname;
    rev = "v${version}";
    sha256 = "1g6wa91awy17z5b704yi9kfynnvfm9lkrvpfvwccscr1h8s3qmiz";
  };

  sourceRoot = "${pname}-v${version}-src/source";

  disabled = python2Packages.isPy3k; # work to support python 3 has not begun

  propagatedBuildInputs = [ chromaprint ] ++ (with python2Packages; [
    configobj
    mutagen
    pyparsing
    pyqt4
  ]);

  doCheck = false;   # there are no tests
  dontStrip = true;  # we are not generating any binaries

  installPhase = ''
    siteDir=$(toPythonPath $out)
    mkdir -p $siteDir
    PYTHONPATH=$PYTHONPATH:$siteDir
    ${python2Packages.python.interpreter} setup.py install --prefix $out
{'fraction_non_alphanumeric': 0.12056367432150313, 'fraction_numerical': 0.02870563674321503, 'mean_word_length': 3.687041564792176, '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': '6193016', 'n_tokens_mistral': 747, 'n_tokens_neox': 709, 'n_words': 152}