2021-10-11 16:52:03 +00:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
|
|
|
, python3
|
|
|
|
, mopidy
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-10-11 16:52:03 +00:00
|
|
|
python3.pkgs.buildPythonApplication rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "mopidy-youtube";
|
2021-10-04 12:37:57 +00:00
|
|
|
version = "3.4";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-10-11 16:52:03 +00:00
|
|
|
disabled = python3.pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-10-11 16:52:03 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "natumbri";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "0lm6nn926qkrwzvj64yracdixfrnv5zk243msjskrnlzkhgk01rk";
|
|
|
|
};
|
2020-05-29 06:06:01 +00:00
|
|
|
|
2021-10-11 16:52:03 +00:00
|
|
|
propagatedBuildInputs = with python3.pkgs; [
|
2021-10-04 12:37:57 +00:00
|
|
|
beautifulsoup4
|
|
|
|
cachetools
|
2021-10-11 16:52:03 +00:00
|
|
|
pykka
|
|
|
|
requests
|
2021-10-04 12:37:57 +00:00
|
|
|
youtube-dl
|
|
|
|
ytmusicapi
|
2021-10-11 16:52:03 +00:00
|
|
|
] ++ [
|
|
|
|
mopidy
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = with python3.pkgs; [
|
|
|
|
vcrpy
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# Test requires a YouTube API key
|
|
|
|
"test_get_default_config"
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTestPaths = [
|
|
|
|
# Fails with an import error
|
|
|
|
"tests/test_backend.py"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-10-11 16:52:03 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"mopidy_youtube"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Mopidy extension for playing music from YouTube";
|
2021-10-11 16:52:03 +00:00
|
|
|
homepage = "https://github.com/natumbri/mopidy-youtube";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.asl20;
|
2021-10-11 16:52:03 +00:00
|
|
|
maintainers = with maintainers; [ spwhitt ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|