about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/tuya-device-sharing-sdk/default.nix
blob: dd95baba855d471a43615b3ac14ab3e347bc164f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
{ lib
, buildPythonPackage
, fetchPypi
, setuptools
, requests
, paho-mqtt
, cryptography
}:
let
  pname = "tuya-device-sharing-sdk";
  version = "0.2.0";
in
buildPythonPackage {
  inherit pname version;

  src = fetchPypi {
    inherit pname version;
    hash = "sha256-fu8zh59wlnxtstNbNL8mIm10tiXy22oPbi6oUy5x8c8=";
  };

  # workaround needed, upstream issue: https://github.com/tuya/tuya-device-sharing-sdk/issues/10
  postPatch = ''
    touch requirements.txt
  '';

  build-system = [
    setuptools
  ];

  dependencies = [
    requests
    paho-mqtt
    cryptography
  ];

  doCheck = false; # no tests

  meta = with lib; {
    description = "Tuya Device Sharing SDK";
    homepage = "https://github.com/tuya/tuya-device-sharing-sdk";
    license = licenses.mit;
    maintainers = with maintainers; [ aciceri ];
  };
}