1{ 2 lib, 3 buildPythonPackage, 4 pythonOlder, 5 fetchFromGitHub, 6 setuptools, 7 beautifulsoup4, 8 lxml, 9 cssutils, 10 nltk, 11 pytest-lazy-fixture, 12 pytestCheckHook, 13}: 14 15buildPythonPackage rec { 16 pname = "pycaption"; 17 version = "2.2.7"; 18 19 disabled = pythonOlder "3.8"; 20 21 pyproject = true; 22 23 src = fetchFromGitHub { 24 owner = "pbs"; 25 repo = "pycaption"; 26 rev = "refs/tags/${version}"; 27 hash = "sha256-0rh8w4zQN5qAIPwnm7FO6VyPxMdutYFflpY+xWdEm3M="; 28 }; 29 30 nativeBuildInputs = [ setuptools ]; 31 32 propagatedBuildInputs = [ 33 beautifulsoup4 34 lxml 35 cssutils 36 ]; 37 38 passthru.optional-dependencies = { 39 transcript = [ nltk ]; 40 }; 41 42 nativeCheckInputs = [ 43 pytest-lazy-fixture 44 pytestCheckHook 45 ]; 46 47 meta = with lib; { 48 changelog = "https://github.com/pbs/pycaption/blob/${version}/docs/changelog.rst"; 49 description = "Closed caption converter"; 50 homepage = "https://github.com/pbs/pycaption"; 51 license = licenses.asl20; 52 maintainers = with maintainers; [ dotlambda ]; 53 }; 54}