1{ lib
2, buildPythonPackage
3, fetchPypi
4, pytestCheckHook
5}:
6
7buildPythonPackage rec {
8 pname = "python-crfsuite";
9 version = "0.9.7";
10 format = "setuptools";
11
12 src = fetchPypi {
13 inherit pname version;
14 sha256 = "1ryfcdfpqbrf8rcd2rlay2gfiba3px3q508543jf81shrv93hi9v";
15 };
16
17 preCheck = ''
18 # make sure import the built version, not the source one
19 rm -r pycrfsuite
20 '';
21
22 checkInputs = [
23 pytestCheckHook
24 ];
25
26 pythonImportsCheck = [
27 "pycrfsuite"
28 ];
29
30 meta = with lib; {
31 description = "Python binding for CRFsuite";
32 homepage = "https://github.com/scrapinghub/python-crfsuite";
33 license = licenses.mit;
34 maintainers = teams.tts.members;
35 };
36}