1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 pytestCheckHook,
6 pythonOlder,
7 flit-core,
8 requests,
9 tomli,
10}:
11
12buildPythonPackage rec {
13 pname = "wn";
14 version = "0.9.5";
15 pyproject = true;
16
17 disabled = pythonOlder "3.8";
18
19 src = fetchPypi {
20 inherit pname version;
21 hash = "sha256-muYuDmYH9W5j6euDYJMMgzfsxE6eBIhDCqH6P7nFG+Q=";
22 };
23
24 nativeBuildInputs = [ flit-core ];
25
26 propagatedBuildInputs = [
27 requests
28 tomli
29 ];
30
31 nativeCheckInputs = [ pytestCheckHook ];
32
33 preCheck = ''
34 export HOME=$(mktemp -d)
35 '';
36
37 pythonImportsCheck = [ "wn" ];
38
39 meta = with lib; {
40 description = "Modern, interlingual wordnet interface for Python";
41 homepage = "https://github.com/goodmami/wn";
42 changelog = "https://github.com/goodmami/wn/blob/v${version}/CHANGELOG.md";
43 license = licenses.mit;
44 maintainers = with maintainers; [ zendo ];
45 };
46}