1{ lib
2, betamax
3, buildPythonPackage
4, cachetools
5, coloredlogs
6, emoji
7, fetchPypi
8, nose
9, python
10, pythonOlder
11, pytz
12, requests
13}:
14
15buildPythonPackage rec {
16 pname = "locationsharinglib";
17 version = "4.1.6";
18 disabled = pythonOlder "3.6";
19
20 src = fetchPypi {
21 inherit pname version;
22 sha256 = "092j8z01nwjqh5zr7aj8mxl1zjd3j2irhrs39dhn47bd6db2a6ij";
23 };
24
25 propagatedBuildInputs = [
26 coloredlogs
27 requests
28 cachetools
29 pytz
30 ];
31
32 checkInputs = [
33 betamax
34 emoji
35 nose
36 ];
37
38 postPatch = ''
39 # Tests requirements want to pull in multiple modules which we don't need
40 substituteInPlace setup.py \
41 --replace "tests_require=test_requirements" "tests_require=[]"
42 '';
43
44 checkPhase = ''
45 runHook preCheck
46 # Only coverage no real unit tests
47 ${python.interpreter} setup.py nosetests
48 runHook postCheck
49 '';
50
51 pythonImportsCheck = [ "locationsharinglib" ];
52
53 meta = with lib; {
54 description = "Python package to retrieve coordinates from a Google account";
55 homepage = "https://locationsharinglib.readthedocs.io/";
56 license = licenses.mit;
57 maintainers = with maintainers; [ fab ];
58 };
59}