<commit_before>{
  lib,
  buildPythonPackage,
  fetchPypi,
  inflection,
  ruamel_yaml,
  setuptools_scm,
  six,
  coreapi,
  djangorestframework,
}:

buildPythonPackage rec {
  pname = "drf-yasg";
  version = "1.20.0";

  src = fetchPypi {
    inherit pname version;
    sha256 = "d50f197c7f02545d0b736df88c6d5cf874f8fea2507ad85ad7de6ae5bf2d9e5a";
  };

  postPatch = ''
    # https://github.com/axnsan12/drf-yasg/pull/710
    substituteInPlace requirements/base.txt --replace packaging ""
  '';

  nativeBuildInputs = [
    setuptools_scm
  ];

  propagatedBuildInputs = [
    six
    inflection
    ruamel_yaml
    coreapi
    djangorestframework
  ];

  meta = with lib; {
    description = "Generation of Swagger/OpenAPI schemas for Django REST Framework";
    homepage = "https://github.com/axnsan12/drf-yasg";
    maintainers = with maintainers; [ ivegotasthma ];
    license = licenses.bsd3;
  };
}
<commit_msg>pythonPackages.drf-yasg: use pythonImportsCheck<commit_after>{ lib
, buildPythonPackage
, fetchPypi
, inflection
, ruamel_yaml
, setuptools_scm
, six
, coreapi
, djangorestframework
, pytestCheckHook
, pytest-django
, datadiff
}:

buildPythonPackage rec {
  pname = "drf-yasg";
  version = "1.20.0";

  src = fetchPypi {
    inherit pname version;
    sha256 = "d50f197c7f02545d0b736df88c6d5cf874f8fea2507ad85ad7de6ae5bf2d9e5a";
  };

  postPatch = ''
    # https://github.com/axnsan12/drf-yasg/pull/710
    substituteInPlace requirements/base.txt --replace packaging ""
  '';

  nativeBuildInputs = [
    setuptools_scm
  ];

  propagatedBuildInputs = [
    six
    inflection
    ruamel_yaml
    coreapi
    djangorestframework
  ];

  checkInputs = [
    pytestCheckHook
    pytest-django
    datadiff
  ];

  # ImportError: No module named 'testproj.settings'
  doCheck = false;

  pythonImportsCheck = [ "drf_yasg" ];

  meta = with lib; {
    description = "Generation of Swagger/OpenAPI schemas for Django REST Framework";
    homepage = "https://github.com/axnsan12/drf-yasg";
    maintainers = with maintainers; [ ivegotasthma ];
    license = licenses.bsd3;
  };
}

{'fraction_non_alphanumeric': 0.10315186246418338, 'fraction_numerical': 0.04775549188156638, 'mean_word_length': 3.4012605042016806, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, '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': '8402', 'n_tokens_mistral': 853, 'n_tokens_neox': 788, 'n_words': 132}