2019-10-31 18:19:05 +11:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, requests
|
|
|
|
, jinja2
|
|
|
|
, pillow
|
2021-05-04 11:43:07 +02:00
|
|
|
, dataclasses
|
|
|
|
, pythonOlder
|
2019-10-31 18:19:05 +11:00
|
|
|
, rasterio
|
|
|
|
, shapely
|
2020-11-19 01:09:49 +01:00
|
|
|
, ndjson
|
|
|
|
, backoff
|
2021-05-04 11:43:07 +02:00
|
|
|
, pydantic
|
2021-01-06 10:46:48 +01:00
|
|
|
, google-api-core
|
2021-01-06 11:25:27 +01:00
|
|
|
, backports-datetime-fromisoformat
|
2019-10-31 18:19:05 +11:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "labelbox";
|
2021-05-04 11:43:07 +02:00
|
|
|
version = "2.5.4";
|
|
|
|
disabled = pythonOlder "3.6";
|
2019-10-31 18:19:05 +11:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-05-04 11:43:07 +02:00
|
|
|
sha256 = "sha256-L1KjP8Yzx9adTK84+Nf9JnirT4p3D3lwulWw6W1L/88=";
|
2019-10-31 18:19:05 +11:00
|
|
|
};
|
|
|
|
|
2020-11-19 01:09:49 +01:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
jinja2 requests pillow rasterio shapely ndjson backoff
|
2021-05-04 11:43:07 +02:00
|
|
|
google-api-core backports-datetime-fromisoformat pydantic
|
2020-11-19 01:09:49 +01:00
|
|
|
];
|
2019-10-31 18:19:05 +11:00
|
|
|
|
2021-05-04 11:43:07 +02:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py --replace "pydantic==1.8" "pydantic>=1.8"
|
|
|
|
'';
|
|
|
|
|
2019-10-31 18:19:05 +11:00
|
|
|
# Test cases are not running on pypi or GitHub
|
2020-08-25 12:07:09 +10:00
|
|
|
doCheck = false;
|
2020-11-19 01:09:49 +01:00
|
|
|
pythonImportsCheck = [ "labelbox" ];
|
|
|
|
|
2019-10-31 18:19:05 +11:00
|
|
|
meta = with lib; {
|
2020-03-31 21:11:51 -04:00
|
|
|
homepage = "https://github.com/Labelbox/Labelbox";
|
2019-10-31 18:19:05 +11:00
|
|
|
description = "Platform API for LabelBox";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ rakesh4g ];
|
|
|
|
};
|
|
|
|
}
|