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