2018-08-07 09:36:23 +01:00
|
|
|
{ lib, buildPythonPackage, fetchPypi
|
|
|
|
, requests, cryptography, pybrowserid, hawkauthlib, six
|
2020-08-16 07:13:50 +01:00
|
|
|
, grequests, mock, responses, pytest, pyjwt }:
|
2018-08-07 09:36:23 +01:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "PyFxA";
|
2020-07-31 09:56:44 +01:00
|
|
|
version = "0.7.7";
|
2018-08-07 09:36:23 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-07-31 09:56:44 +01:00
|
|
|
sha256 = "6c85cd08cf05f7138dee1cf2a8a1d68fd428b7b5ad488917c70a2a763d651cdb";
|
2018-08-07 09:36:23 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
# Requires network access
|
|
|
|
rm fxa/tests/test_core.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2020-08-16 07:13:50 +01:00
|
|
|
pyjwt requests cryptography pybrowserid hawkauthlib six
|
2018-08-07 09:36:23 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
2019-12-02 18:59:52 +00:00
|
|
|
grequests mock responses pytest
|
2018-08-07 09:36:23 +01:00
|
|
|
];
|
|
|
|
|
2020-08-16 07:13:50 +01:00
|
|
|
# test_oath is mostly network calls
|
2019-12-02 18:59:52 +00:00
|
|
|
checkPhase = ''
|
2020-08-16 07:13:50 +01:00
|
|
|
pytest --ignore=fxa/tests/test_oauth.py
|
2019-12-02 18:59:52 +00:00
|
|
|
'';
|
|
|
|
|
2018-08-07 09:36:23 +01:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Firefox Accounts client library for Python";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/mozilla/PyFxA";
|
2018-08-07 09:36:23 +01:00
|
|
|
license = licenses.mpl20;
|
|
|
|
};
|
|
|
|
}
|