2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2021-02-16 17:04:54 +00:00
|
|
|
, pythonOlder
|
|
|
|
, fetchPypi
|
2021-03-09 03:18:52 +00:00
|
|
|
, google-api-python-client
|
2021-02-16 17:04:54 +00:00
|
|
|
, google-auth-oauthlib
|
2020-04-24 23:36:52 +00:00
|
|
|
, jupyterhub
|
|
|
|
, mwoauth
|
|
|
|
, pyjwt
|
2021-02-16 17:04:54 +00:00
|
|
|
, pytest-asyncio
|
|
|
|
, pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
, requests-mock
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "oauthenticator";
|
2021-08-22 07:53:02 +00:00
|
|
|
version = "14.2.0";
|
2021-02-16 17:04:54 +00:00
|
|
|
disabled = pythonOlder "3.6";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-08-22 07:53:02 +00:00
|
|
|
sha256 = "4baa02ff2c159cbba06f8d07fe11a6e624285ca2f813b1258b4c68766c0ee46b";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-02-16 17:04:54 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
jupyterhub
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
2021-03-09 03:18:52 +00:00
|
|
|
google-api-python-client
|
2021-02-16 17:04:54 +00:00
|
|
|
google-auth-oauthlib
|
|
|
|
mwoauth
|
|
|
|
pyjwt
|
|
|
|
pytest-asyncio
|
|
|
|
pytestCheckHook
|
|
|
|
requests-mock
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-05-20 23:08:51 +00:00
|
|
|
disabledTests = [
|
|
|
|
# Test are outdated, https://github.com/jupyterhub/oauthenticator/issues/432
|
|
|
|
"test_azuread"
|
|
|
|
"test_mediawiki"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "oauthenticator" ];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Authenticate JupyterHub users with common OAuth providers, including GitHub, Bitbucket, and more.";
|
|
|
|
homepage = "https://github.com/jupyterhub/oauthenticator";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ ixxie ];
|
|
|
|
};
|
|
|
|
}
|