2021-01-09 10:05:03 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, pythonOlder
|
2020-04-24 23:36:52 +00:00
|
|
|
, attrs
|
|
|
|
, audio-metadata
|
|
|
|
, importlib-metadata
|
|
|
|
, marshmallow
|
|
|
|
, pendulum
|
|
|
|
, protobuf
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "google-music-proto";
|
2020-06-15 15:56:04 +00:00
|
|
|
version = "2.10.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-06-15 15:56:04 +00:00
|
|
|
sha256 = "91b78c0de4f59b1e5503fd6d49cb3fec029d9199cca0794c87667e643342e987";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
sed -i -e "/audio-metadata/c\'audio-metadata'," -e "/marshmallow/c\'marshmallow'," setup.py
|
2020-07-18 16:06:22 +00:00
|
|
|
substituteInPlace setup.py \
|
2021-01-09 10:05:03 +00:00
|
|
|
--replace "'attrs>=18.2,<19.4'" "'attrs'"
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
attrs
|
|
|
|
audio-metadata
|
|
|
|
marshmallow
|
|
|
|
pendulum
|
|
|
|
protobuf
|
|
|
|
] ++ lib.optionals (pythonOlder "3.8") [
|
|
|
|
importlib-metadata
|
|
|
|
];
|
|
|
|
|
|
|
|
# No tests
|
|
|
|
doCheck = false;
|
|
|
|
pythonImportsCheck = [ "google_music_proto" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/thebigmunch/google-music-proto";
|
|
|
|
description = "Sans-I/O wrapper of Google Music API calls";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ jakewaksbaum ];
|
|
|
|
};
|
|
|
|
}
|