1a04744f74
There is no need to disable Python packages for Python versions that are
no longer in Nixpkgs.
This change was generated using the following script:
pattern='^\s*disabled\s*=\s*pythonOlder\s*"3\.\([0-9]\|10\)"\s*;\s*$'
for f in $(find -name '*.nix'); do
grep -q "$pattern" "$f" || continue
sed -i "/$pattern/d" "$f"
if [ $(grep -c pythonOlder "$f") == 1 ]; then
sed -i '/^\s*pythonOlder,\s*$/d' "$f"
fi
nixfmt "$f"
done
51 lines
944 B
Nix
51 lines
944 B
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
freezegun,
|
|
mock,
|
|
pytestCheckHook,
|
|
python-dateutil,
|
|
requests-mock,
|
|
requests-oauthlib,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "fitbit";
|
|
version = "0.3.1";
|
|
format = "setuptools";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "orcasgit";
|
|
repo = "python-fitbit";
|
|
rev = version;
|
|
hash = "sha256-1u3h47lRBrJ7EUWBl5+RLGW4KHHqXqqrXbboZdy7VPA=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace fitbit_tests/test_api.py \
|
|
--replace-fail assertRaisesRegexp assertRaisesRegex
|
|
'';
|
|
|
|
propagatedBuildInputs = [
|
|
python-dateutil
|
|
requests-oauthlib
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
freezegun
|
|
mock
|
|
pytestCheckHook
|
|
requests-mock
|
|
];
|
|
|
|
pythonImportsCheck = [ "fitbit" ];
|
|
|
|
meta = {
|
|
description = "Fitbit API Python Client Implementation";
|
|
homepage = "https://github.com/orcasgit/python-fitbit";
|
|
license = lib.licenses.asl20;
|
|
maintainers = [ ];
|
|
};
|
|
}
|