depot/third_party/nixpkgs/pkgs/development/python-modules/myfitnesspal/default.nix
Default email 22017988c6 Project import generated by Copybara.
GitOrigin-RevId: c777cdf5c564015d5f63b09cc93bef4178b19b01
2022-04-27 11:35:20 +02:00

69 lines
1.2 KiB
Nix

{ lib
, fetchPypi
, buildPythonPackage
, blessed
, keyring
, keyrings-alt
, lxml
, measurement
, python-dateutil
, requests
, rich
, typing-extensions
, pytestCheckHook
, mock
, nose
, pythonOlder
}:
buildPythonPackage rec {
pname = "myfitnesspal";
version = "1.17.0";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "sha256-UXFvKQtC44EvscYWXK7KI/do3U0wTWI3zKwvsRdzKrs=";
};
propagatedBuildInputs = [
blessed
keyring
keyrings-alt
lxml
measurement
python-dateutil
requests
rich
typing-extensions
];
checkInputs = [
mock
nose
pytestCheckHook
];
postPatch = ''
# Remove overly restrictive version constraints
sed -i -e "s/>=.*//" requirements.txt
'';
disabledTests = [
# Integration tests require an account to be set
"test_integration"
];
pythonImportsCheck = [
"myfitnesspal"
];
meta = with lib; {
description = "Python module to access meal tracking data stored in MyFitnessPal";
homepage = "https://github.com/coddingtonbear/python-myfitnesspal";
license = licenses.mit;
maintainers = with maintainers; [ bhipple ];
};
}